Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Categories > Robotics Chat

Notices


Robotics Chat Specific to discussions about robots and the making of.

Reply
 
LinkBack Thread Tools Display Modes
Old 30th March 2004, 01:19 PM   (permalink (permalink))
Default small servo project, I really need HELP

hello guys
hope you are all fine...
well i have an idea in my mind but yet not really ready so am asking for help from my fellow experts )
i will tell you the idea abtractly:
i want to control a bunch of four servos on a vehicle or something through a joystick in my hand. the system is wired and hence i want to have the wire as thin and light as possible and this means that we need to have the number of wires going from the joystick to the bunch of servos are minimal. well in addition each two of the four servos will recieve the same command and hence we can see that generally there will be only 4 possible commands to the servos from the joystick (for each two (up and down= 2X2 =4 ))......... can you get my idea guys. i need to see what kind of circuits do i need on the joystick interface and on the servo side if i would use digital commands or so......
i need to know any feed back , help suggestions and comments on the idea, if someone really knows a site to find some similar things that would be just great.
fakahany1 is offline  
Reply With Quote
Old 30th March 2004, 01:47 PM   (permalink (permalink))
Default

The problem is that how far from your joystick to the servos. Because, if it's as short as 50cm to 10m, you can use serial communication, and you need only 2 wires to control as many servo as you wanna. If it's less than 1m, you can use I2C and it works perfectly.

In your joystick, you should use a MC to communicate with your joytick, then, you need another MC at the servo board. These two MC can communicate with each other.

In case that your distance is less than 1m, you can build a I2C communication and you need only one MC at the joystick as the master chip, and all other chips on servo board are slave.

It will work good with 2 wires only.
falleafd is offline  
Reply With Quote
Old 30th March 2004, 01:49 PM   (permalink (permalink))
Default

Your suggestion of four 'commands' isn't correct, servo's are analogue devices operated by varying width pulses (usually between 0.5mS and 1.5mS long). Probably the easiest way to do it would be to use the encoder and decoder chips from a radio control system - you could easily feed the signal down a couple of wires, or for that matter use the RC system itself?. Feeding two servos from one output shouldn't be a problem.

There are various more complicated ways you could do it, including uses PIC's as encoder and decoder IC's, creating your own coding scheme to feed down the wires.

Or, even simpler, if you can feed three wires rather than two, feed the servo pulses directly down the wires, with everything done at the joystick end.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Reply With Quote
Old 30th March 2004, 01:49 PM   (permalink (permalink))
Default

If you build your joystick yourself, you can take the I2C or serial communication of the joystick to make it as master chip or serial transceiver chip, and you won't need another outside chip to communicate with the joystick anylonger.
falleafd is offline  
Reply With Quote
Old 31st March 2004, 06:50 AM   (permalink (permalink))
Default

hello guys, thanx alot for your help....
first, i am planning that the wire is very long, more than by 1 meter by far.
hence, the second point is that we need to try to keep the number of wires minimal ( would two wires help us in our system ??)
i would like it to be not really complex involving many PIC's... that is i would like it to have all the complexity in one side only , the joystick side and minimize all circuitry in the servos side.
IN SUCH CASE WHAT KIND OF CODING AND ENCODING SHALLWE USE?? or what is the logic of the communication?? and in this case we can use three wires instead of two in order to carry the pulse, but still can one help me grap the circuitry idea in this case
(we have total four servos and taking in mind that each two will recieve the same siganl)) : D
thanx guys, i am a bit of a biginner but you will diff. help me ))

have a nice day )
fakahany1 is offline  
Reply With Quote
Old 31st March 2004, 12:00 PM   (permalink (permalink))
Default

Dear Nigel,

I built my final robot as this:

The servos will be driven by a MC, and four servos, I used 4 MC to control it. The four MC have the same program, if we want to control the servos in the same way. Actually, in my case, it was 2 servos and 1 stepper.

Then, I use one PIC to be the MASTER and the Master is connected to the PC.


The program on slave should be:

1) Receive: velocity, accelerate, and position
2) Send: the current velocity, accelerate and position of motors through reading encoders.

As I need to control a motor, I only send the suitable data to the slave, and the slave automatically control the servo. I'll not care what I'll really do with the master but as a transceiver only.

This structure make the robot work with more ease, and we don't have to compute muchie.

Therefore, if we develope this structure into this application, we can use serial communication to talk in a distance of 10m with the master chip.

That's all what we have to do.

It's fact that we have to use many MCs here, but with more MCs, we don't have to compute much, and we can do many things more, even wireless communication.
falleafd is offline  
Reply With Quote
Old 31st March 2004, 12:17 PM   (permalink (permalink))
Default

hello guys....
dear falleafd..
well i would like to have the solution with minimal MC and PIC and if possible we can put all the circuitry and MC on the Joystick side and almost nothing in the servo side....... I really need no perfect control, i send a command and the servo replys with current status. i dont really want it so complex. just to move according to the signal right or left....

plus i should make it clear that the length of the wire is much more than 10m and hence we have to take an assumption that the length of the wire is infinity in technical computations and hence (as far as i can guess... need clarification??!) the serial technique wont be a good solution???
fakahany1 is offline  
Reply With Quote
Old 31st March 2004, 12:17 PM   (permalink (permalink))
Default

Quote:
i would like it to be not really complex involving many PIC's... that is i would like it to have all the complexity in one side only , the joystick side and minimize all circuitry in the servos side.
IN SUCH CASE WHAT KIND OF CODING AND ENCODING SHALLWE USE?? or what is the logic of the communication?? and in this case we can use three wires instead of two in order to carry the pulse, but still can one help me grap the circuitry idea in this case
(we have total four servos and taking in mind that each two will recieve the same siganl)) : D
thanx guys, i am a bit of a biginner but you will diff. help me ))
The fact that, you can easily build one side pcb for this application. Because

1) With each servo (or 2 or 3 or 4) you need only 1 PICs to drive it. And this PIC will works as a slave chip. And the pcb of this scheme will be simple enough to build on one side board.

2) Imagine that, you have 4 PICs (or less) to control 4 motors. Then you add another PIC to send controling data to each 4 PICs above.

Then, at the joystick, you add another PICs to communicate with the joystick. As result, you have to add 2 more PICs than you intended to do.

And this two PICs have a simple tasks is that transceiver. As you use serial communication between two PICs, you have to use only 2 wire to do so.

3) Don't worry about your board. Take care of the drivers you would build to control the 4 motors. In each 4 PICs I mentioned above, you have to write the full program to control one servo. And the program need the parameters to control the velocity or positions or acceleration.... to run the motors.

4) The PIC connected to joystick will work as a decoder, it change the positions of joysticks into control parameters to send to the 4 PICs



joystick <-> PIC (works as a decoder) ----serial----- PIC <-> Your drivers (I will use 4 PICs in your case).
falleafd is offline  
Reply With Quote
Old 31st March 2004, 12:44 PM   (permalink (permalink))
Default

Quote:
Originally Posted by fakahany1
hello guys....
dear falleafd..
well i would like to have the solution with minimal MC and PIC and if possible we can put all the circuitry and MC on the Joystick side and almost nothing in the servo side....... I really need no perfect control, i send a command and the servo replys with current status. i dont really want it so complex. just to move according to the signal right or left....
I think we may be at cross purposes here?, you keep mentioning servo's, and I've presumed you mean radio control style servo's - is this so, or are you building your own servo's?. It makes a great deal of difference, radio control servo's are fully independent - you provide it a simple variable width pulse, and it does everything it's self - there's no reply given, the servo simply moves to the location which the width of the pulse tells it to.

Quote:
plus i should make it clear that the length of the wire is much more than 10m and hence we have to take an assumption that the length of the wire is infinity in technical computations and hence (as far as i can guess... need clarification??!) the serial technique wont be a good solution???
I would suggest using radio control, the radio gear and servo's are easily and cheaply available, you don't need any wires at all, and it will work at a considerable distance - and it's a ready built solution. It's no good suggesting you want 'infinite' cable length, you need to specify a maximum distance - which needs to be practical, specifying far longer than you need will probably increase costs considerably.

Perhaps you might like to explain better what you are trying to do, we may be able to make further suggestions.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Reply With Quote
Old 31st March 2004, 02:38 PM   (permalink (permalink))
Default

Yes, Nigel is right. For a 10m distance control, you should use RF remote control. I'm just stupid that trying answer your question but don't care about real world application.

However, if faka is a beginner, and he cannot build RF control, he may use serial communication here. But I think, in spite of using serial here, you buy a RF control and use it. The more expensive you pay, the better control you will get. As Nigel suggested, you should buy a 4 channel RF control.

And you know, in helicopers applications, they use 6 channel RF control to drive the helicoper. And it work very very very good. Of course, they also use servo motors.

Well, it's nice that, I saw a circuit of helicoper, it's only as small as your finger. It includes a receiver, and controllers using 2 x 16F84SO... It works so good.
falleafd is offline  
Reply With Quote
Old 1st April 2004, 07:49 AM   (permalink (permalink))
Default clarification

hello guys...
well i guess we need to clear some ideas here, i might have not expressed the idea well the first time.

I need to make a system of two sides: side one is just a simple joystick connect to side 2 with a long wire (propably 500 meters or moreeee) side 2 is a combination of 4 servos (normal servos we use in RC planes) used to control something like a pillar or a post with some sort of signs that i will control with the joystick to point in different directions. each two servos will move in the same direction, that is recieve the same signal.
both falleafd and Nigel (thanx guys) have suggested to use some sort of RF system, well it is easy and nice idea , but the problem is that i might recieve interference from other surroundings i live beside an airport by the way, thats a point PLUS i am taking into consideration that my system the side 2 of it possibly will be destroyed or be damaged due to its job nature, so i cannot afford each time to install a reciever each time i have a damage, so i tend to just use as little circuitry and stuff in side 2 and have most of my circuits and things on the joystick side....

however if you still see that there are cheap RF modules or reciever we might take it still as an option. in both cases i need to know how technically we can use serial communication?????
i have some sort of a primative idea in mind you expert guys can tell me how much it is feasable.
what if we use 3 wires. one wire will carry the signal(with the appropriate length according the the angle of movement or.....) the other two wires can be used as addresses specifiers. that is if you have:

a signal in 1st wire + a signal in the 2nd wire = servo 1 & 3 move right
a signal in 1st wire + no signal in the 2nd wire = servo 1 & 3 move left
no signal in 1st wire + a signal in the 2nd wire = servo 2 & 4 move right
no signal in 1st wire + no signal in the 2nd wire = servo 2 & 4 move left

this primitave way of encodeing i guess it wont cost us alot to make a decoder in the servo side right ???
i need your comment on this fellows.
thanks alot and hope i made the idea clearer
have a nice day : ))))
fakahany1 is offline  
Reply With Quote
Old 1st April 2004, 09:38 AM   (permalink (permalink))
Default Re: clarification

Quote:
Originally Posted by fakahany1
a signal in 1st wire + a signal in the 2nd wire = servo 1 & 3 move right
a signal in 1st wire + no signal in the 2nd wire = servo 1 & 3 move left
no signal in 1st wire + a signal in the 2nd wire = servo 2 & 4 move right
no signal in 1st wire + no signal in the 2nd wire = servo 2 & 4 move left

this primitave way of encodeing i guess it wont cost us alot to make a decoder in the servo side right ???
i need your comment on this fellows.
thanks alot and hope i made the idea clearer
have a nice day : ))))
You still don't seem to understand how servos work - as I've said before, they require a variable width pulse of between 0.5mS to 1.5mS, the position the servo takes up is based on that pulse width. A width of 0.5mS moves the servo to one end, and a width of 1.5mS moves it to the other, obviously a width of 1mS places it in the middle. This action is completely analogue, so the servo can be positioned anywhere in it's range.

Your 'encoding' scheme doesn't provide any pulses, so wouldn't do anything!.

Servo's have a three wire connection, ground, +ve, and input - assuming the supply is available locally at the servo end (and sending power down 500m of cable probably is best avoided), you only need to provide a ground connection (common to all four servo's) and an input wire for each pair of paralleled servo's - this gives a total requirement of three wires.

It would probably be a good idea to use a screened cable, where the screen can be the ground connection, with two wires inside.

I've no idea how well the servo pulses would travel down 500m of cable, you may have to amplify them to overcome the cable capacitance.

If that won't work, some kind of serial scheme involving a PIC at each end could be used - keeping to a slow speed should allow it to carry 500m, or you could use a simple modem system and send audio tones down the wire.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Reply With Quote
Old 1st April 2004, 10:07 AM   (permalink (permalink))
Default

i just wanted to say that the four servos will have for example a common ground and onborad power supply. OK?
how ever the signal will come in one of the three wires from the joystick curcuit.. now we have the power and the signal now we need somethin to tell us which servo will work and to which direction. i suiggested that we have a new circuit that will know which servos to work from the addresses on the other two wires and it will act upon it be give the siggnal on the third wire to the servos responsible after decoding the incoming address on the othe rtwo wires.
sorry for my ignorance but i hope you will be able to help me more.
thanx Nigel
fakahany1 is offline  
Reply With Quote
Old 1st April 2004, 10:31 AM   (permalink (permalink))
Default

Quote:
Originally Posted by fakahany1
i just wanted to say that the four servos will have for example a common ground and onborad power supply. OK?
how ever the signal will come in one of the three wires from the joystick curcuit.. now we have the power and the signal now we need somethin to tell us which servo will work and to which direction. i suiggested that we have a new circuit that will know which servos to work from the addresses on the other two wires and it will act upon it be give the siggnal on the third wire to the servos responsible after decoding the incoming address on the othe rtwo wires.
sorry for my ignorance but i hope you will be able to help me more.
thanx Nigel
Here's a quick diagram of how to connect the servo's, there no addressing or anything, just two variable width pulses (a pair of sample pulses are included on the diagram), one for each pair of servo's. You could use 555 timers to generate the pulses from the joysticks, there are plenty of radio control servo tester designs on the net.
Attached Images
File Type: gif servo.GIF (6.8 KB, 2061 views)
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Reply With Quote
Old 1st April 2004, 10:46 AM   (permalink (permalink))
Default

well this diagram kinds of explains more and in other word is almost perfect. however i still have a question, now...... i want to move the servo this much to the right, how the signal would look like??? and now i want to move the same servo that much to the left, now how would the signal ook like now ???
and if i will depend on the length of the signal to trigger up the servo, what kind of logic will be ised in the servo side, if any ????
thanx alot Mr. Nigel
fakahany1 is offline  
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes





All times are GMT. The time now is 03:09 AM.


Electronic Circuits  |  Electronics Wiki
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.