Meet roastCoffee, my automatic coffee roaster project. It is based on the FreshRoast SR500. I did get some tasty roasts out of it originally, but I couldn't help but think: I could totally improve this.
(NOTE: Do NOT play around with mains AC power if you do not know what you are doing!)
I replaced the original control PCB with one powered by an AVR microcontroller development board, mainly because of they are super easy to come by and easy to tinker with. A 1.3 inch OLED display adds nice potential for the user interface, and a set of satisfyingly clicky buttons add to the experience.
After hours of measuring, 3D modeling, and 3D printing, I had a drop-in control panel that fits right where the original went.
I also replaced the original TRIAC circuit with an off-the-shelf dual TRIAC module for precise control of the fan and heater. This now sits on the back with a big heatsink for power dissipation according to specification of the module's TRIACs. It only gets warm.
In conjunction with the TRIAC module, I used a pair of thermocouple modules for two bean probes in the chamber, using the average of the two for feedback control (or falling back to a single probe if one were to fail at any point during roasting).
To run the machine, I wrote drivers for reading the temperature from the thermocouple chips and controlling the TRIACs in a phase-delay configuration (this corresponded with the non-zero-cross output couplers that came with the module. However, zero-cross output couplers for integral cycle control are a better choice for their reduced impact on EMC and should still provide precise-enough control. I would want to swap the output couplers for future versions). For the control system, I implemented a discrete-time optimized PID controller. I opted to use the nifty U8g2 library for driving the display.
The attached video is of the first roasting before I had completed the enclosure. As for the temperature curve for the roast, I am following the advice presented by Scott Rao in his coffee roasting book. The resulting roast ended up slightly under-developed, but otherwise pretty tasty! It was a very peanut-y bean grown in Honduras.
I really enjoyed working on this, but now that I have the beautiful Kaffelogic Nano 7, I can focus on improving my roasting skills and move on to other fun projects. You can still check out the code here: https://github.com/vjapolitzer/roastCoffee