Pages: [1] 2   Go Down
Author Topic: Serial Errors - Uno + Servo  (Read 1721 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

I've posted here (and several other places) before about serial issues with a project I'm working on.
Steadily, with the help of the arduino and coding community, I've eliminated problems with my project's serial connection.

First, I got rid of a generic 9ft USB extension cable and physically mounted the computer closer to the arduino. This greatly improved the reliability of the serial connection.
Then I stopped using an off brand Arduino system (Diavolino) that used an external FTDI converter. I got an Arduino UNO.

The UNO worked well, and didn't have any serial crashing issues at all.. Until yesterday.
Yesterday I noticed that the system would turn the servo to lock the door (locker() function). But when it called the unlocker() function, the servo would feebly twitch and then remain still. The arduino is powered off USB, and the servo is powered from an independent 5V source. Both circuits were grounded to the arduino. I could only get the servo to receive the correct signal from unlocker() by wiring the 5V servo power to the arduino as well. I'm sure that the servo is fine, it is a full-metal high-torque servo, and I can test it on a separate controller without any issues.

I find the whole situation extremely frustrating. I've replaced the cable, the arduino, changed methods of connecting to its serial port four times, and the problem doesn't seem to be fixed. I need a system that can work for weeks without intervention, and I just don't see how the Arduino platform provides that.

I've tried two serial libraries in C++, but am now just using PuTTY to connect to the arduino and send data from a card-reader.

I'd appreciate any ideas, or suggestions to debug the system.

Thanks,
-BBX


* puttyError.png (59.54 KB, 964x716 - viewed 34 times.)
* SuiteLock.ino (7.54 KB - downloaded 15 times.)
« Last Edit: November 17, 2012, 04:13:36 pm by BBX » Logged

SE USA
Offline Offline
Faraday Member
**
Karma: 41
Posts: 3783
@ssh0le
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

how much current does your servo eat, and how much current can you supply

if your putting supplies in parallel to get things to work, I bet its not enough
Logged


0
Offline Offline
Tesla Member
***
Karma: 141
Posts: 9470
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You have a high torque servo and a sketchy 5v power supply for it. Possible suspects. If it worked and then stopped, maybe you knocked some wiring lose. The arduinos seem to work reliably for hundreds of other people, so I'd imigine your issues are particular to your setup.
Logged

Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   smiley-cool

the land of sun+snow
Offline Offline
Faraday Member
**
Karma: 158
Posts: 2882
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Tomorrow something will work, and the clouds will part, and the sky will be blue .... for about an hour.
Some people are just plain cursed, that's how life is, I'm not alone. Enough philosophy, so

What is the servo being used?
What is the power supply for the servo?
How long are the wires from the servo supply?

I would think things would work worse when using the same power source for both servo and Arduino,
so ???

Running the Arduino off the power in the USB cable may be a problem with servo systems, I rarely do it.

For my part, I "always" use extra electrolytic [eg, 220 uF] and bypass [0.1 uF] caps on the servo power
distribution point, to help filter servo motor noise.

Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
Thank you for the replies!

I'm not sure why I missed including the servo model the first time. It's a 1501MG 6V servo.
I'm taking a 6V 500ma power supply and feeding it through a 7805 with two 22pF caps.
The servo power supply is four feet from a gutted wall-wart to the 7805, and within another foot of wire from there to the servo..

oric_dan, I'm aware that I'll label my thread 'cursed' but it's just me not understanding something here xP You mention not using USB power. How would I accomplish that without losing the serial connection?

Thanks,
-BBX
Logged

New Jersey
Offline Offline
Faraday Member
**
Karma: 65
Posts: 3638
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I'm taking a 6V 500ma power supply and feeding it through a 7805
That doesn't sound good - your servo wants 6 volts and you're reducing it from 6 via a voltage regulator. I suspect you're not even getting 5V. Your wallwart can provide 500mA, the general rule of thumb I've seen here recommends an amp per servo. In short therefore, your issue is likely power related - see if you can scavenge up a more hefty supply.
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Awesome,
I found a 20V 3A laptop PSU lying around, I'll try wiring it in.

Thanks wildbill!

-BBX
Logged

New Jersey
Offline Offline
Faraday Member
**
Karma: 65
Posts: 3638
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That might be a bit too hefty - if your 7805 survives, it'll need a lot of cooling. Perhaps see what you get if you wire the 6V supply to the servo without the voltage regulator at all. You'll still be underpowered, but somewhat better off.
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I think you're right.
I tested the (19V 3A) setup with a multimeter and got 5.01V, which is encouraging. The 7805 has a small heatsink attached to it, and I can feel that it got pretty warm.

I'm loathe to try the 6V without the 7805 because I don't think it's regulated, and I can't afford to lose the servo (while there are several 7805s lying around).

Thanks,
-BBX
Logged

New Jersey
Offline Offline
Faraday Member
**
Karma: 65
Posts: 3638
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well in that case, it looks like a 7806 or three would be a useful addition to your parts box. Since you have spare '05s though, perhaps it's worth trying with the laptop power. I'd be more inclined to find another wallwart - if you're anything like me, you'll have a plethora of them from long defunct devices. Alternatively, do you have any 7812s or similar to do a cooler two stage stepdown?
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ah, I actually do have some 7812s somewhere...

Unfortunately, I moved from my nice basement into what I can best describe as a 'people kennel' at my university. So I had to leave behind all of my wonderful odds and ends smiley-sad

Would I want to wire the two 7805s in parallel? I heard that's a bad idea from an earlier thread..

Thanks,
-BBX
Logged

New Jersey
Offline Offline
Faraday Member
**
Karma: 65
Posts: 3638
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No, I simply meant that if you have spare parts, you could see if one of the 7805s can do the job with the 20V input. If it overheats & fails, at least you have a replacement available & for that one you will know that better cooling and/or lower input voltage is required. 
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 58
No time to learn
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Right, gotcha.
Exactly, I'd much rather burn out a spare 7805 than an Arduino or servo!

I found a 7812. I like the idea of stepping down 20V to 12V, and then taking the 12V down to 5V in two steps. Are there any foreseeable problems with doing that?

Edit
I stand corrected. My circuit uses two 10uF capacitors on the 7805.
/Edit

Thanks,
-BBX
« Last Edit: November 17, 2012, 11:08:17 am by BBX » Logged

SE USA
Offline Offline
Faraday Member
**
Karma: 41
Posts: 3783
@ssh0le
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Are there any foreseeable problems with doing that?

nope
Logged


0
Offline Offline
Tesla Member
***
Karma: 141
Posts: 9470
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You can add a small diode to the 7805 ground like below to up the 7805 output voltage to ~5.7v for better servo performance.

Logged

Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   smiley-cool

Pages: [1] 2   Go Up
Jump to: