Click on image to download 1MB MPEG |
|
The following example application
uses the TR2 Rover connected to a Remote WCM. The Local WCM is connected
to a PC running the PC-WCM Terminal program1.
This example demonstrates an improved servo sweep from the TR1 Rover
with servo sweep example. The new improved program allows the rover
to continuously move forward while the servo sweep motion occurs.
When an obstruction is encountered, the rover stops, moves backwards,
then looks left and right. It decides which is the clearest way, then
moves in that direction.
The addition of the WCMs means a remote link can be made from
a computer to the TR2 enabling a manual control mode to override the
autonomous mode.
By using the PC-WCM Terminal program1
to send values to the remote WCM, control of the rover can be achieved
in situations where the rover has got stuck, or does not go in the
direction the user wants it too.
Download PC to WCM Interface software
WCM
Win98SE interface for Windows 98 & below (1.5Mb)
WCM
interface for XP, NT, 2000 & Windows ME (2.1Mb)
PC-WCM page set up
Enter COM port and open it.
WCM Address = 00
Remote Node Address = 02
Local Node Address = 00
Timeout Value (adjust as necessary)
Data to Remote (see 2)
Local IO Direction = 0
Local IO Data = 0
Remote IO Data = 0
The Data to Remote is the value that is sent to the remote WCM on
the TR2. To enable manual override, decimal 90 should
be entered in Data to Remote and then Write
pressed on the terminal. The rover will stop and wait for instruction.
TR2 commands
Right = 25
Left = 50
Forward = 75
Stop = 100
Backward = 125
Send these in any order to manipulate the TR2. When you want to return
the rover back to autonomous mode, send decimal 150 and
the TR2 rover will return to this state.
Connections
WCM (Remote)
Connect the WCM I2C Input to the I2C Bus on the DS-SXM16S module.
(Just connect SCL, SDA and GND)
WCM Power can also be taken from the DS-SXM16S module.
Address Jumpers set to 00 (see WCM data sheet).
Pull up Jumpers not set (pull ups not used).
WCM (Local)
RS232 Interface cable (DS-W232CAB) 6-pin header connected to RS232
COM port.
(RS232 DB9F connected to computer port (take note of which port)).
6-16VDC-battery supply connected to power pins.
TR2 Rover
Connected as shown in TR2 Rover Data Sheet.
1WCM-PC Terminal
written by Tony Brenke (OOPic.Com).
Not to be used commercially without permission. |
|