Category Archives: Projects

Development of new hardware or software

Bean Mass Probe V2 – Basic Configuration

Some time ago I developed a bean mass probe for the Gene Cafe coffee roaster.  If you are familiar with  this roaster, you will know that adding a bean mass probe is a little tricky because of the way the drum rotates.  Basically, to make this work, you have to have a wireless temperature transmitter to get the data off the rotating drum and, additionally, you have to deal with the fact that the beans will not always be in contact with the thermocouple.

My first attempt at this worked pretty well using an Adafruit ProTrinket coupled with a Bluetooth board.  Recently, I developed the second generation of the bean mass probe using an ESP8266 micro controller (Adafruit Huzzah) that allows me to connect directly to the roaster using WiFi and MQTT.  With this I have now created a pretty slick Internet of Things Bean Mass Probe.

I’ve actually converted the entire RoastGenie system to IoT technology but that is a topic for another post.

The basic architecture of the system is shown in the figure below.  I host my own MQTT server (Mosquitto)  but I think you could easily use Adafruit IO as your MQTT broker.  I’ve not worked with this system but it looks like it has some nice features.   If you use Adafruit IO, I think you could access you live bean mass temperature data with a web browser instead of a traditional MQTT client (I use MQTT Spy). The real utility of having the bean mass probe use the MQTT protocol is that you can easily integrate the data into other systems (like the RoastGenie itself).

Architecture

The bean mass probe consists of the following components: Adafruit Huzzah micro controller, MAX18255 thermocouple amplifier, and a LiPo battery.  The schematic is below.

schematic

Note: A previous version of this schematic I posted had an error (the power lead to the thermocouple amplifier was shown incorrectly connected to 3Vo instead of Vin)

These components are attached to the Gene Cafe on the rotating plate on the inlet side of the roaster.  The connection between the drum and the TC amplifier is done using mini K thermocouple connectors from Omega engineering to facilitate easy removal of the roasting drum.  The LiPo battery is attached to the roaster with a pair of Neodymium magnets so it is very easy to remove and recharge.

IMG_1157

The thermocouple is installed in the drum as shown in this post.  This system works like a charm and is very tolerant to disruption in connections – unlike the Bluetooth version which would typically not reconnect if there was some problem (like a discharged battery).  I will try to get some additional details posted about software over the next several days — in the meantime, let me know if you have any questions.

A new control panel for the Roast Genie

The Roast Genie is on about the 5th generation of hardware.  After trying several different approaches to get a nice looking panel, I came up with this method using adhesive vinyl used for signs.

IMG_0589

Details on how I did this are posted here.  I really have not seen many good ways to mount LCDs that covers up the ugly metal frame around the LCD.  I found some 3D printed bezels but nothing commercially available.  I was pleased with the result.

More Bean Mass Probe Progress

I tidied up the bean mass probe software a bit.  The probe still measures temperature twice per second but only sends it to the Raspberry Pi when requested.

I added some code that will identify local minimum and local maximum temperatures.  The local minimum temperature corresponds to the point in the drum rotation where the bean mass thermocouple is buried in the beans.  I also fixed the temperature synchronization problem.

This Guatemala roast shows a once-per second reading of the bean mass probe — lots of fluctuations due to drum rotation.

201410259

The chart below is the same roast but only plotting the local minimum temperature from the bean mass probe.  Works like a charm.

201410259 (2)

Check this out — according to Sweet Maria’s information on “Using Sight to Determine Degree of Roast”, first crack should start at about 9:20 at a temperature of 401F.   First crack in this roast started at 13:19 at a temperature of 401F.  I think that this is a pretty good sign for the bean mass probe.  The current roast profile I am using controls outlet temp at 510F — I could increase this and achive a faster roast.  Might be worth a try to see if I can match the 9:20 target.

More Bean Mass Probe Experiments – Guatemala Acatenango Gesha

This is the first complete roast profile with the new bean mass probe.  This is 150 g (green) roasted to the beginning of first crack. As for the coffee – the intent here is to get a little darker roast on this bean.  The last batch I roasted stopped between 1st and 2nd crack and was a bit underwhelming.

201410198

 

The bean mass temp is in the light blue.  Directionally this measurement looks OK but there is some strange behavior:

  • The first several readings after the roast started did not rise at all (~71F)  this starting point is about right but the temps should have started to climb quickly.  After touching the TC amplifier board, it started functioning more-or-less as expected.
  • Something similar happened at the end of the roast where the thermocouple appears to be “stuck” continuing to climb after the heater has been turned off.  Again, after touching the amplifier board, it jumped down significantly — but I am not sure the reading is correct. It does appear to be moving in the right direction again.
  • The plot below shows something really weird — the outlet temp and bean mass probes have different periods.  Because the drum rotates, I expect the periodic temperature excursions- I just can’t explain why the periods are different (and not a multiple).  The period of the drum is about 9s.  The period of the bean mass temperatures is about 15s.  The period of the outlet temps is about 9s.  Definitely something going on with the bean mass probe…

Periodicity

This probably has something to do with the way I am capturing temperatures.  Currently the bean mass probe and the other temp probes are not synchronized.  I have the bean mass probe spitting out a temperature every 1/2 second. The Arduino in the Roast Genie triggers a sample of the other probes once per second and triggers the Raspberry Pi to read the serial port from the bean mass probe.  Instead of throwing away the extra data it is queuing up in the serial buffer — this is likely the problem…  Have to make another go of this.

 

Gene Cafe Bean Mass Probe

I just tested out the bean mass probe proof-of-concept on my hacked Gene Cafe.  It worked even better than I had expected.  The probe itself is a bare type-K thermocouple that I inserted through a small hole I drilled near the inlet of the roast chamber.

IMG_0542

 

The thermocouple is positioned to keep it out of the airflow and to maximize the time it spends buried in the bean mass.

I am using a MAX31855 thermocouple amplifier on an Adafruit breakout board. This is attached to the roast chamber itself.

IMG_0535

I attached a chunk of perf board on the rotating plate that the drum snaps into using some stand-offs to help keep it cool during the roast.  On this perf board is a Pro-Trinket, a Bluefruit EZ-Link, and a lithium-polymer battery.  This was extremely easy to get working.

IMG_0538

This interfaces with my laptop to display the temperature once per second.  The sketch I am using right now is the example code “serialthermocouple” that is in the MAX31855 library.

IMG_0540

Forgive the mixed units here… it works!  The temperatures in the chart below are taken at somewhat random intervals during a roast.  I recorded the lowest temperature for both outlet and bean mass during the drum rotation.  You can see a significant difference between the temps.  Note that the outlet temperature was being controlled at 510F.  Once the outlet reached this temperature, it stopped climbing but the bean mass temperature continues to rise.

Chart

Lots of work to do here to get the bean mass probe temperature readings integrated into the Roast Genie but I am very pleased with the results.  This should provide a fantastic opportunity to get a better window into the roast.

Some additional thoughts:

  • The li-po battery is not contacting any hot surfaces but the radiant heat load is significant.  I am guessing it gets up to 140F +.  Some shielding may help keep this cooler.
  • The thermocouple amplifier gets warm since it is directly mounted to the roasting chamber (using Sugru).  It has cold junction compensation but any temperature difference between the amplifier chip and the connection point for the thermocouple will create errors.  This may not be very significant but future versions should be designed to avoid this.
  • Because of the way the beans move around in the roast chamber, sometimes the thermocouple is buried in the bean mass and sometimes it is exposed.  During heating, the lowest temperature read during a cycle is closest to the bean temp.  The thermocouple responds very quickly so I don’t think that this will be a big problem.  I will probably set up the software to compensate for this.