28129 Parallax Inc, 28129 Datasheet - Page 156
28129
Manufacturer Part Number
28129
Description
TEXT BASIC ANALOG & DIGITAL
Manufacturer
Parallax Inc
Type
Programmingr
Datasheet
1.28129.pdf
(176 pages)
Specifications of 28129
Style
Book
Title
Basic Analog and Digital
Contents
Basic Analog and Digital Text
Product
Microcontroller Accessories
Lead Free Status / RoHS Status
Not applicable / Not applicable
- Current page: 156 of 176
- Download datasheet (3Mb)
Then
Program It
Enter Program 8.1 in your BASIC Stamp Editor, and download to the BASIC Stamp.
' Basic Analog and Digital - PL8_1R0.bs2
' Program Listing 8.1 Revision 0.
' {$STAMP BS2}
' {$PBASIC 2.5}
light
dischargeTime
sound
a
DO
LOOP
The Output
The piezoelectric speaker should beep every half second or so. If you put your hand over
the circuit to shade it, the tone of the beep should get lower. If you face your breadboard
directly at a light in the room, the pitch should get higher. Figure 8-5 a sample output for
a well-lit room.
HIGH 15
PAUSE 100
RCTIME 15, 1, light
dischargeTime = light * 2
sound = (65535 - light) / a
FREQOUT 7, 500, sound
DEBUG HOME
DEBUG "Discharge time = ", DEC5 dischargeTime, " u-seconds."
DEBUG CR, CR, "Sound Frequency = ", DEC5 sound, " Hz."
PAUSE 500
RCTIME
RCTIME 15, 1, light
takes care of the time measurement and data storage.
VAR
VAR
VAR
CON
Word
Word
Word
40
Related parts for 28129
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
Part Number:
Description:
Microcontroller Modules & Accessories DISCONTINUED BY PARALLAX
Manufacturer:
Parallax Inc
Part Number:
Description:
BOOK UNDERSTANDING SIGNALS
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
COMPETITION RING FOR SUMOBOT
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
TEXT INFRARED REMOTE FOR BOE-BOT
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
BOARD EXPERIMENT+LCD NX-1000
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
CONTROLLER 16SERVO MOTOR CONTROL
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
BASIC STAMP LOGIC ANALYZER
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
IC MCU 2K FLASH 50MHZ SO-18
Manufacturer:
Parallax Inc
Datasheet: