Skip to content

Set Up FluidNC Using macOS

Longus edited this page Dec 6, 2021 · 5 revisions

This process worked for me in early December 2021 using this:

  • Mid 2012 MacBook Pro running macOS 10.14.6
  • ESP-WROOM-32 Dev Module from amazon ESP32-D0WDQ6 (revision 1) (this apparently is an older chip, but was available, and the price/shipping seemed good and my needs modest)
  • 'fluidnc-v3.2.6', installing for English only (I would advise avoiding 3.2.5 as it didn’t work for me)

Get the FluidNC software

  • Go to the FluidNC project page on Github
  • Click on the releases link on the right side of the page.
  • Click on the release that you want.
  • Click on the fluidnc-v.X.X.X.zip file, (v.X.X.X is the version) to download it (I used 'fludidnc-v3.2.6').
  • Unzip it in a folder on the Desktop of your computer (this avoids problems with long paths or ones containing spaces)

Get and Install the Silicon Labs Driver

This is required in order to establish a serial connection from a Mac to the ESP32. It installed a serial port '/dev/cu.SLAB_USBtoUART', make a note of the path and name for future use.

Confirm Python3 is Available

In 'Terminal.app' enter python3 --version, if you get a response like Python 3.7.4 you are good.

Otherwise you need to install it. If you already have brew enter brew install python3. To install brew, see https://docs.brew.sh/

Hardware Setup

  • It is best to disconnect all other USB/Serial devices from the computer while installing, because the installer will attempt to connect to each one and wait for it to possibly respond
  • connect the ESP32 to the Macbook Pro via USB cable

Install the FluidNC firmware

  • in 'Terminal.app' cd to the location of WiFi installer for FluidNC: cd /Users/your_username/Desktop/fluidnc-vX.X.X-macos You must do this, as the script is calling 'esptool', and expects it to be in the same directory as the script. If you are in any other directory the script fails. The firmware is compiled in different ways depending on the wireless options you want. Bluetooth and WiFi both use code space and a little extra power. Most users would choose WiFi over BT. I used WiFi.

  • hold down the 'io0' button on the ESP32 (next to the usb port), and in 'Terminal.app' run /Users/your_username/Desktop/fluidnc-vX.X.X-macos/install-wifi.sh (I couldn't get it to run unless I used the full path) This will try each of your available ports (I had 3) and when it finds the ESP32 it will install the firmware, and then launch the serial terminal script 'fluidterm.py'. fluidterm needs to know what port to connect to, mine looked like 'tty.SLAB_USBtoUART'

  • Send command '$I' to get general information.

    [VER:3.2 FluidNC v3.2.5:]
    [OPT:PHS]
    [MSG: Machine: Default (Test Drive)]
    [MSG: Mode=AP:SSDI=FluidNC:IP=192.168.0.1:MAC=78-E3-6D-18-4F-C9Mode=AP:SSDI=FluidNC:IP=192.168.0.1:MAC=78-E3-6D-18-4F-C9]
    ok
    

If you don't see the command you are typing, or if it is repeated, try 'ctrl-t' then 'ctrl-e'. See Serial Terminals for more.

You can launch fluidterm at a later date by using cd /Users/your_username/Desktop/fluidnc-vX.X.X-macos/fluidterm then python3 fluidterm.py

Setup the ESP32 to join your WiFi network

In fluidterm:

  • Send command $Sta to get all the network settings
    $Report/Status=1
    $Sta/SSID=
    $Sta/Password=******
    $Sta/IPMode=DHCP
    $Sta/IP=0.0.0.0
    $Sta/Gateway=0.0.0.0
    $Sta/Netmask=0.0.0.0
    ok
    
  • Send command $Sta/SSID=name_of_your_wifi_network to set the network name you want to join
    >>> $Sta/SSID=name_of_your_wifi_network
    $Sta/SSID=name_of_your_wifi_network
    ok
    
  • Send command $Sta/Password=your_wifi_password to set the password (this will not be available to read from the ESP32)
    >>> $Sta/Password=your_wifi_password
    $Sta/Password=your_wifi_password
    ok
    
  • To use a fixed IP address, send the command $Sta/IPMode=Static to set IP address type to fixed.
    >>> $Sta/IPMode=Static
    $Sta/IPMode=Static
    ok
    
  • Send command $Sta/IP=192.168.0.44 to set the IP address.
    >>> $Sta/IP=192.168.0.44
    $Sta/IP=192.168.0.44
    ok
    
  • Send command $Sta/Gateway=192.168.0.2 to set the IP address of your 'Router'.
    >>> $Sta/Gateway=192.168.0.2
    $Sta/Gateway=192.168.0.2
    ok
    
  • Send command $Sta/Netmask=255.255.255.0 to set the 'Subnet Mask'.
    >>> $Sta/Netmask=255.255.255.0
    $Sta/Netmask=255.255.255.0
    ok
    
  • Send command $Sta to see all the settings.
    >>> $Sta
    $Sta
    $Report/Status=1
    $Sta/SSID=name_of_your_wifi_network
    $Sta/Password=******
    $Sta/IPMode=Static
    $Sta/IP=192.168.0.44
    $Sta/Gateway=192.168.0.2
    $Sta/Netmask=255.255.255.0
    ok
    
  • Send command $Bye to restart the ESP32.
    >>> $Bye
    [MSG:INFO: Restarting]
    ok
    ets Jun  8 2016 00:22:57
    rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
    configsip: 0, SPIWP:0xee
    clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
    mode:DIO, clock div:1
    load:0x3fff0018,len:4
    load:0x3fff001c,len:1044
    load:0x40078000,len:10124
    load:0x40080400,len:5856
    entry 0x400806a8
    [MSG:INFO: FluidNC v3.2.6]
    [MSG:INFO: Compiled with ESP32 SDK:v3.3.5-1-g85c43024c]
    [MSG:ERR: Missing config file /config.yaml]
    [MSG:INFO: Using default configuration]
    [MSG:INFO: Axes: using defaults]
    [MSG:INFO: Machine Default (Test Drive)]
    [MSG:INFO: Board None]
    [MSG:INFO: SPI not defined]
    [MSG:INFO: Stepping:RMT Pulse:4us Dsbl Delay:0us Dir Delay:0us Idle Delay:255ms]
    [MSG:INFO: Axis count 3]
    [MSG:INFO: Axis X (-1000.000,0.000)]
    [MSG:INFO: Axis Y (-1000.000,0.000)]
    [MSG:INFO: Axis Z (-1000.000,0.000)]
    [MSG:INFO: Kinematic system: Cartesian]
    [MSG:INFO: Using spindle NoSpindle]
    [MSG:INFO: Connecting to STA SSID:name_of_your_wifi_network]
    [MSG:INFO: Connecting.]
    [MSG:INFO: Connecting..]
    [MSG:INFO: Connected - IP is 192.168.0.44]
    [MSG:INFO: WiFi on]
    [MSG:INFO: Start mDNS with hostname:http://fluidnc.local/]
    [MSG:INFO: SSDP Started]
    [MSG:INFO: HTTP started on port 80]
    [MSG:INFO: Telnet started on port 23]
    Grbl 3.2 [FluidNC v3.2.6 (wifi) '$' for help]
    >>> $$
    $10 = 1    (Status report options, mask)
    ok
    >>> $G
    [GC:G0 G54 G17 G21 G90 G94 M5 M9 T0 F0 S0]
    ok
    
  • For more commands, see FluidNC Commands and Settings

Make a Configuration Dump

  • In a browser, connect to the webUI either with IP address or 'fluidnc.local'
  • in the 'Commands' section
    • enter $CD to get a configuration dump
    • enter $CD=211130_1745.yaml to save a configuration file with the default settings to a file named '211130_1745.yaml' (I use date and time for the name to keep track of the changes)
  • In the 'FluidNC' tab
    • Click the green button, which will display 'FluidNC Local Filesystem'
    • Click on the configuration file you just created and it will open with your configured app, or save the file, depending on your browser settings
    • You can also upload files here by choosing them with the [Upload files] button

Install a settings file

  • In the webUI browser window, 'Commands' section
    • Enter $Config/Filename=211130_1745.yaml to make the file the active configuration (you can also do this in a more graphical manor in the 'FluidNC' tab).
    • Confirm it was set with $Config/Filename

Connect from your phone

  • In your phone's browser use a simpler alternative form of the IP address you used before: 'name_of_your_wifi_network.local'

Now back to 6-Pack Setup to continue.

Clone this wiki locally