Well I am slowly but surely getting my InMoov hand built.  I am having an issue however with MyRobotLab.  I am looking right now just to validate that I can move and control all my servos before I mount everything in the forearm.
This is a follow-up to a Grog-no-worky I sent in last night.
 
I have an Arduino Uno and have it plugged into my laptop and an external power supply.
What happens is that what seems almost random something resets the usb port, I can't tell but it looks like the Arduino resetting.
 
I am running the InMoov_Minimal.py script.
If I have 3 or more servos this will happen usually before the system check completes.
If I have two or less most of the time it will start up ok but sometimes resets.
 
When it does work I can sometimes get manual mode to work but generally it will hang after a period.
The same thing happens if I just run the Arduino and a servo service manually.   It is similar to another
problem I saw on the InMoove forum where it said that moving the slider fast caused hangs.
 
It looks like some sort of serial overflow but it is hard to tell.  I have played around with various baud rates on the port from control panel and within the MRLComm.ino to no avail - all show the same symptoms.
 
So I am attaching my logs and my InMoov_minimal.py script.
 
I am looking for any help anyone can provide on this.
 
PS - On side note it would be useful if the forum allow .log files to be uploaded.

Alessandruino

10 years 11 months ago

Hi bytemedweb...i think that your arduino resets because of the current required by servos is too much high... Arduino can provide only a little current (also if arduino is supplyed by external current) and so, if the current is higher than a prefixed value, it resets or better reboot to protect himself...

It depends by servos kind, how many servos you can hook up directly to arduino...( my arduino with only 2 servos running , reset :( )

There are 2 solutions :

  • low the current using a diode or a resistor (bad solution, valid only if you run a couple of servos)
  • connect servos to an external power supply ( battery pack of 4 AA battery for example) : so the wiring for servos would be ( PWM connected to arduino, red wire (+) connected to the (+) of battery pack, and black wire (- or ground) connected both to (-) of battery pack and Gnd of ARDUINO !!!!!! ( PAY ATTENTION TO THIS POINT : IF YOU DON'T CONNECT TOGHETER GND OF ARDUINO AND (-) OF BATTERY PACK SERVOS WILL NOT MOVE)

Let us know if this works for you

Best regards

P.S. welcome in MRL :D

Alessandruino

Alessandruino

10 years 11 months ago

Oh... A third solution could be to Connect (+) of servo to Vin of Arduino ...it Will provide full current to servo bypassing arduino security current check... But the second solution is the best in term of arduino security

GroG

10 years 11 months ago

Hello and Welcome bytemedwb !

Ya under power is the ROOT OF ALL EVIL !!  Gael went through this several times - at one point he got power-supplies which although "external" still did not have enough power to satisfy all his servo requirements.

Here is a Fritzing example I found on the web which shows how to wire a couple of servos with an external power supply.

PS.  I'm still looking for the posting .log's 

GroG

10 years 11 months ago

finally found where to change to allow .log files ... FIXED !

bytemedwb

10 years 11 months ago

Thanks everyone - I was wondering if it was power related.   I honestly thought that with the external power supply the Arduino would be able to provide enough juice.   Learn something new everyday.

Now I just need to get things rewired.

 

And Grog - thanks for the change to allow log files.

 

bytemedwb

10 years 11 months ago

Face Palm.

I had hooked the server power to the 5V on the Adruino.  When I moved it over to the Voltage in line everything worked like a champ.