Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Stuboy on July 27, 2013, 09:27:43 PM

Title: PWM to 0-10v voltage linearity problem?
Post by: Stuboy on July 27, 2013, 09:27:43 PM
Hi there I have one of the boards in the attached file. It proudly states it has on board PWM to voltage converter (I haven't traced the circuit yet but it appears to be based around an opto coupler then into an LM358 op amp.  Well it does indeed convert PWM to voltage but sadly not linearly!

My spindle VFD is set to 22000 for ten volts so you would think that 5v would be 11000, but no its roughly 7.5 volts at 11000.  The PWM signal is however 50/50!
Can anyone advise me on what the problem might be, and if there's a fix for this board as I assume its the breakout board that has the problem?

Regards
Stu
Title: Re: PWM to 0-10v voltage linearity problem?
Post by: ger21 on July 27, 2013, 10:49:15 PM
Make sure your pulley speeds are set to 0 min and 22,000 max.
Title: Re: PWM to 0-10v voltage linearity problem?
Post by: HimyKabibble on July 27, 2013, 11:07:57 PM
Sounds like their circuit has a hefty DC offset.  I'd guess even at a very low duty cycle the output voltage would be far higher than it should be.  Not much anyone here can do to help, with no schematic for that circuit.  This is the problem with some of the "great deals" on inexpensive hardware from China - a lot of it is just cr@p, and not worth buying at any price.

Regards,
Ray L.
Title: Re: PWM to 0-10v voltage linearity problem?
Post by: Stuboy on July 29, 2013, 07:55:20 AM
I Gerry
         I have set my pulley speed to 0 & 10000 for this experiment and i attach the resultant graph with what i think it should output i.e. a linear ramp "red" and what i am measuring "blue" which is ?   ???

Any advise would be most welcome

Regards
Stuart
Title: Re: PWM to 0-10v voltage linearity problem?
Post by: cncalex on July 29, 2013, 09:49:49 AM
Hi Stuart,
first thing I would do is to be shure that the  Linearity.dat file is not corrupted.
To do so just delete it. It is located in your profile macros folder. Be shure to
delete the right one if you have more then one profile.
When restarting Mach is creating a new clean file.

just a thought

Alex
Title: Re: PWM to 0-10v voltage linearity problem?
Post by: Stuboy on July 29, 2013, 12:16:19 PM
I should have mentioned my pulse train looks fine, its 50/50 at 5000 rpm which as i have "max" set at 10000 would be correct? but my 0-10v output voltage is 8.1v!

Regards
Stuart