Motherboard 1.2

From RepRap
(Redirected from Motherboard 1 2)
Jump to: navigation, search

This page describes something which is no longer the most recent version. For the replacement version see: "Official" Electronics


Overview

Jump to the Index / Table of Contents

Motherboard 1 2-motherboard-modified-small.jpg
Cache-3408779902 7575952594.jpg

The top picture shows the board configured for RepRap. The second picture shows it configured for use in a Cupcake. The few differences are described in the appropriate sections below.

This board is the brains behind the Generation 3 Electronics. The heart is a Sanguino which is an Arduino-compatible board that is powered by an ATMEGA644P chip. It has connectors to hook up all the various peripherals that you'll need to drive a RepRap machine. It has headers for three stepper drivers, as well as 4 RJ45 connectors for Extruder Controller Boards. Not only that, but it has an SD card and a connector to hook it up to an ATX power supply


Some highlights:

  • Onboard atmega644p - 64K flash space, 4k ram, 32 I/O pins, Arduino compatible.
  • 3 x Stepper driver connectors with min/max inputs.
  • Built-in SD card socket for printing from file and buffering large print jobs.
  • RS485 connection for noise-free communications with extruder / toolhead controllers.
  • ATX power connector for power. It can also turn the power supply on and off.
  • Headers to allow existing Sanguinos to plug straight in.
  • I2C headers for simple hookup of external peripherals.
  • On/Off switch for instant-kill and simple control of the entire system.



Get It!

Fully Assembled

If you buy the fully-assembled version and you're making a RepRap you will have to de-solder a couple of components.

It is highly recommended to simply buy a fully-assembled board as it will rarely end up costing less (or at least not enough to make it worth while).

Nah. It is ideologically more pure, or rather, 
just much more fun to etch your own. --Sebastien Bailard 11:24, 22 November 2010 (UTC)

Do-it-yourself PCB

If you buy the PCB you will easily be able to configure the board for use either in MakerBot or RepRap.

Raw Components



Files

Cache-3527845874 e9d5599f2c.jpg

You can download the release file from SourceForge that has a bunch of helpful files for this board. It contains:

  • GERBER files for getting it manufactured
  • PDF files of the schematic, copper layers, and silkscreen
  • Eagle source files for modification
  • 3D rendered image as well as POVRay scene file

* exerciser code to test your board.

If you just want to peek at the files easily, check them out on Thingiverse.


Schematic

Motherboard 1.2 Schematic

There is a bug in this image: in the rectangle of the ATMEGA644A chip the labels RXD0 and INT0 are swapped. I tried to upload a new version of the image but the wiki is not configured correctly, or there is a problem of permissions of the file or something. Please correct it, it caused me (and maybe others) some headaches..

Interface

Pinout

Here is a handy reference that tells you which pins are hooked up to what features of the board:

Stepper Motor Headers

Cache-3432260208 caaacca98a.jpg

See our IDC cable construction page for info on how to make the IDC cables.

Pin Name Function
1 N/C Not Connected to anything
2 GND Connect this to your uC to share a common ground.
3 Step A pulse on this line will make the stepper motor advance one step in the desired direction.
4 Dir If this pin is high, the motor will rotate forward, low it will rotate backwards.
5 Enable This pin allows you to turn the motor on and off. The definitions of high/low are determined by your stepper driver.
6 Min This is the signal from the 'min' sensor. The definitions of high/low are determined by your opto endstop.
7 Max This is the signal from the 'max' sensor. The definitions of high/low are determined by your opto endstop.
8 GND Connect this to uC to share a common ground.
9 GND Connect this to uC to share a common ground.
10 GND Connect this to uC to share a common ground.


RS485 Comms + Power

Cache-3432258560 2753725d0b.jpg

THIS IS NOT ETHERNET!

Name Function
1 RS485 A
2 RS485 B
3 +12V
4 +12V
5 +12V
6 GND
7 GND
8 GND

This is one of the major new features of the Generation 3 electronics. RS485 is a robust serial communications channel. It uses differential signaling to provide very noise tolerant communications over relatively long distances, such as in a RepRap machine. RS485 is how the RepRap motherboard communicates with all the tool controllers. It is a very mature technology and is also pretty cheap. Definitely rad.

RS485 is a half-duplex channel, which means data can either be transmitted OR received at one time. This makes things a little bit tricky, but don't worry... we have it under control. What you need to know is that there are two wires that need to be hooked up: A and B. These are arbitrary names for the wires due to the differential signaling. Basically, you just have to make sure that all the A's are wired together, and all the B's are wired together.

To give a bit more insight into the way RS485 is implemented on the Extruder controller, we have given full control over the RS485 chip to the controller. It can independently enable or disable transmitting and receiving. One of the cool things about RS485 is that you can listen in to your own transmissions. This is a critical feature we exploit to ensure that we keep the transmit functionality enabled until all of our data has had a chance to be sent out.

Both RepRap and MakerBot use the RS485 communications channels to control their extruders. But RepRap doesn't need the four black RJ45 connectors and doesn't distribute power from the motherboard. For RepRap leave those connectors off (this is described below when we come to soldering).

Since RS485 only takes up 1 of the 4 pairs of wires in a Cat5e cable, for MakerBot we decided to use the rest of the pairs as power. This allows us to send something like 10 amps over the wire which is more than enough for most extruder needs. The extruder controller has an onboard voltage regulator to produce the 5v required for powering all the logic chips, as well as the optional servo motors. The H-bridges and MOSFETs are powered directly from this input voltage. The maximum allowable voltage is 18v to avoid overheating the 5v regulator.


Serial Header

Cache-3432255936 a433f16cd9.jpg
Name Color Function
1 Black GND
2 Brown CTS#
3 Red VCC
4 Orange TXD
5 Yellow RXD
6 Green RTS#

This is the serial communications header for programming and communicating with the board. It uses the same USB<->TTL header format as the Sanguino, Boarduino, or any of the other minimal Arduino clones. You can find out more information about the cable and where to get it on the Sanguino website. Its very easy to use.


I2C Headers

Cache-3431443259 567df0a510.jpg
PIN FUNCTION
1 VCC (5v)
2 GND (0v)
3 SDA
4 SCL

The extruder controller has left the I2C pins open for use as an I2C bus. This means you can use any number of really cool peripherals very easily! One idea is to use an I2C based LCD screen to print out information about the extruder for example.

The SDA and SCL pins even have built-in 4.7K pullup resistors to make configuration of the I2C bus hassle-free and automatic. The table below lists the pin-out of the header. The labeling in the v2.0 board is not too good, so pin 1 is towards the top of the board and in to the top and the right in the picture.


SD Card Slot

Cache-3431440243 4df0a8fc29.jpg

The RepRap motherboard can support SD cards up to 2GB. This means we'll be able to implement all sorts of awesome functionality like printing from card, full print job queueing, and many other awesome things that one can do with a 2GB non-volatile memory buffer. Get psyched.


ATX Power Supply Header

TODO: RETAKE

Cache-3432252360 96e73197f0.jpg

For RepRap you replace this header with a couple of power supply components. In RepRap the motherboard is powered by its USB connection and doesn't need the ATX Power Supply Header.

For MakerBot, the RepRap motherboard uses this ATX power supply header. This allow us to power the Motherboard directly and it gives us a little bit of control over the power supply itself. The ATX power supply provides a digital on/off switch that we have interfaced to the Motherboard. This allows us to turn the power supply itself on or off digitally. That gives the motherboard the power to simply and easily turn the entire system on or off in one fell swoop: extruders, stepper motors, everything. The power supply provides a standby 5V supply, so the Motherboard itself will still be powered even if the supply has been turned off.


Circuit Board

Cache-3408003241 82436e37bd.jpg

You can either buy this PCB from a supplier, or you can make your own. The image above shows the professionally manufactured PCB ready for soldering.

Components

Cache-3408810488 4c6e7ee6f3.jpg

<iframe src="http://parts.reprap.org/embed/module/RepRap+Motherboard+v1.2" width="620" height="920" frameborder="0">Visit http://parts.reprap.org/embed/module/RepRap+Motherboard+v1.2</iframe> BROKEN LINK 13 DEC 2013 (rrrf.org no longer exists)


Build Process

This board contains surface mount parts. Trust me when I tell you that it is really, really, really easy! The hardest part about SMT soldering is getting over your fear and staying calm. I've shown complete beginners how to do it, and they had no problems.

There are four parts to building a surface mount board using the Hotplate Reflow Technique:

  1. Apply solder paste to every exposed SMD pad
  2. Place each SMD component on its appropriate pad
  3. Place populated board on a cold hotplate. Turn hotplate on. Board solders itself!
  4. Solder in remaining through hole components.


1. Apply Solder Paste

Cache-3408001061 4116740ed3.jpg

Okay, so this part is pretty easy: get your solder paste syringe and start applying solder paste to every SMD pad. I like to use a squeeze/tap method. That is, I squeeze a bit of solder paste out, then tap the place where it goes, rinse and repeat for every exposed pad. Do not put solder paste on pads with holes in them. You'll solder those in step #4.


Cache-3407999941 3834cd1969.jpg

In order to get the right amount of solder paste on the pads for the small TQFP parts, use your finger to smear the paste like shown in this picture. It looks ugly, but you'll get much fewer solder bridges this way.


2. Place Components

Cache-3526986531 86a241bbfe.jpg

This is probably the trickiest part, but its not too bad once you get the hang of it. The nice thing is that if you mess up, you can reposition the component all day. You can even wipe off the solder paste and start over if you like. Very forgiving to the beginner. The individual components to place are shown below.

Its easiest with tweezers and some sort of magnification. A bit of patience and you'll get it no problem. Since nothing gets soldered yet, you can easily try and try again if you mess up.


R4, R5, R6, R11, R12 - 1.8K ohm resistor (182)

Cache-3407998543 d92a058975.jpg

This component can be placed in any orientation.


R1, R13, R14, R18 - 10K ohm resistor (1002)

Cache-3408805734 6013de56a9.jpg

This component can be placed in any orientation.


R2, R3 - 1K ohm resistor (1001)

Cache-3407996375 077563f1c0.jpg

This component can be placed in any orientation.


R7, R8, R9 - 3.3K ohm resistor (332)

Cache-3408803534 496a204ba8.jpg

This component can be placed in any orientation.


R10, R15 - 4.7K ohm resistor (472)

Cache-3407994305 7e03e24855.jpg

This component can be placed in any orientation.



C3, C5, C8 - 100nF ceramic capacitor

Cache-3408801464 49324682f2.jpg

These components can be placed in any orientation.



C1, C2 - 15pF ceramic capacitor

Cache-3408800432 4fe687b432.jpg

These components can be placed in any orientation.


Green and red LEDs

Cache-3407991167 c4cf1bf1c3.jpg

These components can not be placed in any orientation! The red and green LEDs must be oriented correctly. If you look very closely, you'll see that one end of each led has small green stripes along the edges. Position the LED so that these stripes are facing in the same direction as the white dot on the silkscreen. Zoom in on the picture to make sure you get them right!


IC1 - SN75176A

Cache-3407990227 5b2c1508e6.jpg

This is the RS485 communications chip. It must be placed in the proper orientation. Place the chip so that the line across one end of the chip matches up with the heavy line on the silkscreen. It should face the 'bottom' of the board.'


C6 - 10uF electrolytic capacitor

Cache-3408797452 508a855e03.jpg

This component must be placed in the correct orientation. The black stripe on the capacitor should match up with the stripe on the silkscreen. Check the illustration to make sure you've got it right.


SD Card Socket

Cache-3407988145 f5bf2e03a5.jpg

This one is really easy, and you can place it with your fingers even. If you look on the bottom of the SD card socket, you'll see two little nubs or 'bosses' that fit into corresponding holes on the PCB. When you line them up and place the SD card socket on the board, these will make sure that it goes in exactly the right spot. Nice.


IC2 - Atmega644P TQFP

Cache-3407987181 bb2bd48fdd.jpg

This is the microcontroller that is the heart of the Sanguino. Before you put down the chip, smear away the solder paste a little-- this helps reduce solder bridges. The small smooth circle on one corner of the chip lines up with the dot on the silkscreen. Check the picture above to ensure that you have the chip in the correct orientation. Make sure you get this right-- if you solder the chip in the wrong orientation, it will be almost impossible to desolder it!


R16 - 180 ohm resistor (181) - OPTIONAL

This component is optional, so I would suggest you leave it out. It is on the board in case you need it, and it's in the wiki for completeness. If you don't KNOW that you need it, leave it out. TIf you're asking yourself right now "Do I need this component?" the answer is no. This is a spot for a termination resistor on the RS485 bus and is generally not needed on most systems.


Hot Plate Reflow

Cache-3408792824 431db5ed5b.jpg

I prefer to start with the hotplate off. I burned a few boards one time by putting them on when it was already hot. Instead, carefully place the board on the cold hotplate, then turn the heat up to a low temperature. Wait a few minutes for things to get cooking, and you'll see the small components begin to 'pop' as the solder goes molten. Keep an eye out for components that stick together. If that happens, simply nudge them apart with tweezers or other non-finger device. Wait until you see the largest component leads go silver (usually the big capacitors). If it starts to smell really bad, kill the power and solder the rest by hand. Sometimes the capacitors wont fully solder, so just hit the exposed pad with a soldering iron after the fact.

Once they have soldered, simply turn the hotplate off and let it cool down.

For detailed instructions on how to do hotplate reflow soldering, please see the Hotplate Reflow Technique guide.


Clean up excess solder

Cache-3527796528 8e382ab633.jpg

If you use the smear technique to apply the right amount of paste to the tiny TQFP parts, then you'll end up with what looks like solder sand near the chip. This is actually really easy to clean up. Simply take your hot solder iron and run it over the tiny beads of solder. It will pick them right up and the board will be nice and clean. You may want to click through for a better view.


Check for bridges!

Its important to check for potential bridging. It helps to have a magnifying glass, and backlighting. Just give it a thorough look-over. If you find bridges, they're easy to remove: Simply put some solder wick over the bridge, apply a hot iron over it, wait for the solder to wick up into the solder wick, then remove both. Double check the bridge. 90% of the time, enough solder will remain on the pins for a reliable connection. You may need to add a tiny bit of solder paste back onto the pin and re-solder it, but usually not.

Check for Solder Balls

Cache-3527793088 9cd7ef7777.jpg

Sometimes if you use a bit too much solder, it will ball up and squeeze out the sides. These balls are fairly harmless, but you should definitely remove them with tweezers or even a small brush. Theres a chance that when they break free during use (and they will) that they will short something out, and you dont want that.


Solder Through Hole Components

16Mhz Crystal

Cache-3407982389 a22af04a3a.jpg

This can be inserted in any orientation. Make sure you trim the legs afterwards.


Reset Button

Cache-3407981345 6bf340d6e5.jpg

The button will snap into place. Solder it in and you're good.


ICSP Header

Cache-3407980099 97c5af9aa2.jpg

This is the ICSP header you'll need to burn the bootloader. Make sure you line up the notch with the notch on the silkscreen. It should be facing towards the inside of the board.


On/Off - SPDT Switch

Cache-3407978311 1234ec8d9d.jpg

This is the on/off switch. You can insert it in any orientation. Push it all the way in and then solder it into place.


X/Y/Z Stepper Headers + JTAG

Cache-3484375132 2826079235.jpg

These are the headers where you plug the stepper drivers into. Make sure the opening on the IDC header faces outward (and lines up with the silkscreen). Don't forget the JTAG connector in the Sanguino area of the board.


I2C - 4 pin female headers

Cache-3408785266 1981341499.jpg

These are the headers for the I2C bus. They can be soldered in in any direction. Its easiest if you solder one leg on each one to tack them into place. Get a good grip and then re-heat the joint and push on the component until it is perfectly situated. Then you'll want to solder the rest of the leads.


10 pin female headers

Cache-3407979247 36e2366b45.jpg

These headers give you direct access to the Sanguino pins should you need it. Pin headers do not come in 9-pin varieties, so you'll need to pull out one of the pins on a few of these to make them fit. This component is completely optional, but it doesn't hurt to solder it in.


6-pin serial header

Cache-3408784340 8d323f8605.jpg

This is the header for the serial connection. You'll need to break off a set of 6 pins from the strip of pin headers included with the kit. Solder it into place.


R17 - 30 ohm / 5W power resistor

Cache-3408783148 931c9d48ab.jpg

Leave this resistor off if you're building this board for RepRap.

This resistor is here basically to just suck power. Certain power supplies refuse to turn on unless there is a load on the 5V line. If you have one of those power supplies, then use the power resistor. Otherwise, feel free to leave it out. If you are not sure, then solder it in. It doesn't use much power in the grand scheme of things.


ATX Motherboard Header

Cache-3407974383 45848b98b1.jpg

Leave this header off if you're building this board for RepRap.

This is the header where you plug the ATX power supply into. There is a 'ramp' on one side with a corresponding rectangle on the silkscreen, and the part may also contain locking tabs that fit into the holes next to the silkscreen. Insert the part so that it lines up with these markings and then solder it into place.


RJ45 Connectors

Cache-3407973233 875e80732b.jpg

Leave these connectors off if you're building this board for RepRap.

This is not ethernet.

We're re-using these jacks to provide power and comms to the Extruder controller using RS485. They can only be inserted one way and they snap into place. So snap them in and then solder them all up.


RepRap configuration

Motherboard 1 2-motherboard-labelled-small.jpg

Put a link across two of the mounting holes where the ATX power connector would go for MakerBot (just to the right of C). Solder in a 3.3V regulator (78L33) and a 100uF smoothing capacitor at C. The flat on the regulator and the -ve wire on the capacitor are both towards the bottom of the picture. (These components are not included in the RepRap Parts Lister.)


Solder four 2.54mm 2-pin header connectors where the RJ45 connectors would go for MakerBot, as at D and to the left.

Make sure you have at least one connector for the SDA and SCL connectors at B. Also make sure that there is a jumper at A (this allows the board to be programmed correctly).


Motherboard 1 2-back-small.jpg

Then put a link on the back of the board as shown at A on the right between the third pin of the serial input (the red wire on the USB connector) and pin 2 of the ISP connector.

Your board can now be fully powered by the RepRap USB cable.


Burn the Bootloader

Cache-3431721845 4126f4a775.jpg

Before you start, make sure you have installed the Sanguino software modifications to Arduino.

The atmega644p chips come totally blank, so you'll need to upload the special program called a bootloader to the chip so that you can then easily program it with the Arduino software. In order to do this, you'll need an AVR programmer. I highly recommend the USBtinyISP from LadyAda. Its cheap, simple, and easy to assemble. It is also rock-solid. I've used it to program almost a thousand chips and it works great.

Before you start, make sure your motherboard is not hooked up to anything. In order to program the chip:

  • Plug the USBtinyISP into your computer's USB port
  • Plug the USBtinyISP into the RepRap Motherboard. The Green power LED should light at this time. If not then check to make sure that the jumper on the USBtinyISP is connected.
  • Open the Arduino software, make sure the 'Sanguino' option is selected in 'Boards', and then choose the menu option of "Tools -> Burn Bootloader -> w/ USBTinyISP".

Once you do that, you should get a red light on the USBtinyISP, indicating that the USBtinyISP is 'busy' programming, this should take about a minute. The red light on the motherboard will flash a few times indicating that the burn is complete. If everything is successful, then the Arduino software should tell you "Done burning bootloader".


Program It!

There really isn't much to test on the board that it can do itself, so the easiest way to test it is to program the production firmware and to try using it.

Sanguino Master Firmware

There are two alternatives here. One is standard for RepRap, and the other for MakerBot. However, both ought to work in either machine - they are so similar. But for the moment it's probably best to stick with the one intended for each.

Wire it Up!

History

Changelog

  • Moved power on/off switch to a better place
  • Added pulldown resistor to PS_ON pin
  • Various minor layout changes.
  • Wireing up split off to distinguish RepRap and CupCake.

Previous Versions

Index