28029 Parallax Inc, 28029 Datasheet - Page 200

KIT PARTS SMART SENSORS W/TEXT

28029

Manufacturer Part Number
28029
Description
KIT PARTS SMART SENSORS W/TEXT
Manufacturer
Parallax Inc
Datasheet

Specifications of 28029

Accessory Type
Parts Kit
Product
Microcontroller Accessories
Lead Free Status / RoHS Status
Contains lead / RoHS non-compliant
For Use With/related Products
BASIC Stamp® or Javelin Modules
Lead Free Status / RoHS Status
Lead free / RoHS Compliant, Contains lead / RoHS non-compliant
Other names
28029PAR
Page 188 · Smart Sensors and Applications
Animation and Redrawing the Background
Here is an example of something you can do if you use individual characters, but it won't
work if you try to redraw the entire display with a
ACTIVITY #3: TILT THE BUBBLE GRAPH
This activity combines the graphics concepts introduced in Activities #1 and #2 with the
accelerometer tilt measurement techniques introduced in Chapter 3. The result is an
asterisk “bubble” that illustrates the movement of the heated gas pocket inside the
MX2125’s chamber. Figure 5-11 on the next page shows what the Debug Terminal in
this activity displays when the accelerometer is tilted up and to the left.
Parts Required
(2) 3-inch Jumper Wires
(2) Resistors – 220 Ω
(1) Memsic MX2125 Dual-Axis Accelerometer
Save EepromBackgroundRefresh.bs2 as ExampleAnimation.bs2.
Replace the Main Routine in the program with the one shown here.
Run it and observe the effect.
DO
LOOP
Connect the accelerometer module using Figure 5-10 as your guide.
FOR y = 0 TO 6
NEXT
FOR temp = 1 TO 2
NEXT
FOR x = 0 TO 12
NEXT
IF (temp.BIT0 = 1) THEN
ELSE
ENDIF
PAUSE 50
DEBUG CRSRXY, x, y, "*"
index = (14 * yOld) + xOld + 1
READ index, character
DEBUG CRSRXY, xOld, yOld, character
xOld = x
yOld = y
DEBUG
command.

Related parts for 28029