On 01/14/2017 07:55 AM, Jan Bos wrote: > Hello everybody, > > Thanks for your replies, much appreciated but I got stuck with the scaling. > Since I already use one scaling component for the spindle speed display, I > need to add the scaling function for my 'spindle-load' signal. > The analog input works fine and reads the 5 or 10V from the VFD simulated > by a potentiometer on the desk very accurately. > I connected this 'spindle-load' signal to the Glade panel in a 'h-bar' and > set the maximum for the h-bar to 100 representing 100% max for spindle load. > The potentiometer is hooked up the 12V and I can see the h-bar happily > displaying a value between 0 and 10 when I turn the potentiometer. > > Now I need to scale this up and multiply the value read from the analog > input by 20 to get to the 100 I need for the h-bar. > > Sound simple right? Well I have been trying to get it to work but I need to > throw the towel in the for now because whatever I do, it shows a stubborn > zero and it wont budge. > > When I use the scale function the analog value goes into the scale > component and 0 (zero) comes out. > I am doing something wrong but I cant figure out where it goes wrong. > > First of all I added in my HAL file: > > loadrt scale names=scale.spindle,scale.spindle-load > > When I do this I can see the 2 scale components. > > Then I added this to the same HAL file: > > # Spindle load set-up > setp scale.spindle-load.gain 20 > net spindle-load => scale.spindle-load.in > net spindle-load-scaled => scale.spindle-load.out > > And I connect the 'spindle-load-scaled to the Gladevcp panel and I got > nothing. Zero. > Attached the screenshot from the HAL configuration showing what happens. > > I do get an error when I add this to my HAL: > > addf scale.spindleload servo-thread
Shouldn't that be scale.spindle-load? <snippage> > > G21 Cheers, Mark ------------------------------------------------------------------------------ Developer Access Program for Intel Xeon Phi Processors Access to Intel Xeon Phi processor-based developer platforms. With one year of Intel Parallel Studio XE. Training and support from Colfax. Order your platform today. http://sdm.link/xeonphi _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users