Shop OBEX P1 Docs P2 Docs Learn Events
-10 to +10 Volt Control (For Motor Controller) — Parallax Forums

-10 to +10 Volt Control (For Motor Controller)

I'm assisting a friend with a project that needs a new motor controller. The motor control products we've found that are in his budget tend to be voltage controlled. For our end, we're going to use a Propeller to run the thing if we can get this all sorted out.

Analog stuff like this is not my bag, so I'm hoping a friend or two here can point me in the right direction so I can help my friend.

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2016-09-07 20:16
    Wouldn't a PWM'd H-bridge do the job? Nevermind. I misread. It's the motor controller that requires the +-10V, not the motor itself.

    -Phil
  • Jon, I think this circuit will work, but I'll test it to make sure:

    DAC.gif

    -Phil
    580 x 260 - 3K
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2016-09-07 21:29
    Here's the circuit that eventually worked. I had to buffer the DUTY-mode input to get a full-scale output. And the pot has to be there to adjust for offset.

    DAC2.gif

    Here's what the output looks like, using the program shown below it:

    DAC%20Output.gif
    CON
    
      _clkmode      = xtal1 + pll16x
      _xinfreq      = 5_000_000
    
    VAR
    
      long  i
    
    PUB  start
    
      dira[0]~~
      ctra := %00110 << 26
      repeat
        repeat i from 0 to $7fff_ffff step $80000
          frqa := i << 1
    
    640 x 480 - 11K
  • Here is an alternative.

    5v PWM @ 50% duty = 0v
  • Mickster wrote:
    5v PWM ...
    The Propeller outputs a 3.3V DUTY/PWM.

    -Phil
  • Mickster wrote:
    5v PWM ...
    The Propeller outputs a 3.3V DUTY/PWM.

    -Phil

    Oh sure but when interfacing to industrial servo drives and I/O, I opto-couple everything and I use a separate 5v PSU for the isolated stuff. +/- 10v is the standard motor command in my world.

  • Your opto output would have to be push-pull for your circuit to work without an input buffer. Most optos are open-collector/open-drain.

    -Phil
  • Hmmm, don't remember the specifics. It's been many years since we used the LM629 motion chip which gave us no-end of trouble until we isolated the PWM. Funnily enough, I only had that image because a customer was asking if he could modify it to accommodate an offset pot....something that you already thought of :smile:
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2016-09-09 02:31
    Just use a single opamp in the non-inverting config, I've done it heaps of times. One resistor for gain, none for offset. (The values shown are for 0-3V in but if you use two resistors in series it is very easy to trim to an exact value )
    0-10v.png
    Try 6k8 for R2 and then 12k + 1k8 for a gain of 3.03 * 3.3V = 9.997V
    1117 x 467 - 23K
Sign In or Register to comment.