Print Thread
500g (hopefully) fluidbed roaster
Hi !
After substituting thermometers I'd be pretty convinced the measured temps are accurate and
you've already had a glass chamber crack as a gap closes under expansion. Too, the beans start to jump around more at that stage suggesting there's less resistance to airflow from the beans proper.
If a jump in heating output can be eliminated, perhaps with the help of a low-wattage lamp across the heater's input, could the ET thermocouple be used as a 'sniffer' around the roast chamber to detect any hot air leaking during the roast ?
I have done some sciencing today and finally found the cause (and sollution). It?s probably no surprise, that allenb was right claiming, that it is probably real BT/ET rise caused by high heat and not an artifact. The fact that it was always happening at the same time confused me so much I started looking for some sophisticated reason and did not look into my first suspect - the faulty dimmer.
As I was roasting some navy beans today (BTW did you know that they roast very similar to Panama and even have sort of a First Crack? Grin ) I got a spike again at the 5 minute mark. But since I was roasting navy beans and not some expensive coffee and was in an experimenting mode I wanted to crank the heat up to max to see how fast the BT can really rise. So I did it and... nothing happened. So I dialed it all the way down and... nothing happened. The BT was still rising at the usuall rate.
At that moment it hit me. My controls are enclosed in a wooden cigar box with no real ventilation (I guess most of you already know the cause by now as well) so as the roast progressed, the dimmer got hotter and hotter until (around the 4-5 minute mark) it was like "F#!k this s#!t, I?m too hot and sick of regulating your heat." and it sent full power to the heater. And as I cooled the beans after the roast, it cooled as well and was ready for another 5 minutes of glory with the next batch.
So I tried to open the box today and cool it with a PC fan and... IT WORKED. Full control during the whole roast and no spikes. Now it?s ready for the TC4 PID control which I cannot get to work but that is story for another day Grin
Thanks all of you for the input and for pointing me in the right direction.
Another insignificant step for mankind but a huge leap for me - I have finally completed the control box for my roaster. If you ever wondered how small can you make a TC4 based control box with 2 SSRs and a ZCD here is your answer - I managed to fit it all in a aluminium enclosure with internal diameters 116x86x36mm and I don't think you could go any smaller. Even with this box I had to file the sides of both SSRs and the box to fit them next to each other.
Good thing is that the box is from alluminium so it also functions as a heatsink for the rellays (I mounted them directly to the box case with screws and thermal conductive paste. During roasts it all gets a bit warm but nothing excessive.
I get great PID driven background roasts with this setup - I just need to tune second set of PID parameters for the last stage of the roast. Regular parameters follow the background great but the BT dips with FC and never catches back with the SV. I have tried increasing the P value and using zero for D value and it seems to be a step in the right direction.
Last thing I strugle with is the Artisan software - I have the PID duty as a separate slider and would love to also plot it as a graph. Unfortunately I was not able to do this. Is this even possible?
I'm able to graph Duty Cycle and Setpoint in Artisan by:
Config-Device-Extra Device and selecting "ArduinoTC4_34" and marking them "SV" and "Duty" in label1, label2 fields.
which assumes you're able to get the software to send those data in the third and fourth fields sent from the TC4 to Artisan.
I'm not sure how to plot the slider's value directly , are you sending a Duty Cycle demand from the Artisan to TC4 rather than a desired setpoint temperature ?
Thanks, also, for the observation about Gain vs Bean Temp. I'd been thinking along the same lines and I think you're right: it takes a bigger duty cycle change for a 1 degree change at 200c than it does at 50c so the PID's gain should vary with temperature.
I added to my PID parameters a compensation factor that multiplies the nominal Proportional Gain by a factor that varies as the Bean Temp exceeds 50c ( my popper's idle temp because of the smaller heating coil).

Kp is my nominal proportional gain
Kappa is my compensation factor

Every second, the PID's 'P' gain is computed for a compensated gain, Kc
Kc is set to Kp x ( 1 + Kappa x ( BeanTemp - 50 ) / 50 ))
e.g if Kappa is 0.75 then at 150c the working gain is Kp x ( 1 + 0.75 x 2 ) or 2.5x nominal

Obviously, from the plot below, I need to tweak some numbers to eliminate the ringing at rate change and for the oscillation at higher temps but it's a very encouraging improvement over some of the results I'd been getting before.

Thanks for the motivation !

Edit 'ET' , below, is 'Expected Temp' not Environment temp; it's the instantaneous target temp during a controlled ROC
Edited by chaff on 08/31/2017 3:08 PM
Apologies, the above plot is in debug 'Virtual Thermocouple' mode so the bean temp is in reality nowhere near as smooth for me ( stirring the beans changes the sensed temp a lot ) .
Thanks for the tips. I am not 100% sure, but I THINK, that the way I have finally set it up is as follows - I am using Artisan?s PID and background roast profile. So Artisan takes the SV from the background profile, BT from the probe and based on PID parameters sets the "Duty" slider acordingly. The Duty slider is set to control the OT1 on TC4 which drives the heater SSR. I was using the PID in TC4 but I had to switch it up to be able to change PID parameters through events/alarms. I was not able to do that when using TC4 PID.
When I change the Duty slider manualy, it plots the change into the graph (the same way as the Fan slider). But if the changes are driven by the PID it doesn?t show in the graph even when the slider is moving.

Variable PID parameters seem interesting, but I think that 2 sets of parameters will be enough. The "normal" values are just fine until the FC. But as the RoR dips due to the gas release upon FC, the PID is unable to catch back up with the target profile. So I need to crank up the P value just for the last stage...
That makes sense, I hadn't tried using Artisan's PID.
I've seen the same as you, temp dropping at first crack, although the conventional wisdom seems to be the temp 'flicks' upward as mass is ejected in water vapour and the chemistry goes 'exothermic'. I can only guess the PID's output drops suddenly in response but then you'd still expect to see the temp rise; it would sure be good to monitor duty cycle at that point. I wonder if increasing 'D' term, which resists sudden moves, would help.
I not expert in TC4 firmware but it looks as if setting a compile flag and rebuilding does what you need (I'm looking at REL_aArtisanQ_PID_3_7):
In user.h line 72:
#define PLOT_POWER // send heater and fan power levels to Artisan instead of 3rd and 4th channels
change to
#define PLOT_POWER 1 // send heater and fan power levels to Artisan instead of 3rd and 4th channels

And rebuild for your Arduino

That change should cause the code at aArtisanQ.ino line 301 to push the OT1, OT2 values into the output channels sent to Artisan where you can use the TC4_34 setup mentioned above to plot them.
REL_aArtisanQ_PID_3_7 is out dated now. 6_2_3 is the latest version in the GitHub repository. The PLOT_POWER option does not exist in the more recent versions. Instead, the sketch will send the heater duty, fan duty and setpoint if the TC4 PID is active. This could easily be adjusted in the code to suit individual needs.

Also, the PID parameters in the TC4 sketches can changed on the fly. Just send the PID tuning command. It's largely untested though. The parameters should reset to the defaults when the TC4 is reset.


Sets new PID parameters ("T" is for "tuning"):
ppp = proportional coefficient Kp
iii = integral coefficient Ki
ddd = derivative coefficient Kd
@RedAce Very cool setup!

I would like to build one following your project. Do you mind to share with me the parts list, it would be great if you could provide amazon links.

Thank you so much and happy roasting!


lucapinello wrote:

@RedAce Very cool setup!

I would like to build one following your project. Do you mind to share with me the parts list, it would be great if you could provide amazon links.

Thank you so much and happy roasting!

I second the parts list!
Jump to Forum: