Inexpensive LinuxCNC interface for MPCNC

Awe, that’s sweet. Kind of makes me wish I didn’t have the TMC driver edition of the Archim. The sweet song of the Maker.

The jumpers on the unpopulated sockets are set for 1/8 mocrostepping for A4988.

Not sure the effect, but something I just noticed is that you have the CNC shield stuck on a piece of foam… possibly the slightly conductive stuff for static protection? You might try removing it…

1 Like

Ok. I’ll have to look at that table again. Logic failure here.

And I never thought about the foam. Interesting. Will test it out. And to top it all, I went to try my coin sorter to see if that driver was still working and I am not getting movement in the stepper on that either. I think I have too many things swimming around to think through this clearly. Had a funeral today, was really nice, but it does put my mind in a different frame.

I’m making progress. I eliminated one defective driver (ignoring the fact that I first plugged it in upside down and then upon plugging it back in, immediate magic smoke and real fire erupted. Woohoo!).

I’m puzzled. I went ahead and hooked up my Arduino with a working sketch to get step and direction to the shield. I know these were going fine. Nothing on any of the drivers. Perhaps the drivers are messed up. I did have some sparks along the way as I was setting them up initially so maybe all five are dead now.

Still mystified about the Bob. I am getting the direction signal clearly. Not sure again how to test the step signal. On the Arduino, I am used an LED and resister to get a good read on step and direction. And the shield is passing that on to the pin header for step and direction to the driver.

I’m sorry to make a cringe-worthy post, but all in the interest of knowledge. Might be time to get some new drivers and the DRV8825 would be an upgrade.

Please don’t sweat not seeing the step signals. Since you have seen motion a few times in the past, it is IMO probably safe to assume they are there… and press on with other issues. If you’re getting nothing out of your drivers – even in your test lash-up – then I think that replacing them is priority. Getting “sparks along the way” is never a good thing. And DRV8825 would be a good upgrade…

1 Like

Check your psu too. It is also a common part in these tests. And if you made sparks, it was the psu pushing the current.

1 Like

I’m getting 24v from all places that it should on vmot. I’m getting 5v from all places it should on logic.

Ordered some DRV8825s and we’ll see what happens. I got two sets, just in case! Didn’t get the Pololu originals but the vendor seemed to have some reliable reviews.

I’ll take a break from it this afternoon and actually get some milling done.

Won’t help you with the signals from the break out board but, in case you don’t know, the signals that LinuxCNC thinks it’s putting out to the board via the parallel port can be monitored with the HAL configuration screen. Select what signals to watch from the tree, and monitor via the watch tab.

3 Likes

That’s cool!

That is helpful. Got my new drivers today. Do not think I will be able to try them out until Thursday, depending on how long dinner lasts and guests stay on Christmas Day.


Success finally with the information displayed here.

I got the DRV8825s, two packs of five. I figured I would need extra and I was right.

I first tried again with the A4988s. Nothing. Blew a few of those. Do not cut power to your setup with the power switch on the power strip. Too easy to forget to turn it off. Now unplugging everything for good measure.

I got the drivers plugged into the CNC shield and ran each axis with an Arduino one at a time. So I knew the shield was good. I then tried with the DRV8825s. Got them to run on the Arduino, but not with the BOB and LinuxCNC. These are clones without the vref point marked and it was a bit sketchy to set voltage. Multimeter slipped a few times. There went two drivers. One was catastrophic and the Arduino Mega is now toast. I have an ESP32 though, so still ok for testing. Just learning how to do this and mistakes are being made.

I had one fleeting instance of a stepper spinning during setup and got my hopes high, but then nothing. It did have some interesting noises so that made me think of frequency issues, aside from VRef issues. I did set up HAL meters and signal references so I knew that things were going well from the computer to the board. Something must be off.

Spent a couple hours today reading up on everything and going back to the things that I don’t understand and hence have a tendency to ignore. Read up on examples of each config page.

The page in Stepconfig that gives all the base information I was using was all wrong. I dug a bit and found a references to these drivers for using with LinuxCNC. Then found the data sheet for the driver to confirm. Put in the correct numbers and away we went.

Thanks for your assistance. Now I can at least go see Star Wars without being distracted. Drives me nuts until I can get something figured out.

3 Likes

Is GRBL_ESP the next project?

1 Like

In the meanwhile I am working on the tinyG board I have too. The more options or paths to this, the more I will learn. I think all toward getting a 4th axis going too. I might have to build another MPCNC just as a test bed. Make it small and dedicated to milling aluminum.

I have been cranking out the slip fit boxes while I’ve been playing with this, so still productive.

2 Likes

Finally got around to wiring up two series connector. Got my dupont crimpers and parts and didn’t ruin too many before I got that knack for it.

Here was the old setup with jumpers to make sure I understood how these work.

And this is the new wiring, All connected and the three axes were responding as expected.

I did some manual commands. Then ran the LinuxCNC logo Hello World that is built in. Then ran the crown a couple times.

A couple times there seemed to be stalling. Not sure if I have the speed and acceleration correct yet. Hard telling just with the motors. And there was a strange phenomenon with the Z. It kept turning 1 mm at a time. Wasn’t quite sure what was going on with that crown gcode for the Z.

So then I threw the LCD case side at it. Pressed run and pop. Magic smoke and sparks come out of the Z driver. Shoot. Can’t figure out why. It wasn’t running hot at all and the vref was set correctly.

Seems it blew out the X driver too for good measure. So now I have one working DRV8825 of the pack of ten. They were pretty cheap, so don’t know if the price indicated low quality.

Kind of maddening. But I’ll figure it out. Still wondering what about the LCD panel blew the driver. I guess I learned a lesson that you just can’t throw random bits of gcode from anywhere into this setup.

1 Like

Huh that is strange. If the vmot is ok and the step/dir are normal signal levels it should be impossible for commands to smoke the driver.

I see your power supply looks like it has +V and -V. I cant see if your power cord has “L” “N” and “G” but I’ll assume it does. Is -V internally connected to Gnd of the psu or is it floating? If you had negative voltage relative to gnd and the cnc shield tied them together then… well it would still probably have different symptoms like immediate smoke. I dunno. Or if neutral and ground were backwards, it might not be apparent right away until you start drawing current and then pop. Grasping at straws here, I really have no idea.

I’ll check that out tomorrow and post pics. I have the three connected for the power cord.

The whole ground/earth thing and neutral and circuits in general mystify me. I can imitate a picture and make it look like it, but if I’m going from diagrams and referencing to the physical board, it’s like reading Russian. You know some of the letters, but it takes a while to decode them.

The breakout board has an interesting click when I test each axis in the stepconf wizard. I hadn’t noticed that before.

Is there anything you can do in LinuxCNC that can’t be done with GRLB and CNC.JS? I started playing with LinuxCNC but gave up on it when I found CNC.JS. I can write macros for hole and edge finding, and what ever else I need to do.

I’d love to hear your experience.

Ryan

Short answer: A couple of metric shit tonnes.

Long answer: Not with an MPCNC.

Non-asshole answer: It’s nearly infinitely customizable, and the number of devices it can control is astounding, provided you have the I/O and driver boards for them. But that’s all moot, given that we’re dealing with a Cartesian CNC device with minimal accessories.

3 Likes

I use cncjs+marlin on my mpcnc. I’m playing with linuxcnc on a lowrider build. I’ll say that I’m learning to really like linuxcnc, I’ll probably convert my mpcnc over to it later if I can get it running on a raspberry pi.

It’s a lot easier to adjust linuxcnc’s config files than it is to reflash firmware. If you’re into coding, the gcode dialect for linuxcnc is much more powerful.

I know Ryan has been doing a lot of work lately in trying to improve arcs in marlin. For things like that I would be curious to see if there are any performance differences side by side between linuxcnc, marlin, grbl.

If you’re into nerding out on these things it’s fun, but at the end of the day it’s not necessary for our little machines in stock configurations. That said there are those of us who do things like add a plasma torch or rotary axis to our machines so then linuxcnc becomes a much more attractive option.

1 Like

You should try grbl Kyle. It can also be configured via software, and it is pretty bare bones, but works great with CNC.js.

2 Likes