One of the oddities of the RepRap community is the heated bed circuitry on the very popular RAMPS controller. It's undersized for modern beds and this is known for years. Even a claim of a fix exists, but such fixes aren't recognized by cheapo-china, where everybody buys, so the undersized variants are found about everywhere.
Anyways. One of the solutions to work around this situation is to use a SevenSwitch to do the hard work. Here we show how to connect this switch to a RAMPS and how to tweak the popular firmwares to work with the new switch instead of the old one.
First step is to find an appropriate signal pin on the RAMPS. “Signal” means, a pin which can be switched between 0 V and 5 V by the firmware, preferably using PWM. A RAMPS has a whole lot of extension connectors, we choose the Servos one. This connector features 4 PWM-able signal pins as well as convenient GND pins.
Some vendors solder in pins there already, others don't. If there are none, you have to do this yourself. Standard 0.1“ spaced pins are fine. Another option is to solder the signal wire directly into the board.
There are 4 signal pins available for interfacing in the servo section: D4, D5, D6 and D11. Each of them works equally well. Connecting more than one SevenSwitch is possible, too.
The above picture shows how things get together:
One obvious task left is to tell the firmware which pin to use to switch the heated bed. How to do this depends a bit on the used firmware.
There are several pin naming schemes in use. This table shows different names for the same pin. Teacup Firmware allows two names, each of them works equally well:
Launch Configtool, go to the board panel, then to the heater panel, then mark the line for the bed and click on Modify. Select the new pin, click on Save, build and upload the firmware.
For the actual code, depending on which version of RAMPS you have there will be a pins.h
, or pins_ramps_13.h
if you have the Makerfarm Pegasus, file that has a few lines that will need to be changed. There should be between 1 and 2 lines that have a value that need to be changed. Typically the line will be:
#define HEATER_BED_PIN 8 // BED
We will use pin D4 for the new SevenSwitch. This will need to be changed to:
#define HEATER_BED_PIN 4 // BED
Or whatever pin you decide to use. Once this is done, from within the Arduino software, go to the corresponding pins file and confirm the changes. After that you can upload the firmware and proceed to testing.
Some people tend to try connecting a SevenSwitch a different way. Let's elaborate on this.
Using D8 is a possible, but poor choice for several reasons: