On Wed, Sep 15, 2010 at 12:42:55PM -0500, Jon Elson wrote: > The PPMC > driver takes a +/- 1.0 value and multiplies it by 10 to give a +/- 10 V > output range.
Are you sure? I was looking at the pwmgen code earlier instead of the dac code (not sure how these differ) and I *think* pwmgen full scale value at the hal input pin is +-1 and dac full scale value at the hal input pin is +-10. I think this means the scale I suggested is off by a factor of 10 (should have been 0.889 instead of 8.89). Here's the relevant code from the ppmc driver: volts = *(pg->value) / pg->scale; dc = (long) (((volts / 10.0) * 0x7FFF)+0x8000); Confusingly, I think we have PPMC: output in volts = value / scale Hostmot2: output in volts = 10 * (value / scale) STG: output in volts = (value - offset) * scale VTI: output in volts = (value - offset) * scale Motenc: output in volts = (value - offset) * scale (yay, I guess a few of them match) HAL Canonical analog output: output in volts = scale * value + offset or maybe the documentation means this (not sure): output in volts = scale * (value + offset) (HAL docs are from the time machine): http://www.linuxcnc.org/docs/2.1/html/hal/general_ref/index.html ------------------------------------------------------------------------------ Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users