Re: [Emc-users] RPI4 is pretty close to a decent machine - now linear scales and servos

2020-02-19 Thread dave engvall



On 2/19/20 4:16 AM, Les Newell wrote:

On 18/02/2020 23:54, Marshland Engineering wrote:
Just a correction, I have setup a few stepper systems with LinuxCNC 
and step
and direction is no problem. The problems came in when using 2KW 
servo drives

and linear scales on the axis.


The subject of using linear scales for feedback pops up every so often 
on this list and always the recommendation is not to do it. I just 
checked back through the list history and you were also told this. 
It's not a LinuxCNC or competence issue. It's a hardware issue.


Feedback loops like a very stiff connection between the motor and the 
encoder. Even a tiny amount of backlash or spring has a major effect 
on loop stability. Have you ever tried driving a car with badly worn 
steering? It's hard to keep a straight line. Linear scales have have 
the same effect on the feedback loop. If you fit encoders directly on 
your motors most of your tuning issues will go away. If the machine is 
very stiff and has very little backlash you MAY get away with using 
velocity mode drives with your scales. Even then it's likely to be 
twitchy to set up. In fact this was also suggested to you at the time.


Using linear scales for secondary feedback in addition to encoders on 
the motors can in some cases improve accuracy but this is a pretty 
advanced configuration and off hand I don't know of anyone who has 
done it with LinuxCNC. It is done on some high end commercial machines.

http://wiki.linuxcnc.org/cgi-bin/wiki.pl?Combining_Two_Feedback_Devices_On_One_Axis


I have purchased and tried a 80V 20A Servo Drive upgrade Geckodrive 
G320X

DG4S-08020 DCS810 from ebay and it worked well on a small motor.


See above. A motor with a directly connected encoder is easy to set 
up. If you tried the G320 on your linear scale setup you would have 
had exactly the same tuning issues.


I think having the servo tuning external to the PC is a good option. 
This makes the

LinuxCNC servo installation much easier.


I have used position mode drives (step/direction), velocity mode and 
torque mode with LCNC, Mach, Eding CNC, my own custom controller and 
others. I've tested Gecko, Mesa, Rutex, Granite Devices, Xylotex, 
Kinco, Bosch, Yaskawa and others in various configurations so I have a 
reasonable sample set. In my opinion the best control scheme overall 
is torque mode with LinuxCNC doing the feedback. Velocity mode comes 
second and position mode (step/dir) a long way behind.


The drives like Gecko, Rutex R9x series and Xylotex are very basic and 
you have no way of knowing what following errors you are getting until 
the drives trip. It's difficult to get a really good tune without 
knowing what the drive is doing.


Configuring digital drives such as Kinco, Yaskawa etc with a couple of 
buttons and a tiny LED display is frustrating to say the least. GD, 
the later Rutex drives Kinco, and many other digital drives have their 
own tuning software (mostly Windows only) but I haven't yet found one 
that is easier to use than LinuxCNC with Halscope. Some drives have 
auto tuning but I've not yet seen auto tuning that does a really good 
job.


My Hurco mill came with Yaskawa brushless servos in velocity mode. The 
velocity tuning in the drives was very touchy and I struggled to get a 
good balance between accuracy and oscillation. Some hunting is to be 
expected with velocity drives but this was too much for my liking. I 
then switched to torque mode and my problems went away. No hunting and 
much lower following error. My lathe is torque mode with Mesa 2KW 
drives. Again very smooth, no hunting and very low following error. 
They are not without their issues though (see below). My router uses 
Bosch analog velocity mode drives. Following error is adequate for a 
router but being velocity mode they do hunt a bit when the machine is 
stationary. I will say velocity mode is generally a little easier to 
tune than torque mode so if you aren't fanatical about pushing the 
limits of your machine and you can put up with the hunting it's not a 
bad way to go.


Here are some of my impressions of various drives:

Gecko G320. Step/dir DC brushed. Rather rudimentary feedback loop. 
Fixed following error limit. You need to take them apart and attach an 
oscilloscope to tune them properly. I suffered from issues with random 
tripping that I never fully solved. Physical pots to adjust which is 
nice. Would I buy again? No.


Mesa 7i29. Analog PWM DC brushed. Cheap and powerful. Generate lots of 
electrical noise so it's well worth adding some filtering. I had 
issues with noise pickup on the encoder inputs, to the point where I 
ended up using them for my handwheels and used a separate encoder 
board for the servos. The onboard dc-dc converter let the smoke out 
once but I managed to fix it by replacing a couple of small surface 
mount transistors. I've run my lathe on this drive for many years and 
the DC-DC converter circuit looks pretty well designed so I am 

Re: [Emc-users] RPI4 is pretty close to a decent machine - now linear scales and servos

2020-02-19 Thread Les Newell

On 18/02/2020 23:54, Marshland Engineering wrote:

Just a correction, I have setup a few  stepper systems with LinuxCNC and step
and direction is no problem. The problems came in when using 2KW servo drives
and linear scales on the axis.


The subject of using linear scales for feedback pops up every so often 
on this list and always the recommendation is not to do it. I just 
checked back through the list history and you were also told this. It's 
not a LinuxCNC or competence issue. It's a hardware issue.


Feedback loops like a very stiff connection between the motor and the 
encoder. Even a tiny amount of backlash or spring has a major effect on 
loop stability. Have you ever tried driving a car with badly worn 
steering? It's hard to keep a straight line. Linear scales have have the 
same effect on the feedback loop. If you fit encoders directly on your 
motors most of your tuning issues will go away. If the machine is very 
stiff and has very little backlash you MAY get away with using velocity 
mode drives with your scales. Even then it's likely to be twitchy to set 
up. In fact this was also suggested to you at the time.


Using linear scales for secondary feedback in addition to encoders on 
the motors can in some cases improve accuracy but this is a pretty 
advanced configuration and off hand I don't know of anyone who has done 
it with LinuxCNC. It is done on some high end commercial machines.



I have purchased and tried a 80V 20A Servo Drive upgrade Geckodrive G320X
DG4S-08020 DCS810 from ebay and it worked well on a small motor.


See above. A motor with a directly connected encoder is easy to set up. 
If you tried the G320 on your linear scale setup you would have had 
exactly the same tuning issues.



I think having the servo tuning external to the PC is a good option. This makes 
the
LinuxCNC servo installation much easier.


I have used position mode drives (step/direction), velocity mode and 
torque mode with LCNC, Mach, Eding CNC, my own custom controller and 
others. I've tested Gecko, Mesa, Rutex, Granite Devices, Xylotex, Kinco, 
Bosch, Yaskawa and others in various configurations so I have a 
reasonable sample set. In my opinion the best control scheme overall is 
torque mode with LinuxCNC doing the feedback. Velocity mode comes second 
and position mode (step/dir) a long way behind.


The drives like Gecko, Rutex R9x series and Xylotex are very basic and 
you have no way of knowing what following errors you are getting until 
the drives trip. It's difficult to get a really good tune without 
knowing what the drive is doing.


Configuring digital drives such as Kinco, Yaskawa etc with a couple of 
buttons and a tiny LED display is frustrating to say the least. GD, the 
later Rutex drives Kinco, and many other digital drives have their own 
tuning software (mostly Windows only) but I haven't yet found one that 
is easier to use than LinuxCNC with Halscope. Some drives have auto 
tuning but I've not yet seen auto tuning that does a really good job.


My Hurco mill came with Yaskawa brushless servos in velocity mode. The 
velocity tuning in the drives was very touchy and I struggled to get a 
good balance between accuracy and oscillation. Some hunting is to be 
expected with velocity drives but this was too much for my liking. I 
then switched to torque mode and my problems went away. No hunting and 
much lower following error. My lathe is torque mode with Mesa 2KW 
drives. Again very smooth, no hunting and very low following error. They 
are not without their issues though (see below). My router uses Bosch 
analog velocity mode drives. Following error is adequate for a router 
but being velocity mode they do hunt a bit when the machine is 
stationary. I will say velocity mode is generally a little easier to 
tune than torque mode so if you aren't fanatical about pushing the 
limits of your machine and you can put up with the hunting it's not a 
bad way to go.


Here are some of my impressions of various drives:

Gecko G320. Step/dir DC brushed. Rather rudimentary feedback loop. Fixed 
following error limit. You need to take them apart and attach an 
oscilloscope to tune them properly. I suffered from issues with random 
tripping that I never fully solved. Physical pots to adjust which is 
nice. Would I buy again? No.


Mesa 7i29. Analog PWM DC brushed. Cheap and powerful. Generate lots of 
electrical noise so it's well worth adding some filtering. I had issues 
with noise pickup on the encoder inputs, to the point where I ended up 
using them for my handwheels and used a separate encoder board for the 
servos. The onboard dc-dc converter let the smoke out once but I managed 
to fix it by replacing a couple of small surface mount transistors. I've 
run my lathe on this drive for many years and the DC-DC converter 
circuit looks pretty well designed so I am chalking this one down to 
random bad luck. Excellent support from Mesa. They even sent me 
schematics. Would I buy again? The 

Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Rafael Skodlar

On 2020-02-18 15:23, Chris Albertson wrote:

This is a problem with many people using Linux to do something complex like
build a CNC system or using ROS to build a robot.  They are doing something
complex with Linux before they try to do simple things with Linux.


Among other things, ROS is wrongfully named Robot Operating System, when 
it's a service. Must be a tradition in naming things the wrong way. 
Cookies for example are baked in bakeries not cookeries. Therefore they 
should be called bakies!



The best approach is to fist use Linux for everyday tasks, like reading and
writing emails, watching youtube videos.  Simply use it for all your normal
tasks.Get rid of your Windows system.


It takes some courage and experimentation to use Linux for your work. 
Granted, too many silly software companies don't create their programs 
for Linux platform since 1990s when they wrote them on Unix platform in 
the first place.


This month is 26 years since I started using Linux on my home and work 
computers exclusively. Over the years I tested all kinds of 
distributions and settled on Ubuntu based Supermicro servers in my 
garage and Kubuntu for my workstation and a laptop.


Some silly recruiters ask me to send my resume in "word format". I 
respond with either simple ASCII file or PDF exported from LibreOffice 
Writer. LibreOffice set of programs is good enough for office work. 
There are other utilities and programs that make my life exciting. I use 
Kate for writing bash and Python scripts, Jupyter for testing python 
scripts, etc.


There are other great programs for taking notes, editing or viewing 
pictures, creating 3D pictures with Blender, Thunderbird for handling 
email, listening or editing music and videos, etc.


I rarely turn on large TV because I can watch TV programs on HDhomerun 
that connects over LAN to SiliconDust TV box in my garage. That's 
running in parallel to other programs for my work.


One of my favorite utilities is Virtualbox which allows me to test 
different Linux distributions (Centos for example) or other OS like BSD 
that I need for professional work. I installed LinuxCNC as a virtual 
machine to see how it looks like. RT kernel is not important in this case.


Virtualbox is available for Windows also. You can create Linux VMs for 
testing. The other way around is possible also. Yes, start using Linux 
for most if not all of your work.



It is a little like buying a harbor freight mini lathe and then your first
project is a working gas airplane engine.



Oh my, I won't be able to build a working gas engine. Little Greta told 
the World that gas engines are forbidden now anyway.


--
Rafael Skodlar


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Robert Murphy

John,

I agree the Beagle bone made a very good system, well the first images
from a few years ago. I was using mine to control my mill with a custom
cape.

What turned my to Linuxcnc was just the general support infrastructure.

On 19/2/20 10:26 am, John Dammeyer wrote:

Hi Wallace,
I've been way more successful although also taken a number of stabs at it 
compared to how easy it was to get MACH2 and then MACH3 working.

Even the BeagleBone was easy because the install came with the hal and ini 
files for  the Xylotex.  So in many ways it was just like installing MACH3.  
Very turnkey.  I probably would have stayed with that config except the Xylotex 
cape was set up for NO switches.  And the enable signal internally on the board 
was the wrong polarity so ultimately that project was shelved.  Perhaps to be 
used with the lathe since limits aren't as big an issue with it.

So I went the route of the dual boot PC and I have used LinuxCNC to mill some 
parts.

Support from both forums has been good.  Given that my hardware is somewhat 
non-standard and has some odd issues, I'm finding that LinuxCNC with respect to 
ENABLE and ESTOP is a bit easier for my system.  I have to much around with the 
big red RESET button and the ONLINE button in MACH to get it to work after a 
fault.

Also all things being equal if it's a simple system with say open loop 
steppers, vfd for spindle I think MACH4 is probably worlds easier to set up and 
the Wizards would be that tipping point for the WOW factor.I was also able 
to easily add the Z probe function to my MACH3 setup on the CNC router and at 
the moment I haven't a clue where to begin on that for the mill.

If your existing mill has a BoB with the standard Parallel Port interface I'd 
suggest you find a PC with a parallel port and start simple.  ESTOP, Home/Limit 
switches and XYZ step/dir.  Don't bother about spindle speed or direction.  Use 
one of the predefined configs if possible.

But if you are used to being able to automatically find the X and Y edges and 
have the 0 set after subtracting half the diameter of your probe you won't find 
that in the standard distribution of  Linux and the AXIS user interface.

If things go well then by this summer I may well have an installation manual 
written that helps someone migrate from a PC WINDOWS MACH3 system to a LinuxCNC 
system.  But there's still a lot to do.

John



-Original Message-
From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
Sent: February-18-20 12:18 PM
To: emc-users@lists.sourceforge.net
Subject: [Emc-users] RPI4 is pretty close to a decent machine

Les - Valuable comments, however, some facts.

I'm and BSc electrical engineer and worked as an industrial control engineer
with PLC, servos etc for a number of years.

I have 2 complete PC with Mesa servo drives, wiring, machines retrofitted
etc.
I been following LinuxCNC for a long time, even years before when it was
EMC2.

I have tried 4+ times over the years to get it all to work. I have yet to get
a one system up and running !!

I do understand that my Linux is limited and that is probably the biggest
factor.

I can buy stuff off the shelf from China and get it working, even Mach3 is
easy.

The only reason I went LinuxCNC is that I can retain the handwheels and use
servo drives.

I am going to make space in my calender this year to try again as I can see
that having it running would be a nice compliment to my SouthWestern
Indistries mill. Thread milling would be great.

PS I forgot, spent 15 years as a commercial programmer.

Cheers Wallace



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread John Dammeyer



> -Original Message-
> From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
> Sent: February-18-20 3:54 PM
> To: emc-users@lists.sourceforge.net
> Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine
> 
> Just a correction, I have setup a few  stepper systems with LinuxCNC and
> step
> and direction is no problem. The problems came in when using 2KW servo
> drives
> and linear scales on the axis. I just could not get the system to respond
> correctly. From memory the StepConfig didn't seem to get the drives to work
> smoothly. My mistake but I did not know how to fix it.
> 
> I have purchased and tried a 80V 20A Servo Drive upgrade Geckodrive G320X
> DG4S-08020 DCS810 from ebay and it worked well on a small motor. I think
> having the servo tuning external to the PC is a good option. This makes the
> LinuxCNC servo installation much easier. '
> 
> Cheers Wallace.

I agree.  In this day and age with the power of embedded systems I believe the 
motors/encoders should be black boxes with a fault output of they have issues.  
The STMBL drive is one example.  The HP_UHU with Henrik Olsson's dsPIC upgrade 
for my brushed DC servos is another.  There are probably a few extras.  I've 
not run the Bergerda AC servo motor and drive long enough but once I made it 
past the teething pains with it I have been considering replacing the brushed 
DC motors with the AC servos.But all the wiring is already done I'm 
reluctant to change things at the moment.  Too many other projects.

John


> 
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Marshland Engineering
Just a correction, I have setup a few  stepper systems with LinuxCNC and step
and direction is no problem. The problems came in when using 2KW servo drives
and linear scales on the axis. I just could not get the system to respond
correctly. From memory the StepConfig didn't seem to get the drives to work
smoothly. My mistake but I did not know how to fix it. 

I have purchased and tried a 80V 20A Servo Drive upgrade Geckodrive G320X
DG4S-08020 DCS810 from ebay and it worked well on a small motor. I think
having the servo tuning external to the PC is a good option. This makes the
LinuxCNC servo installation much easier. '

Cheers Wallace. 



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread John Dammeyer
Hi Wallace,
I've been way more successful although also taken a number of stabs at it 
compared to how easy it was to get MACH2 and then MACH3 working.

Even the BeagleBone was easy because the install came with the hal and ini 
files for  the Xylotex.  So in many ways it was just like installing MACH3.  
Very turnkey.  I probably would have stayed with that config except the Xylotex 
cape was set up for NO switches.  And the enable signal internally on the board 
was the wrong polarity so ultimately that project was shelved.  Perhaps to be 
used with the lathe since limits aren't as big an issue with it.

So I went the route of the dual boot PC and I have used LinuxCNC to mill some 
parts.

Support from both forums has been good.  Given that my hardware is somewhat 
non-standard and has some odd issues, I'm finding that LinuxCNC with respect to 
ENABLE and ESTOP is a bit easier for my system.  I have to much around with the 
big red RESET button and the ONLINE button in MACH to get it to work after a 
fault.

Also all things being equal if it's a simple system with say open loop 
steppers, vfd for spindle I think MACH4 is probably worlds easier to set up and 
the Wizards would be that tipping point for the WOW factor.I was also able 
to easily add the Z probe function to my MACH3 setup on the CNC router and at 
the moment I haven't a clue where to begin on that for the mill.  

If your existing mill has a BoB with the standard Parallel Port interface I'd 
suggest you find a PC with a parallel port and start simple.  ESTOP, Home/Limit 
switches and XYZ step/dir.  Don't bother about spindle speed or direction.  Use 
one of the predefined configs if possible.

But if you are used to being able to automatically find the X and Y edges and 
have the 0 set after subtracting half the diameter of your probe you won't find 
that in the standard distribution of  Linux and the AXIS user interface.  

If things go well then by this summer I may well have an installation manual 
written that helps someone migrate from a PC WINDOWS MACH3 system to a LinuxCNC 
system.  But there's still a lot to do.

John


> -Original Message-
> From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
> Sent: February-18-20 12:18 PM
> To: emc-users@lists.sourceforge.net
> Subject: [Emc-users] RPI4 is pretty close to a decent machine
> 
> Les - Valuable comments, however, some facts.
> 
> I'm and BSc electrical engineer and worked as an industrial control engineer
> with PLC, servos etc for a number of years.
> 
> I have 2 complete PC with Mesa servo drives, wiring, machines retrofitted
> etc.
> I been following LinuxCNC for a long time, even years before when it was
> EMC2.
> 
> I have tried 4+ times over the years to get it all to work. I have yet to get
> a one system up and running !!
> 
> I do understand that my Linux is limited and that is probably the biggest
> factor.
> 
> I can buy stuff off the shelf from China and get it working, even Mach3 is
> easy.
> 
> The only reason I went LinuxCNC is that I can retain the handwheels and use
> servo drives.
> 
> I am going to make space in my calender this year to try again as I can see
> that having it running would be a nice compliment to my SouthWestern
> Indistries mill. Thread milling would be great.
> 
> PS I forgot, spent 15 years as a commercial programmer.
> 
> Cheers Wallace
> 
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Chris Albertson
This is a problem with many people using Linux to do something complex like
build a CNC system or using ROS to build a robot.  They are doing something
complex with Linux before they try to do simple things with Linux.

The best approach is to fist use Linux for everyday tasks, like reading and
writing emails, watching youtube videos.  Simply use it for all your normal
tasks.Get rid of your Windows system.

It is a little like buying a harbor freight mini lathe and then your first
project is a working gas airplane engine.

On Tue, Feb 18, 2020 at 12:20 PM Marshland Engineering <
marshl...@marshland.co.nz> wrote:

> Les - Valuable comments, however, some facts.
>
> I'm and BSc electrical engineer and worked as an industrial control
> engineer
> with PLC, servos etc for a number of years.
>
> I have 2 complete PC with Mesa servo drives, wiring, machines retrofitted
> etc.
> I been following LinuxCNC for a long time, even years before when it was
> EMC2.
>
> I have tried 4+ times over the years to get it all to work. I have yet to
> get
> a one system up and running !!
>
> I do understand that my Linux is limited and that is probably the biggest
> factor.
>
> I can buy stuff off the shelf from China and get it working, even Mach3 is
> easy.
>
> The only reason I went LinuxCNC is that I can retain the handwheels and use
> servo drives.
>
> I am going to make space in my calender this year to try again as I can see
> that having it running would be a nice compliment to my SouthWestern
> Indistries mill. Thread milling would be great.
>
> PS I forgot, spent 15 years as a commercial programmer.
>
> Cheers Wallace
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>


-- 

Chris Albertson
Redondo Beach, California

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Gene Heskett
On Tuesday 18 February 2020 17:16:59 Robert Murphy wrote:

> On 19/2/20 7:17 am, Marshland Engineering wrote:
> > Les - Valuable comments, however, some facts.
> >
> > I'm and BSc electrical engineer and worked as an industrial control
> > engineer with PLC, servos etc for a number of years.
> >
> > I have 2 complete PC with Mesa servo drives, wiring, machines
> > retrofitted etc. I been following LinuxCNC for a long time, even
> > years before when it was EMC2.
> >
> > I have tried 4+ times over the years to get it all to work. I have
> > yet to get a one system up and running !!
> >
> > I do understand that my Linux is limited and that is probably the
> > biggest factor.
> >
> > I can buy stuff off the shelf from China and get it working, even
> > Mach3 is easy.
> >
> > The only reason I went LinuxCNC is that I can retain the handwheels
> > and use servo drives.
> >
> > I am going to make space in my calender this year to try again as I
> > can see that having it running would be a nice compliment to my
> > SouthWestern Indistries mill. Thread milling would be great.
> >
> > PS I forgot, spent 15 years as a commercial programmer.
> >
> > Cheers Wallace
>
> I'm a basic Builder's\Civil labourer and have had no trouble getting
> Linuxcnc up and running.
>
> Linuxcnc had really nothing to do with "Linux Skills" it's being able
> to follow instructions as per any new app you would install,
> regardless of OS.
>
> I can't get my head around Autocad, Fusion 360, is that because my
> "Windows Skills" are lacking ?
>
> Rob
>
Could be, I've had a bounty on windows crap, for 30 years, it gets nuked 
sooner rather than later here except for one win10home on a really cheap 
hp, gets used as a display for a redpitaya's smith chart antenna tuner.  
Works nice for that. Part of my retirement cash cow. :)
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> 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)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page 


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Robert Murphy



On 19/2/20 7:17 am, Marshland Engineering wrote:

Les - Valuable comments, however, some facts.

I'm and BSc electrical engineer and worked as an industrial control engineer
with PLC, servos etc for a number of years.

I have 2 complete PC with Mesa servo drives, wiring, machines retrofitted etc.
I been following LinuxCNC for a long time, even years before when it was EMC2.

I have tried 4+ times over the years to get it all to work. I have yet to get
a one system up and running !!

I do understand that my Linux is limited and that is probably the biggest
factor.

I can buy stuff off the shelf from China and get it working, even Mach3 is
easy.

The only reason I went LinuxCNC is that I can retain the handwheels and use
servo drives.

I am going to make space in my calender this year to try again as I can see
that having it running would be a nice compliment to my SouthWestern
Indistries mill. Thread milling would be great.

PS I forgot, spent 15 years as a commercial programmer.

Cheers Wallace


I'm a basic Builder's\Civil labourer and have had no trouble getting
Linuxcnc up and running.

Linuxcnc had really nothing to do with "Linux Skills" it's being able to
follow instructions as per any new app you would install, regardless of OS.

I can't get my head around Autocad, Fusion 360, is that because my
"Windows Skills" are lacking ?

Rob




___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


[Emc-users] RPI4 is pretty close to a decent machine

2020-02-18 Thread Marshland Engineering
Les - Valuable comments, however, some facts. 

I'm and BSc electrical engineer and worked as an industrial control engineer
with PLC, servos etc for a number of years. 

I have 2 complete PC with Mesa servo drives, wiring, machines retrofitted etc.
I been following LinuxCNC for a long time, even years before when it was EMC2.

I have tried 4+ times over the years to get it all to work. I have yet to get
a one system up and running !!

I do understand that my Linux is limited and that is probably the biggest
factor.

I can buy stuff off the shelf from China and get it working, even Mach3 is
easy. 

The only reason I went LinuxCNC is that I can retain the handwheels and use
servo drives. 

I am going to make space in my calender this year to try again as I can see
that having it running would be a nice compliment to my SouthWestern
Indistries mill. Thread milling would be great. 

PS I forgot, spent 15 years as a commercial programmer. 

Cheers Wallace



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-18 Thread Sam Sokolik
well..  I know a lot of us have strong feelings for linuxcnc.  For me it is
seeing what it can actually do..

As (I think) Les had said.  you can run the smallest desktop machine all
the way up to a machining center with pallets and tool changer.

This is what really sold me.   We have the K with analog servos, 60 tool
chain and changer, pallets and all sorts of do-dads.
I bought 2 mesa cards + analog interface cards.  This gave me 90+ i/o and
10 analog/encoder counters.

Everything is controlled within linuxcnc - between the integrated ladder
and hal.  tool changes, spindle gear changes, pallet changes..  All done
within linuxcnc and all realtime..  No external plc's or anything.

sam

On Tue, Feb 18, 2020 at 11:15 AM John Dammeyer 
wrote:

> > I'm sorry, this is degenerating into a useless argument and I'm gonna
> > take a step back and leave you to it.
> >
> > Les
> >
> Thank you.  Your insights have been invaluable.
> John
> >
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-18 Thread dave engvall


On 2/17/20 5:18 PM, Ed wrote:

On 2/17/20 6:20 PM, John Dammeyer wrote:

From: Sam Sokolik [mailto:samco...@gmail.com]
Because your examples are not running a full operating system...
I don't buy that.  That's like saying.  Look.  The ride is a tad 
uncomfortable but that's to be expected.  After all this is a 10 Ton 
gravel truck.  But look at what it can carry.  True it's only 
groceries today and most days but that one time it will come in so 
handy...  dear...


John

I'll buy that because it is true. Linuxcnc carries the baggage of 
being a motion controller with attached OS. If you like using a go 
between board that uses a $2 chip that sings and dances go gettum. 
Check and see the availability of that chip in a couple years.


Many CNC users don't measure machine life in weeks or months or years 
but DECADES. My first LCNC machine is still going strong after almost 
20 years, step and direction to Gecko 320's. Where will the Pi be in 
20 years or your $2 chip?


Not to knock using a Pi or whatever but to point to the fact that a PC 
running LCNC is the point to measure from and will remain so.


The $2 chip solution may a great thing esp in a headless setup as a 
facilitator but I would buy backups.



Ed.


Quote on a BP dealer site:

"Knee Mill Series I is the most popular vertical milling machine ever 
made with over 370,000 machines built over the past 70-plus years."


I suspect people that buy Griz mills, etc. start out bare and work into 
axis motor drives and maybe eventually full cnc. Part of that is cash 
flow; if you are young and have a family there simply isn't enough 
money. It gets better after the kids leave home and the dog dies. :-)


In the early 2000's manual mills could be had for hauling them off. I 
bought a Mazak V5 for $1500 ...  with a dead  control. Of course getting 
it here and shoehorned into the shop, adding new servo drives, etc is 
another story, a long story.


Speaking of motion control; we have no control over the availability of 
usable cpu's. So far we've been lucky. I like the idea of motion 
residing in a microcontroller but in terms of something surviving for 
years I think that a product based  on a popular FPGA series has the 
best chance of being viable over time. Use the FPGA only for motion and 
a general purpose computer for all the non-realtime stuff. Can I do this 
... not a chance. I do best at ideas and let the really smart people do 
the rest.


Dave









___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-18 Thread John Dammeyer
> I'm sorry, this is degenerating into a useless argument and I'm gonna
> take a step back and leave you to it.
> 
> Les
> 
Thank you.  Your insights have been invaluable.
John
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-18 Thread Les Newell

I don't buy that.  That's like saying.  Look.  The ride is a tad uncomfortable 
but that's to be expected.  After all this is a 10 Ton gravel truck.  But look 
at what it can carry.  True it's only groceries today and most days but that 
one time it will come in so handy...  dear...


I'd much rather have my 10 ton dump truck with a windscreen I can see 
out of and that can go around corners rather than your tricycle with a 
windscreen the size of a postage stamp and can't go around corners. But 
the ride is sweet...


Not to mention I very often need to haul 10 tons, not just occasionally.


I went to the Grizzly tools site.  I think I counted 38 mills.  None of them 
CNC.
You are cherry picking your results. By the same logic I can go to the 
Haas website and not find any manual machines. Therefore no-one uses 
manual machines.
For more realistic results, how about people who actually use machines 
on a regular basis? Go to any engineering job shop and take a look at 
their machines. Most will be CNC. They may have the odd manual gathering 
dust for occasional very simple on-off tasks.



CNC routers can't really operate with hand wheels so they are a different class 
of hardware
Huh? LinuxCNC runs CNC machines. By definition CNC routers are CNC 
machines.


You seem to have a fixed idea of what all users want, when in fact it's 
just what you want. Anything else doesn't count or is being done wrong. 
I'm sorry, this is degenerating into a useless argument and I'm gonna 
take a step back and leave you to it.


Les




___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-18 Thread Phill Carter



> On 18 Feb 2020, at 6:51 pm, John Dammeyer  wrote:
> 
> I went to the Grizzly tools site.  I think I counted 38 mills.  None of them 
> CNC.  
> KBC tools here in Canada has, in the this month's flier, 5 milling machines 
> of various sizes and only one CNC milling machine with Acu-Rite control for 
> $41K.
> KMS tools aas 4, none of them CNC.
> Don't know how many Sherline mills are sold with or without the CNC kit.
> 
> No idea how many used Bridgeport type machines are out there starting from 
> say post war 1945 over 85 years?  I believe CNC machines are a small fraction 
> of those even if there were 10K MACH3 licenses sold.  And of those licenses 
> how many actually went to CNC routers.   I have one with a valid MACH3 
> license but it's one built from scratch.  CNC routers can't really operate 
> with hand wheels so they are a different class of hardware.
> 
> Judging by the number of $250 to $500 CNC controllers available through 
> AliExpress I'd guess the number of non-CNC machines out there is still really 
> high.
> 
Handy to know...



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread John Dammeyer
I went to the Grizzly tools site.  I think I counted 38 mills.  None of them 
CNC.  
KBC tools here in Canada has, in the this month's flier, 5 milling machines of 
various sizes and only one CNC milling machine with Acu-Rite control for $41K.
KMS tools aas 4, none of them CNC.
Don't know how many Sherline mills are sold with or without the CNC kit.

No idea how many used Bridgeport type machines are out there starting from say 
post war 1945 over 85 years?  I believe CNC machines are a small fraction of 
those even if there were 10K MACH3 licenses sold.  And of those licenses how 
many actually went to CNC routers.   I have one with a valid MACH3 license but 
it's one built from scratch.  CNC routers can't really operate with hand wheels 
so they are a different class of hardware.

Judging by the number of $250 to $500 CNC controllers available through 
AliExpress I'd guess the number of non-CNC machines out there is still really 
high.

John



> -Original Message-
> From: Jon Elson [mailto:el...@pico-systems.com]
> Sent: February-17-20 8:51 PM
> To: Enhanced Machine Controller (EMC)
> Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> solution...
> 
> On 02/17/2020 11:37 AM, John Dammeyer wrote:
> > I've been asking on other metal working groups about CNC
> > and it's really amazing how few CNC installations there
> > are out there. Many people are happy with a DRO and power
> > feed on one or two axis.
> And, no, you are looking in the wrong places.  Numbers are
> hard to come by, but there are well over 10K Mach 3 users
> out there, I am told.  That may refer only to PAID
> licenses.  I have no idea how many Smithy, Novakon and
> Tormach machines are in use.  I suspect their numbers dwarf
> the LinuxCNC users.
> 
> If you don't know of CNC Zone, you should check it out.
> (But, I hate the slow response of their server.)
> 
> Jon
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Jon Elson

On 02/17/2020 11:37 AM, John Dammeyer wrote:
I've been asking on other metal working groups about CNC 
and it's really amazing how few CNC installations there 
are out there. Many people are happy with a DRO and power 
feed on one or two axis.
And, no, you are looking in the wrong places.  Numbers are 
hard to come by, but there are well over 10K Mach 3 users 
out there, I am told.  That may refer only to PAID 
licenses.  I have no idea how many Smithy, Novakon and 
Tormach machines are in use.  I suspect their numbers dwarf 
the LinuxCNC users.


If you don't know of CNC Zone, you should check it out.  
(But, I hate the slow response of their server.)


Jon


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Jon Elson

On 02/17/2020 11:37 AM, John Dammeyer wrote:
I think that supports my position that LinuxCNC is really 
just a middle box between display and motion hardware and 
if you want optimal performance you offload the real work 
to something that isn't LinuxCNC.
But, that is NOT what my boards do.  In general, each of the 
3 systems has an encoder counter and some kind of velocity 
output.  We have options for step output, PWM or analog 
velocity command.  Also, there is some digital I/O.
So, these are NOT motion controllers (despite the name of 
the boards) but really just interfaces to encoders and motor 
drives. The servo loop is closed through the PC's CPU.  This 
makes servo loop tuning and diagnostics much easier, all the 
tools you need are part of LinuxCNC.


Jon


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread Sam Sokolik
there are still printer port options available if that is what you want..
I have played with 3rd gen i5's (HP 8300 sff)

this is with rt_preempt...  I still wouldn't expect much more than 40khz
stepping.. (in my experience)

http://www.electronicsam.com/images/KandT/testing/8300/Screenshot_2019-08-11_05-02-25.png

and another video...
https://www.youtube.com/watch?v=OMreIgsMnW8

On Mon, Feb 17, 2020 at 8:38 PM Ed  wrote:

> On 2/17/20 7:51 PM, John Dammeyer wrote:
>
>
> SNIP
>
> > Truthfully, all the Intel type NUC PCs don't have parallel ports and
> unless you buy two 7i92H or whatever MESA board you buy there is no
> guarantee that they will be there in 20 years either.
> >
> >
> https://www.intel.ca/content/www/ca/en/products/boards-kits/nuc/boards.html
> >
> > But if that RPi4 costs $50 and your 7i92H costs you $89. Then buy 4 of
> the RPi4.  That's the price of one Intel NUC PC compatible and now you have
> 3 spares.
> >
> > But I agree.  All this stuff being built nowadays has a life of 1 to 3
> years before it's out of date.  As long as I don't update my iPhone 4S it
> will work.  I'm still on the original battery and get about two days out of
> it.  But if I update the OS then Apple will make sure that my 4S is
> useless.   And already the industry has done some of that by updating HTML
> pages in such a way to provide that "improved user experience" which is
> code for more advertising and tracking but it breaks the browser on the
> iPhone 4S.  So that I can't do very well anymore.
> >
> > And of course new apps aren't backwards compatible so eventually I'll
> have to buy a new phone.
>
> Ah but LCNC IS backward compatible, forget the base hardware, the
> software still runs!
>
> >
> > It's probably the biggest reason I'm considering LinuxCNC instead of
> MACH3/4.  The lack of drivers for the newer hardware with the older OS is
> the clue.  But the latency of LinuxCNC on the parallel port means an
> upgrade to some sort of Ethernet device.  And your 20 year old PC will face
> that same issue likely if it fails.  Not a bad thing.  Just nothing 20
> years old can be replaced with something identical.
> >
> If you want to keep using software stepping that is fine, my old machine
> runs great with no latency problems. I recently finished a retro on an
> identical machine but this one has full servo 4 axis with spindle
> encoder that will run just as fast as the motors will go and spindle
> will turn with rigid tapping. It set me back a little over $1K but is
> well worth it for me. Now you do not want to spend $1K on your machine
> but a board from Pico or Mesa will get you into high speed steppers for
> not as much and no worries about latency, your choice.
>
> Think of LCNC as a constantly updated OS and drivers unlike Mach3/4
> Windows, just add a little hardware and let it rip!
>
>
> Ed.
>
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread Ed

On 2/17/20 7:51 PM, John Dammeyer wrote:


SNIP


Truthfully, all the Intel type NUC PCs don't have parallel ports and unless you 
buy two 7i92H or whatever MESA board you buy there is no guarantee that they 
will be there in 20 years either.

https://www.intel.ca/content/www/ca/en/products/boards-kits/nuc/boards.html

But if that RPi4 costs $50 and your 7i92H costs you $89. Then buy 4 of the 
RPi4.  That's the price of one Intel NUC PC compatible and now you have 3 
spares.

But I agree.  All this stuff being built nowadays has a life of 1 to 3 years before it's 
out of date.  As long as I don't update my iPhone 4S it will work.  I'm still on the 
original battery and get about two days out of it.  But if I update the OS then Apple 
will make sure that my 4S is useless.   And already the industry has done some of that by 
updating HTML pages in such a way to provide that "improved user experience" 
which is code for more advertising and tracking but it breaks the browser on the iPhone 
4S.  So that I can't do very well anymore.

And of course new apps aren't backwards compatible so eventually I'll have to 
buy a new phone.


Ah but LCNC IS backward compatible, forget the base hardware, the 
software still runs!




It's probably the biggest reason I'm considering LinuxCNC instead of MACH3/4.  
The lack of drivers for the newer hardware with the older OS is the clue.  But 
the latency of LinuxCNC on the parallel port means an upgrade to some sort of 
Ethernet device.  And your 20 year old PC will face that same issue likely if 
it fails.  Not a bad thing.  Just nothing 20 years old can be replaced with 
something identical.

If you want to keep using software stepping that is fine, my old machine 
runs great with no latency problems. I recently finished a retro on an 
identical machine but this one has full servo 4 axis with spindle 
encoder that will run just as fast as the motors will go and spindle 
will turn with rigid tapping. It set me back a little over $1K but is 
well worth it for me. Now you do not want to spend $1K on your machine 
but a board from Pico or Mesa will get you into high speed steppers for 
not as much and no worries about latency, your choice.


Think of LCNC as a constantly updated OS and drivers unlike Mach3/4 
Windows, just add a little hardware and let it rip!



Ed.




___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread John Dammeyer


> -Original Message-
> From: Ed [mailto:ate...@mwt.net]
> Sent: February-17-20 5:18 PM
> To: emc-users@lists.sourceforge.net
> Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> 
> On 2/17/20 6:20 PM, John Dammeyer wrote:
> >> From: Sam Sokolik [mailto:samco...@gmail.com]
> >> Because your examples are not running a full operating system...
> > I don't buy that.  That's like saying.  Look.  The ride is a tad 
> > uncomfortable
> but that's to be expected.  After all this is a 10 Ton gravel truck.  But 
> look at
> what it can carry.  True it's only groceries today and most days but that one
> time it will come in so handy...  dear...
> >
> > John
> >
> I'll buy that because it is true. Linuxcnc carries the baggage of being
> a motion controller with attached OS. If you like using a go between
> board that uses a $2 chip that sings and dances go gettum. Check and see
> the availability of that chip in a couple years.
> 
> Many CNC users don't measure machine life in weeks or months or years
> but DECADES. My first LCNC machine is still going strong after almost 20
> years, step and direction to Gecko 320's. Where will the Pi be in 20
> years or your $2 chip?
> 
> Not to knock using a Pi or whatever but to point to the fact that a PC
> running LCNC is the point to measure from and will remain so.
> 
> The $2 chip solution may a great thing esp in a headless setup as a
> facilitator but I would buy backups.
> 
> 
> Ed.
> 
>
Truthfully, all the Intel type NUC PCs don't have parallel ports and unless you 
buy two 7i92H or whatever MESA board you buy there is no guarantee that they 
will be there in 20 years either.

https://www.intel.ca/content/www/ca/en/products/boards-kits/nuc/boards.html

But if that RPi4 costs $50 and your 7i92H costs you $89. Then buy 4 of the 
RPi4.  That's the price of one Intel NUC PC compatible and now you have 3 
spares.

But I agree.  All this stuff being built nowadays has a life of 1 to 3 years 
before it's out of date.  As long as I don't update my iPhone 4S it will work.  
I'm still on the original battery and get about two days out of it.  But if I 
update the OS then Apple will make sure that my 4S is useless.   And already 
the industry has done some of that by updating HTML pages in such a way to 
provide that "improved user experience" which is code for more advertising and 
tracking but it breaks the browser on the iPhone 4S.  So that I can't do very 
well anymore.

And of course new apps aren't backwards compatible so eventually I'll have to 
buy a new phone.

It's probably the biggest reason I'm considering LinuxCNC instead of MACH3/4.  
The lack of drivers for the newer hardware with the older OS is the clue.  But 
the latency of LinuxCNC on the parallel port means an upgrade to some sort of 
Ethernet device.  And your 20 year old PC will face that same issue likely if 
it fails.  Not a bad thing.  Just nothing 20 years old can be replaced with 
something identical.



 
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread John Dammeyer
> From: Sam Sokolik [mailto:samco...@gmail.com]
> Because your examples are not running a full operating system...

I don't buy that.  That's like saying.  Look.  The ride is a tad uncomfortable 
but that's to be expected.  After all this is a 10 Ton gravel truck.  But look 
at what it can carry.  True it's only groceries today and most days but that 
one time it will come in so handy...  dear...

John

> 
> On Mon, Feb 17, 2020, 5:40 PM John Dammeyer 
> wrote:
> 
> >
> >
> > > -Original Message-
> > > From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
> > > Sent: February-17-20 2:51 PM
> > > To: emc-users@lists.sourceforge.net
> > > Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> > >
> > > My Rasperberry pi is acting as a database server and works well. I still
> > > marvel at my Southwestern Industries CNC machine that runs on a  8085
> > > (5Mhz)
> > > that controls a 3 axis mill at 2m/min with 2000 line encoders and servo
> > > drives. All programming is conversational and tool compensation is done
> > by
> > > the
> > > 8085. I can create subroutines, 8 sided polys, etc and string up to 99
> > > operations into one program. It hs work flawlessly for the 15 years I
> > have
> > > owned it and works almost every day.
> > >
> > > I wonder if making PCs work as controllers is the right way to go. The
> > > ATMEGA
> > > could easily do the job, just my c is not up to it.
> > >
> > Having also controlled a very large XY Laser system with 8085 code you can
> > understand why I'm puzzled that 1GHz and up 32 ARM computers have so
> much
> > trouble.
> > John
> >
> > >
> > > ___
> > > Emc-users mailing list
> > > Emc-users@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/emc-users
> >
> >
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
> >
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread Bari

On 2/17/20 5:38 PM, John Dammeyer wrote:


Having also controlled a very large XY Laser system with 8085 code you can 
understand why I'm puzzled that 1GHz and up 32 ARM computers have so much 
trouble.



Recent PC's don't have real time capable GPIO ports tied to pins on the 
motherboard. Some chipsets have had a few GPIO lines that you can toggle 
at up to ~1MHz but only 6 pins max :(. It is the same for ARM SOC's. If 
someone added 16 lines of GPIO to their ARM SOC's internal bus that you 
could toggle at ~1MHz  it would not require the use of a PCIe, SPI or 
Ethernet IO card.




___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread Sam Sokolik
Because your examples are not running a full operating system...

On Mon, Feb 17, 2020, 5:40 PM John Dammeyer  wrote:

>
>
> > -Original Message-
> > From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
> > Sent: February-17-20 2:51 PM
> > To: emc-users@lists.sourceforge.net
> > Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> >
> > My Rasperberry pi is acting as a database server and works well. I still
> > marvel at my Southwestern Industries CNC machine that runs on a  8085
> > (5Mhz)
> > that controls a 3 axis mill at 2m/min with 2000 line encoders and servo
> > drives. All programming is conversational and tool compensation is done
> by
> > the
> > 8085. I can create subroutines, 8 sided polys, etc and string up to 99
> > operations into one program. It hs work flawlessly for the 15 years I
> have
> > owned it and works almost every day.
> >
> > I wonder if making PCs work as controllers is the right way to go. The
> > ATMEGA
> > could easily do the job, just my c is not up to it.
> >
> Having also controlled a very large XY Laser system with 8085 code you can
> understand why I'm puzzled that 1GHz and up 32 ARM computers have so much
> trouble.
> John
>
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread John Dammeyer



> -Original Message-
> From: Marshland Engineering [mailto:marshl...@marshland.co.nz]
> Sent: February-17-20 2:51 PM
> To: emc-users@lists.sourceforge.net
> Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> 
> My Rasperberry pi is acting as a database server and works well. I still
> marvel at my Southwestern Industries CNC machine that runs on a  8085
> (5Mhz)
> that controls a 3 axis mill at 2m/min with 2000 line encoders and servo
> drives. All programming is conversational and tool compensation is done by
> the
> 8085. I can create subroutines, 8 sided polys, etc and string up to 99
> operations into one program. It hs work flawlessly for the 15 years I have
> owned it and works almost every day.
> 
> I wonder if making PCs work as controllers is the right way to go. The
> ATMEGA
> could easily do the job, just my c is not up to it.
> 
Having also controlled a very large XY Laser system with 8085 code you can 
understand why I'm puzzled that 1GHz and up 32 ARM computers have so much 
trouble.
John

> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control

2020-02-17 Thread Marshland Engineering
My Rasperberry pi is acting as a database server and works well. I still
marvel at my Southwestern Industries CNC machine that runs on a  8085 (5Mhz)
that controls a 3 axis mill at 2m/min with 2000 line encoders and servo
drives. All programming is conversational and tool compensation is done by the
8085. I can create subroutines, 8 sided polys, etc and string up to 99
operations into one program. It hs work flawlessly for the 15 years I have
owned it and works almost every day. 

I wonder if making PCs work as controllers is the right way to go. The ATMEGA
could easily do the job, just my c is not up to it. 



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread John Dammeyer



> -Original Message-
> From: Les Newell [mailto:les.new...@fastmail.co.uk]
> Sent: February-17-20 11:23 AM
> To: emc-users@lists.sourceforge.net
> Subject: Re: [Emc-users] RPI4 is pretty close to a decent machine control
> solution...
> 
> 
> > I've done something similar for a client with a PiZeroW that took 18 seconds
> to boot but the logging of CAN messages was required on power up.  I ended
> up using a PIC32 since it had enough RAM and it also used a SPI interface to
> transfer data once the Pi was awake and ready to talk.  Even Python on the Pi
> was way too slow to keep up with the data so the Pi Code was C.  The PIC32
> code was C.
> 
> Well, you have programmed a Pi in C using SPI. Arduino uses C/C++ you
> should be pretty comfortable having a go at making your own LinuxCNC
> step module. 

Can't stand Arduino development environment or that you can't do breakpoints 
and look at what the processor is doing.  Handy for quick little projects but 
every single Arduino library I've used for LED lighting control tends to reset 
or halt sometime after it's been running.  With no clue as to why.

Ran into a similar problem with a Python program on a Pi Using the Enviro+ 
module I thought would be ideal for some sensing applications I had in mind.  
About 7 hours in it throws out a memory pointer error.   This is from inside a 
python SPI library.   Not a lot of use for either Python nor Arduino.  
Autonomous garbage collection at inopportune times is the bane of real time 
software.

Writing your own hal modules is pretty easy. Take a look at
> the documentation for halcompile
> <http://linuxcnc.org/docs/html/hal/comp.html>. Halcompile does a lot of
> the hard work for you.
> 
Thanks.  I'll take a look.

> 
> > If you consider that LinuxCNC, (and so many of the other Linux
> applications) which are done by volunteers, likely have Completion time set
> as the principal goal.  After all, they have busy lives and have other
> interesting things to do too so finishing and getting it out there as quickly 
> as
> possible certainly makes sense.
> 
> Not really. LCNC's source is reasonably well documented. The LinuxCNC
> core developers are unlikely to accept submissions that are difficult to
> understand. Generally it is more a case of people working on things that
> they need or they are particularly interested in. For instance I needed
> a carousel tool changer module for two of my machines. I couldn't find
> anything in LCNC that suited so I wrote one. After tidying it up a bit
> and documenting it I submitted it to be added to LCNC.
> 
> Les
>
Here I think we disagree in a major way.  LinuxCNC writing guideline 
specifically states that functions should be small and not have any 
documentation in them.  The idea that if you need to explain what you are doing 
then it's too complicated.  Yeah right.  So flipping back and forth through 
files reading 20 different 4 line functions is a better solution?In 
reality, someone working for me writing code the way it's done for Linux 
wouldn't be employed by me for very long.

I agree this is pretty crappy documentation
TempVar = OtherTempVar + 5;  // Add 5 to OtherTempVar and store to TempVar

and best not even put in the code.
TempVar = OtherTempVar + 5;  

This is better but doesn't explain much.
tempPositionIndex = LocalPositionIndex + TABLE_RECORD_SIZE;  

This is best because it says 'why'  not 'what'.
tempPositionIndex = LocalPositionIndex + TABLE_RECORD_SIZE;// adjust index 
to access the next passed parameter

Upper case on Local says it's static or Global and holds the value between 
invocations.  Lower case on temp says it's local variable that  is not static.  
Upper case on constant tell us it's not  a variable.  This could also be a 
sizeof(T_TABLE_RECORD) depending on what's going on under the covers.

Most of the LinuxCNC code I've looked at falls into the second example except 
the variables are c,I, j,j, etc. and say even less.

The moment you have to page to another file or section of a document you've 
failed.  
IMHO.
And I know many who disagree with me.

John


> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Les Newell




I've done something similar for a client with a PiZeroW that took 18 seconds to 
boot but the logging of CAN messages was required on power up.  I ended up 
using a PIC32 since it had enough RAM and it also used a SPI interface to 
transfer data once the Pi was awake and ready to talk.  Even Python on the Pi 
was way too slow to keep up with the data so the Pi Code was C.  The PIC32 code 
was C.


Well, you have programmed a Pi in C using SPI. Arduino uses C/C++ you 
should be pretty comfortable having a go at making your own LinuxCNC 
step module. Writing your own hal modules is pretty easy. Take a look at 
the documentation for halcompile 
. Halcompile does a lot of 
the hard work for you.




If you consider that LinuxCNC, (and so many of the other Linux applications) 
which are done by volunteers, likely have Completion time set as the principal 
goal.  After all, they have busy lives and have other interesting things to do 
too so finishing and getting it out there as quickly as possible certainly 
makes sense.


Not really. LCNC's source is reasonably well documented. The LinuxCNC 
core developers are unlikely to accept submissions that are difficult to 
understand. Generally it is more a case of people working on things that 
they need or they are particularly interested in. For instance I needed 
a carousel tool changer module for two of my machines. I couldn't find 
anything in LCNC that suited so I wrote one. After tidying it up a bit 
and documenting it I submitted it to be added to LCNC.


Les



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Sam Sokolik
This is the distinction between a motion controller and interface
hardware.   linuxcnc is the motion controller.   The external hardware that
interfaces with linuxcnc does what the computer doesn't do well

step generation
pwm
encoder counting
resolver interfacing
other stuff I can't think of now..

sam

On Mon, Feb 17, 2020 at 12:41 PM Gene Heskett  wrote:

> On Monday 17 February 2020 12:01:40 John Dammeyer wrote:
>
> > > From: Les Newell [mailto:les.new...@fastmail.co.uk]
> > >
> > > > Since very slow PCs with limited memory could do this as well as
> > > > the slower
> > >
> > > PRU processors on the BBB, I'd venture a guess that if a Pi4 can't
> > > do at least 50kHz stepping while also doing trajectory planning and
> > > screen updates there is something really 'off' with LinuxCNC.
> >
> > [SNIP]
> >
> > > > Maybe too many hardware abstraction layers?
> > >
> > > Remember LinuxCNC is designed to be a versatile, highly customizable
> > > and modular machine controller. It's original name Enhanced Machine
> > > Control reflects this. You can use it to run anything from a simple
> > > X,Y desktop engraver to a huge 5 axis monster with a complex tool
> > > changer or a robot arm. It was never intended to be optimized,
> > > tweaked and streamlined to wring out every last drop of performance
> > > for one task. You can have performance or you can have versatility.
> > > You can't have both.
> >
> > Thank you Les.  That was a very comprehensive reply and I appreciate
> > the time you took to write it.
> >
> > I want the performance, not the versatility.  And it appears that this
> > performance is only possible by offloading from LinuxCNC to MESA or
> > PICO or whatever.  Which is why I bought the MESA 7i92H instead of
> > just complaining about the speed of the parallel port.
> >
> > Since I know very little about rebuilding Linux systems in general
> > it's unlikely at this point that I could spend any time doing even
> > what Gene has done rebuilding the system to run on a Pi.  What he says
> > is a totally foreign language to me.
> >
> My apologies John, perhaps somewhat explained by the fact that
> my "training" is 100% from experience gained at what is sometimes called
> the University of Hard Knocks, which if anybody cares, is actually
> existed as a fund raiser for the student loan fund at Alderson Broddus
> University in Phillipi WV. They hold an annual dinner for graduates from
> UHK that costs $125, A $100 donation to the fund and $25 for the catered
> dinner. Other that that, my formal education stops at the end of the 8th
> grade, at which point I went to work fixing what was then these
> new-fangled things called televisions. It seems I had the "Nack", google
> that, but I was an electronics nerd before the word was invented. I was
> blessed with a mother that was the only girl in the 1929 class on
> aviation technology at Des Moines Technical High School, and if she
> didn't know the answer to a 6 yo's questions, she did know where the
> Madison County library was, so by the time I was 7 and about finished
> with McGuffies Readers in a little one room school, I was also reading
> high school physics text books. Making LinuxCNC run on a pi is not my
> first electronics project by about 75 years.  Now that is slowly fading
> with the years, 85 now, and medical accidents that have slowed my
> thinker some, first of which was a pulmonary embolism when I was 79.
> Thats a blood clot stuck in the lung preventing blood flow to the brain
> and is typically slightly over 98% fatal. And that should explain why I
> at times ask what should be common sense questions. At the same time,
> I've got a lot of BTDT's I can still remember quite well.  And I have a
> reputation for interrupting people saying it can't be done, by doing it
> while they are argueing against me.
>
> Perhaps my biggest mistake is in asssuming everyone on this list is not
> only a machinist, but also has a C.E.T. And thats not the case for many
> here. The bottom line is that each of us can teach the other a lot, if a
> common starting point can be found, something I readily admit I am not
> very good at finding.
>
> > But I am perplexed that if LinuxCNC is so modular why MachineKit for
> > the Beagle was forked rather than maintained as part of LinuxCNC.
> > Perhaps the word modular is overused in this case?  After all the goal
> > of running a RPi4 must be to have a really low cost small processor
> > but it does require a MESA if you want stepping pulses over 10kHz.  If
> > the BBB doesn’t need a MESA card then the overall cost does end up
> > being lower.  And it gets away with that by using the PRUs then that's
> > a good thing.But it seems that the BBB and LinuxCNC into
> > MachineKit were more like an exercise to see if it could be done
> > rather than a desire to make a smaller more modular LinuxCNC engine.
> >
> > All I remember is there was a discussion and some lamenting that the
> > fork for MachineKit wasn't 

Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Gene Heskett
On Monday 17 February 2020 12:01:40 John Dammeyer wrote:

> > From: Les Newell [mailto:les.new...@fastmail.co.uk]
> >
> > > Since very slow PCs with limited memory could do this as well as
> > > the slower
> >
> > PRU processors on the BBB, I'd venture a guess that if a Pi4 can't
> > do at least 50kHz stepping while also doing trajectory planning and
> > screen updates there is something really 'off' with LinuxCNC.
>
> [SNIP]
>
> > > Maybe too many hardware abstraction layers?
> >
> > Remember LinuxCNC is designed to be a versatile, highly customizable
> > and modular machine controller. It's original name Enhanced Machine
> > Control reflects this. You can use it to run anything from a simple
> > X,Y desktop engraver to a huge 5 axis monster with a complex tool
> > changer or a robot arm. It was never intended to be optimized,
> > tweaked and streamlined to wring out every last drop of performance
> > for one task. You can have performance or you can have versatility.
> > You can't have both.
>
> Thank you Les.  That was a very comprehensive reply and I appreciate
> the time you took to write it.
>
> I want the performance, not the versatility.  And it appears that this
> performance is only possible by offloading from LinuxCNC to MESA or
> PICO or whatever.  Which is why I bought the MESA 7i92H instead of
> just complaining about the speed of the parallel port.
>
> Since I know very little about rebuilding Linux systems in general
> it's unlikely at this point that I could spend any time doing even
> what Gene has done rebuilding the system to run on a Pi.  What he says
> is a totally foreign language to me.
>
My apologies John, perhaps somewhat explained by the fact that 
my "training" is 100% from experience gained at what is sometimes called 
the University of Hard Knocks, which if anybody cares, is actually 
existed as a fund raiser for the student loan fund at Alderson Broddus 
University in Phillipi WV. They hold an annual dinner for graduates from 
UHK that costs $125, A $100 donation to the fund and $25 for the catered 
dinner. Other that that, my formal education stops at the end of the 8th 
grade, at which point I went to work fixing what was then these 
new-fangled things called televisions. It seems I had the "Nack", google 
that, but I was an electronics nerd before the word was invented. I was 
blessed with a mother that was the only girl in the 1929 class on 
aviation technology at Des Moines Technical High School, and if she 
didn't know the answer to a 6 yo's questions, she did know where the 
Madison County library was, so by the time I was 7 and about finished 
with McGuffies Readers in a little one room school, I was also reading 
high school physics text books. Making LinuxCNC run on a pi is not my 
first electronics project by about 75 years.  Now that is slowly fading 
with the years, 85 now, and medical accidents that have slowed my 
thinker some, first of which was a pulmonary embolism when I was 79. 
Thats a blood clot stuck in the lung preventing blood flow to the brain 
and is typically slightly over 98% fatal. And that should explain why I 
at times ask what should be common sense questions. At the same time, 
I've got a lot of BTDT's I can still remember quite well.  And I have a 
reputation for interrupting people saying it can't be done, by doing it 
while they are argueing against me.

Perhaps my biggest mistake is in asssuming everyone on this list is not 
only a machinist, but also has a C.E.T. And thats not the case for many 
here. The bottom line is that each of us can teach the other a lot, if a 
common starting point can be found, something I readily admit I am not 
very good at finding.

> But I am perplexed that if LinuxCNC is so modular why MachineKit for
> the Beagle was forked rather than maintained as part of LinuxCNC.  
> Perhaps the word modular is overused in this case?  After all the goal
> of running a RPi4 must be to have a really low cost small processor
> but it does require a MESA if you want stepping pulses over 10kHz.  If
> the BBB doesn’t need a MESA card then the overall cost does end up
> being lower.  And it gets away with that by using the PRUs then that's
> a good thing.But it seems that the BBB and LinuxCNC into
> MachineKit were more like an exercise to see if it could be done
> rather than a desire to make a smaller more modular LinuxCNC engine.
>
> All I remember is there was a discussion and some lamenting that the
> fork for MachineKit wasn't maintained.  Or that it couldn't be
> maintained.
>
> I think partly I don't understand the difference between the current
> LinuxCNC and the MachineKit LinuxCNC.  What does make them so
> different that a newer version of LinuxCNC with bugs removed can't be
> used?  Since the Beagle has an Ethernet port could I use it to run the
> MESA?  Or does that once again require long strings of LinuxOS upgrade
> knowledge since the for LinuxCNC need a precompiled (for BBB) hostmot2
> driver?
>
> loadrt 

Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Les Newell



But I am perplexed that if LinuxCNC is so modular why MachineKit for 
the Beagle was forked rather than maintained as part of LinuxCNC.


The Machinekit team wanted to replace and redesign some of the core 
components of LinuxCNC including the framework that enable the modules 
to talk to each other. NML works but is pretty old and techniques have 
improved over time. They also wanted a more well defined split between 
the core motion control and the user interface. While these goals are 
theoretically good the end result is that we have two projects running 
in parallel with the available developers split between the two 
projects. Machinekit appears to have pretty much run out of steam due to 
a lack of developers and interest.


This is a pretty common sequence of events with open source projects. 
Someone or a group decide they can do it better so they fork a project 
and go their own way. After a while they lose interest and their project 
stalls. Occasionally the fork becomes more popular than the original in 
which case the original project often peters off.


I think partly I don't understand the difference between the current 
LinuxCNC and the MachineKit LinuxCNC. What does make them so different 
that a newer version of LinuxCNC with bugs removed can't be used?
For the average user there isn't a huge difference. They just had 
different ideas of how it should be done.
Since the Beagle has an Ethernet port could I use it to run the MESA? 
Or does that once again require long strings of LinuxOS upgrade 
knowledge since the for LinuxCNC need a precompiled (for BBB) hostmot2 
driver?


LinuxCNC requires real time support. Real time support reduces 
performance for user-space applications so out of the box the Linux 
kernel is not set up for this. There are some projects that add real 
time support to the Linux kernel such as RTAI, Xenomai and rt-linux. 
These projects modify the Linux kernel to add this support. To do this 
you need to rebuild the kernel. The kernel is the bit that talks to the 
actual hardware. The Beagle and the Pi use quite different hardware so 
they have different kernels. Kernels are so specific even the Pi3 and 
Pi4 have different versions.


Machinekit use Xenomai on the Beagle so they have this modified kernel. 
The rest of the Beagle specific stuff could be back ported from 
Machinekit to LinuxCNC. As usual it just needs someone to spend the time 
to do this.


If you want fast stepping from a Pi you are going to have to resort to 
external hardware. To be honest in my opinion for step generation the 
best bang for your buck would be to hang an Arduino off the Pi using the 
SPI bus then grab some of the step generator code from GRBL or Marlin. 
It's not exactly a one weekend project but it is realistic for one 
person to complete in a reasonable time. As far as I know LinuxCNC 
already has an SPI driver for the 7I90 so it wouldn't take much to tweak 
that driver to work with an Arduino.


I already use Arduinos talking over Modbus for keypads and front panel 
indicators. Modbus however is not fast enough for motion control.


I'm working on a project for a customer at the moment that has an Pi 
compute module talking to an XMega over SPI. The Pi runs a touch screen 
GUI and the XMega does the real-time stuff. There isn't much that could 
translate to to LinuxCNC though. The XMega is outputting lots of PWM 
channels rather than step/dir.


Les




___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread John Dammeyer
Hi Peter,
> >long strings of LinuxOS upgrade knowledge since the for LinuxCNC need a
> >precompiled (for BBB) hostmot2 driver?
> >
> >loadrt hostmot2
> >loadrt hm2_eth board_ip="192.168.1.121" config=" num_encoders=0
> num_pwmgens=0
> >num_stepgens=5"
> >setphm2_7i92.0.watchdog.timeout_ns 500
> >etc...
> >
> >Again, thanks for your very thoughtful reply.
> >John Dammeyer
> 
> LinuxCNC should run a Ethernet connected interface on a BBB without any
> changes,
> It may be that a buildbot ARMHF image will work (so you dont need to build
> LinuxCNC) but I dont know if it has been tried.
> 
> Theoretically the PRU support could be ported to LinuxCNC, I think that
> would be
> a good thing.
> 
> 
> Peter Wallace
> Mesa Electronics
> 

HI Peter,
I have three BBB.  One with the Replicape that may still one day drive the very 
dusty POS (Piece of S...) Delta 3D printer.  One just for playing around with 
since it's the older one with smaller flash memory.  And one with the xylotex 
Cape that uses normally open switches for limits and ESTOP.  (Not the best idea 
in the world).

I wish I had the time to spend on that project.  With the built in CAN bus 
interface, serial ports and not great HDMI output it's still one of the nicer 
platforms for machine control.  CANopen support with a CAN bus opens up modular 
tool changers, robot arms, even spindle motors if you can afford one with a 
CANopen interface.Adding your 7i92H to it for the axis control while using 
a CAN cape and LCD display plus buttons would be an ideal and not very 
expensive solution. 

John Dammeyer
> 
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread John Dammeyer
Hi Jon,
> On 02/16/2020 06:10 PM, John Dammeyer wrote:
> > Hi Sam,
> > Nice.  But it does seem to support my premise on isolating LinuxCNC from
> the hardware control.
> >
> > For example, way back a Pentium 386-66 with WIN-95 and MACH2 CNC was
> able to do this at 25KHz stepping.
> >
> > A BeagleBone Black with Machine Kit has PRUs to do the stepping and it's
> what, 4 years older than a RPi4?
> >
> > You�ve already shown that for a 1GHz+ LinuxCNC system that with an
> external Ethernet Hardware engine you can now get faster stepping rate .
> >
> > But only 10K steps/second on a 1GHz+ Pi?
> >
> Well, I really don't think software stepping is a good
> solution except for desktop "toy" machines of very low
> performance.   I've been making a step pulse generator for
> EMC/EMC2/LinuxCNC since 2002.  It can
> go up to 250K steps/second on all 4 axes at the same time.
> It can provide far finer timing resolution
> that any software stepping code, even the Beagle Bone's
> PRU.  (Step timing resolution is 100 ns.)
> 
> Even better than that, I also make controller/interfaces for
> analog velocity servos and PWM servos.
> 
> Jon

I think that supports my position that LinuxCNC is really just a middle box 
between display and motion hardware and if you want optimal performance you 
offload the real work to something that isn't LinuxCNC.

So that fits in with my suggestion that a box with display showing DROs etc, 
push button panel and MPG knobs that could be stand alone for manual operation 
is totally reasonable and if you wanted G-Code interpretation you add a PC that 
adds that set of velocity/accel sequences.

I've been asking on other metal working groups about CNC and it's really 
amazing how few CNC installations there are out there.  Many people are happy 
with a DRO and power feed on one or two axis.

John







___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Peter C. Wallace

On Mon, 17 Feb 2020, John Dammeyer wrote:

SNIP--

I think partly I don't understand the difference between the current LinuxCNC 
and the MachineKit LinuxCNC.  What does make them so different that a newer 
version of LinuxCNC with bugs removed can't be used?  Since the Beagle has an 
Ethernet port could I use it to run the MESA?  Or does that once again require 
long strings of LinuxOS upgrade knowledge since the for LinuxCNC need a 
precompiled (for BBB) hostmot2 driver?


loadrt hostmot2
loadrt hm2_eth board_ip="192.168.1.121" config=" num_encoders=0 num_pwmgens=0 
num_stepgens=5" 
setphm2_7i92.0.watchdog.timeout_ns 500

etc...

Again, thanks for your very thoughtful reply.
John Dammeyer


LinuxCNC should run a Ethernet connected interface on a BBB without any changes, 
It may be that a buildbot ARMHF image will work (so you dont need to build 
LinuxCNC) but I dont know if it has been tried.


Theoretically the PRU support could be ported to LinuxCNC, I think that would be 
a good thing.



Peter Wallace
Mesa Electronics



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread John Dammeyer


> From: Les Newell [mailto:les.new...@fastmail.co.uk]
> > Since very slow PCs with limited memory could do this as well as the slower
> PRU processors on the BBB, I'd venture a guess that if a Pi4 can't do at least
> 50kHz stepping while also doing trajectory planning and screen updates there
> is something really 'off' with LinuxCNC.
> 
[SNIP]
> > Maybe too many hardware abstraction layers?
> Remember LinuxCNC is designed to be a versatile, highly customizable and
> modular machine controller. It's original name Enhanced Machine Control
> reflects this. You can use it to run anything from a simple X,Y desktop
> engraver to a huge 5 axis monster with a complex tool changer or a robot
> arm. It was never intended to be optimized, tweaked and streamlined to
> wring out every last drop of performance for one task. You can have
> performance or you can have versatility. You can't have both.

Thank you Les.  That was a very comprehensive reply and I appreciate the time 
you took to write it.   

I want the performance, not the versatility.  And it appears that this 
performance is only possible by offloading from LinuxCNC to MESA or PICO or 
whatever.  Which is why I bought the MESA 7i92H instead of just complaining 
about the speed of the parallel port.   

Since I know very little about rebuilding Linux systems in general it's 
unlikely at this point that I could spend any time doing even what Gene has 
done rebuilding the system to run on a Pi.  What he says is a totally foreign 
language to me. 

But I am perplexed that if LinuxCNC is so modular why MachineKit for the Beagle 
was forked rather than maintained as part of LinuxCNC.   Perhaps the word 
modular is overused in this case?  After all the goal of running a RPi4 must be 
to have a really low cost small processor but it does require a MESA if you 
want stepping pulses over 10kHz.  If the BBB doesn’t need a MESA card then the 
overall cost does end up being lower.  And it gets away with that by using the 
PRUs then that's a good thing.But it seems that the BBB and LinuxCNC into 
MachineKit were more like an exercise to see if it could be done rather than a 
desire to make a smaller more modular LinuxCNC engine.

All I remember is there was a discussion and some lamenting that the fork for 
MachineKit wasn't maintained.  Or that it couldn't be maintained.

I think partly I don't understand the difference between the current LinuxCNC 
and the MachineKit LinuxCNC.  What does make them so different that a newer 
version of LinuxCNC with bugs removed can't be used?  Since the Beagle has an 
Ethernet port could I use it to run the MESA?  Or does that once again require 
long strings of LinuxOS upgrade knowledge since the for LinuxCNC need a 
precompiled (for BBB) hostmot2 driver?

loadrt hostmot2
loadrt hm2_eth board_ip="192.168.1.121" config=" num_encoders=0 num_pwmgens=0 
num_stepgens=5" 
setphm2_7i92.0.watchdog.timeout_ns 500
etc...

Again, thanks for your very thoughtful reply.
John Dammeyer


 



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Jon Elson

On 02/16/2020 06:10 PM, John Dammeyer wrote:

Hi Sam,
Nice.  But it does seem to support my premise on isolating LinuxCNC from the 
hardware control.

For example, way back a Pentium 386-66 with WIN-95 and MACH2 CNC was able to do 
this at 25KHz stepping.

A BeagleBone Black with Machine Kit has PRUs to do the stepping and it's what, 
4 years older than a RPi4?

You’ve already shown that for a 1GHz+ LinuxCNC system that with an external 
Ethernet Hardware engine you can now get faster stepping rate .

But only 10K steps/second on a 1GHz+ Pi?

Well, I really don't think software stepping is a good 
solution except for desktop "toy" machines of very low
performance.   I've been making a step pulse generator for 
EMC/EMC2/LinuxCNC since 2002.  It can
go up to 250K steps/second on all 4 axes at the same time.  
It can provide far finer timing resolution
that any software stepping code, even the Beagle Bone's 
PRU.  (Step timing resolution is 100 ns.)


Even better than that, I also make controller/interfaces for 
analog velocity servos and PWM servos.


Jon


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-17 Thread Les Newell



Since very slow PCs with limited memory could do this as well as the slower PRU 
processors on the BBB, I'd venture a guess that if a Pi4 can't do at least 
50kHz stepping while also doing trajectory planning and screen updates there is 
something really 'off' with LinuxCNC.


It depends on your definition of 'off'. On a Pi LinuxCNC runs it's 
realtime stuff as normal operating system tasks, just with high 
priority. The task scheduler has been tuned to be very aggressive in 
running high performance tasks but even so you have a lot of overhead. 
Linux and modern computer hardware are designed for high overall 
throughput for many tasks that are accessing huge amounts of data. They 
are not designed for ultra low latency on small tasks.


To get good stepping on older PCs you need RTAI which is effectively an 
RTOS that runs Linux as one of it's tasks. Realtime tasks are then run 
on this RTOS rather than the operating system. This is a simplification 
but you get the idea.


LinuxCNC has been designed to be versatile, easy to develop and easy to 
maintain. If you take a look at the stepgen code it's very generic and 
does not take advantage of any architecture specific code. The same code 
runs step generation on PCs running RTAI or rt-linux. It also runs on a 
Pi or a Beagle. It can run a parallel port, the PI GPIO pins, MESA GPIO 
pins etc with no modification.


So why is Mach able to get fast step speeds? It hijacks a hardware timer 
(the APIC) and has a custom interrupt handler that is tightly optimized 
for step generation on a PC with a parallel port. The code has one 
target and it works well on that target. It won't work on anything else. 
If someone was to write an equivalent driver for for the Pi you would be 
able to get blistering stepper speeds. The problem is that the code 
would only work on a Pi. On the Beagle someone wrote a driver that 
offloads the step task to the PRU. That code only runs a a Beagle. To go 
this route for all platforms you now have to write and maintain a 
different driver for each platform. LinuxCNC is a small project with a 
limited number of maintainers. If you make it too hard to maintain the 
project simply would not have the available man-hours to continue.



Maybe too many hardware abstraction layers?
Remember LinuxCNC is designed to be a versatile, highly customizable and 
modular machine controller. It's original name Enhanced Machine Control 
reflects this. You can use it to run anything from a simple X,Y desktop 
engraver to a huge 5 axis monster with a complex tool changer or a robot 
arm. It was never intended to be optimized, tweaked and streamlined to 
wring out every last drop of performance for one task. You can have 
performance or you can have versatility. You can't have both.


3D printers are used as examples of how it 'should' be done. They have a 
different design philosophy. They do one job.  The controllers are jam 
packed with highly optimized code that wrings out every drop of 
performance from both the hardware and software. Maintaining that code 
is hard. Porting it to a different platform is a huge job. Configuring 
it for a range of very different targets is pretty much impossible for 
anyone other than an experienced programmer who is willing to put in a 
lot of time. Luckily for the 3D printer community there are a lot of 
people and businesses willing to donate the time and money needed to do 
this. LinuxCNC does not have those resources.



  And generally the trajectory planners create FIFO buffers that hold a step 
and a direction bit for 4 axis in one byte.  Each byte, sent out at 50Hz, 
either has a step signal nor not.  At the end of the 5uS step pulse time as you 
said, the step levels are set off again.


Nope. That's not how LinuxCNC, Mach, GRBL or Marlin work. The step 
generators are fed velocity or position commands and they work out when 
to send out the steps as needed.  They aren't fed a pre-processed byte 
stream.


Mach does have a FIFO for the velocity commands. It's trajectory planner 
runs in user space and tries to keep the FIFO filled with velocities. 
That's why things like feed rate override and pause don't act 
immediately. There is a small delay as the new velocities filter through 
the FIFO. If the TP can't keep up your machine stops abruptly. When 
jogging the driver uses a very basic built in trajectory planner to get 
around the FIFO delay.


LinuxCNC's trajectory planner runs in real time. Stepper velocities are 
calculated on the fly. This is why pause, FRO etc are pretty much 
instantaneous (within the acceleration limits of the machine).


I haven't looked at GRBL and Marlin that closely but it looks like their 
step gens are fed position targets from a FIFO rather than velocities. 
The step gens effectively do some of the trajectory planning on the fly.



I'd say being able to 10kHz stepping and being happy with that might be setting 
the bar very very low.


Keep in mind the Pi is a very new 

Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread Gene Heskett
On Sunday 16 February 2020 18:27:24 Sam Sokolik wrote:

> software stepping...
>
> https://www.youtube.com/watch?v=LKjNOVHhHio
>
> Ethernet
>
> https://www.youtube.com/watch?v=2SEB7TuCUR0
>
> I don't have an spi solution to try
>
Works great Sam. I started out with a pi3 driving a 7i90HD, wasted a 
bunch of time trying to connect it, discovered the 7i42TA, bought 3 and 
stacked them on top of the 7i90HD, with the pi3 upside so the terms and 
pi was upside down in order to do away with the cable twist and 
shortened the cable to about an inch. But by the time I loaded up axis 
with hand dials and other gingerbread, much of which is running in a 200 
HZ thread because I can't turn a 100ppr hand dial any faster. The pi3 
was about tapped out but dead stable. Come the rpi4, its now running at 
only 800mhz and might as well be sitting in a beach chair with a cuppa 
and running an 11x54 Sheldon very well.  I've since built a new kernel 
with 16 u-s of latency but don't have it collected on my web site yet.

And since you dropped armhf support, I've been building master on the 
rpi4 about monthly so I'm not too far behind master.

And my offer to send you a 2G rpi4 to replace that odroid piece of 
crasher in the buildbot is still good. It will have a 5x5 psu, heat 
sinks, It will need a small fan, I'm useing a teeny 12volt from an old 
video card, running it from the 5 volt supply and keeps it at 45C, the 
swapfile turned off, an ssd big enough to build everything includeing a 
5G swap partition and the rest of it as workspace. Very little traffic 
on the 64Gig u-sd while its building all this on the ssd attached by a 
starttech sata to usb3 cable. It will build that new kernel in under an 
hour, and LinuxCNC debs of master ready to install in 35 or 40 minutes. 
With an uptime from power bump to power bump.  Whats not to like?  If 
your power is really bumpy, I might throw in a 650WA ups from 
Tiger-Direct who is selling refurbed small CyberPower ones for less than 
$40, free shipping when I bought one for this one. Debatable as to my 
need as I've got a D-525-MW in a building in the back yard running TLM, 
my 7x12, still running wheezy, no ups, and showing:

gene@lathe:~$ uptime
 22:36:03 up 180 days, 1:33, 1 user, load average: 0.07, 0.03, 0.05

What say you?  It would take me a bit to collect all that, but I'd try to 
make it as plug-and-play for the buildbot as I can.

Enjoy your videos, do more of them. :)
> sam
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> 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)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page 


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread John Dammeyer
> On Sun, Feb 16, 2020 at 4:12 PM John Dammeyer 
> wrote:
> 
> >
> > If I do the math.  The RISC processors generally run one instruction per
> > clock cycle and if that's really true there are 20,000 CPU cycles between
> > each step at 50kHz.  Coming from the embedded world where I work
> that�s
> > huge.  And generally the trajectory planners create FIFO buffers that hold
> > a step and a direction bit for 4 axis in one byte.  Each byte, sent out at
> > 50Hz, either has a step signal nor not.  At the end of the 5uS step pulse
> > time as you said, the step levels are set off again.
> >
> 
> No.  An embedded processor can do much better because thee processors
> come
> with specialized hardware for generating precision timed pulses.  All they
> need to do is set a register to control the set rate and then change the
> register whenever the rate changes.   In LinuxCNC-speak the register
> changes each cycle in the servo loop.This way a small embedded
> processor would very much beat a large one like what is onside the Pi4.
> 

> General-purpose processors like the PC or the Pi4 have to do these
> functions in software.
> 

That may well be true but on my dual boot LinuxCNC PC I can't do 50kHz stepping 
while I can with that archaic WIN-XP and MACH3 both off the parallel port.  

But I think that's really beside the point.  What surprises me is that people 
accept that 32 bit Pi4 really can't do more than about 10kHz stepping.  Or even 
20kHz and we still have tens of thousands if not more 3 axis G-Code 
interpretation machines doing 3D printing with 8 bit processors.

To be fair, a 10 microstep/step motor (2000 steps per rev) generally can't run 
more than about 700 RPM before torque falls off so badly that you miss steps so 
to make an open loop system work that speed limit needs to be adhered to. Which 
if you are running MACH3 fits just under the 25Khz max step rate.  With 20kHz 
it's 600 RPM.  Now it depends on whether the motor is direct coupled or there's 
a reduction to the lead screw.  So it's only with servos and high line count 
encoders that the higher step rates are required.

And I can say with personal experience dealing with encoder pulses in software 
and doing floating point to recalculate speed that tracks a spindle is really 
difficult without hardware counters.  A BeagleBone Black has two quadrature 
counter inputs. I don't know if the Pi processor has a quadrature counter. I 
think some of the Arduino based processors also have a quadrature based counter 
so things are possible that in the past required an external quadrature encoder 
chip.   

I still have a tube of 5 of those collecting dust.  They were used with two 
encoders to track drill rig heave on ocean swells and tides.  To prevent driil 
bit from being lifted up and down and smashed.  As the drill ship platform rose 
up the cable holding the drill string would let out to keep the same load on 
the turning drill bit.  As the water went down the drill string winch pulled 
the string up again for the same reason.  The second encoder was connected to a 
drum which had a cable connected to the ocean floor.  Essentially measuring the 
height of the drill ship above the ocean bed.

John








___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread Chris Albertson
On Sun, Feb 16, 2020 at 4:12 PM John Dammeyer 
wrote:

>
> If I do the math.  The RISC processors generally run one instruction per
> clock cycle and if that's really true there are 20,000 CPU cycles between
> each step at 50kHz.  Coming from the embedded world where I work that’s
> huge.  And generally the trajectory planners create FIFO buffers that hold
> a step and a direction bit for 4 axis in one byte.  Each byte, sent out at
> 50Hz, either has a step signal nor not.  At the end of the 5uS step pulse
> time as you said, the step levels are set off again.
>

No.  An embedded processor can do much better because thee processors come
with specialized hardware for generating precision timed pulses.  All they
need to do is set a register to control the set rate and then change the
register whenever the rate changes.   In LinuxCNC-speak the register
changes each cycle in the servo loop.This way a small embedded
processor would very much beat a large one like what is onside the Pi4.

It is the same with encoder handing.  The embedded processor will have a
quadrature decode that is done with flip-flops and hardware counters so the
software is not involved with the process except to read out the encoder
value at the servo loop rate.

General-purpose processors like the PC or the Pi4 have to do these
functions in software.

BTW the ARM CPU inside the Pi does better than one double-precision
operation per clock cycle per core.  Each core does a bit better than one
operation per cycle and these are four cores.Also, these are SIMD
instructions.  But what beats all this is the programmable hardware on the
embedded core. For example, there is a hardware analog comparator.
So while the CPU on the ARM-M is technically  40X slower the ARM-M can
generate pules in the megahertz range while the Pi4 can't come close.


> So as long as you can keep the buffer filled it's the interrupt routine
> that places it out to a parallel port.  And filling the buffer is the job
> of the trajectory planner which does the co-ordinated accel, velocity,
> decel for all axis to be able to maintain a specific feed rate in 3 or 4
> dimensions.
>
> I'd say being able to 10kHz stepping and being happy with that might be
> setting the bar very very low.
>
> BTW, I really do enjoy your videos.
>
> John Dammeyer
>
>
> > -Original Message-
> > From: Sam Sokolik [mailto:samco...@gmail.com]
> > Sent: February-16-20 3:27 PM
> > To: Enhanced Machine Controller (EMC)
> > Subject: [Emc-users] RPI4 is pretty close to a decent machine control
> > solution...
> >
> > software stepping...
> >
> > https://www.youtube.com/watch?v=LKjNOVHhHio
> >
> > Ethernet
> >
> > https://www.youtube.com/watch?v=2SEB7TuCUR0
> >
> > I don't have an spi solution to try
> >
> > sam
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>


-- 

Chris Albertson
Redondo Beach, California

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread andrew beck
Just want to second John here Sam.

You videos are awesome!

I have learnt a whole bunch of Hal from your videos.



On Mon, Feb 17, 2020, 1:28 PM Sam Sokolik  wrote:

> Technically it should be able to do about 20khz (with reset added to the
> pi_gpio component - SMOP).  This is playing within the constraints of the
> RT_Preempt realtime kernel...   This kernel doesn't usually have very low
> latency.  It is what it is.
>
> I really wasn't expecting the PI to do any software stepping.   But 20khz
> would be a decent solution for a lot of people.
>
> If you need more - buy external hardware like mesa.  It also runs it well.
>
> I am glad you enjoy the videos - I like making them.  I hope to make many
> many more.
>
> On Sun, Feb 16, 2020 at 6:12 PM John Dammeyer 
> wrote:
>
> > Hi Sam,
> > Nice.  But it does seem to support my premise on isolating LinuxCNC from
> > the hardware control.
> >
> > For example, way back a Pentium 386-66 with WIN-95 and MACH2 CNC was able
> > to do this at 25KHz stepping.
> >
> > A BeagleBone Black with Machine Kit has PRUs to do the stepping and it's
> > what, 4 years older than a RPi4?
> >
> > You’ve already shown that for a 1GHz+ LinuxCNC system that with an
> > external Ethernet Hardware engine you can now get faster stepping rate .
> >
> > But only 10K steps/second on a 1GHz+ Pi?
> >
> > Since very slow PCs with limited memory could do this as well as the
> > slower PRU processors on the BBB, I'd venture a guess that if a Pi4 can't
> > do at least 50kHz stepping while also doing trajectory planning and
> screen
> > updates there is something really 'off' with LinuxCNC.  Maybe too many
> > hardware abstraction layers?
> >
> > If I do the math.  The RISC processors generally run one instruction per
> > clock cycle and if that's really true there are 20,000 CPU cycles between
> > each step at 50kHz.  Coming from the embedded world where I work that’s
> > huge.  And generally the trajectory planners create FIFO buffers that
> hold
> > a step and a direction bit for 4 axis in one byte.  Each byte, sent out
> at
> > 50Hz, either has a step signal nor not.  At the end of the 5uS step pulse
> > time as you said, the step levels are set off again.
> >
> > So as long as you can keep the buffer filled it's the interrupt routine
> > that places it out to a parallel port.  And filling the buffer is the job
> > of the trajectory planner which does the co-ordinated accel, velocity,
> > decel for all axis to be able to maintain a specific feed rate in 3 or 4
> > dimensions.
> >
> > I'd say being able to 10kHz stepping and being happy with that might be
> > setting the bar very very low.
> >
> > BTW, I really do enjoy your videos.
> >
> > John Dammeyer
> >
> >
> > > -Original Message-
> > > From: Sam Sokolik [mailto:samco...@gmail.com]
> > > Sent: February-16-20 3:27 PM
> > > To: Enhanced Machine Controller (EMC)
> > > Subject: [Emc-users] RPI4 is pretty close to a decent machine control
> > > solution...
> > >
> > > software stepping...
> > >
> > > https://www.youtube.com/watch?v=LKjNOVHhHio
> > >
> > > Ethernet
> > >
> > > https://www.youtube.com/watch?v=2SEB7TuCUR0
> > >
> > > I don't have an spi solution to try
> > >
> > > sam
> > >
> > > ___
> > > Emc-users mailing list
> > > Emc-users@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/emc-users
> >
> >
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
> >
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread Sam Sokolik
Technically it should be able to do about 20khz (with reset added to the
pi_gpio component - SMOP).  This is playing within the constraints of the
RT_Preempt realtime kernel...   This kernel doesn't usually have very low
latency.  It is what it is.

I really wasn't expecting the PI to do any software stepping.   But 20khz
would be a decent solution for a lot of people.

If you need more - buy external hardware like mesa.  It also runs it well.

I am glad you enjoy the videos - I like making them.  I hope to make many
many more.

On Sun, Feb 16, 2020 at 6:12 PM John Dammeyer 
wrote:

> Hi Sam,
> Nice.  But it does seem to support my premise on isolating LinuxCNC from
> the hardware control.
>
> For example, way back a Pentium 386-66 with WIN-95 and MACH2 CNC was able
> to do this at 25KHz stepping.
>
> A BeagleBone Black with Machine Kit has PRUs to do the stepping and it's
> what, 4 years older than a RPi4?
>
> You’ve already shown that for a 1GHz+ LinuxCNC system that with an
> external Ethernet Hardware engine you can now get faster stepping rate .
>
> But only 10K steps/second on a 1GHz+ Pi?
>
> Since very slow PCs with limited memory could do this as well as the
> slower PRU processors on the BBB, I'd venture a guess that if a Pi4 can't
> do at least 50kHz stepping while also doing trajectory planning and screen
> updates there is something really 'off' with LinuxCNC.  Maybe too many
> hardware abstraction layers?
>
> If I do the math.  The RISC processors generally run one instruction per
> clock cycle and if that's really true there are 20,000 CPU cycles between
> each step at 50kHz.  Coming from the embedded world where I work that’s
> huge.  And generally the trajectory planners create FIFO buffers that hold
> a step and a direction bit for 4 axis in one byte.  Each byte, sent out at
> 50Hz, either has a step signal nor not.  At the end of the 5uS step pulse
> time as you said, the step levels are set off again.
>
> So as long as you can keep the buffer filled it's the interrupt routine
> that places it out to a parallel port.  And filling the buffer is the job
> of the trajectory planner which does the co-ordinated accel, velocity,
> decel for all axis to be able to maintain a specific feed rate in 3 or 4
> dimensions.
>
> I'd say being able to 10kHz stepping and being happy with that might be
> setting the bar very very low.
>
> BTW, I really do enjoy your videos.
>
> John Dammeyer
>
>
> > -Original Message-
> > From: Sam Sokolik [mailto:samco...@gmail.com]
> > Sent: February-16-20 3:27 PM
> > To: Enhanced Machine Controller (EMC)
> > Subject: [Emc-users] RPI4 is pretty close to a decent machine control
> > solution...
> >
> > software stepping...
> >
> > https://www.youtube.com/watch?v=LKjNOVHhHio
> >
> > Ethernet
> >
> > https://www.youtube.com/watch?v=2SEB7TuCUR0
> >
> > I don't have an spi solution to try
> >
> > sam
> >
> > ___
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
>
>
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread John Dammeyer
Hi Sam,
Nice.  But it does seem to support my premise on isolating LinuxCNC from the 
hardware control.

For example, way back a Pentium 386-66 with WIN-95 and MACH2 CNC was able to do 
this at 25KHz stepping.

A BeagleBone Black with Machine Kit has PRUs to do the stepping and it's what, 
4 years older than a RPi4?

You’ve already shown that for a 1GHz+ LinuxCNC system that with an external 
Ethernet Hardware engine you can now get faster stepping rate .

But only 10K steps/second on a 1GHz+ Pi?

Since very slow PCs with limited memory could do this as well as the slower PRU 
processors on the BBB, I'd venture a guess that if a Pi4 can't do at least 
50kHz stepping while also doing trajectory planning and screen updates there is 
something really 'off' with LinuxCNC.  Maybe too many hardware abstraction 
layers?

If I do the math.  The RISC processors generally run one instruction per clock 
cycle and if that's really true there are 20,000 CPU cycles between each step 
at 50kHz.  Coming from the embedded world where I work that’s huge.  And 
generally the trajectory planners create FIFO buffers that hold a step and a 
direction bit for 4 axis in one byte.  Each byte, sent out at 50Hz, either has 
a step signal nor not.  At the end of the 5uS step pulse time as you said, the 
step levels are set off again.

So as long as you can keep the buffer filled it's the interrupt routine that 
places it out to a parallel port.  And filling the buffer is the job of the 
trajectory planner which does the co-ordinated accel, velocity, decel for all 
axis to be able to maintain a specific feed rate in 3 or 4 dimensions.

I'd say being able to 10kHz stepping and being happy with that might be setting 
the bar very very low.

BTW, I really do enjoy your videos.

John Dammeyer


> -Original Message-
> From: Sam Sokolik [mailto:samco...@gmail.com]
> Sent: February-16-20 3:27 PM
> To: Enhanced Machine Controller (EMC)
> Subject: [Emc-users] RPI4 is pretty close to a decent machine control
> solution...
> 
> software stepping...
> 
> https://www.youtube.com/watch?v=LKjNOVHhHio
> 
> Ethernet
> 
> https://www.youtube.com/watch?v=2SEB7TuCUR0
> 
> I don't have an spi solution to try
> 
> sam
> 
> ___
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users



___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


[Emc-users] RPI4 is pretty close to a decent machine control solution...

2020-02-16 Thread Sam Sokolik
software stepping...

https://www.youtube.com/watch?v=LKjNOVHhHio

Ethernet

https://www.youtube.com/watch?v=2SEB7TuCUR0

I don't have an spi solution to try

sam

___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users