View Full Version : Tx Rx Code questions and concerns (class Final Project)

11-16-2006, 05:28 AM
Some of the questions that i have are:
· How much data can be transmitted?
· Different baud rates..???
· Sync'ing up?
· The reason for all these questions is the project is a Remote control(one basic stamp2) is gonna control a "car"(the other basic stamp2)·by sending data to control one unipolar stepper(the drive wheels) and one servo motor(directional wheels).
· I know i gotta send direction, step speed, and other parameters for the stepper and just a pulse value for the servo. Other than that alot of misc questions arise. My stepper motor is from jameco pt# 237745 and the driver is also from jameco pt# 141532. The reason i choose that driver is because it has more functions like free spinning, half or full stepping, two ways of driving the stepper, and is bi-directional.
· I know i am asking alot from the forum but any help would be most appreciated.

11-16-2006, 10:56 AM
Another question arises is that if you can run two servos at the same time· just w/ the chip alone

11-16-2006, 09:52 PM
Some related questions:

Is the 'remote control' going to be implemented using a hard-wired connection, an RF remote, or an IR remote? Each has different speeds.

You CAN run two servos at the same time, since the servo control signal is a 1 mSec to 2 mSec 'pulse', repeated every 20 msec. So you can pulse servo 1, then pulse servo 2, then wait 18 mSec and repeat. However, one of your motors is a 'stepper' motor -- I don't think there's any 'dead time' in a stepper motor's control signals for you to send the Servo control signal. Using the 'driver' may free up the BS2, though.

11-21-2006, 07:45 AM
i changed the design to (2) stepper motors.· i am using the parallax transeiver kit· which uses rf· there is a bug that might hit if something goes wrong.. see code

'Tx Part

(replace this text with your code)
'Tx Part
i VAR Byte
wallData VAR Byte

FOR i = 0 TO 7
PULSOUT 15,1200
SEROUT 15,16486,["!",i]
SERIN 14,16486,[WAIT("?"),wallData]
debug bin wallData.LOWNIB
pause 200
GOTO start

'Rx Part
i VAR Byte 'counter
stepData VAR Byte
sense VAR Byte

FOR i = 0 to 7
SERIN 14,16486,[WAIT("!"),sense]
DEBUG CLS,?sense
SEROUT 15,16486,["?",wallData]
GOTO start

what i see wrong is that if the Rx part misses the transmission both codes are waiting for something that will never come.

Rx would be waiting for "!"

Tx would be waiting for "?"

any solutions??