SparkFun Forums 

Where electronics enthusiasts find answers.

General project discussion / help
Did you make a robotic coffee pot which implements HTCPCP and decafs unauthorized users? Show it off here!
By Vesselserenity
#167861
So my simple project got far more complicated now I'm here hoping the electronic whizzards can help
We have a directional antenna on a ship needs to face 210 degrees when in use so I mounted a large scale RC servo to it and a Servo test box so we move the antenna each time we need it tuned but I want it to track 210 degrees on its own
I thought a simple magnetic compass attached to one of the control boards should work but now we are unsure which board will work and do we need a DC motor driver added to the system ?
There is very little interference on the ocean,pitch and roll don't affect the dish it seems any lend a hand
J
By Mee_n_Mac
#167911
What's in the existing "Servo test box" ? You could in theory get some compass module, mount it properly, align and correct it and then read it with some microcontroller (MCU). The MCU could filter those readings, account for the zero deg alignment of the antenna and command the servo to point to 210 (mag or true?). I will say getting a compass to work properly on a ship can be hard, you might want to see if the existing compass (or GPS if in motion) could be used before going the separate route. Also an RC servo has (normally) a limited (180 deg) range of rotation. At some headings it won't be able to point to 210. If that's a concern you may need something more custom.
By markaren1
#168171
So you are steering/tracking a microwave dish on a boat ?

Can you provide more details. Size of dish, size of boat, application, budget

-Mark
By Vesselserenity
#169606
Hi sorry for the extended delay in getting the information
Test box was a simple servo control device to test the mechanics of the system
Details are as follows sparkfun LSM303DLH break outboard connected to the UNO board
We are using a 5.1 volt power supply to the arduino presently we have the breakout board connected as follows
Gnd to gnd VCR to 5 v out scl to A2 and sad toA3 we have no idea where to start in hardware setup with the programming and are starting fresh again
We read so many designs I think we have over complicated the idea
Lsm303 aims servo in the direction the board is pointed that's what we need
By Vesselserenity
#169607
It's is a directional antenna 12 inches square on a 36 inch mast on a turret base for a spot light we scavenged from the ship the vessels 61 foot and presently our owners are not supporting the idea so our 6 guys on board are trying there best to make it work
By Mee_n_Mac
#169613
Break this down in to 2 pieces at first. That would be reading of the compass and controlling of the servo. Then combine them. If the servo works with the test box then the latter should be easy to do. The hobby servo interface is 3 wires; a ground, a power wire ... typically 5v and a control signal from your Uno. I might imagine that the power/current required is non-trivial so using the test box for the supply might be a good idea. A really simple Uno program might be to read a potentiometer and move the servo to a corresponding position. Later you'd replace the reading of the pot with reading of the compass and a control loop to point the servo.

So how about that to start with ? Read this ...
http://arduino.cc/en/Tutorial/Knob#.UyyPlYUVBrA

ps - providing links to datasheets or some info for the compass and servo would be useful and likely to get you more responses.

BTW given your servo has some limited (not a full 360 deg) range of motion, what's your plan for when the vessel is headed on those courses where the servo can turn the antenna enough to get to 210 deg ?