Page 1 of 4

[HowTo] Upload your 3d Printer Firmware in Linux

Posted: Tue Apr 28, 2015 6:43 pm
by mediaklan
Hi everyone !
Chances are ... most of Linux users won't really need this tiny tutorial. But if you're new to linux, or if you're new to 3d printing, you might be wondering where to start. If that's the case, here some tips in order to make the most of your printer with Linux (off course that tutorial can help a little for Windows users too). Don't forget the security basics when handling your printer, and don't forget I can't be held responsible if this tutorial burns your mustache or insult some aliens passing by who might just decide to vaporize you. After some experiments.
1. Get Arduino IDE !
http://www.arduino.cc/en/main/Software
Arduino IDE :
The open-source Arduino Software (IDE) makes it easy to write code and upload it to the board.
You can download and install Arduino in two ways : using your system-wide distribution packages, or from sources, to compile Arduino IDE. I will not explain neither of them, since you should first learn how to use your package manager, and if you're installing from sources, well, you just really don't need this tutorial. So, fortunately, every major mainstream distribution already has arduino packages ready to get installed. For example, you can install them like this in Ubuntu (13.04 to 15.04) or Fedora (F20 to F21) :

Code: Select all

sudo apt-get install arduino arduino-core
# for debian/ubuntu derivatives

Code: Select all

sudo yum install arduino.noarch arduino-core.noarch
# for rhel/fedora
2. Connect your Printer !
- Useless section since I won't tell you what to plug into what ... hmm ... oh well : USB -> PC -> USB -> Printer Power On. Done. Now, just to be sure everything's fine, open a terminal and check with lsusb :
Mine (iduino mega R3 board+ramps 1.4) looks like this :

Code: Select all

Bus 001 Device 004: ID 2341:0010 Arduino SA Mega 2560 (CDC ACM)
. Now, if your system do not even see your printer (which would quite surprise me), you're in for a lot of trouble. Better check and recheck everything.
3. Now, Get your firmware !
First, a zhangxueyou's quote ;) :
Firstly, we have to Declare that all the printers have been burnt correct firmware before sending. You don't need to do the same thing again.
Meaning you won't need to ask here for your firmware if it's already burnt in your board. And if you don't know, ask GT about it.
Now you might need your firmware for, let's say, modify it to suit your need. Here's how it's done :
- Download and extract your firmware somewhere safe on your desktop : you will end up (normally) with a folder named after the firmware, with a file name "something-bla-bla.ino".
- Open Arduino IDE, you will see this window :
Image
4. Get your settings right in Arduino IDE
Check your board from Arduino IDE. Menu -> Tools/Board/your-board :
Image
Ensure what your board is, and select accordingly. There was a problem for me since at first, my board was recognised as Arduino Uno, I had to change it to Arduino Mega 2560. Also, check your port in Arduino IDE and see if it's correctly selected :
Image
5. Fire up your firmware !
Menu -> Open the file "something-bla-bla.ino" in the extracted folder mentionned before.
Image
A new Arduino IDE window opens, while the previous one can be closed. Now look and select the tab named "configuration.h". Here you can make some pretty modifications, so don't go messing things up if you don't know what you're doing.
6. Finally time to cross your fingers, Check and ... Upload !
Here, click on the "Verify" button and let Arduino checks if everything is fine within your firmware and such (look at the terminal-looking part in the bottom to see what is going on).
Image
If everything's fine, hit the "Upload" button and wait for successful results (if not, try again from Point 2. until it works, or just give me your 3d printer. Unfortunately I can't say for sure if you're going to see it again) :
Image
- - -
And Voilà ! You've successfullly uploaded your firmware ! Now is the time to congratulate yourself ! Yipikaï ! ;)

° mediaklan °
PS : here's a list of some linux working 3d printing apps you might find helpful (this is not SPAM in any way, I just want to share some of my linux apps, if you know some I don't, please share) :

- Repsnapper : like that one, it's kind of a slic3r/repertierhost mix but easier to handle.
- Slic3r : Probably the most powerful slic3r (comes with the name) but can be tricky to use, and you can expect some bugs sometimes.
- Skeinforge : Good slic3r alternative, not sure if this is still developped though. Its interface comes from a previous century. Or two. Not sure about it.
- SFACT : basically a fork/clone of skeinforge.
- Cura : Nice. Supposed to be use specifically with some printers, but I think it can work with Prusa i3 too (didn't try it ... yet)
- MakerWare : same as Cura, basically.
- Pronterface : one of the first and most powerful 3d printing app. Careful with it.
- Plater : comes (for me in Fedora) with Pronterface, not quite sure what it is supposed to do. To test.
- Pronsole : comes with Pronterface, it's Pronterface without the GUI.
- RepetierHost : another one of the most powerful 3d printing app, people slowly tend to prefer it today.
- MatterControl : didn't know it even exists some days ago, kinda look like Arduino IDE for the interface, but it's more like a slic3r/Cura alternative.
- Blender : boy, do i really need to talk about the most advanced open source 3d software out there ?

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Wed Apr 29, 2015 9:27 am
by zhangxueyou
So specific! Thank you for sharing. :D

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Thu May 28, 2015 8:50 am
by johnz
WOW...thank you!!! Help me out on my windows PC ..Just followed the instructions on the Arduino part . Thank you. :D

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Thu Sep 17, 2015 12:43 am
by 4lynne
Well now NOTHING will connect to the 3 D printer not Repetier-Host, MatterControl, or Repsnapper
Ardunio IDE will not allow Serial Port to be set . . I did get the controller set to the Mega 2560 and that is it ! !
How do I delete all the stuff you said to add ?
Dropped windows side of this and went to just the Lnux side (Ubuntu 15.04 ) and it talks to the 3D printer via /dev/ttyUSB0
did the blink and another few things to stop the blinking LED

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Fri Sep 18, 2015 12:49 am
by mediaklan
Hi 4lynne ! What is your linux OS ? Was it working at first ?
Just to be sure, repeat the 1st steps, like this :
- Shut down your printer
- Connect the USB cable from your computer to your printer
- Power on your printer, open a terminal in your computer and type :

Code: Select all

lsusb
then :

Code: Select all

dmesg
Please return what these two commands gives here. lsusb will tell us if your board (arduino) is recognized, dmesg may tell us in which port (mine is /dev/ttyACM1 at the moment).
If we can't find your arduino in the lsusb list, there's no wonder why any app can't work.
- FYI, my arduino IDE crashes on me once, corrupting the uploaded firmware. What I did was to reset the printer with the ramps, and try to upload the firmware again.

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Fri Sep 18, 2015 11:28 pm
by 4lynne
Okay I made my self Root and also made my self a member of USB . . Then every thing now loads via /dev/ttyUSB0
so now just need the Marlin.ino file to get all the edits and up load it

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Fri Sep 18, 2015 11:32 pm
by 4lynne
Ubuntu 14.04 as 15.XX is not read for prime time has to many problems ( I tried it yesterday and it crashed ) I have a lot of 14.04 re installed and working on getting the rest working ( got my HP multi thing installed )

Now have connection at /dev/ttyUSB0 in Arduino IDE and using 15.04 Ubuntu and it loads Blink and several other things now !

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Sat Sep 19, 2015 12:08 am
by 4lynne
. . Got every thing to connect via /dev/ttyUSB0 now after upgrading to 15.04 Ubuntu so now it up to getting marlin.ino file working !

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Sat Sep 19, 2015 12:54 am
by 4lynne
. . Well that is no longer a problem as I now connect via /dev/ttyUSB0 and have Repetier-Host, Slic3r, and Ardunio IDE installed and Blink and a few others work .
made my self ROOT and made my self member of USB group since then all connect
Now just need marlin.ino edits fixed

Re: [HowTo] Upload your 3d Printer Firmware in Linux

Posted: Sat Sep 19, 2015 2:01 am
by 4lynne
Need to add this to your way of getting into the Dial out group
sudo adduser <the user you want to add> dialout
sudo reboot
id -Gn