I am controlling a DC motor via micro. DC motor draws 2A at full load and r equires 12V. Motor needs to move 30 degrees after every hour. Total require d rotation is 180 degrees. Motor starts from zero degree, moves 30 degrees every hour reaches 180 degree and then travels back to 180 degree without s topping and then repeats, 30 degree every hour. I am using 12 V 4AH Lead a cid battery,

Motor moves six times in 6 hours . Each time motor moves 30 degrees, it dra ws 2A. But it moves for a very little time. How can I calculate that time? Plus what would be current draw for the entire cycle? How long the batteries will last without charging?

On 2015-12-18 Jessica Shaw wrote in comp.arch.embedded:

You mean you rotate the motor 30 degrees? Or is it a gear motor and the output shaft turns 30 degrees? How do you know (and control) you have moved 30 degrees?

How fast does the motor move? Does it have ramp-up/down times? Why not just measure it?

Again, best to measure this. Motor current will not be a constant over accellerate, steady state and decellerate. There may also be variations in mechanical load that influence the current. If you have a scope and a suitable current to voltage converter (current clamp, resistor, etc.) you can measure the current profile and integrate for energy consumption. That measurement will also show you the time required for the move.

Is there any other current consumption than that of the motor?

With lead acid you also have to watch out for high current draws, this leads to much lower capacity than rated. The rated capacity is for 20 hour discharge rate. When drawing 2A from a 12V battery, you would expect the battery to last for 2 hours. But in practice, one hour is more realistic. And that is with 100% depth of discharge, not the best situation for lead acid. And also aging of the battery is to be taken into account if you still want the system to work after a few years.

--
Stef (remove caps, dashes and .invalid from e-mail address to reply by mail)
Half Moon tonight. (At least it's better than no Moon at all.)

Den fredag den 18. december 2015 kl. 13.14.18 UTC+1 skrev Jessica Shaw:

requires 12V. Motor needs to move 30 degrees after every hour. Total requi red rotation is 180 degrees. Motor starts from zero degree, moves 30 degree s every hour reaches 180 degree and then travels back to 180 degree without stopping and then repeats, 30 degree every hour. I am using 12 V 4AH Lead acid battery,

raws 2A. But it moves for a very little time. How can I calculate that time ?

not enough info, the naive upper limit is 4AH/2A = 2 hours of motor run time you need to find out how long each 30 degree move takes and how much the mo tor is loaded

So, you've more or less asked this question before, and the answer remains the same: first, you haven't given enough information, and second, you have some calculating to do.

The biggest missing part is how much your mechanism is going to load the motor. Without that, you can play math games all day long but it'll be completely unproductive.

You can _assume_ that the motor will operate at full load and get some answers (surely you know the _speed_ at full load), but without knowing what load your mechanism is going to present it's just pointless calculation.

Whether you can make this work reliably simply by powering the motor for a fixed amount of time depends upon how accurate you need the rotation to be and the predictability of the motor's speed. A slower speed will be more predictable because the acceleration and deceleration become less significant. Typically, the speed of a DC motor is proportional to the applied voltage, so you need a predictable voltage to get predictable speed.

Otherwise, you'll need some form of sensor and a feedback loop so that you can measure the rotation and cut the power at the appropriate time.

So you are again trying to control a solar panel ? In that case, I would suggest using 15 degrees each hour :-)

How are you going to control a DC motor to perform a specific number of revolution with a variable mechanical load ? I would guess that you would need some kind of feedback (encoder) telling when the desired angle has been achieved and then cut the motor current. Depending on friction or wind load at different time or at different current that will be needed to achieve the 30 degree displacement, so form of feedback is essential.

In addition, if the load has some mechanical torque e.g. due to asymmetrical weight distribution or wind load, you may need some station keeping current to maintain the assigned angular position, which will dry up your battery. I would strongly suggest using a proper stepper motor (with or without a gearbox). As a bonus, you could use more positions within each hour, say every 5 degrees.

I am using an accelerometer to calculate tilt. Its single axis control. Wh y 15 degrees an hour?

The motor takes about 28 second to move 15 degrees. The motor takes about 2 A at 12Volts. I am trying to figure out how much current it is drawing in 2

8 seconds.

Let's say I want the motor to move 15 degrees after every hour. If it moves from 90 to -90 then the travel is 180 degrees which means that motor will move 12 times in a day and then after Sun set it will travel back ( 3 minut es) to its initial position facing East waiting for the Sun rise again. So, total number of times motor moved = 13.

I want to calculate that how much current it will use from the battery ( 12 V, 2AH) each day plus how long ( how many days) my battery will last witho ut charging. How can I make these calculations?

If you already knows it takes 2 amps for 28 seconds, one move will take

56 Amp-seconds (2x28), for simplicity round up to an Amp-minute, so you can make 60 moves with an Amp-Hour. You should know how many Amp-Hours are in the battery to compute about how long things will last, assuming your initial data is correct.

Well, lessee. You're tracking the sun, and a day is 24 hours long, and the sun scribes a circle in the sky once per day, and a day is 24 hours long, and a circle has 360 degrees, and 360 / 24 = 15 and that ain't no coincidence at all.

How can you make these calculations? By getting the rest of the information you need, as has been pointed out to you, repeatedly.

Asking the question again and again won't make the information magically appear -- you need to actually Do Some Work to dig it up.

Yes, batteries typically have a limited number of electrons they can deliver, based on chemical reaction progressing. This count of electrons can be done in a number of units, be it Coulomb (aka Amp-Second), or Amp-Hours (often used as operational life is normally in hours, so more reasonable numbers).

This is a nonsense expression. You could say that

2 AH / 2A = 1 hour = 3600 seconds

No, the current draw is 2A for 28 seconds. I have no idea where these numbers are coming from.

as above, 2 AH / 2A = 1 Hour active run time. At 28 seconds per move the is 3600 seconds / 28 Seconds/move = 128 moves.

13 moves a day = about 10 days. (note, this may be optimistic, as the return move is likely longer.

As others have pointed out, you also need to include the fact that your controller is consuming power too, which needs to be considered.

Also, as you drain the battery, it generates less voltage, which says the load (motor) will likely draw less current, which might sound good, but it also won't push as hard and take longer to make the move.

Also, a major factor is how that 2A draw for 28 seconds was determined. I actually strongly suspect that the draw will NOT be constant over the full move. You will normally get a large surge when you first start the moter, and the current will drop as the motor gets moving.

wrong. It would be 150 mAH. I will use 150 mAH of CAPACITY of the battery. The current that you draw is 2A (for 28 sec.).

Wrong again. The motor will do 12 moves of 28 sec. and a big move of 3 minu tes to go back, so it will move for 12* 28 sec + 180 sec = 516 sec.

Notes about batteries:

- read on the datasheet of the battery what is the rated current you can ge t. If you draw more current than what is rated you''l get less AH than what is rated.

- If you want to keep the battery in good shape, keep at least 50% charge i n it (so if battery is 4AH, don't use more than 2AH).

- Temperature has a huge impact on battery capacity: the colder, the less c apacity you can use.

Wont even go into depends on lattiude and time of year as well, as to work out longer and shorter arcs.

But then again as the current draw has not been mapped out for the start/move/accelerate under different mechanical loadings and battery charge levels not much hope of sorting this.

--
Paul Carpenter | paul@pcserviceselectronics.co.uk
PC Services

Just use equatorial mount, i.e. the panel axis is parallel to the axis of the earth. Adjust the panel axis according to your latitude. After that you just need one constant velocity mover to track the sun regardless of the day of year.

The OP did not specify any feedback mechanism how to ensure accurate tracking.

While I understand that a battery may be required to swing back the panel at night and perhaps during a few rainy days. In normal situations the panel would be quite sufficient to charge the battery.

In the worst case after an extended rain period, turn the panel to the meridian (to the south in northern hemisphere) and when the sun appears, it will charge the battery sufficiently and the next day it will track the sun properly.

I am using a single axis accelerometer to measure the tilt. Since, its sing le axis tracking. I am planning to only follow the elevation of the Sun not azimuth.

So, I have Real Time clock on board and then I calculate the Sun's elevatio n for that particular day w.r.t time. So, the motor starts from 40 degrees ( mechanical assembly mounted to face the Sun at 40 degrees at Sun rise) a nd moves "x" ( elevation angle) degrees every hour until it reaches -40 d egrees.

I can calculate the Sun elevation w.r.t to time but how can I map the Sun's elevation values into my code to control the motor. I just turn ON and OF F the motor and monitor the tilt using accelerometer. I am not using PWM. I am just little confused about it

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here.
All logos and trade names are the property of their respective owners.