On 23 January 2010 15:55, Klemen Ozebek <klemen.oze...@gmail.com> wrote:

> my charge pump require 12,5Khz signal, what would be the thread setting to
> get my charge pump working?

There is a charge pump realtime module:
http://www.linuxcnc.org/docview/html//man/man9/charge_pump.9.html

12.5kHz is every 80uS, so if you have a 40,000nS base thread then that
would be exactly right.

Alternatively you could use pwmgen to create a 50% duty cycle square
wave of arbitrary frequency.
http://www.linuxcnc.org/docview/html//man/man9/pwmgen.9.html

In your case you would need the following lines in your HAL file.

loadrt pwmgen output_type=0
addf pwmgen.make-pulses base-thread
addf pwmgen.update servo-thread

setp pwmgen.0.enable 1
setp pwmgen.0.pwm-freq 12500
setp pwmgen.0.scale 100
setp pwngen.0.value 50


(You might not need the addf pwgen.update..... line as the pwm is
fixed in value, try running without it)
(You might also want to connect the pwmgen.enable to the e-stop, but
this way the amp is live as long as the realtime system is running)

-- 
atp

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to