Closed photodude closed 9 years ago
Hi, @photodude.
You are doing something pretty advanced by using two shields and a servo at the same time. I do not think this qualifies as an issue with the library as currently described. Can you post more information about your setup, including your code, on the Pololu forum and we can look into it more?
Ryan
Hi, @ryantm my setup maybe "pretty advanced" but is fairly simple still. (Mega 2560 + two dual-vnh5019-motor-shield + xbee shield + 1 servo) I'm using the dual-vnh5019-motor-shield library, the standard arduino servo.h library, Arduino IDE 1.6.3, and serial3 for the xbee. We found a temporary "work around" for the servo issue by using the old softwareServo library and updating that library for arduino IDE 1.x
I've done a quick search in the forum. According to this tread in the forum ,,, and this thread there is a known issue with timer conflicts between the dual-vnh5019-motor-shield and the servo library when used with an Uno. I believe a similar issue is occurring with the Mega 2560.
Based on this information, I think the best solution would be to provide an optional parameter to switch the timer used by the dual-vnh5019-motor-shield. (switching, changing or modifying timers is unfortunately beyond my arduino skill level at the moment)
Notes about timers:
I was wondering if you have a list of exactly what pins to use to connect the two motordrivers to the arduino mega
Hi @craig-w-a I have a fork that is prebuilt for running with two dual-vnh5019 motor drivers on a mega, https://github.com/photodude/DualVNH5019MotorShieldMod3
All the details about pins and stuff for that set up are listed there.
I saw the fork and it mentions the different timers and stuff. idk maybe im looking at wrong file. im new to github and programming
@craig-w-a you should be able to follow the instructions there and use the 3.0.1-dualsheilds release https://github.com/photodude/DualVNH5019MotorShieldMod3/releases/tag/3.0.1-dualsheilds
Everything you need for running with two shields on the mega is contained in the fork https://github.com/photodude/DualVNH5019MotorShieldMod3
@photodude how did u solve this issue of one not running? im using DC motors but still have one that isnt running. i checked the pins and soldering points
@craig-w-a My issue was related to PWM timer conflicts. As noted above "a temporary "workaround" for the servo issue by using the old softwareServo library and updating that library for arduino IDE 1.x"
The other part of the solution was avoiding using the specific PWM pins that caused conflicts. But that all goes beyond just using the library I built to handle running two boards. that library is just about controlling the pins for two boards with single functions.
I am newbie and I want to build a project that contains two linear actuator that move synchronously. Two of them will lift up and down at same time. I use arduino mega and VNH5019 motor driver. I have thompson electrac ELD linear actuator. I have never tried to synchronize two linear actuator. Linear actuator have encoder output ( it is hall effect encoder -( not absolute. So it cannot keep last position in case of power cut )). Encoder type is hall effect type. Encoder output voltage levels low (logical zero), typical / max is 0.1/0.25 Vdc. Also it has output fully extented/retracted signal. I tested it with H-Bridge motor driver made of 4 SSR relays and push button switches to retract and extract. There is a synchronization problem. How should I solve that synchronozation problem could you help me ? What should I do? How to achieve speed control to run actuators simulatenously and sycchronously
@kutluky The Pololu forum would be a more appropriate place for your question (the GitHub issues are intended for discussing problems with and changes to this library, and your question is not relevant to this issue).
Recently ran into an issue where Using a servo on a Mega 2560 with two dual-vnh5019-motor-shields to drive 4 motors causes one motor to fail.
All 4 motors work fine until servo.write is in the loop then one of the motors will not turn on.
Seems something in the dual-vnh5019-motor-shield library and the servo.h library conflict