Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-10 Thread John Thornton
Tom, an even better explanation is in the 2.3 docs here:

http://www.linuxcnc.org/docs/devel/html/hal_basic_hal.html#r1_1_4

John

On 10 Jan 2009 at 6:20, Tom wrote:

 Stephen  John,
 
 I should have mentioned that it was me who was going to get the
 wording right all along ;-)
 
 John, thanks for your attention to helping me (or us) understand the
 new net
 command. I only recently started using it, and it works just as
 outlined here:
 http://www.linuxcnc.org/docview/html//hal_basic_hal.html#r1_1_4
 
 Of course you are right about leaving verbose comments in the body
 of the hal
 and ini files. I can do better here...
 
 Thanks a bunch for your help guys. 
 
 Tom
 
 
 
 
 
 
 --
 Check out the new SourceForge.net Marketplace.
 It is the best place to buy or sell services for
 just about anything Open Source.
 http://p.sf.net/sfu/Xq1LFB
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users
 



--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-10 Thread Donnie Timmons
John, thanks for your attention to helping me (or us) understand the new net
command. I only recently started using it, and it works just as outlined here:
http://www.linuxcnc.org/docview/html//hal_basic_hal.html#r1_1_4


I have to second Tom's comment. As a newbie to EMC you look at other files and 
they use linksp all thou the file but the manual never gives a explanation of 
linksp. If you search thru the manual it uses linksp several times in 
examples. So it kind of like stepping into a mud puddle the more you move 
around the muddier the puddle gets.  The link above is for the new commands the 
fact there are new commands and still working old commands that are not explain 
added to the mud. If you look in section 5.4.3 of the hal manual it list 
command that can be use in hal but does not list net. 

I think adding a section to the link above that shows old but still useable 
commands would be helpful. Then add the whole thing to the hal manual would 
great.

Donnie
--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-10 Thread John Thornton
I'm not sure if they are deprecated or not... I don't think they are perhaps 
just obsolete. I was 
just as lost with linksp and other commands when I first started. In the trunk 
(2.3) there is 
only 4 linksp's left to fix. Now that you reminded me :). and yes I need to add 
the description 
for them in the basic hal section somewhere because you will find them in most 
older 
configurations and some if not most of the sample configurations. 

Thanks for the feedback
John

On 10 Jan 2009 at 10:46, Greg Michalski wrote:

 Instead of a dedicated section for old commands - maybe the
 inclusion of the
 deprecated command(s) and formatting of it(them) where appropriate
 in the
 sections of the new 'preferred' commands/operations?  Or would it be
 easier
 from the standpoint of actually editing and maintaining the manual
 to make a
 dedicated section like Donnie suggests?
 
 Greg
 www.distinctperspectives.com
  
 
 -Original Message-
 From: Donnie Timmons [mailto:dtimm...@etex.net] 
 Sent: Saturday, January 10, 2009 9:41 AM
 To: emc-users@lists.sourceforge.net
 Subject: Re: [Emc-users] absolute analog output signal 0 - 10 V
 
 John, thanks for your attention to helping me (or us) understand
 the new
 net
 command. I only recently started using it, and it works just as
 outlined
 here:
 http://www.linuxcnc.org/docview/html//hal_basic_hal.html#r1_1_4
 
 
 I have to second Tom's comment. As a newbie to EMC you look at other
 files
 and they use linksp all thou the file but the manual never gives
 a
 explanation of linksp. If you search thru the manual it uses
 linksp
 several times in examples. So it kind of like stepping into a mud
 puddle the
 more you move around the muddier the puddle gets.  The link above is
 for the
 new commands the fact there are new commands and still working old
 commands
 that are not explain added to the mud. If you look in section 5.4.3
 of the
 hal manual it list command that can be use in hal but does not list
 net. 
 
 I think adding a section to the link above that shows old but still
 useable
 commands would be helpful. Then add the whole thing to the hal
 manual would
 great.
 
 Donnie
 
 
 --
 Check out the new SourceForge.net Marketplace.
 It is the best place to buy or sell services for
 just about anything Open Source.
 http://p.sf.net/sfu/Xq1LFB
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users
 
 
 
 --
 Check out the new SourceForge.net Marketplace.
 It is the best place to buy or sell services for
 just about anything Open Source.
 http://p.sf.net/sfu/Xq1LFB
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users
 



--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-10 Thread John Thornton
and quick as quick can be both Alex and myself added this almost at the same 
time :)

http://www.linuxcnc.org/docs/devel/html/hal_basic_hal.html#r1_1_6

John

On 10 Jan 2009 at 10:47, John Thornton wrote:

 I'm not sure if they are deprecated or not... I don't think they are
 perhaps just obsolete. I was 
 just as lost with linksp and other commands when I first started. In
 the trunk (2.3) there is 
 only 4 linksp's left to fix. Now that you reminded me :). and yes I
 need to add the description 
 for them in the basic hal section somewhere because you will find
 them in most older 
 configurations and some if not most of the sample configurations. 
 
 Thanks for the feedback
 John
 
 On 10 Jan 2009 at 10:46, Greg Michalski wrote:
 
  Instead of a dedicated section for old commands - maybe the
  inclusion of the
  deprecated command(s) and formatting of it(them) where
 appropriate
  in the
  sections of the new 'preferred' commands/operations?  Or would it
 be
  easier
  from the standpoint of actually editing and maintaining the
 manual
  to make a
  dedicated section like Donnie suggests?
  
  Greg
  www.distinctperspectives.com
   
  
  -Original Message-
  From: Donnie Timmons [mailto:dtimm...@etex.net] 
  Sent: Saturday, January 10, 2009 9:41 AM
  To: emc-users@lists.sourceforge.net
  Subject: Re: [Emc-users] absolute analog output signal 0 - 10 V
  
  John, thanks for your attention to helping me (or us)
 understand
  the new
  net
  command. I only recently started using it, and it works just
 as
  outlined
  here:
  http://www.linuxcnc.org/docview/html//hal_basic_hal.html#r1_1_4
  
  
  I have to second Tom's comment. As a newbie to EMC you look at
 other
  files
  and they use linksp all thou the file but the manual never
 gives
  a
  explanation of linksp. If you search thru the manual it uses
  linksp
  several times in examples. So it kind of like stepping into a
 mud
  puddle the
  more you move around the muddier the puddle gets.  The link above
 is
  for the
  new commands the fact there are new commands and still working
 old
  commands
  that are not explain added to the mud. If you look in section
 5.4.3
  of the
  hal manual it list command that can be use in hal but does not
 list
  net. 
  
  I think adding a section to the link above that shows old but
 still
  useable
  commands would be helpful. Then add the whole thing to the hal
  manual would
  great.
  
  Donnie
 
 
  
  --
  Check out the new SourceForge.net Marketplace.
  It is the best place to buy or sell services for
  just about anything Open Source.
  http://p.sf.net/sfu/Xq1LFB
  ___
  Emc-users mailing list
  Emc-users@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/emc-users
  
  
 
 
  --
  Check out the new SourceForge.net Marketplace.
  It is the best place to buy or sell services for
  just about anything Open Source.
  http://p.sf.net/sfu/Xq1LFB
  ___
  Emc-users mailing list
  Emc-users@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/emc-users
  
 
 
 
 
 --
 Check out the new SourceForge.net Marketplace.
 It is the best place to buy or sell services for
 just about anything Open Source.
 http://p.sf.net/sfu/Xq1LFB
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users
 



--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-09 Thread John Kasunich
Tom wrote:
 Marko Bukovinsky bukovinsk...@... writes:
 
 how to change this code into abosolute 0 - 10 Volt output?
 ...
 
 Mark, 
 Here is the abs statement from my m5i20_io.hal file, this might help you get 
 the
 wording right:
 
 loadrt abs count=2
 addf abs.0 servo-thread
 net spindle-rpm-cmd motion.spindle-speed-out
 newsig abs-spindle float
 linkps abs.0.in = spindle-rpm-cmd
 linkps abs.0.out = abs-spindle 
 linksp abs-spindle = m5i20.0.dac-03-value
 setp m5i20.0.dac-03-offset 0
 net SpindleOn motion.spindle-on
 linksp SpindleOn = m5i20.0.dac-03-enable
 setp m5i20.0.dac-03-gain [SPINDLE]DAC_SCALE
 
 I don't think it was necessary to load 2 abs realtime components, but that is
 what is in my file right now.


If you are only using one abs component, then you should say count=1 
(or leave count out - I'm about 99% sure the default is 1).  If you do 
need more than one, remember to have an addf command for each one.

The example above uses a mix of the old-style newsig/link notation and 
the current net notation, which I think makes it a bit confusing.  Here 
is the same thing using only net notation:

# route speed command through abs block to get 0-10V
loadrt abs
addf abs.0 servo-thread
net spindle-rpm-cmd motion.spindle-speed-out = abs.0.in
net spindle-rpm-cmd-abs abs.0.out = m5i20.0.dac-03-value
# scale factor converts RPM into DAC volts
setp m5i20.0.dac-03-gain [SPINDLE]DAC_SCALE
setp m5i20.0.dac-03-offset 0
net spindle-on motion.spindle-on = m5i20.0.dac-03-enable

I made a couple changes to signal names.  Signal names can be whatever 
you want, so make life easy for yourself.  The new names for the three 
signals all start with spindle, so when you do a halcmd show sig 
they will all be grouped together.  The would also appear close together 
in a halscope or halmeter dialog box.  The old ones started with 
spindle, Spindle, and abs, and would appear far apart in the 
listing or dialog.

The most important change is that I added a couple comments - some 
people may have perfect memory, but I don't.  When I want to change 
something on my machine a year or two after I did the initial config, 
comments will be vital to help me understand what I did back then.  The 
second comment is a bit lame, but that's because I don't actually know 
anything about this setup.  If it was my own machine, I would probably 
spell out the details, maybe something like:

# 10V to the VFD gives 60Hz = 1780 motor RPM, belt ratio is 2:1
# so 10V = 890 RPM at the spindle.  So 1V = 89 RPM.  When speed
# command is 89 RPM, I want 1V, so scale factor is 1/89 = 0.01123
setp m5i20.0.dac-03-gain 0.01123

Sure, if I can figure it out once, I can figure it out again later, but 
why?  Write it down while you are doing it, then you'll never have to
guess later.

Regards,

John Kasunich


--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-09 Thread Stephen Wille Padnos
John Kasunich wrote:

[snip]

# scale factor converts RPM into DAC volts
setp m5i20.0.dac-03-gain [SPINDLE]DAC_SCALE
setp m5i20.0.dac-03-offset 0
net spindle-on motion.spindle-on = m5i20.0.dac-03-enable
  

Note that this example (and Toms) requires you to have a [SPINDLE] 
section in your ini file, and there must be a DAC_SCALE value in that 
section, like so:

[SPINDLE]
DAC_SCALE = 0.01

- Steve


--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


[Emc-users] absolute analog output signal 0 - 10 V

2009-01-08 Thread Marko Bukovinsky
how to change this code into abosolute 0 - 10 Volt output?

loadrt scale count=1
addf scale.0 servo-thread
setp scale.0.gain  -0.004
net spindle-speed-scale motion.spindle-speed-out = scale.0.in
net spindle-speed-DAC scale.0.out = m5i20.0.dac-03-out

This works but when i use M4 S i get negative voltage output.

My VFD acceppt 0 - 10 Volt.

--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] absolute analog output signal 0 - 10 V

2009-01-08 Thread sam sokolik
I think I answered your question here..  (well one way..)
http://www.cnczone.com/forums/showthread.php?t=71072


If I am understanding what you want.. Could you send the 
motion.spindle-speed-out thru abs? (take the absolute value of it)

http://www.linuxcnc.org/docs/2.2/htm...an9/abs.9.html 
http://www.linuxcnc.org/docs/2.2/html/man/man9/abs.9.html

then it would always be positive..



Marko Bukovinsky wrote:
 how to change this code into abosolute 0 - 10 Volt output?

 loadrt scale count=1
 addf scale.0 servo-thread
 setp scale.0.gain  -0.004
 net spindle-speed-scale motion.spindle-speed-out = scale.0.in
 net spindle-speed-DAC scale.0.out = m5i20.0.dac-03-out

 This works but when i use M4 S i get negative voltage output.

 My VFD acceppt 0 - 10 Volt.

 --
 Check out the new SourceForge.net Marketplace.
 It is the best place to buy or sell services for
 just about anything Open Source.
 http://p.sf.net/sfu/Xq1LFB
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users

   

--
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users