Driving a charge pump with a Mesa 5i25 stepgen

More
4 years 8 months ago #234128 by PCW
setp [HMOT](CARD0).stepgen.04.position-scale 10000
setp [HMOT](CARD0).stepgen.04.step_type 2
setp [HMOT](CARD0).stepgen.04.control-type 1
setp [HMOT](CARD0).stepgen.04.maxaccel 0
setp [HMOT](CARD0).stepgen.04.maxvel 0
setp [HMOT](CARD0).stepgen.04.velocity-cmd 0.25

This will generate a 2500 Hz square wave, not 10 KHz


For clarity, I would probable set


setp [HMOT](CARD0).stepgen.04.position-scale 1
setp [HMOT](CARD0).stepgen.04.velocity-cmd 10000

for a 10 KHz chargepump signal

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

More
4 years 8 months ago #234157 by dbotos
Peter,

Thanks.  I changed those two values and no luck.

Do I need to add a line that adds the charge pump to the base thread?  Section 14.10.2.9 of the 2.8.2 documentation says:

"The Charge Pump should be added to the base thread function."

 

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

More
4 years 8 months ago #234160 by PCW
No, the base thread is not needed for hardware stepgens

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

More
4 years 8 months ago #234174 by dbotos
Let me see if I understand this correctly:

position-scale = (distance) / (# of steps)

Divide the numerator and denominator of the right side by unit time:

position-scale = (distance / s) / (# steps / s)

If position-scale = 1, then:

(distance / s) = (# steps / s)

So a velocity command (distance / s) should generate a waveform of step pulses with a frequency (in Hz) equal to the value of the velocity commanded.

Is the charge pump expecting a 50% duty cycle wave?  Should the steplen and stepspace be bumped up to 50,000 ns each?

T = 50,000 ns + 50,000 ns = 100,000 ns

f = 1 / T = 1 / (0.000 100 000) = 10,000 Hz

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

More
4 years 8 months ago #234177 by PCW
The quadrature output mode (mode 2) insures 50% duty cycle

(the step time and step space need to be set to small
values so they do not limit the step rate)

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

More
4 years 8 months ago #234179 by dbotos
Ah, okay.

Am I missing some sort of virtual connection between the stepgen.04 output and pin 16 of the 5i25 DB25 connector (P3)?

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

Moderators: PCW, jmelson
Time to create page: 0.080 seconds
Powered by Kunena Forum