France
Asked — Edited

Roli H-Bridge Question Too

Hi,

I have a probleme with my Roli h-bridge.

I checked my connections like explained in those posts : https://synthiam.com/Tutorials/Lesson/44 https://synthiam.com/Community/Questions/6809&page=2

My h-bridge was initially connected like the wrong way as here :

User-inserted image

Now when I open the exemple project from roli in ARC , if I want to go forward, only the right motor is going forward (nok), if I want to go right, only right motor is going backward (nok), if I want to go backward, the two motors are going backward (ok), if I want go left, left motor is going backard, right motor is going forward (ok).

I don't know where is my mistake.

Thanks


ARC Pro

Upgrade to ARC Pro

Subscribe to ARC Pro, and your robot will become a canvas for your imagination, limited only by your creativity.

PRO
Synthiam
#9  

Did you set the pwm speed?

Modifying the project did you accidentally miss the speed initialization script for the hbridge in the connection control?

France
#10  

here is the init script :

# This is the initialization script for your Roli robot
# This script is called from the Connection Control when a connection
# is made to the Roli EZ-B

# Move the servos into the calibration position
# All servos will be set to 90 degrees
ControlCommand("Auto Position", AutoPositionFrameJump, "Calibrate")

# Pause for a brief period of time to ensure the servos have been initialized
sleep(500)

# We want the arm and neck servos to move smoothly
# To do this, we will set the speed of each servo
# The speed is how quickly a servo will move between positions
# We set a variable for the speed, and then use that variable for
# every speed command.
# This is an effecient way to reuse a value numerous times
$speed = 1

servospeed(d12, $speed)
servospeed(d13, $speed)
servospeed(d14, $speed)
servospeed(d15, $speed)
servospeed(d16, $speed)
servospeed(d17, $speed)
servospeed(d18, $speed)
servospeed(d19, $speed)

# This sets the speed for the HBridge Motor Controller
# The speed is a number between 0 and 255
# Setting this speed will initialize the PWM on the motor controller
SetSpeed(255)

# Even though we set the speed, we will also enable the PWM
# on the speed pins that connect to the HBridge Motor Controller
# The number is 100, which means 100%
pwm(d0, 100)
pwm(d5, 100)
France
#11  

Hello,

Sorry, I did not have time to see my problem.

Maybe I could during the Christmas holiday;)