PDA

View Full Version : Solved POV demo for the Demo board?



ProcessingData...
10-18-2011, 12:04 AM
I recall there being an object that used the Built-on LEDs on the Demoboard for a simple POV display.

Does anyone still have a link to the thread or code?

Thanks,

ProccessingData...

WBA Consulting
10-18-2011, 12:10 AM
Post#12 on this thread. (http://forums.parallax.com/showthread.php?83915) Coded by Beau Schwabe


''************************************************ ********************************
''** Fun example uses the LED's on the demo board to display a bitmap **
''** pattern stored in a data table **
''************************************************ ********************************
'' Coded by Beau Schwabe (Parallax). **
''************************************************ ********************************
''
'' Directions:
'' Load the program. LED's will appear to ALL be on.
'' Rapidly move the demo board back-n-forth.
'' (unplug USB2SER connector first-grin
''
''
'' Other options to this program would be to use an accelerometer
'' to determine which direction/speed you are moving, and display
'' an actual message forward or backward accordingly.
_xinfreq = 5_000_000 'Set crystal frequency to 5 MHz
_clkmode = xtal1 + pll16x 'wind it up to 80 MHz via a X16 PLL

CON
Rate = 50_000 'Set motion rate.

VAR

PUB Message | scan
dira[16..23] := %11111111 'Make I/O's 16 to 23 OUTPUTs

repeat 'Enter Endless Loop
repeat scan from 0 to 26 'Create an offset index from 0 to 26
outa[16..23] := Propeller[scan] 'Lookup byte value in data table at offset 'scan'
waitcnt(Rate + cnt) 'pause so we can see something

DAT
Propeller byte %00000000
byte %00010000
byte %00111000
byte %01111100
byte %11111110
byte %01111100
byte %00111000
byte %00010000
byte %00000000

byte %00000000
byte %11111111
byte %10000001
byte %10000001
byte %10000001
byte %11111111
byte %00000000

byte %00000000
byte %10000000
byte %01000000
byte %00110000
byte %00011000
byte %00000111
byte %00011000
byte %00110000
byte %01000000
byte %10000000
byte %00000000

WBA Consulting
10-18-2011, 12:12 AM
PS, it is easy to find if you use the Google "site restricted search". Type the following into a Google search box......


pov demo board site:forums.parallax.com