PnCConf and setting up PWM on 7i96

More
01 Apr 2020 22:55 #162396 by GND
No problem;

26 bit IN TRUE hm2_7i96.0.pwmgen.00.enable
26 float IN 1 hm2_7i96.0.pwmgen.00.value <== spindle-speed
==> hm2_7i96.0.pwmgen.00.value
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out0.invert_output
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out0.is_opendrain
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out1.invert_output
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out1.is_opendrain
26 s32 RW 1 hm2_7i96.0.pwmgen.00.output-type
26 float RW 5000 hm2_7i96.0.pwmgen.00.scale
26 u32 RW 0x00004E20 hm2_7i96.0.pwmgen.pdm_frequency
26 u32 RW 0x000003E8 hm2_7i96.0.pwmgen.pwm_frequency
hm2_7i96.0.pwmgen.00.out0.invert_output hm2_7i96.0.gpio.025.invert_output
hm2_7i96.0.pwmgen.00.out0.is_opendrain hm2_7i96.0.gpio.025.is_opendrain
hm2_7i96.0.pwmgen.00.out1.invert_output hm2_7i96.0.gpio.026.invert_output
hm2_7i96.0.pwmgen.00.out1.is_opendrain hm2_7i96.0.gpio.026.is_opendrain

Hope that gives you some clues....
Graeme

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

More
01 Apr 2020 23:08 #162399 by PCW
OK so if the scale is 5000 did you try setting the spindle speed to 2500 (that should be 50% duty cycle)

The current value of 1 would be close to 0 PWM duty cycle

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

More
01 Apr 2020 23:10 #162400 by GND
This is with 51% dialed in for spindle speed override....

26 bit IN TRUE hm2_7i96.0.pwmgen.00.enable
26 float IN 0.51 hm2_7i96.0.pwmgen.00.value <== spindle-speed
==> hm2_7i96.0.pwmgen.00.value
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out0.invert_output
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out0.is_opendrain
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out1.invert_output
26 bit RW FALSE hm2_7i96.0.pwmgen.00.out1.is_opendrain
26 s32 RW 1 hm2_7i96.0.pwmgen.00.output-type
26 float RW 5000 hm2_7i96.0.pwmgen.00.scale
26 u32 RW 0x00004E20 hm2_7i96.0.pwmgen.pdm_frequency
26 u32 RW 0x000003E8 hm2_7i96.0.pwmgen.pwm_frequency
hm2_7i96.0.pwmgen.00.out0.invert_output hm2_7i96.0.gpio.025.invert_output
hm2_7i96.0.pwmgen.00.out0.is_opendrain hm2_7i96.0.gpio.025.is_opendrain
hm2_7i96.0.pwmgen.00.out1.invert_output hm2_7i96.0.gpio.026.invert_output
hm2_7i96.0.pwmgen.00.out1.is_opendrain hm2_7i96.0.gpio.026.is_opendrain

I thought it looked convincing!

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

More
01 Apr 2020 23:14 #162401 by GND
I presume that just dialing a spindle override should affect the PWM output - if the spindle is enabled? Or do I need to achieve it via MDI, or by some other means?

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

More
01 Apr 2020 23:19 #162403 by PCW
I would do it with mdi

S2500 M3

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

More
01 Apr 2020 23:27 #162406 by GND
Guess what! That worked...

It seems strange that I was getting the value I selected via the override visible on the PWM value pin - but maybe it was a slightly artificial test. Either way, I'm more than happy with that and can now make progress.

Many thanks - once again - for your exceptional support.

Cheers
Graeme
The following user(s) said Thank You: Clive S

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

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