Shop OBEX P1 Docs P2 Docs Learn Events
Can BS2 do it? — Parallax Forums

Can BS2 do it?

ClarkHClarkH Posts: 1
edited 2010-01-02 18:18 in BASIC Stamp
I am new to the basic stamp.· I have this problem to solve.· Can the BS2 do it?
Inputs:
Auto/Manual Switch
8-bit parallel 2- byte data input ( Enable, clock, data(8) )
Knob generates pulse trains for positive and negative rotation on 2 separate inputs, 16 pulses/rotation
Auto Mode:
····· Input data goes into 16-bit binary register.
····· Knob rotation pulses ignored
Manual Mode:
····· Knob rotation pulses increment or decrement 16-bit register
····· Parallel input data ignored
Both Modes:
····· A change in register content· initiates
····· (1)a serial 24 bit output (ASCII code for “C” + register content)
····· (2)1 x 16 LCD display shows decimal value of (register content x 8)
··········· For example, a decimal value of 74124 would result in a display of··74.124 000 000· ( zeros, spaces, and decimal point are fixed)

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2010-01-02 18:18
    You will need some kind of parallel data register if you're going to use a BS2 since that has only 16 I/O pins. A pair of 74HC165 serial shift registers will work well and there's plenty of sample code showing how to use them. You could also use a BS2p40 which has 32 I/O pins in two banks of 16 each. A BS2 could handle input change rates on the order of 100/second (16 bit value changes or knob pulses).
Sign In or Register to comment.