i have started using QtDragon_hd and need some help with my spindle

More
25 Jan 2024 18:58 #291619 by jyeomans
hello all after many years of geocarpy. i upgraded to linuxCNC 2.9.1 i all so switched to QtDragon_hd every thing works correctly as far as I can tell.  except for the spindle stuff.  The at speed light is instantly on.  There is no RPM reported. and I cannot change the speed.   I use the hy_vfd to control the spindle  I can see all the information in HAL show I seem to be a little lost on how to get it to work. i have looked over a few posts but have not seen what i am looking for.  


my vfd.hal file. 
loadusr -Wn vfd hy_vfd -n vfd -d /dev/ttyUSB0 -p none -r 9600
setp vfd.enable 1
net spindle-speed spindle.0.speed-out => vfd.speed-command
net spindle-cw spindle.0.forward => vfd.spindle-forward
net spindle-ccw spindle.0.reverse => vfd.spindle-reverse
net spindle-on spindle.0.on => vfd.spindle-on
net spindle-speed-fb <= vfd.spindle-speed-fb
net spindle-current <= vfd.OutA
net spindle-voltage <= vfd.ACV
#net spindle-current => qtdragon.spindle-amps
#net spindle-voltage => qtdragon.spindle-volts
net spindle-comm-ok <= vfd.hycomm-ok
net spindle-at-speed => vfd.spindle-at-speed
net spindle-at-speed <= spindle.0.at-speed
 

Please Log in or Create an account to join the conversation.

More
26 Jan 2024 03:03 #291639 by cmorley
Can you post the rest of your config files?

Please Log in or Create an account to join the conversation.

More
26 Jan 2024 13:14 #291654 by jyeomans
sure they are all most straight out of the stepcomf wizard. 
Attachments:

Please Log in or Create an account to join the conversation.

More
26 Jan 2024 22:03 - 26 Jan 2024 22:04 #291689 by cmorley
Any qtdragon pin names (such as in the vdf.hal file ) need to be call by POSTGUI_HALFILE
otherwise qtdragon might not of made the pins yet. you should have got error messages - maybe that's why you commented them out?

Start the spindle manually in qtdragon, then using halmeter can you check:
vfd.enable is true
spindle.0.forward or spindle.0.reverse is true
spindle.0.on is true
spindle.0.speed-out is getting a command number

Also do you still have the gmoccapy HAL code? are you using the same hardware? A reference to the vdf HAL code might help me.

finally, qtdragon's up_to_speed LED uses internal calculations to light based on spindle.0.speed-in and requested speed.
This can be changed to just work from an on/off state rather then internal calculations but let's not worry about that yet.
Last edit: 26 Jan 2024 22:04 by cmorley.

Please Log in or Create an account to join the conversation.

More
26 Jan 2024 22:52 #291693 by jyeomans
So this afternoon i moved all the qtdragon to the postgui_halfile.
and i got the power bar to work.
every thing works as it should.  when i run a file linuxCNC waits for the spindle to come to speed.  i just dont have any indication of the actual speed. 
i do have the files form my gmocapy install.

ind i think all the pins are correct.   
Attachments:

Please Log in or Create an account to join the conversation.

More
26 Jan 2024 23:23 #291695 by cmorley
try adding this to postgui:

net spindle-speed-feedback => spindle.0.speed-out-rps => spindle.0.speed-in

Please Log in or Create an account to join the conversation.

More
27 Jan 2024 00:02 #291699 by jyeomans
ok now it reflects the set speed and not the actual speed.
it turns on and instantaneously reports the set speed

but that is a result.

Please Log in or Create an account to join the conversation.

More
27 Jan 2024 00:24 #291700 by cmorley
Does vfd.spindle-speed-fb give RPM or RPS?
If it's RPS then you could use it:

net spindle-speed-fb <= vfd.spindle-speed-fb
net spindle-speed-fb => spindle.0.speed-in

Otherwise it would need to be scaled to RPS first

Please Log in or Create an account to join the conversation.

More
03 Feb 2024 14:40 #292311 by jyeomans
I am sorry i was not able to keep working on this. how ever i have had some time to get back to it today.

this does work! thank you for your time.

i had figured that i would need to scale the input. but i was not able to get any thing to show up on the rpm readout. But one step at a time.

i understand now that my problem is that i was trying to do every thing be for the post GUI hal file.
and that makes since to me now.

thanks you for your help.
i greatly appreciate it

Please Log in or Create an account to join the conversation.

Moderators: cmorley
Time to create page: 0.098 seconds
Powered by Kunena Forum