My idea is FreeRTOS on probably PIC32 because that's what I have.  Or possibly 
use a BeagleBone but at the IDE level scrapping Linux and using just FreeRTOS.

It should have DROs, at least 4 axis power feed (only step/dir, no smart 
serial), Spindle quadrature for spindle RPM display along with Limit, home and 
estop inputs.  Very much like my ELS but for a mill.  And with an Ethernet 
connection and the appropriate software interface to LinuxCNC.

And around a 7" LCD display with a bunch of mechanical buttons and a quadrature 
input MPG for easier control.

So essentially an intelligent BoB with an Ethernet connection.  

The intelligence comes from the ability to power feed any axis from a BEGIN_n 
location to an END_n location where _n is the axis letter.

There is always a desire to try and service all markets with a single product.  
Often they don't serve any of them well.  For example the latest crop of 
electronic gearing for lathes using Arduinos at first appear pretty powerful 
until you want to run it on Sherline lathe at 3000 RPM.  Or you want that 
custom thread or turn rate and discover that you have to start up the 
development IDE after keying new values into a spread sheet and then reprogram 
the processor with some new values.  For some that's fun.  For others not 
exactly turnkey.  But at a very low cost and some low level participation you 
get a simple electronic gearing system.

OTOH, I don't know of too many people who manually turn their 3 jaw chuck a 
quarter turn on their LinuxCNC system and expect the carriage to track that.  
And if there's 0.025" backlash on the worn half nut that equates to a quarter 
turn you might just snap the edge off the carbide threading tool bit.  So a 
simple electronic gearing might also work well for a mill.

But with an ELS_Mill the point would be to create a user interface that has the 
mill behave like a manual mill with DRO and power feed.  One might even want 
the MPG knobs mounted on plates in the same location as the original handles so 
it has the feel of a manual lathe and a mental change of perspective/direction 
isn't needed.

With perhaps only 4 or 5 axis this would not work for that robot arm.  Nor that 
specialized CNC system with odd axis.  But who cares.  As far as I can see 99% 
of the small mills sold fit the standard XYZ model and very few people even add 
an A+B axis trunnion setup.  If they wanted that there's standard LinuxCNC and 
MachineKit.

And then run MachineKit or LinuxCNC on a PC or even a Pi4 strapped to the back 
of a monitor but instead of connecting via Ethernet to a MESA series of boards 
that ultimately are the Break Out Board they connect to this ELS-MILL.    The 
opportunity of a project like this is that the many many users out there who do 
not subscribe to any of the CNC groups because they are adamant that they do 
_not_ want CNC might well add or change up their BoB to add the power feed and 
DRO features.  Then tie in a quadrature encoder to the spindle to get spindle 
RPM since that new VFD they installed can now remove the need to change belts.

And then, when that project shows up that needs an actual CNC G-Code program to 
mill a spiral or something the opportunity to suddenly run CNC is there.  Ready 
to go.

So the above is my basic SYNOPSIS or PROBLEM on what that sort of product would 
do.    Under the MATERIALs heading perhaps start with something simple like 
https://www.busybeetools.com/products/mini-mill-3-4hp-brushless-motor-cx-serie.html
or even cheaper
https://www.kmstools.com/king-industrial-king-industrial-mini-milling-drilling-machine-154139

Find the kit or youtube video that has a conversion to CNC for it and put on 
the motors, belts and far east stepper motor drivers.   And maybe pick up a 
cheap BoB to start with so you can use say MachineKit on a BeagleBone Black to 
at least test the motion and get things rolling.

Next under materials is the display.  The Nuts & Volts magazine has started a 
series on the Nextion displays so perhaps to start with, again to move forward 
rather than spend it all trying to design the perfect solution, 
https://www.itead.cc/nextion-nx8048t070.html 
for $75 US.

Wire up a panel with 42 keys in a 7x6 matrix and add an ESTOP button to it.  A 
few serial/parallel chips with SPI selection to poll the switches.  A bit of 
code to read them.

Now we're into METHOD some of which I've described above.  
1. We can make our motors move, 
2. We've added an encoder to the spindle to read quadrature and determine speed 
and direction.  
3. We've wired up limit switches to help arrest motion at both ends of travel 
and mark as World Home Position.
4. Using the Nextion software we create a simple user interface with DROs for 4 
axis, a spindle RPM and several fields for feed rate and setting spindle speed. 
At the moment this looks very much like the Far East CNC boxes with 4.3" 
displays that you can buy for as little as $200.  These are ARM processor based.

So what's next in the METHOD section?
Well you want to create the code to accelerate and move the motors so you need 
a method of entering values and testing motion for each axis.  Take a close 
look at the method used n MACH 3 and given there's a 7" graphic display this is 
a good place to copy a concept.  The file created by this screen interaction 
may well be written out (and read back when the screen is displayed) to look 
like this:
[AXIS_0]
TYPE = LINEAR
HOME = 0.0
MAX_VELOCITY = 3.3
MAX_ACCELERATION = 15.0
STEPGEN_MAXACCEL = 35.0
SCALE = 15000.0
FERROR = 0.05
MIN_FERROR = 0.01
MIN_LIMIT = -0.04
MAX_LIMIT = 13.5
BACKLASH = 0.0215
HOME_OFFSET = -0.1
HOME_SEARCH_VEL = -0.8
HOME_LATCH_VEL = 0.01
HOME_FINAL_VEL = 0.2
HOME_IGNORE_LIMITS = YES
HOME_VOLATILE = 1
HOME_SEQUENCE = 1

That would all be described in more detail in the DESCRIPTION section of this 
project.  An initial layout that describes what is wanted and how it should 
work.  Or just clone the tools that come with LinuxCNC/MachineKit.

Finally we get to the point where we write the code that accelerates and 
decelerates a motor and runs it a given speed.  Track the stepping pulses, 
convert to engineering units and show them on the display.    It's not that 
much more work to then add another screen with BEGIN/END points for each axis 
and expand the software to now move from BEGIN to END using the accel and vel 
values.

So far we're really only talking about each axis operating independently.  
There's nothing in there, nor maybe should there be anything that says our feed 
rate is F30 and the distance from BEGIN to END is a tuple like BEGIN(X,Y and Z) 
and move to END(X,Y and Z).  That’s' so easily done with a single G code 
command that duplicating that means a user wants complex behaviour and so 
should invest in the time to learn a complex system.

But the reality is that the lowest acceleration value can be used for all axis 
and the max velocity of the slowest axis is also the limit.  So it's now simple 
linear algebra to calculate the motion of the tool bit from BEGIN to END at F30 
and supply an accel value, velocity value and distance value to the motion 
engine and move the motors so the tool bit travels at the expected rate from 
BEGIN to END.

The question is should it at this level of a tool.  That question needs to be 
answered before a single line of code is written.

This is all just me thinking out loud.  Perhaps the solution for a BeagleBone 
connected to a decent Cape is to run MachineKit but instead of the Axis 
Interface run the stand alone ELS-MILL user interface with the LCD screen and 
array of buttons.  But plug in a monitor, keyboard and mouse and press the 
local/remote switch on the LCD user interface and suddenly you are running 
MachineKit.

John Dammeyer.


> -----Original Message-----
> From: cern via Machinekit [mailto:[email protected]]
> Sent: March-01-20 2:38 PM
> To: Mr Greg
> Cc: Machinekit
> Subject: Re: [Machinekit] Re: PICnc with Machine Kit.
> 
> Hi,
> I have been looking from afar (as I don't need another project at the time) at
> the Zephyr RTOS project. It gets me thinking, something like PICnc needs
> mainly access to encoder and PWM peripheral timers, right? And then
> receive and send messages over some time-deterministic line, right?
> 
> So, wouldn't it be possible to use some RTOS "middleware" (for lack of better
> terminus technicus) for this? That way the support for the hardware would
> be outsourced to somebody else.
> 
> (Sorry for my [maybe] naive idea.)
> 
> Cern.
> 
> Mar 1, 2020, 23:10 by [email protected]:
> 
> > Hello
> >
> > Yes, reasonably priced / cheap "off the shelf hardware", simplicity, docu -
> manuals - tutorials etc in line with Kinsa's original picnc project.
> >
> > I suggest it would be best to avoid using ethernet. wifi & BT want to be
> ruled out of the RT. This leaves ethernet as being the only practical option 
> to
> keep the machine networked. Somewhat necessary in the majority of use
> cases.
> > SPI is most likely available in the likely candidate MCUs. ARM, PIC
> whatever...
> >
> > The code is already for PIC. Developing the existing code for a current PIC
> Dev board does make sense. However..PIC developers seem to be a bit thin
> on the ground? The popularity of� and future availability PIC Dev boards is
> also open to question.
> >
> > The ARM Cortex M0 series and upwards� would perhaps be a good place
> to start if there is the skill and interest, not to mention quite a lot of 
> time to
> effect a Porting and development of existing code?
> > ARM Documentation states that (in theory at least) that code written for
> the M0 will run on any later Mx series. Eg STM32 series, Arduino Zero, Due,
> and any number of clones and similar ARM M0, M3 M(whatever boards) that
> are quite ubiquitous, cheap and a probable assured future as far as can be
> seen.
> > The previously mentioned developer (and myself)� started this project a
> year+ ago.
> >
> > https://gitlab.com/samdcnc/samdcnc
> >
> > It was only a start, with limited headway made. External pressures and the
> enormity of the task brought about a halt. He may well be interested in
> contributing further TBD.
> > Guess you will hear from him if he is.....
> >
> > Just a basic rework and update of the existing Picnc driver and firmware on
> the existing pic32MX150 that works with current hardware and OSs +
> Machinekit and Lcnc would be a most excellent solution in itself without
> porting it to anything else. It works well and is cheap. Gerber files for 
> existing
> PCBs are available. It is already is capable of fulfilling the use cases of 
> many
> potential users. Perhaps nobody has taken much notice of it.
> >
> > For those readers here who haven't
> >
> > https://github.com/kinsamanka/PICnc-V2/wiki
> >
> > I am prepared to do test & verification on PIs 2, 3 and 4. I have ARM M0 and
> M3 boards. Bench test cnc and 3/4 axis cnc machine(s) currently running
> Picnc.
> > I am happy to write docu, at least for the Pi stuff that I have tested.
> possibly more TBA.
> >
> > So, yes I am interested in a resurrection, or perhaps rebirth sounds a bit
> more positive? of Picnc.
> >
> > Food for thought and possible collaboration,
> >
> > Cheers
> > MrGreg
> >
> >
> >
> > On Sunday, 1 March 2020 00:27:38 UTC, [email protected]  wrote:
> >
> >> Hi,
> >>
> >> I am all in for cheap, low entry hardware. Don't care if it is PIC or ARM. 
> >> I
> think that for most cases it would be enough to have just serial connection
> between PC/SBC and this board. But some simple� Ethernet based
> communication (maybe lower in the OSI model) would be nice too.
> >>
> >> I have a feeling that to get traction, it has to be simple, it has to be
> documented and it has to have tutorials and pre-compiled usecases which
> are near the real-word wants and needs of machine builders. (Like the BBB
> and CRAMPS, simple one use device.)
> >>
> >> Some type of free-cool-in social networking with Youtube videos would
> also help.
> >>
> >> Then, I think, you have change to get involvement from general
> community.
> >>
> >> And I think that the interest is there: Look for example on the YAPSC:10v
> project.
> >>
> >> BTW, there are implementations for the smartserial protocol which could
> be used for mining operation. The STMBL guy have implementation and
> there are guys around the world who reverse-engineered it.
> >>
> >> Cern.
> >>
> >>
> >> Feb 29, 2020, 19:27 by >> [email protected] <>>> :
> >>
> >> >
> >> > I do have a MESA 7i92H that works with > LinuxCNC> �on a dual boot
> PC.> � > I have to switch to standard parallel port for MACH3 or use a USB
> Smooth Stepper (more expensive than the 7i92H).
> >> >
> >> >
> >> > I've also had my mill running with the > BeagleBone> �Black, >
> MachineKit> �and the > Xylotex> �Cape.> � > There are issues with the
> cape, not with the BBB that had me change to a PC.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > The BBB with > Xylotex> �uses the PRUs for step/> dir> �for up to 4
> axis.> � > It can also take on Encoder input> � > Although there is a serial> 
> � >
> port the CAN bus port is taken up by the > Xylotex> �cape and I think SPI is
> too.> � > Partly, IIRC, because the HDMI also uses much of the I/O.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > There are LCD displays for the BBB but once again they take up all the
> important I/O and support is minimal.> � > This screen was done in Python.
> >> >
> >> >
> >> > >> http://www.autoartisans.com/>> MachineKit/BB-W1-LCD4.jpg>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Once you remove the HDMI and change which pins on the BBB can be
> used for step/> dir> �and spindle encoder the potential of using SPI or I2C
> for keypad matrix and LCD display along with at least one Serial Port and one
> CAN port for > CANopen> �you can address > MODbus> �VFDs and >
> CANopen> �based hardware for tool changers and other peripherals.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > That means the basic > Machinekit> �port to the BBB wouldn't have to
> be touched, the HAL and INI files would take care of remapping the step/>
> dir> �pins but the AXIS user interface would have to go.> � > A new interface
> that handled say 48 buttons, a graphical LCD display and an encoder knob like
> I have on my ELS could provide the basics.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > In fact, to start with and to not have to build large amounts of 
> >> > hardware,
> I'd probably use my ELS with a 20x4 character screen (instead of the 20x2)
> and the 35 buttons along with the MPG knob.> �
> >> >
> >> >
> >> > For example:
> >> >
> >> >
> >> > >> http://www.autoartisans.com/>> ELS/photos/ELS110D.JPG>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > >> http://www.autoartisans.com/>> MachineKit/FourLines2.jpg>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > This photo shows the RS232 connection and if the Y axis step/> dir>
> �pulses aren't used and the CAN driver chip is installed I've had it operating
> as a > CANopen> �User Interface Device.
> >> >
> >> >
> >> > >> http://www.autoartisans.com/>> ELS/photos/ELSBottom.jpg>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > A prototype cape that has headers to plug in place of the PIC CPU on my
> ELS could be the starting point as in the past I've created companion boards
> that plug into jumper the header on the bottom of the ELS.> �
> >> >
> >> >
> >> > >> http://www.autoartisans.com/>> MachineKit/IO_Interface-1.jpg>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > To expand a companion board with a ribbon cable to the 40 pin PIC IC
> socket then gives access to all the I/O and the header.> � > The BBB could
> plug into that.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > And finally, since the BBB still has Ethernet it runs > MachineKit> �but
> can perhaps talk MESA Ethernet protocol to a PC running > LinuxCNC> �or >
> MachineKit> �for the full blown AXIS display.> � > So you get the best of
> both worlds.> � > A small LCD/Keypad/MPG based module not much bigger
> than a DRO for pseudo manual operation of the mill but also attach a laptop
> or roll up a PC and you have full blown CNC.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > This is all still kicking the tires.> � > Maybe a PIC32 would be an 
> >> > easier
> solution.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > John Dammeyer
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > From:> �>> [email protected] <>>>  [mailto:>> machi...@>>
> googlegroups.com <>>> ] > On Behalf Of > mngr
> >> > Sent:> �February-29-20 2:46 AM
> >> > To:> �Machinekit
> >> > Subject:> �[Machinekit] Re: PICnc with Machine Kit.
> >> >
> >> > �
> >> >
> >> >
> >> > Hi,
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > In my humble opinion it should have both SPI and Ethernet connection.
> >> >
> >> >
> >> > I do not see any difference in the real-time capabilities of these two
> protocols.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > cost would go up a bit, but this project could receive more attention
> form already existing communities.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Maybe it could re-use the MESA protocol over ethernet, allowing for
> mutiple slaves to be connected, reusing work on the machinekit side, and
> attracting the attention of the LinuxCNC community. I am in europe, I cannot
> buy MESA because it came out way too expensive.
> >> >
> >> >
> >> > There already are some open source motor driver, like Odrive or VESC.
> Maybe we could reuse something from here (BLDC are not stepper, i know,
> but hey, stepper are way easyer!)
> >> >
> >> >
> >> > How hard do you think it is to move the MESA protocol from an FPGA,
> VHDL, to a microcontroller?
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > I would use something like an ATSAME54, which is a cortex m4. I feel
> that atmel start libraries are well made, but I am not a seasoned developer.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > I can work on this, but I need the guide of a experienced one.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Regards,
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > mngr
> >> >
> >> >
> >> >
> >> >
> >> > Il giorno venerd� 28 febbraio 2020 16:11:23 UTC+1, Mr Greg ha scritto:
> >> >
> >> >
> >> >
> >> > @ JohnD
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Re your OP
> >> >
> >> >
> >> > The answer is yes.
> >> >
> >> >
> >> > I have been using a Picnc + RPi2 -Jessy OS combo with machinekit for
> several yrs. Looking to upgrade/resurect/or move on if necessary.
> >> >
> >> >
> >> > I'm personally not the chap to do the detail code, but am working with a
> dev who has an interest and can contribute some limited time and effort.
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > I am currently exploring Pi4 + Buster with a view to either Mesa or
> Picnc? TBD
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > @ Tomp
> >> >
> >> >
> >> > I understand you have had Picnc successfully running on a Pi3 ?
> >> >
> >> >
> >> > I can't seem to get it to behave on a Pi3. Not with Jessie + MK anyways.
> All motors just spiral out of control soon as MK is started :(
> >> >
> >> >
> >> > All the SPI and dma addressing looks compatible They are both 2837
> >> >
> >> >
> >> > Any ideas?
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > @ All
> >> >
> >> >
> >> > By way of a little history. I did quite a bit of testing & verification 
> >> > for
> Kinsa' on the original Picnc v1.� ( circa 2012/13) This was on a Pic764 which
> had potential to run faster with more IO
> >> >
> >> >
> >> > I'm not sure of how much info there is left for that version. I may have
> some stuff archived?
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Cheers
> >> >
> >> >
> >> > MrGreg
> >> >
> >> >
> >> >
> >> >
> >> > On Thursday, 27 February 2020 06:42:41 UTC, John Dammeyer wrote:
> >> >
> >> >
> >> >
> >> > This project seems to have lapsed 5 years ago.�
> >> >
> >> >
> >> > >> https://github.com/kinsamanka/>> PICnc-V2/wiki>>
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > Any interest in resurrecting it?
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > John Dammeyer
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> > "ELS! Nothing else works as well for your Lathe"
> >> >
> >> >
> >> > Automation Artisans Inc.
> >> >
> >> >
> >> > www dot autoartisans dot com
> >> >
> >> >
> >> > �
> >> >
> >> >
> >> >
> >> > --
> >> > website: > >> http://www.machinekit.io>> > �blog: > >>
> http://blog.machinekit.io>> > �github: > >>
> https://github.com/machinekit>>
> >> > ---
> >> > You received this message because you are subscribed to the Google
> Groups "Machinekit" group.
> >> > To unsubscribe from this group and stop receiving emails from it, send
> an email to > >> machi...@>> googlegroups.com <>>> > .
> >> > To view this discussion on the web visit > >>
> https://groups.google.com/d/>> msgid/machinekit/228f471a->> 3292-4373-
> 9fe8-08bf92f8fd3c%>> 40googlegroups.com>>  <>>
> https://groups.google.com/d/>> msgid/machinekit/228f471a->> 3292-4373-
> 9fe8-08bf92f8fd3c%>> 40googlegroups.com?utm_medium=>>
> email&utm_source=footer>> >> .
> >> >
> >> >
> >> >
> >> >
> >> >
> >> > --
> >> > �website: > >> http://www.machinekit.io>> > �blog: > >>
> http://blog.machinekit.io>> > �github: > >>
> https://github.com/machinekit>>
> >> > �---
> >> > �You received this message because you are subscribed to the Google
> Groups "Machinekit" group.
> >> > �To unsubscribe from this group and stop receiving emails from it, send
> an email to > >> machi...@>> googlegroups.com <>>> > .
> >> > �To view this discussion on the web visit > >>
> https://groups.google.com/d/>> msgid/machinekit/17f901d5ef2d%>>
> 24e86ecd00%24b94c6700%24%>> 40autoartisans.com>>  <>>
> https://groups.google.com/d/>> msgid/machinekit/17f901d5ef2d%>>
> 24e86ecd00%24b94c6700%24%>> 40autoartisans.com?utm_medium=>>
> email&utm_source=footer>> >> .
> >> >
> >>
> >>
> >
> >
> >
> > --
> >  website: > http://www.machinekit.io>  blog: > http://blog.machinekit.io>
> github: > https://github.com/machinekit
> >  ---
> >  You received this message because you are subscribed to the Google
> Groups "Machinekit" group.
> >  To unsubscribe from this group and stop receiving emails from it, send an
> email to > [email protected]> .
> >  To view this discussion on the web visit >
> https://groups.google.com/d/msgid/machinekit/efc06de1-01bd-48fa-881d-
> c233ac822017%40googlegroups.com
> <https://groups.google.com/d/msgid/machinekit/efc06de1-01bd-48fa-881d-
> c233ac822017%40googlegroups.com?utm_medium=email&utm_source=foot
> er>> .
> >
> 
> --
> website: http://www.machinekit.io blog: http://blog.machinekit.io github:
> https://github.com/machinekit
> ---
> You received this message because you are subscribed to the Google Groups
> "Machinekit" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/machinekit/M1NEzHw--3-2%40tuta.io.

-- 
website: http://www.machinekit.io blog: http://blog.machinekit.io github: 
https://github.com/machinekit
--- 
You received this message because you are subscribed to the Google Groups 
"Machinekit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/machinekit/009701d5f027%2409ec9cb0%241dc5d610%24%40autoartisans.com.

Reply via email to