Following on from my earlier post about installing the hardware for a Viki LCD controller (and in light of several people asking for more info on the QU-BD forum), I decided to go ahead and write up some guidelines on configuring and installing Repetier firmware. This write-up specifically covers the Revolution XL 3D printer, although it should generalize pretty well to the non-XL version of that printer, and indeed to pretty much any other machine running Repetier firmware, although you’ll need to be sure and use the correct configuration parameters in those cases, and not the RXL-specific ones that I used.

Getting the Tools

In order to compile and install the firmware onto your printer, all you need is the Arduino Integrated Development Environment (IDE), which is available here. I recommend version 1.0.5 which is the current release version.  Download and install the correct version for your computer, and review the basic overview of the tools online.

This walk-through that you already have all the necessary drivers etc installed, so that you are able to communicate with your printer over USB from Repetier Host or other print spooling and control application. If not, you may want to review the getting started instructions on QU-BD’s web site.

Obtaining the Firmware Source Code

QU-BD makes available a version of the source code on their product page in the store. If you download and unzip that, you will see that it contains two sub-folders of particular interest – the one named ‘Repetier’ is the main source code for the firmware. The ‘Revolution_XL’ folder is a copy, with tweaks for use on the RXL. In particular, the Configuration.h file includes the altered settings that work with the RXL. You should compare that with the Configuration.h file in the Repetier folder to see what is different. I highlight some of the key changes I made, in a later post.

I also suggest that you download the latest official version of Repetier Firmware from the project’s github page – look on the right side of the page for the ‘Download ZIP’ option if you don’t want to go to the trouble of creating your own fork of the project, and just want a snapshot of the code. Once you have that, then you can update the configuration file that comes with that, to match the key settings in QU-BD’s ‘RXL’ version. That way you have the latest greatest version of the firmware, set up correctly for the QU-BD printer, rather than relying on an older copy of the whole source code that may contain bugs, or not have been updated to the latest functionality.

My Version of the Firmware

Alternatively, you can download the version of the firmware that I am currently running from github, or create your own forked copy there to work from.  This has already merged a recent official version of Repetier with the necessary QU-BD configuration. The  ‘Master’ branch contains all the settings that I am using. One thing to note is that it’s specifically set up to work with the Viki LCD panel and Azteeg X3. I believe it will work ok still without the Viki panel, but I’m not entirely sure (feedback is welcome). Even in the worst case, you should be able to just upload new firmware to fix anything that doesn’t work right on your machine with that firmware, or any other. But of course, once you start messing with your machine’s firmware, whatever version you use, you do so at your own risk. While it’s usually easy to recover from a bad firmware file, by installing a new one, it is possible (although fairly unlikely) that you may damage your hardware if the settings in the firmware are wrong.

IDE Setup

Whichever version of the source code you decide to use, you can open it in the Arduino IDE by double clicking the .pde or .ino file in the ‘Repetier’ folder (pde and ino are equivalent; the former was the extension used in the pre-1.0 versions of the IDE; later versions can open either).  Alternatively, run the IDE application, and open the file from the ‘File -> Open’ menu. If you want to build directly from QU-BD’s version downloaded from their website, then be sure to open the files in the ‘Revolution_XL’ folder rather than the ‘Repetier’ folder. However, I recommend working from the latest Repetier source code from github, and simply copying over the relevant lines of the Configuration.h file: do not just copy the entire config file across, as that might delete some other non-RXL related changes. (Or just try using my version, which already has the merge done, but is specific to, and only tested on, the RXL/X3/Viki hardware combination).

Go ahead and hook your printer up to the USB port on your computer, and turn it on. Make sure you aren’t running Repetier Host, or some other application that is communicating with the printer.  From the tools menu in the IDE, you need to set the board as ‘Arduino Mega 2560 or Mega ADK’. Also set the serial port for your printer under ‘Tools -> Serial Port’. On my Mac, the port looks like ‘/dev/tty.usbserial-DA005U6F’: yours will be different, depending on your OS and computer hardware configuration.

Using the IDE

You can click on the tabs in the IDE to see the various source files that make up the firmware. In particular, you will want to look at the Configuration.h file, as noted above.  You don’t actually have to use the IDE to edit the files; you can open them in another text editor instead if you prefer, or even use a fully-featured C/C++ IDE such as Eclipse (getting Eclipse to understand the Arduino code is pretty straightforward, and it offers a lot of benefits in terms of understanding and working with the code. I will post an article about doing that in the next few days, but in the meantime, this post about using Eclipse as a Marlin firmware editor may be helpful). Of course, if you just need to review the file or make a few simple changes, then the Arduino IDE will be sufficient.

Arduino IDE

When you have the code ready, you can click on the first icon on the top left corner of the IDE toolbar, to perform a test compilation. The IDE will show ‘Compiling Sketch’ in the blue bar under the source code text (a ‘Sketch’ is an Arduino program), and a progress bar. If there are syntax errors in the code, then diagnostic messages will appear in the black console area under the source code. If all is well, you will see something like this (albeit the size info may vary slightly, depending on the version of the source code that you have:

Arduino Success Message

If there are errors reported, you will need to fix them, but once you get a successful completion of the test compilation, then you can go ahead and upload the firmware to the printer.  Click the ‘Compile and Install’ button, and the IDE will repeat the compilation and then go ahead and write the firmware to the printer. Once it is complete, the printer will reboot, and be ready for testing.

Testing the Firmware

I recommend that you start testing new firmware with some fairly modest first steps. Exit the IDE, and connect to the printer over USB as you normally do, using Repetier Host, or similar.  Make sure that the connection happens correctly, and then try moving the head in small steps on each axis in turn, to make sure that it seems to move roughly the right distance, in the right direction, and the right speed. If that works, try homing each axis in turn (be ready to kill the power, if it become clear that something has gone wrong – e.g., the head moves the wrong way, or doesn’t respect the limit switches). If that works, then try heating the bed and head, and make sure they reach the correct temperature.

If you have an LCD controller such as a Viki installed, then you should also put that through its paces, paying attention to responsiveness, sensitivity of the controls, direction of cursor movement, as well as the ability to actually control the printer as expected.

Once all the basics seem to be in place, only then should try a print.  If something seems wrong, then pay careful attention to the Configuration.h file, adjust it as needed, and then re-upload corrected firmware, and re-test until everything seems good.

Configuration Specifics

I made several changes to the Configuration.h file in order to set it up the way that I want it for my RXL. I discuss those in more detail in my next post.

Tagged with →  

4 Responses to QU-BD RXL: Build and Install Repetier

  1. Bravin Neff says:

    Every time I try to compile your firmware, I get an error on this line: WRITE(EXT0_STEP_PIN,HIGH);

    Is this normal?

    • illuminarti says:

      No, that shouldn’t happen. Which Arduino IDE version are you using? Is it possible that you haven’t set the board type to ‘Arduino Mega 2560’ in the tools menu?

      If you can give me a bit more info about the error, and which line of which file it’s complaining about, I’ll dig further.

  2. Timothy says:

    I can’t for the life of me get a clean verify for firmware for my Azteeg X1 board. I loaded the Aduino patch so I can see the X1 board with the Atmega 1284P however I keep getting errors. Do you know where I can get a copy that will work or is there another board type I can choose that is close enough? The other board types verify properly. I get the verify errors before I even change any of the settings. If I use the Atmega1280 board type I don’t get any verify errors.

    Thank you, in advance, for your assistance.

    • illuminarti says:

      Hi Timothy –

      Not really very familiar with the X1 set up. Did you follow all of the instructions at the bottom of this page:

      http://reprap.org/wiki/Azteeg_X1

      I think at the very least you will need to set your Motherboard type to 62, as mentioned there, in order to get the code to compile.

      Which type of printer are you using it with?

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: