Changes

Jump to: navigation, search

GRBL

204 bytes added, 01:48, 18 May 2014
To compile GRBL and upload to the Arduino
*Open Terminal.
*Set the following environment variabels (i.e. run these commands in the terminal):
**<codesyntaxhighlight lang="bash">export AVRPATH=/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr</codesyntaxhighlight>**<codesyntaxhighlight lang="bash">export DEVPATH=/dev/tty.usbmodem1411</codesyntaxhighlight>
***(note: DEVPATH should match the name of your currently connected arduino. you can find this from arduino software under Port selection)
**<codesyntaxhighlight lang="bash">export GRBLHEX=grbl.hex</codesyntaxhighlight>
*Add the avr compiler's to your PATH. type this into the terminal:
**<codesyntaxhighlight lang="bash">export PATH="$PATH:$AVRPATH/bin"</codesyntaxhighlight>
*Change to the grbl directory:
**<codesyntaxhighlight lang="bash">cd ~/Downloads/grbl-master</codesyntaxhighlight>
**NOTE: replace <code>~/Downloads</code> with the full path where you downloaded GRBL.
*Compile GRBL. In the grbl-master director, type: <code>make</code>. GRBL should compile.
*Upload GRBL to the arduino. From the grbl-master directory, run:
**<codesyntaxhighlight lang="bash">$AVRPATH/bin/avrdude -C$AVRPATH/etc/avrdude.conf -pm328p -carduino -P$DEVPATH -D -Uflash:w:$GRBLHEX</codesyntaxhighlight>
adapted from here: https://github.com/grbl/grbl/wiki/Flashing-Grbl-to-an-Arduino

Navigation menu