Shop OBEX P1 Docs P2 Docs Learn Events
constant current control, how? — Parallax Forums

constant current control, how?

tonyp12tonyp12 Posts: 1,951
edited 2017-04-28 19:26 in General Discussion
For constant voltage, there are 1000's switching regulators & LDO's out there,
the simpler ones sometime also state with a slight different hook-up they can be used as constant current regulator.
Most LED-drivers delivers constant current, not sure if they could work for my project.

How is constant current achieved? beside pwm based voltage-chopping by reading a sense resistor.

I want to use Hex Half-bridge Driver ATA6838C to drive a 5-phase stepper (pentagon drive)
http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-9237-Standard-Drivers-ATA6838C_Datasheet.pdf

I just want two settings: ~1A in rush and ~0.5A hold current at 24V.
As CS going high, it latches new data and a new movement, I would like to use that signal to select inrush/hold current.

I don't more than one part, don't want it to cost more than 50cents.

1: Have a nmosfet on ground connections, that you leave fully-on or choke to ~5 ohm resistance by vgs control.
don't like that, IC direct connection to a large ground plane for cooling is gone.

2: use a pmosfet on highside, though I seem to need to invert the CS signal for the resistor divider for -vgs control.
a dual n-p mosfet could do that, or as I need to redrive the CS signal anyway (boards can be daisy chained) I could get a buffer with complementary outputs.

3: Apply a Square-wave on the INH pin, I don't see what maximum freq it allows, but even a low 1KHz voltage-chopping should produce the 0.5A average holding current.
oscillator made from a single Schmitt trigger should work.

Any thoughts and input?

Comments

  • ercoerco Posts: 20,256
    On the cheap, simple and wasteful side, a LM317 makes a handy dandy current regulator & heater with just one resistor. Rated to 37V and 1.5A with thermal protection. Easy to limit to 0.5A with a 2.5 ohm resistor. 0.625W lost through the resistor. But of course the 1A inrush mode ain't there.

    http://www.bristolwatch.com/ccs/LM317.htm

    lm317b.jpg
  • Just a note about the LM317: you lose 1.2V of your 24V across the resistor, the rest in the LM317, which could get quite hot.

    But you might be able to do what you want with just a resistor on each lead, depending on the resistance of the windings. For example if they're close to 24 ohms, a 24-ohm resistor in series with the lead will give you a steady-state 0.5A current. But when the coil is first powered, its resistance is effectively infinite, due to the inductance. So it will see the full 24V until the current builds up. This works even better with lower-resistance coils and higher-valued series resistors.

    -Phil

  • tonyp12tonyp12 Posts: 1,951
    edited 2017-04-28 22:05
    coils are 1.2ohm 0.75A and as rdson is 1.2 ohm (40c), I hope it don't go over 1A by much, IC does have short detection on a ms timer.
    As one steeper's often stay still, it's recommended to apply a 50% hold current while "in rest".
    Keeps IC and motor cool, I will try pulsing INH pin, not sure how fast it can be done though (don't have pcb yet)

    5-phase drivers are rare, so there is a demand for this product.
    picture shows full steps, there is a sequence of 10 steps. 0.72deg/Step
    There is also half-steps by doing 20 sequences.

    629 x 757 - 56K
  • kwinnkwinn Posts: 8,697
    Seems to me like this is a job for one of the tiny sub $1.00 microcontroller chips.
  • kwinn wrote:
    Seems to me like this is a job for one of the tiny sub $1.00 microcontroller chips.
    'Probably cheaper than a large aluminum heatsink! :)

    -Phil
  • jmgjmg Posts: 15,173
    tonyp12 wrote: »
    3: Apply a Square-wave on the INH pin, I don't see what maximum freq it allows, but even a low 1KHz voltage-chopping should produce the 0.5A average holding current.
    Hmmm, they do seem slack in not giving Frequencies.

    They do give a 20us delay time for turn on/off on most and 3us for Low ON, which indicated these are modest-speed parts.

    Some details to ponder...

    Usually, parts with inbuilt charge pumps, have some energy limit on that, which imposes some max switching frequency for gate Charge-Discharge.
    You could check for that by starting lower in freq, and checking high-side saturation ?

    When flipping from ON to inhibit, the inductive current will flyback, and clamp on internal diodes.
    To ease IC dissipation here, you could add schottky diodes externally for that current path.
    tonyp12 wrote: »
    coils are 1.2ohm 0.75A and as rdson is 1.2 ohm (40c)...
    What inductance do they have ?
    If the part is too slow, the other approach is to modulate the main supply. - A switching regulator should do that.
  • tonyp12tonyp12 Posts: 1,951
    edited 2017-04-29 20:02
    Or just do it in software, it's not like a mcu mind repeating data constantly.
    So keep toggling high-side for a holding current.

    Example: 1MHz SPI/16bit/ 3(daisy-chained) /4 (25/50/75% pwm ) = 5KHz

    compare that to ST's L99MD02 have 4 internal PWM settings, but it only does it at 100Hz

  • jmgjmg Posts: 15,173
    tonyp12 wrote: »
    Or just do it in software, it's not like a mcu mind repeating data constantly.
    So keep toggling high-side for a holding current.

    Example: 1MHz SPI/16bit/ 3(daisy-chained) /4 (25/50/75% pwm ) = 5KHz

    compare that to ST's L99MD02 have 4 internal PWM settings, but it only does it at 100Hz
    Sure SW update works, and can mean the FETS take the current, not diodes. Less drop is less power.
    Is 5KHz going to be audible ?
    Is that ATA6838C ok from a power budget angle ?


Sign In or Register to comment.