Welcome to Synthiam!

Program robots using technologies created from industry experts. ARC is our free-to-use robot programming software that makes features like vision recognition, navigation and artificial intelligence easy.

Get Started
Asked — Edited

Communication Between Ezb4/2 And Parallax Dhb-10 Motor Board

I am building my robot by starting with an Arlo base. I am using the new DHB-10 drive board that takes the place of the HB25 drives. The board accepts serial commands on what is label CH1. The board has it's own processor and is pre loaded firmware commands that can be issued by its serial port.

I want to issue these commands from my EZB4/2. I am powering the EZB from the 6.5vdc regulated power provided by the parallax power distribution board. The DHB-10 board receives 12 VDC from the same source. They should have a common ground.

I did the following:
1. Ran wire from port 0 on the EZB to channel 1 on the DHB-10. On the DHB-10 end only the signal and ground are used.

2. I wrote a script as follows:
SendSerial(do,115200,"GOSPD 20000 20000")

3. The EZB ran the script successfully

4. The DHB reacted. It has a status light for each motor that flashes until it detects a received command.

5. The motors did not respond.

I would appreciate any comments on what I did wrong and to know if someone else has done this.

AI Support Bot
Related Content
Synthiam
PRO
USA
#1  
if you read the documentation:
https://www.parallax.com/sites/default/files/downloads/28231-DHB-10-Motor-Controller-Guide-v1.0.pdf

page 5:

Quote:


Serial Under a default configuration, connect a bidirectional serial port at 19,200 kilobaud, to CH1. For different baud rates or separate transmit and receive pins, see the BAUD and RXPIN commands.


the default communication is 19200 bauds and you are using 115200

although is possible to communicate at 115200 you need to send a BAUD command at 19200 bauds to change to 115200, and only then you can communicate at 115200.

I think 19200 is enough for short message commands.

if you look the existent examples:
http://learn.parallax.com/tutorials/robot/arlo/arlo-activity-board-brain/control-activity-board-arlo-serial-messages

you need a line terminator i.e. character: \r byte: 13

to summarize:

Code:


SendSerial(D0, 19200, "GOSPD 20000 2000", 13)


I had only an issue with an older serial chip, but the documentation mentions:

Quote:


connect a bidirectional serial


I would connect the RX line too, is not a problem per se, but it can help to troubleshot DHB-10 feedback.

don't forget the common GND, connect a GND from EZ-B to the DHB-10 GND board.
#2  
Thanks for your input. I did see the 9200 baud rate. That is what I tried first with no results. I then notice that in the Arlo tutorial I did about their serial terminal sending commands to the board they showed a 115200 buad rate in their screen shot. I could not make it work with either baud rate. I will try the code you suggested. Thanks again.
#3  
Thanks again ptp. I ran your code and it worked perfectly. As to the ground, I thought since both boards are supplied from the same power distribution board which is feed from the same bank of batteries they would have a common ground.
PRO
USA
#4  

Quote:


As to the ground, I thought since both boards are supplied from the same power distribution board which is feed from the same bank of batteries they would have a common ground.


Yes, you are correct.

Although some switch voltage regulators have complex circuits, and/or some particular cases the output lines are isolated.
#5  
This is what makes robotics interesting. Last night I ran the code ptp gave me and it ran perfectly. I shut down the power to the robot and laptop for the night.

This morning I started the robot and laptop and executed the same script. EZB ran the script successfully but once again the motors didn't respond. I check the board out by connecting it to the parallax board and it runs fine. I also checked for continuity between the EZB ground and the DHB-10. They have a common ground.

I am trying find out what happened overnight.
#6  
I found out what happened last night. When I plugged my external speaker to the EZB I heard "my battery is low which stops I/o activity.

I am using 2 lead acid batteries in parallel. So I disabled the low battery alarm. Now my EZB4 will run at 6.4 volts.

So for now all is well.

Thanks again "ptp" i appreciate help.

Dave