# Introduction

Rambo(RepRap Arduino-compatible Mother Board)is a microcontroller board of 3D printer which integrates the stepper motor, hotbed, extruder, fan driver and thermometry in one. Rambo is completely compatible with Arduino in that it adapts the same IC, ATMEGA 2560, with Arduino mega2560. 3 additional resettable fuses are added to Rambo to protect it from over current. What’s more, the motor drive current can be controlled with code. The present popular LCDs that Rambo supports are smart controller 2004 and 12864.

Features:

1. Adopting the IC atmega2560 and atmega16u2 that are completely compatible with Arduino

2. 4 interface for thermometry.

3. All interfaces of 2560 and 16u2 are broken out for external use

4. 2 channel of sdramps that is compatible with SPI

5. 5 a4982 of 1/16 step size, 1 for X/Y axis respectively, 2 for Z axis, 2 for extruder.

6. Every control signal of stepper motor has a test point

7. The step size of stepper driver can be divided by firmware.

8. Reserved interface for LCD

9. 5 channel of PWM for extruder control

10. 3 power inputs source that is protected by resettable fuses: 12v 15a for hotbed; 12v 5a for extruder; 12v 5a for stepper motor.

11. PCB is composed of 4 layer of 35um copper sheet

## Overview and Hardware Resources

RAMBo (RepRap Arduino-compatible Mother Board) is an all in one RAMPS class motherboard targeting convenience, reliability, and performance.Our version is 1.2a.

size：102mm*104mm

weight：80g

## Software Resources

Compiling environment: Arduino IDE

Firmware: Marlin

PC Software:printrunRepetier-Host

# Interfaces

## Interface specifications

4 ADC interfaces (one for hotbed, 2 for extruder and one for thermometry)

5 PWM: 2 for extruder, 2 for fan control and 1 for heatbed

6 interfaces for end stop（X/Y/Z min, X/Y/Z max）which can be connected with mechanical or optical end stop, or hall sensor.

## Pins

The extension headers are in the format "Extension Name" "Pin Number" "Function". Example: MX1-5 Direction = "Motor Extension 1" "Pin 5".

## LCD panel support

There is now a fairly easy method for using a Smart Lcd with a Rambo board. See RamboLCD for instuctions.

# Fuses and lockbits

32u2 fuses - BODLEVEL = 3V0; HWBE = [X]; DWEN = [ ]; RSTDISBL = [ ]; SPIEN = [X]; WDTON = [ ]; EESAVE = [ ]; BOOTSZ = 2048W_3800; BOOTRST = [ ]; CKDIV8 = [ ]; CKOUT = [ ]; SUT_CKSEL = EXTXOSC_8MHZ_XX_16KCK_4MS1

EXTENDED = 0xF4; HIGH = 0xD9; LOW = 0xEF

2560 Fuses BODLEVEL = 2V7; OCDEN = [ ]; JTAGEN = [ ]; SPIEN = [X]; WDTON = [ ]; EESAVE = [X]; BOOTSZ = 4096W_1F000; BOOTRST = [X]; CKDIV8 = [ ]; CKOUT = [ ]; SUT_CKSEL = EXTXOSC_8MHZ_XX_16KCK_65MS

EXTENDED = 0xFD; HIGH = 0xD0; LOW = 0xFF;

Lock bits for both only set BLB1 = LPM_SMP_DISABLE (0x0F).

# Heated bed maximum voltage

The heated bed circuit's voltage is limited by the RGEF1400 PTC fuse which is rated to 16V. If a higher voltage is required this fuse can be replaced with a jumper wire and off board fuse holder. Make sure that your wire and solder are sufficient to carry the high current of this rail.

# Motor Current

The current for the stepper motors is set by firmware controlling the 8-bit digital potentiometer. The following formula from the Allegro datasheet describes how to set the reference voltage: ITripMAX = VREF/(8 X RS). RS, the value of the sense resistor on RAMBo is equal to 0.1$\Omega$. ITripMAX is the current the stepper motors are rated for. Ideally you should start with 70%-90% of maximum. You can verify the voltage for each driver by plugging the reference voltage (VREF) measured at the X_REF test point (Y_REF,etc for the other drivers) in the following formula:

$V_{Ref}= I_{TripMAX} \times 0.8$

Note the A4982 is set to be limited to 2A. This means the adjustable voltage range is 0 to 1.66 volts. The following formula will yield the 8-bit binary value, $W_v$, to be entered into firmware or directly over SPI.

$W_v = \frac{V_{Ref}}{1.66} \times 255$

# Fuses

RAMBo has 3 replaceable fuses. The small white fuse holders are Little Fuse OMNI-BLOCK fuse holders. They are compatible with NANO2 Fuses. Fast or very fast acting are recommended. An example part number for replacement fuses is 0448005.MR F2 supplies the motors and on-board power supply. F3 supplies the extruder heater and fan outputs. F4 is a 15A ATO (the type found in many automotives). F4 supplies the heated bed output.

# Development Environment setting

## Interface Connecting and Setting

Software Setting Before uploading, driver should be installed for windows. Then choose the type of board: Tools > Board > Arduino Mega 2560 or Mega ADK. (Picture below)

Select the serial port: Tools > Serial Port, the serial port for Rambo is usually the last one.

Click to check if there is any mistake. If not, click to upload.

After the uploading, you can go on with the next step. If the uploading is unsuccessful, read the error report on IDE, figure out the problem, and then try again. Some frequent errors are: a wrong select of board type and serial port.

# Get Started

Rambo is the CPU of a 3d printer, manipulating the whole process of printing which can’t be put in use directly without uploading firmware.

2. Setting parameters of the firmware

3. The parameters that need setting are as below, for those not mentioned just leave them as default.

 #define BAUDRATE 250000


This parameter is for the baud rate of serial port. Note: a successful communication can be realized only when the Baud rate of upper computer is identical with that of Firmware. The Baud rate is not set in random. The common Baud rate are: 2400，9600，19200，38400，57600，115200，250000. The last three are frequently used for 3D Printer.

1. define MOTHERBOARD 701

This parameter is set for board type. 3D Printer has many types of main board, and the setting of IOs is different, therefore, the parameter has to correspond to the type of your board, or it can’t operate normally. For other board, you can refer to the annotation on the board.

 #define TEMP_SENSOR_0 3
#define TEMP_SENSOR_BED 3


The two parameters are set for the type of temperature sensor respectively. They are the critical parameter to check if the sensor read temperature correctly. The printer can’t operate normally, even has potential risk (damage the device and even worse). You must modify depending on the temperature sensor you use.

 #define EXTRUDE_MINTEMP 170


This parameter is set to avoid the potential risks when the extruder operates before reaching the rated temperature. If you use other 3D Printer, such as printer to make Chocolates, 45℃ is appropriate, so that the parameter configured to a lower value(such as 40℃).

 const bool X_ENDSTOPS_INVERTING = true;
const bool Y_ENDSTOPS_INVERTING = true;
const bool Z_ENDSTOPS_INVERTING = true.


The three parameters are set for the end stops of three axes. If the configuration is true, the end stop outputs 1 in default condition, and outputs 0 when triggered. That is to say, mechanical end stop should connect to the NO (normally open) contactor. If it is connected to the NC (normally closed), true should be changed to false.

 #define INVERT_X_DIR false
#define INVERT_Y_DIR true


Mistakes are often made in the above two parameters. The parameters are different for different machinery. In principle, the origin should be at lower-left corner of the print platform (origin: [0, 0]), or at up-right corner (origin: [max, max]). Only in this way will the printing be correct, otherwise, the printing is the mirror image of one axis which is not what expected.

 #define X_HOME_DIR -1
#define Y_HOME_DIR -1
#define Z_HOME_DIR -1


If the position of the origin is the minimum, the parameter is -1; if it is the maximum, the parameter is 1.

 #define X_MAX_POS 205
#define X_MIN_POS 0
#define Y_MAX_POS 205
#define Y_MIN_POS 0
#define Z_MAX_POS 200
#define Z_MIN_POS 0


These parameters are crucial to the printing size. Fill in parameters by reference to the coordinate graphs. It is important to note that the origin is not the printing center and the real printing center usually lies at [(x.max - x.min)/2, (y.max -y.min/2)]. The coordinate of central will be used in the slice tool. The printing center’s coordinate must correspond to the parameter configuration, or it will print to the outside of the platform.

 #define HOMING_FEEDRATE {50*60, 50*60, 4*60, 0}


The parameter means the homing speeds (mm/min). This parameter can be set as default if you use the x-axis and y-axis adopt synchronous belt drive and z-axis adopts screw drive.

 #define DEFAULT_AXIS_STEPS_PER_UNIT {85.3333, 85.3333, 2560, 158.8308}


These parameters are crucial to the printing size. These parameters indicate the pulse the axis need when operating 1mm. they are corresponding to x, y, z axis and extruder respectively. In most cases these figure should be calculated by yourself, you can refer to: http://calculator.josefprusa.cz/#steppers.

So far, the commonest parameters have been configured and the printer can work now. In addition, if the 2004 LCD needs verifying, you should delete the “//” from “//#define REPRAP_DISCOUNT_SMART_CONTROLLER” to ensure the normal working.

# FAQS

1. I can’t upload program for Rambo using a USB.

Check if the external power supply for logic part is plugged in, or if the power supply is ok.

2. How many extruders does Rambo support?

Rambo supports at most 2 extruders.

3. What should I do if the driver installation failed?

You may encounter a problem “system cannot find the specific folder” in the process of driver installation when you use starter edition windows, because the starter edition of windows system has deleted some uncommon information for driver. The resolutions are as follows,

A: open C:\windows\inf\setupapi.dev.log

The file not only includes plug and play device, information for driver installation, but also record the reason of the failure of driver installation. Open this file and move to the end of the file you will observe the following information.

It is just the file error that causes the failure of Arduino driver installation.

B: creating a folder” mdmcpq.inf_x86_neutral_******** “in the path of

"C:\Windows\System32\DriverStore\FileRepository\ "

The identifications of all computers are different, so please refer to the prompt box from the “setupapi.dev.log” to know the “******* “. For example, information provided by my computer is

“C:\Windows\System32\DriverStore\FileRepository\mdmcpq.inf_x86_neutral_9f203c20b6f0dabd “

According to this prompt, I created another folder with the same name in the path of “C:\Windows\System32\DriverStore\FileRepository\”, as follows,

32bits windows:

64bits windows

mdmcpq.inf_amd64.rar [[Media:(http://www.arduino.cn/forum.php?mod=attachment&aid=MTIzMXxkN2QxMzdiMHwxNDA0NzAyMDgxfDY0MDF8MjQ4NQ%3D%3D) ]]

D. Reinstall driver step-by-step.

At this point, driver can be installed.

If the computer system is windows 8 and driver cannot be installed, there are some other alternative methods for you.

Click Windows and R

Input shutdown.exe /r /o /f /t 00

Click “ok”

The system enters “option” page automatically

Click FAQ

Click windows boot settings

Click reboot button

The system will reboot and go to the advanced boot options

Click “disable driver and mandatory signature”

After the restart of the system, you can install the driver and the installation method is the same with that of windows 7.

RAMBo-manual:

RAMBo silk:

# Rambo family

Compared with the 1.1b version，Rambo 1.2G has the following updates: 1. Increased ESD (Electro-Static discharge) Electrostatic Discharge in the USB circuit section 2. The logical part of the circuit and MOSFET share the same power supply 3. enhanced anti-interference ability of signals.