This isn’t a post that lends itself well to pictures.
A lot of what the BeerMKR does during the brewing process is to just hold a temperature.
My concept for replacing the board on the BeerMKR is to use Open Source 3D printing software, “Marlin”, to do the maintenance on the heaters, coolers, and temperature monitoring. Something else will have to know the recipe and when to switch temperatures.
The RepRap project, which is about self replicating machines, came up with a set of specifications to turn an inexpensive single board computer into the smarts inside a 3d printer. The board the itself, the “Mega”, was from another project called Arduino. The interface board they came up with is called RAMPS for “RepRap Arduino Mega Pololu Shield”. Shield means that it plugs right into the top of the Mega board and that the board itself has pluging for more shields, the Pololu stepper motor driver.
That’s all for 3D printing. The software doesn’t actually know if there is a board sitting on top of the Arduino Mega or if it’s really configured for 3D printing. But the software does have hooks for heating, cooling, fans, temperature measurement and some other odds and ends that look a lot like our BeerMKR.
I picked up a new Arduino Mega 2560 R3 (clone) at Microcenter for $20. I downloaded the Arduino Integrated Development Environment (IDE). I had actually done this already. While I was waiting for some of the connectors I had identified to be delivered I hooked up the pressure sensor to and older and smaller Arduino Uno that I had in a drawer for probably 10 years. I was able to use the IDE to write a small bit of code to read out the pressure sensor that’s hooked to the snorkel on our BeerMKR. I was surprised when I identified the chip and read it out that it also will tell me ambient temperature. I can get a pressure number, but I don’t know the scale of the number. It obviously isn’t going to be very high so I’m going to have to see if I can peek at it with a brew running to see what values the BeerMKR triggers on to open the vent solenoid. I don’t have to know the exact settings, just the approximate range that it takes action.
After having the Uno operable, I downloaded the Marlin software. I started to look at how to configure it and started taking out things like extruders and movement axes that I don’t have. Well, that was a mistake. I got a bunch of compile errors so I put them back in. I don’t think it’s going to hurt anything since nothing will be hooked up to those stepper motor interfaces (at least at this time I’m not expecting it).
Marlin has a pretty good configuration file (well, set of files) that pretty much lets you describe your machine and it sorts the code out for you. It does have an option for # of extruders =0 so you would think that would work, but I don’t need to fight it.
I previously measured the resistance of the BeerMKR temperature sensor at around 10k. When I looked at the Marlin documentation this was considered a very non-standard value. That sort of makes sense since these are “Negative Temperature Coefficient” thermistors, meaning the resistance goes down as the temperature goes up. 3D printers work with a lot higher temperatures than our BeerMKR goes. A thermistor for a 3D printer probably doesn’t track down to 40F that well.
Today I got into the specifics of how Marlin read the thermistor and set up the values and found the pins. For my test I just used a 4.7k resistor pulling up to 5 volts with a 10uF capacitor for a little filtering. I did have to re-build my cable that the BeerMKR temperature sensor plugs into because I used a wire that was too big to go into one of those prototype boards. I connected 5v, ground and pin 13 (Analog) from the Arduino to the appropriate spots on my little prototype divider.
I set up the thermistor as a type “4” which meant it was a 10K thermistor with a 4.7K pullup. I also set the bed thermistor to a type 998 (dummy) that always reports 25C so I wouldn’t get a safety shutdown. I compiled and loaded. After it started I ran a “M155 S10” command which means to report temperatures and do it every 10 seconds.
Amazingly, I got back a very plausible 21.29C which translates to about 70F. The thermometer on my clock says 69 but who knows how accurate that is. I had a bag or room temperature water sitting on the sensor with the squeeze bar in. Then I used my fingers on the temperature sensor for about a minute. The temperature reported went up to 25 and some change so those are plausible numbers. I don’t know how much calibration I will need to do.
I think I’m going to add another temperature sensor, this time a kitchen thermometer probe. If I’m going to have to control heat separately I want something food safe I can put up in the grain basket during mashing.
Anyway, this is two or three steps accomplished towards a board replacement. I got marlin running on the Mega and I’m able to configure and read the BeerMKR temperature sensor from within the Marlin firmware using out-of-the-box commands.
Leave a Reply