Discussion:
[Emc-users] Maybe we don't need rtai anymore?
sam sokolik
2017-07-04 22:22:27 UTC
Permalink
I have been playing with linuxcnc for a long time... It has come a long
way.

Currently the RTAI folks seem to have issues developing.

Now there is RT_Preempt. Couple cool things.. It has been migrated to
the linux foundation. This means a lot eyes on it. It is also pretty
easy to build. I have done it quite a few times now. My experience is
that the out of the box rt_preemt has ok realtime performance.
Anywhere from 20 to 100us latency. Perfect for external interface cards
(mesa, pico and such). I have a computer that has decent enough
rt-preempt performance that it is running 50us base thread. (small emco
lathe - 100 line encoder for threading) I have been running this for
quite a while this way with no issues.

Why am I rambling...

Well - I have been playing with debian stretch and 4.9.0-3-rt kernel.
I booted our matsuura (j1900 quad core) which with no tweeking has aprox
100us latency. (it has been running mesa ethernet cards with rt_preempt
- no issues) Next I booted it with some kernel line tweaks. (checking
the hardware - processors 0,1 and 2,3 share cache. So I added

isolcpus=2,3 idle=poll

The latency on this system was phenomenal. It has been running for
hours now and still <6us



these numbers are as good or better than rtai. Could we, with some
tweaks, use rt_preempt for printer port configs and forget about rtai
for now? I have more computer hardware I can test - but this is pretty
awesome.

Good video explaining realtime


Rt-preempt even runs decently on my laptop. I have actually run test
and real machines with it. (don't mute the speakers though... causes
huge spikes)

sam
sam sokolik
2017-07-04 22:33:10 UTC
Permalink
This image got stripped

Loading Image...

sam
I have been playing with linuxcnc for a long time... It has come a
long way.
Currently the RTAI folks seem to have issues developing.
Now there is RT_Preempt. Couple cool things.. It has been migrated
to the linux foundation. This means a lot eyes on it. It is also
pretty easy to build. I have done it quite a few times now. My
experience is that the out of the box rt_preemt has ok realtime
performance. Anywhere from 20 to 100us latency. Perfect for
external interface cards (mesa, pico and such). I have a computer
that has decent enough rt-preempt performance that it is running 50us
base thread. (small emco lathe - 100 line encoder for threading) I
have been running this for quite a while this way with no issues.
Why am I rambling...
Well - I have been playing with debian stretch and 4.9.0-3-rt
kernel. I booted our matsuura (j1900 quad core) which with no
tweeking has aprox 100us latency. (it has been running mesa ethernet
cards with rt_preempt - no issues) Next I booted it with some kernel
line tweaks. (checking the hardware - processors 0,1 and 2,3 share
cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
these numbers are as good or better than rtai. Could we, with some
tweaks, use rt_preempt for printer port configs and forget about rtai
for now? I have more computer hardware I can test - but this is
pretty awesome.
Good video explaining realtime
http://youtu.be/BKkX9WASfpI
Rt-preempt even runs decently on my laptop. I have actually run test
and real machines with it. (don't mute the speakers though... causes
huge spikes)
sam
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Todd Zuercher
2017-07-04 23:57:35 UTC
Permalink
That looks pretty nice. My J1900 board is only around 10us running RTAI. Maybe I'll have to give it a try.

But can a Preempt-rt kernel pull off acceptable latency scores (50-100us) on old hardware? Such as the old P4 box (with ISA slots) I have that runs great with Lucid (20us), but I can't get the Wheezy RTAI Kernel to work on it at all.

----- Original Message -----
From: "sam sokolik" <***@empirescreen.com>
To: "Enhanced Machine Controller (EMC)" <emc-***@lists.sourceforge.net>
Sent: Tuesday, July 4, 2017 6:33:10 PM
Subject: Re: [Emc-users] Maybe we don't need rtai anymore?

This image got stripped

http://electronicsam.com/images/KandT/testing/user-04Jul2017-1172.png

sam
I have been playing with linuxcnc for a long time... It has come a
long way.
Currently the RTAI folks seem to have issues developing.
Now there is RT_Preempt. Couple cool things.. It has been migrated
to the linux foundation. This means a lot eyes on it. It is also
pretty easy to build. I have done it quite a few times now. My
experience is that the out of the box rt_preemt has ok realtime
performance. Anywhere from 20 to 100us latency. Perfect for
external interface cards (mesa, pico and such). I have a computer
that has decent enough rt-preempt performance that it is running 50us
base thread. (small emco lathe - 100 line encoder for threading) I
have been running this for quite a while this way with no issues.
Why am I rambling...
Well - I have been playing with debian stretch and 4.9.0-3-rt
kernel. I booted our matsuura (j1900 quad core) which with no
tweeking has aprox 100us latency. (it has been running mesa ethernet
cards with rt_preempt - no issues) Next I booted it with some kernel
line tweaks. (checking the hardware - processors 0,1 and 2,3 share
cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
these numbers are as good or better than rtai. Could we, with some
tweaks, use rt_preempt for printer port configs and forget about rtai
for now? I have more computer hardware I can test - but this is
pretty awesome.
Good video explaining realtime
http://youtu.be/BKkX9WASfpI
Rt-preempt even runs decently on my laptop. I have actually run test
and real machines with it. (don't mute the speakers though... causes
huge spikes)
sam
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
Emc-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users
Chris Albertson
2017-07-05 16:03:45 UTC
Permalink
Maybe what's needed is a stable and well supported real-time OS.
Xenomai might work.

But even better is a more modularized Machine Kit architecture that
lets you run the various parts on different computers that each use a
different OS. The real time loops could run under a true RTOS,
then path planning g-code parsing and graphics could all be done on
some other computers or even a couple of them in user space.

I'm using an RTOS for some other motion control work and getting much
better performance on much less powerful hardware.

On Tue, Jul 4, 2017 at 4:57 PM, Todd Zuercher
Post by Todd Zuercher
That looks pretty nice. My J1900 board is only around 10us running RTAI. Maybe I'll have to give it a try.
But can a Preempt-rt kernel pull off acceptable latency scores (50-100us) on old hardware? Such as the old P4 box (with ISA slots) I have that runs great with Lucid (20us), but I can't get the Wheezy RTAI Kernel to work on it at all.
----- Original Message -----
Sent: Tuesday, July 4, 2017 6:33:10 PM
Subject: Re: [Emc-users] Maybe we don't need rtai anymore?
This image got stripped
http://electronicsam.com/images/KandT/testing/user-04Jul2017-1172.png
sam
I have been playing with linuxcnc for a long time... It has come a
long way.
Currently the RTAI folks seem to have issues developing.
Now there is RT_Preempt. Couple cool things.. It has been migrated
to the linux foundation. This means a lot eyes on it. It is also
pretty easy to build. I have done it quite a few times now. My
experience is that the out of the box rt_preemt has ok realtime
performance. Anywhere from 20 to 100us latency. Perfect for
external interface cards (mesa, pico and such). I have a computer
that has decent enough rt-preempt performance that it is running 50us
base thread. (small emco lathe - 100 line encoder for threading) I
have been running this for quite a while this way with no issues.
Why am I rambling...
Well - I have been playing with debian stretch and 4.9.0-3-rt
kernel. I booted our matsuura (j1900 quad core) which with no
tweeking has aprox 100us latency. (it has been running mesa ethernet
cards with rt_preempt - no issues) Next I booted it with some kernel
line tweaks. (checking the hardware - processors 0,1 and 2,3 share
cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
these numbers are as good or better than rtai. Could we, with some
tweaks, use rt_preempt for printer port configs and forget about rtai
for now? I have more computer hardware I can test - but this is
pretty awesome.
Good video explaining realtime
http://youtu.be/BKkX9WASfpI
Rt-preempt even runs decently on my laptop. I have actually run test
and real machines with it. (don't mute the speakers though... causes
huge spikes)
sam
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
--
Chris Albertson
Redondo Beach, California
Nicklas Karlsson
2017-07-05 17:01:04 UTC
Permalink
Post by Chris Albertson
But even better is a more modularized Machine Kit architecture that
lets you run the various parts on different computers that each use a
different OS. The real time loops could run under a true RTOS,
then path planning g-code parsing and graphics could all be done on
some other computers or even a couple of them in user space.
Sound reasonable and I am working in that direction although a little bit slow but soon I should be able to move into Linuxcnc.
Post by Chris Albertson
I'm using an RTOS for some other motion control work and getting much
better performance on much less powerful hardware.
I also do but mostly I run from interrupt handler with almost perfect performance. I think need for real time computation are rather small compared to most software on an ordinary computer.

Number of real time tasks are rather small. I guess TCP/IP communication is the choice for communication with user interface. For real timer there might be Ethercat, CAN, UART, SPI and they are all usually availble for the larger micro controllers, GPIOs connected directly to CPU bus may also be used but there are limited number available of these.
andy pugh
2017-07-05 17:49:53 UTC
Permalink
Post by Chris Albertson
But even better is a more modularized Machine Kit architecture that
lets you run the various parts on different computers that each use a
different OS.
Maybe, but the raison d'etre of LinuxCNC is "one, off the shelf,
machine does everything"

I am not even sure that LinuxCNC is a good starting point for such a
distributed architecture.
--
atp
"A motorcycle is a bicycle with a pandemonium attachment and is
designed for the especial use of mechanical geniuses, daredevils and
lunatics."
— George Fitch, Atlanta Constitution Newspaper, 1916
Nicklas Karlsson
2017-07-05 18:14:11 UTC
Permalink
Post by andy pugh
Post by Chris Albertson
But even better is a more modularized Machine Kit architecture that
lets you run the various parts on different computers that each use a
different OS.
Maybe, but the raison d'etre of LinuxCNC is "one, off the shelf,
machine does everything"
It does but there are several "modules" with communication in between.
Post by andy pugh
I am not even sure that LinuxCNC is a good starting point for such a
distributed architecture.
There are NML communication between the modules.

I have started by moving servo control loop a step further down. Next step will be splitting real time part from GUI and it this point I could start to contribute something useful.


Nicklas Karlsson
theman whosoldtheworld
2017-07-06 07:31:21 UTC
Permalink
Post by Nicklas Karlsson
There are NML communication between the modules.
I'm workin on powerLink ie & opensafety bus using NML .... I'm quite sure
that NML is thinking for remote/local interface not for other pourposes
.... any how the new realtime bus (for ex. lasth mounth I ask about CC-Link
ie, 1Gb data 1ms realtime ... this mouth I discover a "tryk to become
cc-link ie association member for free ... so I study about) in adding a
custom realtime comp They can simulate your think. By the way, I'm not a
developer so any one of them can defy me ... but I think you have to go a
little further behind NML to achieve your purpose.
I plan to do these, but first realize my project for learn me about
internal call of Lcnc ... after study realtime linux book than try to do
somethings about.

bkt
Post by Nicklas Karlsson
Post by andy pugh
Post by Chris Albertson
But even better is a more modularized Machine Kit architecture that
lets you run the various parts on different computers that each use a
different OS.
Maybe, but the raison d'etre of LinuxCNC is "one, off the shelf,
machine does everything"
It does but there are several "modules" with communication in between.
Post by andy pugh
I am not even sure that LinuxCNC is a good starting point for such a
distributed architecture.
There are NML communication between the modules.
I have started by moving servo control loop a step further down. Next step
will be splitting real time part from GUI and it this point I could start
to contribute something useful.
Nicklas Karlsson
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Les Newell
2017-07-06 15:13:47 UTC
Permalink
I have been working on retrofitting my Hurco mill for the last couple of
days and I'm about ready to start setting up LinuxCNC. However I'm lost
as to the correct bit file and configuration options for a 7i80HD +7i48
combination.
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1. I
have my I/Os on P3.
I'm not sure what my loadrt line should be. I got this far:
loadrt hm2_eth board_ip="192.168.1.121" config="num_encoders=6
num_pwmgens=6"
Looking at the gpio parameters I can see 0-23 are missing as expected.
However 48,49 and 50 are missing as well, which is a bit unfortunate as
50 is my drives enable. Am I doing something wrong or do I need to make
a longer ribbon cable so I can put my I/Os on P2?

Les
Nicklas Karlsson
2017-07-06 15:43:11 UTC
Permalink
On Thu, 6 Jul 2017 16:13:47 +0100
Post by Les Newell
I have been working on retrofitting my Hurco mill for the last couple of
days and I'm about ready to start setting up LinuxCNC. However I'm lost
as to the correct bit file and configuration options for a 7i80HD +7i48
combination.
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1. I
have my I/Os on P3.
loadrt hm2_eth board_ip="192.168.1.121" config="num_encoders=6
num_pwmgens=6"
I got in the *.ini file:
[HOSTMOT2_2]
DRIVER=hm2_eth board_ip="192.168.1.11,192.168.1.10"
BOARD=7i80
CONFIG="firmware=hm2/7i80-1.5/SVST8_8.BIT num_encoders=4 num_pwmgens=4 num_stepgens=8"

And in the *.hal file:
loadrt [HOSTMOT2_2](DRIVER) config=[HOSTMOT2_2](CONFIG)
loadrt hostmot2

Then running with two cards, parameters are probably not useful for you but should give a hint.
andy pugh
2017-07-06 15:45:34 UTC
Permalink
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1. I have
my I/Os on P3.
https://github.com/LinuxCNC/hostmot2-firmware/blob/master/src/PIN_SV12IM_2X7I48_72.vhd

Which I think means that the 7i48s would use IO pins 0 to 23 on P1 and
24 to 47 on P2.

But IO 48 to 59 are also set up to be index mask pins for each of the
6 encoders, which is a little unfortunate but probably explains what
the "im" is in 7i80hd-16-sv12im-2x7i48.

Is there a 7i80hd-16-sv12-2x7i48 bitfile to try instead?
--
atp
"A motorcycle is a bicycle with a pandemonium attachment and is
designed for the especial use of mechanical geniuses, daredevils and
lunatics."
— George Fitch, Atlanta Constitution Newspaper, 1916
Peter C. Wallace
2017-07-06 15:54:11 UTC
Permalink
Date: Thu, 6 Jul 2017 16:13:47 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: [Emc-users] Configuration options for 7i80 + 7i48
I have been working on retrofitting my Hurco mill for the last couple of days
and I'm about ready to start setting up LinuxCNC. However I'm lost as to the
correct bit file and configuration options for a 7i80HD +7i48 combination.
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1. I have
my I/Os on P3.
loadrt hm2_eth board_ip="192.168.1.121" config="num_encoders=6 num_pwmgens=6"
Looking at the gpio parameters I can see 0-23 are missing as expected.
However 48,49 and 50 are missing as well, which is a bit unfortunate as 50 is
my drives enable. Am I doing something wrong or do I need to make a longer
ribbon cable so I can put my I/Os on P2?
Les
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Yeah that config has index masks on P3 so some pins will be forced to be
inputs (the IM in the name) Either use P2 or maybe try 7i80hd_16_svss6_8.bit
(it has sserial on P3 but you should be able to disable the probe for sserial
devices in driver the config line)

Peter Wallace
Mesa Electronics
Les Newell
2017-07-06 16:14:40 UTC
Permalink
Hi Andy,

I can't find a 7i80hd-16-sv12-2x7i48 so I'll try Peter's suggestion of
7i80hd_16_svss6_8.

Les
Post by Peter C. Wallace
Date: Thu, 6 Jul 2017 16:13:47 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
To: "Enhanced Machine Controller (EMC)"
Subject: [Emc-users] Configuration options for 7i80 + 7i48
I have been working on retrofitting my Hurco mill for the last couple
of days and I'm about ready to start setting up LinuxCNC. However I'm
lost as to the correct bit file and configuration options for a
7i80HD +7i48 combination.
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1.
I have my I/Os on P3.
loadrt hm2_eth board_ip="192.168.1.121" config="num_encoders=6 num_pwmgens=6"
Looking at the gpio parameters I can see 0-23 are missing as
expected. However 48,49 and 50 are missing as well, which is a bit
unfortunate as 50 is my drives enable. Am I doing something wrong or
do I need to make a longer ribbon cable so I can put my I/Os on P2?
Les
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Yeah that config has index masks on P3 so some pins will be forced to
be inputs (the IM in the name) Either use P2 or maybe try
7i80hd_16_svss6_8.bit
(it has sserial on P3 but you should be able to disable the probe for
sserial devices in driver the config line)
Peter Wallace
Mesa Electronics
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter C. Wallace
2017-07-06 16:16:39 UTC
Permalink
Date: Thu, 6 Jul 2017 17:14:40 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
Hi Andy,
I can't find a 7i80hd-16-sv12-2x7i48 so I'll try Peter's suggestion of
7i80hd_16_svss6_8.
Les
Heres a 2x 7i48 7I80HD-16 config with no index mask option:

http://freeby.mesanet.com/7i80hd_16_sv12_2x7i48.bit

Peter Wallace
Mesa Electronics
Post by Peter C. Wallace
Date: Thu, 6 Jul 2017 16:13:47 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: [Emc-users] Configuration options for 7i80 + 7i48
I have been working on retrofitting my Hurco mill for the last couple of
days and I'm about ready to start setting up LinuxCNC. However I'm lost as
to the correct bit file and configuration options for a 7i80HD +7i48
combination.
I have 7i80hd-16-sv12im-2x7i48 bitfile loaded and the 7i48 is on P1. I
have my I/Os on P3.
loadrt hm2_eth board_ip="192.168.1.121" config="num_encoders=6 num_pwmgens=6"
Looking at the gpio parameters I can see 0-23 are missing as expected.
However 48,49 and 50 are missing as well, which is a bit unfortunate as 50
is my drives enable. Am I doing something wrong or do I need to make a
longer ribbon cable so I can put my I/Os on P2?
Les
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Yeah that config has index masks on P3 so some pins will be forced to be
inputs (the IM in the name) Either use P2 or maybe try
7i80hd_16_svss6_8.bit
(it has sserial on P3 but you should be able to disable the probe for
sserial devices in driver the config line)
Peter Wallace
Mesa Electronics
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
Les Newell
2017-07-06 17:01:14 UTC
Permalink
Hi Peter,

I tried that one and 7i80hd_16_svss6_8. The encoders appear to work but
I'm not getting any analog out.

Each pwmgen is configured the same:
output-type 1
scale 1
enable true
value in the range -1 to +1

Les
Post by Peter C. Wallace
http://freeby.mesanet.com/7i80hd_16_sv12_2x7i48.bit
Peter Wallace
Mesa Electronics
Peter C. Wallace
2017-07-06 17:29:11 UTC
Permalink
Date: Thu, 6 Jul 2017 18:01:14 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
Hi Peter,
I tried that one and 7i80hd_16_svss6_8. The encoders appear to work but I'm
not getting any analog out.
output-type 1
scale 1
enable true
value in the range -1 to +1
Les
Note that 7I48 PWMGens must be configued in up/down mode (mode 2)

Also note that the 7I48 has a global analog out enable, most firmware connects
this to PWMEna 0
Post by Peter C. Wallace
http://freeby.mesanet.com/7i80hd_16_sv12_2x7i48.bit
Peter Wallace
Mesa Electronics
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
Les Newell
2017-07-06 18:05:33 UTC
Permalink
I set pwmgen.00.enable to true and set the output-type of the 4 pwmgens
I am currently using to 2 but I'm still getting no output.

Les
Post by Peter C. Wallace
Note that 7I48 PWMGens must be configued in up/down mode (mode 2)
Also note that the 7I48 has a global analog out enable, most firmware
connects this to PWMEna 0
Peter C. Wallace
2017-07-06 18:13:59 UTC
Permalink
Date: Thu, 6 Jul 2017 19:05:33 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
I set pwmgen.00.enable to true and set the output-type of the 4 pwmgens I am
currently using to 2 but I'm still getting no output.
Les
What is the pwm value?
Post by Peter C. Wallace
Note that 7I48 PWMGens must be configued in up/down mode (mode 2)
Also note that the 7I48 has a global analog out enable, most firmware
connects this to PWMEna 0
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
Les Newell
2017-07-06 18:21:42 UTC
Permalink
I'm setting the pwm value in the range -1 to +1 with scale set to 1.

Les
Post by Peter C. Wallace
What is the pwm value?
Peter C. Wallace
2017-07-06 19:28:35 UTC
Permalink
Date: Thu, 6 Jul 2017 19:21:42 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
I'm setting the pwm value in the range -1 to +1 with scale set to 1.
Les
Hmm, can't duplicate that here, just tested and PWM / analog
out works on both 7i80hd_16_svss6_8 and 7i80hd_16_sv12_2x7i48.bit

(using a basic hal file with PID setup and
looking at analog out on a meter while turning encoder)


Here are my test hal/ini files:

http://freeby.mesanet.com/7i80-7i48.zip
Post by Peter C. Wallace
What is the pwm value?
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
Les Newell
2017-07-06 20:17:45 UTC
Permalink
I took some time out to modify the spindle motor windings - I'm
converting it from 415V to 230V. Anyway I got the axes working by
turning all of the enables on. I now have motion and yikes, it's fast!
I'm only running 10m/min and the machine is rated for 15. With a Y
travel of only 0.5m it doesn't take long to get from one end to the other.

Thanks for your help.

Oh, by the way with 7i80hd_16_svss6_8 a couple of my outputs would pulse
on for a fraction of a second as LinuxCNC started up. I think it was 51
and 53. My outputs are active high with the 7i80 resistors set to pull
down. It's no big deal and 7i80hd_16_sv12_2x7i48 doesn't do it.

Les
Post by Peter C. Wallace
Date: Thu, 6 Jul 2017 19:21:42 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
I'm setting the pwm value in the range -1 to +1 with scale set to 1.
Les
Hmm, can't duplicate that here, just tested and PWM / analog
out works on both 7i80hd_16_svss6_8 and 7i80hd_16_sv12_2x7i48.bit
(using a basic hal file with PID setup and
looking at analog out on a meter while turning encoder)
http://freeby.mesanet.com/7i80-7i48.zip
Post by Peter C. Wallace
What is the pwm value?
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics
(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter C. Wallace
2017-07-06 20:49:54 UTC
Permalink
Date: Thu, 6 Jul 2017 21:17:45 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
I took some time out to modify the spindle motor windings - I'm converting it
from 415V to 230V. Anyway I got the axes working by turning all of the
enables on. I now have motion and yikes, it's fast! I'm only running 10m/min
and the machine is rated for 15. With a Y travel of only 0.5m it doesn't take
long to get from one end to the other.
Thanks for your help.
Oh, by the way with 7i80hd_16_svss6_8 a couple of my outputs would pulse on
for a fraction of a second as LinuxCNC started up. I think it was 51 and 53.
My outputs are active high with the 7i80 resistors set to pull down. It's no
big deal and 7i80hd_16_sv12_2x7i48 doesn't do it.
I forgot that in addition to controlling the external enable pins, the PWM
enable sets PWM to 0 in the driver when not enabled so all active PWM channels
must have enable set true


And yes, sserial outputs are enabled to do the sserial device probe (and
disabled when nothing is found), I _think_ you can disable this behaviour by
disabling all sserial ports in the config line (but probably better to just
use a config that doesnt have sserial if you dont need it)
Les
Post by Peter C. Wallace
Date: Thu, 6 Jul 2017 19:21:42 +0100
Reply-To: "Enhanced Machine Controller (EMC)"
Subject: Re: [Emc-users] Configuration options for 7i80 + 7i48
I'm setting the pwm value in the range -1 to +1 with scale set to 1.
Les
Hmm, can't duplicate that here, just tested and PWM / analog
out works on both 7i80hd_16_svss6_8 and 7i80hd_16_sv12_2x7i48.bit
(using a basic hal file with PID setup and
looking at analog out on a meter while turning encoder)
http://freeby.mesanet.com/7i80-7i48.zip
Post by Peter C. Wallace
What is the pwm value?
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics
(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
andy pugh
2017-07-06 22:07:43 UTC
Permalink
Post by Peter C. Wallace
And yes, sserial outputs are enabled to do the sserial device probe (and
disabled when nothing is found), I _think_ you can disable this behaviour by
disabling all sserial ports in the config line (but probably better to just
use a config that doesnt have sserial if you dont need it)
"sserial_port_0=xxxxxxxx" in the config= string should do the trick.
--
atp
"A motorcycle is a bicycle with a pandemonium attachment and is
designed for the especial use of mechanical geniuses, daredevils and
lunatics."
— George Fitch, Atlanta Constitution Newspaper, 1916
Gene Heskett
2017-07-05 01:58:15 UTC
Permalink
Post by sam sokolik
I have been playing with linuxcnc for a long time... It has come a
long way.
Currently the RTAI folks seem to have issues developing.
Now there is RT_Preempt. Couple cool things.. It has been migrated
to the linux foundation. This means a lot eyes on it. It is also
pretty easy to build. I have done it quite a few times now. My
experience is that the out of the box rt_preemt has ok realtime
performance. Anywhere from 20 to 100us latency. Perfect for external
interface cards (mesa, pico and such). I have a computer that has
decent enough rt-preempt performance that it is running 50us base
thread. (small emco lathe - 100 line encoder for threading) I have
been running this for quite a while this way with no issues.
Why am I rambling...
Well - I have been playing with debian stretch and 4.9.0-3-rt kernel.
I booted our matsuura (j1900 quad core) which with no tweeking has
aprox 100us latency. (it has been running mesa ethernet cards with
rt_preempt - no issues) Next I booted it with some kernel line
tweaks. (checking the hardware - processors 0,1 and 2,3 share cache.
So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
Somebody figure out how to do that to an r-pi-3b please, running on
4.4.4-rt9-v7+ #7 SMP PREEMPT RT Mon Mar 7 14:53:11 UTC 2016 armv7l
GNU/Linux.

Is horrible. None of the newer kernels Bertho and I have tried are any
better, as they all throw away half the local keyboard and mouse events,
making typing code impossible. The one above works well in that regard
about 1 out of 3 powerdown reboots, and never on a hot reboot.

An even when the keyboard behaves itself, I am looking at an exit report
from a 4 hour session of linuxcnc showing 20 to 100 or more instances it
overran the 1khz servo-thread by more than 10x the servo-thread times.

Thanks to Andy's help, its now running both g33 and g76, HOWEVER I had to
slow the spindle to around 50 rpms AND move the starting point, which I
did have set .1" off the end of the workpiece, to .5" off the end of the
workpiece. Why? Huge rubber band in series with the z movements,
associated I think with the z acceleration limits, so z would start,
wind up and overtake the spindle, then slowly settles into a steady run
until the stop point was reached, at which time it stopped nicely and
dead on the stop point, only on the start point did it hunt for synch.

Once I had done that, the threads were cut very precisely, so precisely
that if I want exact groove widths, I'll need to take 30 thou off the
end of the tool to get back to where its actually 50 thou wide. Or run
it twice with a 4 thou offset, doable in nice soft pvc pipe, but not in
S.S. even if I rehardened the tool. Which, limited to a propane torch, I
am not convinced I could do, not enough heat.

But its not long enough to spare the 30 thou without cutting back the
leading side too. I made it wrong in the first place. :( Another of my
dumb-assed mistakes. Sigh.> 
Post by sam sokolik
these numbers are as good or better than rtai. Could we, with some
tweaks, use rt_preempt for printer port configs and forget about rtai
for now? I have more computer hardware I can test - but this is
pretty awesome.
I agree, Sam. Great stuff on an intel cpu. congratulations.

?: I have one machine, a D-525-MW that is still on the parport. Running
the wheezy rt kernel. Would that idle=poll help it? Better yet, I'll
test it yet tonight.

Humm, latency slightly worse, from 9330 to 11450, about 2 u-secs worse,
and glxgears went from 20 frames a second to 21 frames a second.

Insignificant on that board and its atom cpu.
Post by sam sokolik
Good video explaining realtime
http://youtu.be/BKkX9WASfpI
Rt-preempt even runs decently on my laptop. I have actually run test
and real machines with it. (don't mute the speakers though... causes
huge spikes)
sam
Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>
andy pugh
2017-07-05 14:41:50 UTC
Permalink
Post by Gene Heskett
Why? Huge rubber band in series with the z movements,
associated I think with the z acceleration limits,
That has nothing to do with the Pi and everything to do with the INI
file settings. Did you guess the accel limits, or derive them by
experiment?
--
atp
"A motorcycle is a bicycle with a pandemonium attachment and is
designed for the especial use of mechanical geniuses, daredevils and
lunatics."
— George Fitch, Atlanta Constitution Newspaper, 1916
Gene Heskett
2017-07-05 18:24:34 UTC
Permalink
Post by andy pugh
Post by Gene Heskett
Why? Huge rubber band in series with the z movements,
associated I think with the z acceleration limits,
That has nothing to do with the Pi and everything to do with the INI
file settings. Did you guess the accel limits, or derive them by
experiment?
Experimental, for max speed. However, this machine can move z 3x faster
than x, so I could go for a lower top speed and a higher accel. This is
stuff yet to be fully optimized I'm sure. And this z motor was the one I
took back off the G0704 because it was too slow, way too slow when
lifting the heavy head by direct coupling to the screw. Its belt drive
now, 32 teeth on the motor and 40 on the screw, but it still has the
22mh per coil inductance, so the torque falls off a cliff at 60 rpms,
but it has surplus torque for the lathe so can move z at close to 90
ipm. I should cut MAX_VEL's in half, and double the MAX_ACCEL's.
(nominally)

I am not impressed with the dm860 driver either, and have an automation
tech version waiting for me to find a round tuit & swap it out. The
microstep mapping of the dm860 misses the mark when running at this
motors reduced 3.4 amp current, missing one microstep completely when
creeping along. I'd like to get another motor like the 8 wire 950 oz I
put on the G0704. Another of those round tuit things. :)

But first I need to grind me a better tool than the one I made yesterday,
its tapered on the sides way too much. Works in plastic water pipe,
sure breakage halfway thru the 10 tpi, 20 thou deep cuts it needs to
make in SS. If I make the tool correctly, I won't need near as much
stickout.

And 2 hours later, after cutting the maxvels in half, and quadrupling the
max_accels, I believe I have it. Very good looking threads in the pvc
pipe. But I'll next try it on a piece of cold rolled.

Gotta go get my sleeping beauty the papers so she has some crosswords to
work when she awakes.

Take care Andy.

Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>
Jon Elson
2017-07-05 03:15:41 UTC
Permalink
Post by sam sokolik
Well - I have been playing with debian stretch and
4.9.0-3-rt kernel. I booted our matsuura (j1900 quad
core) which with no tweeking has aprox 100us latency. (it
has been running mesa ethernet cards with rt_preempt - no
issues) Next I booted it with some kernel line tweaks.
(checking the hardware - processors 0,1 and 2,3 share
cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been
running for hours now and still <6us
6 us is quite good, although RTAI can do better on some
boxes. But, 6 us is probably good for most interfaces.

Jon
sam sokolik
2017-07-12 18:13:30 UTC
Permalink
here is a shot of linuxcnc running a 30us base period. You can see the
jitter on this analog scope.

Loading Image...

Using parport resest (5us). So theoretically you could run close to
30khz with rt_preempt on this system (3rd gen i5).

sam

(scope isn't calibrated very good)
Post by sam sokolik
Well - I have been playing with debian stretch and 4.9.0-3-rt
kernel. I booted our matsuura (j1900 quad core) which with no
tweeking has aprox 100us latency. (it has been running mesa ethernet
cards with rt_preempt - no issues) Next I booted it with some kernel
line tweaks. (checking the hardware - processors 0,1 and 2,3 share
cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
6 us is quite good, although RTAI can do better on some boxes. But, 6
us is probably good for most interfaces.
Jon
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
R.L. Wurdack
2017-07-12 19:05:45 UTC
Permalink
[OT] But the Megabot, giant robot guys (""Make"" magazine vol 58) are
running rtai. Don't know what for.


----- Original Message -----
From: "sam sokolik" <***@empirescreen.com>
To: <emc-***@lists.sourceforge.net>
Sent: Wednesday, July 12, 2017 11:13 AM
Subject: Re: [Emc-users] Maybe we don't need rtai anymore?
Post by sam sokolik
here is a shot of linuxcnc running a 30us base period. You can see the
jitter on this analog scope.
http://electronicsam.com/images/matsuura/20170712_130107.jpg
Using parport resest (5us). So theoretically you could run close to
30khz with rt_preempt on this system (3rd gen i5).
sam
(scope isn't calibrated very good)
Post by sam sokolik
Well - I have been playing with debian stretch and 4.9.0-3-rt kernel.
I booted our matsuura (j1900 quad core) which with no tweeking has aprox
100us latency. (it has been running mesa ethernet cards with
rt_preempt - no issues) Next I booted it with some kernel line tweaks.
(checking the hardware - processors 0,1 and 2,3 share cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running for
hours now and still <6us
6 us is quite good, although RTAI can do better on some boxes. But, 6 us
is probably good for most interfaces.
Jon
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Gene Heskett
2017-07-12 21:37:40 UTC
Permalink
Post by R.L. Wurdack
[OT] But the Megabot, giant robot guys (""Make"" magazine vol 58) are
running rtai. Don't know what for.
----- Original Message -----
Sent: Wednesday, July 12, 2017 11:13 AM
Subject: Re: [Emc-users] Maybe we don't need rtai anymore?
Post by sam sokolik
here is a shot of linuxcnc running a 30us base period. You can see
the jitter on this analog scope.
http://electronicsam.com/images/matsuura/20170712_130107.jpg
Using parport resest (5us). So theoretically you could run close
to 30khz with rt_preempt on this system (3rd gen i5).
sam
(scope isn't calibrated very good)
Post by sam sokolik
Well - I have been playing with debian stretch and 4.9.0-3-rt
kernel. I booted our matsuura (j1900 quad core) which with no
tweeking has aprox 100us latency. (it has been running mesa
ethernet cards with rt_preempt - no issues) Next I booted it with
some kernel line tweaks. (checking the hardware - processors 0,1
and 2,3 share cache. So I added
isolcpus=2,3 idle=poll
The latency on this system was phenomenal. It has been running
for hours now and still <6us
6 us is quite good, although RTAI can do better on some boxes. But,
6 us is probably good for most interfaces.
Jon
From what I have read, that looks like at least a 25% jitter, and that,
according to what I've read, will destroy around 75% of the torque
compared to a 1 or 2% jitter. That situation limits my toy mill, the hf
little one, to 8 to 10 ipm before the x/y motors will stall. Thats fast
enough to stall the spindle motor when a 1/4" upcut tool is in it,
turning 1500 revs, so my chips are thin and sharp. That slow of course
is also hard on the tools edge, particularly if plowing alu .025" deep
per pass. I have a 5i25 to put in it, and a 42 volt supply to replace
the 28 volts feeding the motor drivers now. But to explore that movement
increase, I'd have to also swap spindle motors, putting in the one I
took out of TLM years ago.
Post by R.L. Wurdack
Post by sam sokolik
-------------------------------------------------------------------
-----------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
--------------------------------------------------------------------
---------- Check out the vibrant tech community on one of the world's
most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
----------------------------------------------------------------------
-------- Check out the vibrant tech community on one of the world's
most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
https://lists.sourceforge.net/lists/listinfo/emc-users
Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>
Loading...