|
Hi,
I've written a small Visual Basic program so I can use Cybermaster under
Windows 3.1x. (So I cannot use spirit.ocx.)
Sending commands works (motor on/off, sound, etc.). But I don't get any
echo. I cannot get any sensor data, and I can't see if my commands are
correctly received by the Spirit unit.
I use mscomm.vbx for communicating with the RC tower:
' 2400 baud, odd parity, 8 data bits, 1 stop bit:
Comm1.Settings = "2400,o,8,1"
' setting InputLen to 1 or 15 doesn't seem to change anything:
Comm1.InputLen = 0
' opening port:
Comm1.PortOpen = True
' setting flags:
Comm1.DTREnable = True ' set dtr
Comm1.RTSEnable = True ' set rts
Comm1.CDHolding = False ' set cd
Comm1.CTSHolding = False ' set cts
Comm1.DSRHolding = False ' set dsr
The Spirit unit seems to send something (LED flashes) but the RC tower
doesn't receive anything (no LED activity unless it's sending).
When I connect to a modem, receiving data works (e.g. 'OK.' after 'AT').
BTW, of course the Cybermaster CD works, too (e.g. Arena reacts to punches
on sensors and Garage can read battery power)
BTW, another problem: When I send to commands in a row the second is not
understood by the Spirit unit until I have a pause of about 100 ms between
two commands.
Does anybody have a suggestion?
TIA,
Oliver
|
|
Message has 1 Reply:
Message is in Reply To:
| | Re: reading sensors on CM
|
| Hi :) [Note1: CM = CyberMaster; pBrick = { CM | RCX | Scout | RCX2 } ] [Note2: I think this could be usefull to others = CC:lego-robotics] [Note3: I'm showing source code done by Mark Overmars = CC:markov+lego] Well, all my PC apps were done with (...) (24 years ago, 3-Jan-01, to lugnet.robotics)
|
6 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|