28029 Parallax Inc, 28029 Datasheet - Page 227

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
The
enter into the Debug Terminal's Transmit windowpane.
subroutine will be modified to store accelerometer readings instead. The
again starts at
through the loop, the
Terminal's Transmit windowpane and stores it in the EEPROM address selected by
eeIndex
To retrieve and display the values that were stored, the
FOR
...
Record_Data
NEXT
Clear_Data:
Record_Data:
with
Saving space with value = value + 100
Before each value variables’ content is copied to EEPROM, 100 is added to it. So instead
of a value between −100 and 100, a value between 0 and 200 is stored in the EEPROM.
This is because each EEPROM memory cell can store a byte-sized value between 0 and
255. Storing negative numbers would require word-sized storage.
Word-size values can also be stored with
before the
that this command uses two EEPROM bytes to store the word-size value, so
have to be incremented by 2 before the next value is written. By adding 100, we’ve saved
one byte-sized cell per write.
FOR eeIndex = Records TO RecordsEnd
NEXT
DEBUG CR, "Records cleared."
PAUSE 1000
RETURN
DEBUG CR, "Enter values from -100 to 100", CR
FOR eeIndex = Records TO RecordsEnd
NEXT
DEBUG CR, "End of records.",
DEBUGIN char
RETURN
loop with
WRITE eeIndex, 100
DEBUG "Record ", DEC eeIndex, " >"
DEBUGIN SDEC value
value = value + 100
WRITE eeIndex, value
WRITE eeIndex, value
Records
CR, "Press Enter for menu..."
subroutine in the next example program collects the values that you
DataItem
READ eeIndex, value
value
and repeats until
variable receives a signed decimal number from the Debug
. For example
.
WRITE eeIndex, Word value
eeIndex
. Since 100 was added to each value before
DATA
Chapter 6: Accelerometer Projects · Page 215
directives if you place the
exceeds
Display_Data
In the next activity, this
RecordsEnd
subroutine has a
FOR
. Keep in mind
Word
eeIndex
. Each time
...
NEXT
modifier
loop
will

Related parts for 28029