Generation 7 Electronics

From RepRap
Revision as of 19:22, 21 February 2011 by Traumflug (talk | contribs) (Started a Parts List.)
Jump to: navigation, search
Crystal Clear action run.png
Generation 7 Electronics

Release status: working

Gen7 Layout.png
Generation 7 Electronics
GPL v2
CAD Models
External Link

This is a complete set of electronics designed to be manufactured on RepRap machines. Replication is what makes RepRap unique, so this is extended to electronics now.

Technically, it's loosely based on the (a bit unfortunately named) Gen2OnABoard. It also has many features in common with the various Pololu_Electronics variants. Another description would be "RAMPS with integrated Arduino".

Design Goals

  • PCB easy to manufacture on a RepRap.
  • All parts on one board. Except for the Opto Endstops, of course.
  • Enough components to run a Mendel or Huxley with extruder and heated bed.
  • Easy to set up. For example, this would include an USB port.
  • Well available and cheap parts.
  • Based on the ATmega644.
  • Well suited for community driven development.

Features & Specifications

  • Single board solution.
  • Dimensions about 100 x 130 mm.
  • Single sided PCB.
  • Processor: ATmega644 (Atmel Corp.)
  • Pololu stepper drivers, exchangeable.
  • 4x stepper motor drivers with 1/16 microstepping.
  • TODO: on-board USB-RS232 converter.
  • Integrated hardware for driving one extruder (stepper, heater and thermistor).
  • Integrated hardware for a heated bed (heater, thermistor).
  • Integrated hardware for driving a fan.
  • Ready to be hooked up onto a generic PC power supply unit (PSU) via it's 20-pin connector.
  • Power supply via only the 4-pin Molex connectro supported as well.
  • Use of standard connectors.
  • Debug LEDs for power, Fan and both heater outputs.
  • Can turn PSU on and off in software, when supplied via the 20-pin connector.
  • Reset button.
  • ICMP header.
  • I2C header.

How to get it

You want three groups of parts:


How to manufacture the PCBs on a RepRap or a general milling machine is described later on this page. You want one "Gen7Board" PCB and up to six "Endstop" PCBs.

Even if there's currently nobody offering industry-manufactured PCBs, you're free to order them yourself. Gen7 is single sided, so this won't cost a fortune.

Electronic components

Open the layout with gEDA/PCB and export a "BOM". This will give you a list of all required components. Purchase this from your favourite electronics dealer. You may want to add the cable side of the connectors, their crimp pins and some wire.

Special considerations:

  • The Pololu Stepper Drivers want two single rows of 8 pin female connectors soldered into the board, so get them.
  • The Stepper Drivers come with their male headers, so there's no need to purchase them seperately.
  • Don't forget enough (8-9) jumpers for the jumper headers.
  • Resistors with 0.25 W are on the safe side, even if the footprint name reads "0.125".
  • The Pololus can be operated with up to 35 V, so you may want like-rated electrolytic capacitors.


You need four Pololus. Only few general electronics dealers offer them, but many RepRap specific shops have them in stock.

Part List



Opto Endstop



Generation 7 Electronics uses a TTL header for serial communications to the host. As many modern PCs lack a serial port, these need an appropriate USB to Serial cable:

USB to TTL Cable Mouser Adafruit Industries MAKE Store MakerBot Industries

In case your PC features a serial port or you already own an USB to Serial converter without a cable, you need an adapter cable.

Serial Adapter Cable TBD


10. Feb 2011: v1.0

New features: it works. Isn't that the most important thing on an 1.0 release?


In principle, you can run any of the RepRap Firmwares on this board. Adjust the I/O pin layout in config.h, adjust compile time options for no secondary board/no RS485 and proceed. Just like Gen2, RAMPS or similar electronics.

User:Jacky2k wrote: I discovered a bad problem with the board wich can destroy you ISP programmer or the ATMega! When you are using the board without the 20 pin ATX connector do NOT programm the board while the endstops are plugged in! The endstops may hold some lines of the ISP low. As a workaround pull out the endstops (X_MAX, X_MIN and Y_MIN) or use the 20 pin ATX connector when programming and don't forget to remove the jumper J13 when using the ATX connector!


You can try to use one of the following configurations for different firmware. But that may be a problem because the firmware versions are changing so fast that this wiki cannot be up to date every time, so the configuration files may become incompatible.


You may need the pinout for creating or porting a firmware:

Function ATMega Name Adruino Name Original firmware pin Direction in firmware
X Step PC3 DIO19 unknown Digital Output
X Direction PC2 DIO18 unknown Digital Output
X Min PB7 DIO7 unknown Digital Output
X Max PB6 DIO6 unknown Digital Output
Y Step PC7 DIO23 unknown Digital Output
Y Direction PC6 DIO22 unknown Digital Output
Y Min PB5 DIO5 unknown Digital Output
Y Max PB4 DIO4 unknown Digital Output
Z Step PA5 DIO26 unknown Digital Output
Z Direction PA6 DIO25 unknown Digital Output
Z Min PB3 DIO3 unknown Digital Output
Z Max PB2 DIO2 unknown Digital Output
Extruder Step PA3 DIO28 unknown Digital Output
Extruder Direction PA4 DIO27 unknown Digital Output
Power Enable PD7 DIO15 unknown Open Drain Output, low active
Heater 1 PA0 DIO31 unknown Digital Output
Heater 2 PB0 DIO0 unknown Digital Output
Fan 1 PB1 DIO1 unknown Digital Output
Temp 1 PA1 AIO1 unknown Analog Input
Temp 2 PA2 AIO2 unknown Analog Input



First test board of Gen7

24.12.2010: A first version of the Gen7 board has been etched and is beeing tested. The hardware seems to work, but the software still needs to be ported and tested with a RepRap.

29.12.2010: Some patches were made in the firmware to support endstops and homing. The patched firmware can be downloaded in the firmware section.

30.12.2010: Some more patches to the firmware. Current firmware seems to be stable and working. Not 100% tested yet.

04.01.2011: We found some bugs in the firmware again. All of them seems to be fixed, release is planned tomorrow.

05.01.2011: Uploaded current firmware with a lot of patches.

08.01.2011: Some little modifications of the PCB are required. Pull-Up resistors for I²C are missing, we want to change some headers to more common one, some resistor values are missing, ...

12.01.2011: I discovered a bad problem with the board wich can destroy you ISP programmer or the ATMega! When you are using the board without the 20 pin ATX connector do NOT programm the board while the endstops are plugged in! The endstops may hold some lines of the ISP low. As a workaround pull out the endstops (X_MAX, X_MIN and Y_MIN) or use the 20 pin ATX connector when programming and don't forget to remove the jumper J13 when using the ATX connector!

09.02.2011: The master branch of FiveD on Adruion firmware is ported and seems to work but is not tested 100%. The config file for the firmware will come soon.

Layout, PCB Editing

Gen7 uses gEDA, a true open source set of Electronics Development Applications (EDA). While gEDA has a bit of a learning curve and has some room for improvement regarding the graphical user interface, it's reliable, fast and well suited for the task. gEDA is available for Linux and Mac OS X and has ready-to-use packages on Debian/Ubuntu and SuSe. To install it on Ubuntu, simply type

sudo apt-get install geda geda-utils geda-xgsch2pcb

and you'll find schematics and PCB layout editor applications in your applications menu.

Typical Work Loop

RepRap is all about evolution of machines and lowering entry barriers into their (self-)replication, so here you have an easy how-to type description of a typical work loop for changing these electronics with the gEDA/PCB tool chain.

Download the files with Git or GitHub's download button. In the later case choose to download source and unpack that when done.

  • Always start editing with the project (.gsch2pcb suffix) file. You can open it by double-clicking it.
  • Select the schematics and use the button below the list to open it.
  • When done, save it and return to the project.
  • Open the PCB using one of the buttons to the right. Both have almost the same functionality.
  • If you have choosen to update the PCB, footprints no longer in use will have vanished and new or previously missing ones appear in the upper left corner. An updated list of connections (netlist) will have been loaded. Update the rats nest to find areas requiring work.
  • When done, save it and return to the project.

You get the idea?

PCB Manufacturing

gEDA can export PCBs to the Gerber and other file formats, of course.


On how to proceed further with that, see the PCB Milling page.


For etching, you likely want to reduce the amount of etched copper to a minimum. One way to get there perfectly, is to lay a ground plane into the layout.

Note: if you're in a hurry, you can leave out the step removing the tracks on the "GND-sldr" layer and setting Thermals. It'll work anyway.

  1. Open the layout in PCB.
  2. Switch to the "GND-sldr" layer.
  3. Remove all tracks on this layer ( = all light blue ones = all of the GND net minus vias and bridges, find the net with Menu -> Window -> Netlist).
  4. Draw a RECT (find the tool in the left bar) as big as the entire board.
  5. Do an "optimize rats nest" (o-key).
  6. Some non-GND tracks might be shortened with the new ground plane. Move the mouse over each of these tracks and press the "j" key (on your keyboard). Works for tracks hidden behind the ground plane as well, you'll see the difference immediately.
  7. For pins and pads you actually want to connect to the ground plane, set a Thermal (THRM tool to the left).
  8. Loop the last two steps until you get congratulations (no errors) on "optimize rats nest".
  9. In case the default clearance between the copper plane and pins/tracks are not sufficient for your purposes, you can adjust them with some command line work:
    1. Switch to the "solder" layer.
    2. Select Menu -> Edit -> Select all visible.
    3. Select Menu -> Windows -> Command Entry.
    4. Type the following and hit Enter:
      ChangeClearSize(selectedlines, 0.5, mm)
    5. Repeat the above with selectedpins instead of selectedlines.
    6. Repeat both of the above on the "Vcc-sldr" layer.
    7. As you probably guessed already, you can change this "0.5" to arbitrary values and "mm" to "mil", and use different values for each of the 4 groups.
  10. You're done.

On how to proceed with this etching-optimized board, see ... [Links needed]

Bug fixing, Sending Changes

This is community development, so getting changes from everyone is more than welcome. Write them to the forum, to the reprap-dev mailing list, use GitHub's Issue Tracker, whatever is most convenient for you. If you fork the repository at GitHub, you can also send Traumflug pull requests.