ESP32-Based Grbl CNC Control Board

New Home Forum Mostly Printed CNC – MPCNC Hardware Development – MPCNC ESP32-Based Grbl CNC Control Board

This topic contains 41 replies, has 9 voices, and was last updated by  Jeffeb3 1 week, 2 days ago.

Viewing 12 posts - 31 through 42 (of 42 total)
  • Author
    Posts
  • #99791

    Bart Dring
    Participant
    1. SD Card. You can store gcode on the SD card and run it using a web browser interface. It is sort of like Octoprint for CNC. This feature is not required, but recommended if you are laser engraving. (faster, more reliable than streaming)
    2. Probe Pin: This feature allows you to use a touch probe to accurately set the Z zero on your work. The Grbl_ESP32 will allows you to use virtually any pin for this. A few pins require a pullup. See this I/O guide for help.
    3. TB6600. I am familiar with that driver chip. It can do 4.5A and 16x microstepping. I believe it is compatible with 3.3V logic. You probably are using it built into a larger assembly or as a multi-driver package. Some of those have opto-isolators or other things that would need to be tested with 3.3V logic. That driver seems overkill for a MPCNC. NEMA17 motors mounted to 3D printed cannot be run with much current. Also, some of the more sophisticated mini driver modules might be able to run the motors cooler per watt.
    4.  Limit Switches: These are not required, but I highly recommend them. IMHO: Your machine is still a manual tool until you add them. Also, with them you can enable auto-squaring.
    5. Code changes. You will need to map the I/O pins you are using to the functions (step, dir, spindle, etc). I would suggest starting with one that is close.

    If you have further questions on how to use Grbl_ESP32, I suggest you ask them at the GitHub repo. More people familiar with the firmware will see the questions and we update the wiki with common questions.

    1 user thanked author for this post.
    #99840

    Marcelo
    Participant

    Hello Bart,

    Thank you vy much,

    My machine, uses nema 23,

    Its a ridged small home made cnc ,i do cut aluminium, copper and engraving ,

    I could use the drivers that you are using on your board ,i do have some here, and they will work fine too…with nema 23.

    Anyway, thank you again

    Ill try esp32,

     

    Marcelo

     

     

     

    #100005

    MegaDad3D
    Participant

    I finally got some time to work on this. I got rid of blinking light on the ESP32 dev board and have this instead:

    esp32_grbl

    The ESP32 is acting as a WIFI access point and hosting the page via a web server, if you’re curious.

    Now that I have the software installed on the ESP32, I’ll move forward with the hardware. I did already solder the pins on the ESP32 dev board, so everything is plug-and-play from here. I have the drivers ready, and will swap the servo wires from my RAMBo to see if I can make my MPCNC dance.

    Attachments:
    2 users thanked author for this post.
    #100034

    MegaDad3D
    Participant

    I got it to move. You may notice the ‘Alarm’ on that screen in the previous post. It took me a while to figure out that I needed to clear that error (click it until it went away) in order for the commands to go to the drivers. As with MPCNC, this is the kind of project where persistence is required.

    This demo was done by disconnecting the cables from my RAMBo (including the power cable) and driving the MPCNC with Bart’s controller board. I skipped the end stops (mine is set up for dual-endstops), which did not affect the jogging.

    Now that it’s moving, it’s time for some actual gcode.

    1 user thanked author for this post.
    #100058

    Bart Dring
    Participant

    The alarm is due to you having homing enabled, but have not homed yet. The machine does not know where it is in 3D space yet. you can clear the alarm by sending “$X”, but it is better to home it to clear it. You can also turn off the homing feature.

    Grbl is designed for subtractive machines (milling) and Marlin is designed for additive machines (FDM printing). There will be a bit of a learning curve, but I think once you master both, you prefer Grbl for milling.

    If you are struggling with anything, I am happy to help via Slack.

    2 users thanked author for this post.
    #100158

    MegaDad3D
    Participant

    One last thing… I used Ryan’s gcode to run this crown using a v-bit on some scrap plywood. I copied the gcode file to an sd card and kicked it off via the Web UI. I still have some tweaking to do, and I’m learning the differences between this UI and Repetier, but it does seem at this point be a viable option.

    crown_still_sm

    Big thanks to Ryan and to Bart for your great contributions to our creative endeavors!

    Attachments:
    1 user thanked author for this post.
    #100239

    Marcelo
    Participant

    Hello Bart, maybe some day you can try to conect esp32/grbl  on bcnc , it creates several adresses on the connect box, with the CP210x USB, but no one work out,

    after two days, i got an older ugs version conected to the board, but it was on my other lap top, on my cnc im using raspberry pi3, and i tryed to install the new ugs version, but it is on conflit now, and many discussions on git hub, im waiting for a estable version, too much information for a small user….im good with tools, and 1/2 inch screws…

    God Bless you

     

    Marcelo

    #100241

    Bart Dring
    Participant

    I’ll give BCNC a try. Some Grbl senders rely on the reboot that occurs when you connect to an Arduino to get a startup message. The ESP32 does not do that and it is not something we want.

    #100282

    Brian
    Participant

    I do not know whether I missed that point or not hence asking: can Estlcam directly drive this ESP32-board?

    #100298

    Bart Dring
    Participant

    bCNC

    I installed bCNC and can confirm some issues with it. It does not give any feedback when it encounters a problem, so it was quite hard to debug.

    First Issue

    It has this in the main readme…

    “GRBL should be configured to use MPos rather than Wpos. This means that $10= should be set to odd number. As of GRBL 1.1 we reccomend setting $10=3. If you have troubles communicating with your machine, you can try to set failsafe value $10=1.”

    The default for Grbl_ESP32 is $10=2. If I set it to 3, I was able to connect.

    I am not sure why it has a problem with other modes. You would think it would report an error if it did not like the current reporting mode.

    Second Issue

    After sending some commands it requests the gcode settings with $G. I noticed that that was getting caught in the buffer.

    It looks like Grbl_ESP32 might have a non standard response where it was sending…

    [GC:G0 G54 G17 G21 G90 G94 M5 M9 T0 F:0 S0.000]

    It should have been…

    [GC:G0 G54 G17 G21 G90 G94 M5 M9 T0 F0 S0.000]

    There was a colon after the F.

    Again, locking up on a simple parsing error, without reporting it is frustrating.

    Next Steps

    • Grbl_ESP32:
      • I will update the code and do a pull request to get rid of the “:” in the $G report.
      • I’ll ask on the Grbl_ESP32 GitHub issues if anyone thinks changing the reporting default to 1 or 3
    • bCNC:
      • Consider using regular expressions for parsing and trapping errors  🙂
      • ….Also, there may be other issues…please let me know
    #100299

    Bart Dring
    Participant

    EstlCAM

    Last time I checked, that requires proprietary firmware running on an Arduino.

    #100304

    Jeffeb3
    Participant

    EstlCAM

    Last time I checked, that requires proprietary firmware running on an Arduino.

    Yep. Estlcam can not directly control any of our boards anymore. It can still create gcode which can be used on any of the Marlin or grbl boards.

Viewing 12 posts - 31 through 42 (of 42 total)

You must be logged in to reply to this topic.