Help with dual servos

Thanks, I'll check it out today and find out how it works and if I need to tweak it a bit.

I've been reviewing it and the code looks easy to follow, I can see what it's doing and how :slight_smile:

it looks easy, but I would have spent weeks trying to come up with the same thing.

I forgot to mention, at some point, somewhere, on it's own timer, I need to send a signal to a pin for X amount of seconds.

I need to use a transistor as a switch to control a solenoid to open and close briefly.

Do you mean that this action is timer driven, rather than respectively in a loop?

yes, but once an hour or something like that.

I guess it could happen within the loop, that would probably be easier I think?

A whole lot easier in the loop. Just delay for an hour at the end of the loop:

delay(3600000); // wait one hour

Pat.

but I need to send that out to a digital pin I think.

What will the digital output pin control? Maybe I'm missing something key here...

Transistor base.

We have a 24V solenoid, I was going to use a transistor as a switch to turn the 24V solenoid on and off.
It has to operate without delaying the servo loops.

dont use delay(). It will stop the servos from moving and wont have the desired effect. Take the code from the "blink without delay" example, modify it to "blink" every hour, and add it to your code.

p.

fkeel:
dont use delay(). It will stop the servos from moving and wont have the desired effect. Take the code from the "blink without delay" example, modify it to "blink" every hour, and add it to your code.

p.

genius.... I'll give it a try as soon as my partner stops being stupid and understands that gears can't have play or they bind......it's been about 2 weeks now and he doesn't seem to believe me when I tell him the gearing shafts can't move (except torsionally)

ok, this program works fairly well, however it's important that the "turnstile" move 90* then the "wiper" starts moving and while it's moving, the turnstile is also moving at the same time to a position of 180*.....same on the reverse.

is that possible or incredibly difficult to accomplish?

Fairly easy. The hard part will be syncing them together since they are geared differently. Do you know what the ratios are? Otherwise, it will take some trial and error.

Either way will be easy to code.

You might check servo city below for gears/pullys to change the final gearing of the servo output. Bottom is a discussion concerning moving a servo at less than full speed.

http://www.servocity.com/html/mechanicals___accessories.html

http://arduino.cc/forum/index.php/topic,61586.0.html

Just to wrap this up, The project is done however my partner is still under the impression we're working on this so he can solve the worlds problems and become a millionaire with this but it was a school project and we're finished.

I never did get the programming quite right but because of my partners inability to think simple things through it made it quite difficult to get it working.

So I'm done with this, but still have an arduino and nary a thing to do with it :slight_smile:

I'd love some suggestions as to what to do with it preferably automotive related.

a picture? link? write-up?

fkeel:
a picture? link? write-up?

of what?? A school project that was never about the actual device, but instead about the paperwork/project management?

I just didn't want to leave people hanging, wondering what ever became of this.

Well, we're glad you're done, even if it was just a "management" project. A picture would be nice, and maybe a copy of the code.

Now... It's time to put that Arduino to some real use! I've seen some automotive projects on these forums. You might get some cool ideas from them.

Pat.

Document your projects. You wont regret it. ... in a year or two you will have completely forgotten what you did. Its so nice to be able to go back to a blog or a post in this forum or somewhere else and figure out how the hell one solved some random problem two years ago.

I'll try and get some pics of this project tomorrow for you guys then, it was supposed to be a bed bug trap but honestly it was all my partners idea and he is seriously one helluva an idiot. Looking for any idea as his "million dollar idea".

What I am wondering automotive wise with the arduino is could I tap into various sending units on my vehicle and have an LCD to display actual values.

For instance, my oil pressure gauge is a dummy gauge, it only displays normal, low or high. If the PCM detects a signal above X then it displays normal etc no matter how the pressure changes.

I'd like to get the signal directly from the sending unit and have live values of things such as temp, oil pressure and such.

The biggest problem I would see is determining the scale as I don't know what voltage values correspond to what pressure/temp.