April 24 2017 08:09:54


Not a member yet?
Click here to register.

Forgotten your password?
Request a new one here.
bullet2.gif Active Forums
bullet2.gif FORUM INDEX
bullet2.gif Downloads
bullet2.gif News
bullet2.gif Forum FAQ
bullet2.gif Contact Me
bullet2.gif Photo Gallery
bullet2.gif Search
bullet2.gif User's Voice
Forum Threads
Newest Threads
bullet2.gif i need your help! (s...
bullet2.gif Hello from DFW Texas
bullet2.gif Ready to rock and ro...
bullet2.gif Lets talk Halogen he...
bullet2.gif Rocquette Roaster Build
Hottest Threads
bullet2.gif TC4 with aArtisan... [217]
bullet2.gif PETS also part of... [70]
bullet2.gif My Experience wit... [44]
bullet2.gif Rocquette Roaster... [32]
bullet2.gif Cant get Artisan ... [27]
Donate to HRO
Please enter your site username (if you have one) and your email address (required) to be sent with this donation for tracking and contact purposes.

Site Username
If you don't have a site username, just enter "Guest"

eMail Address **REQUIRED**

Users Online
bullet2.gif Guests Online: 2

bullet2.gif Members Online: 0

bullet2.gif Total Members: 4,885
bullet2.gif Newest Member: Chip
BotSlap Panel
bullet2.gif Last check: 04/24/2017 07:43
bullet2.gif Slap count: 0
bullet2.gif Last checked ID: 5904
View Thread » DATALOGGERS - CONTROLLERS - RATE OF RISE METERS » Dataloggers/Controllers/Rate of Rise Meters
Who is here? 1 guest(s)
 Print Thread
TC4 with aArtisanQ_PID
Hi All,

This post is to help clarify what my aArtisanQ_PID code does and how it differs from the standard aArtisan code.

Like the base aArtisan code, aArtisanQ_PID supports the Artisan Visual Scope application for logging and control of a coffee roaster.

Here's a few points I put together some time ago when I was documenting the differences between the starndard aArtisan code and my aArtisanQ_PID code. There may be further differences but this should cover the major ones.

aArtisanQ_PID is a variation of aArtisan and has these additional features:

- Integral Cycle Control on OT1 (requires zero cross detector connected to IO3)
- Phase angle control on OT2 (requires zero cross detector connected to IO3)
- Analogue control of OT1 and OT2 (optional)
- Support for 4x20 LCDs
- Support for logging OT1 and OT2 power levels in Artisan
- Rate of Rise displayed on LCD
- PID control on OT1 (optional) including multiple roast profile storage on EEPROM and PID parameters adjustable on the fly
- Support for pBourbon Processing software

Currently (this may eventually change) I have my roast profiles stored on my laptop in a seperate Arduino sketch. When I want to change or add a profile I upload the sketch to the Arduino. The arduino will run the sketch and store the new profiles in the TC4 EEPROM. Once they are stored in the TC4 EEPROM I have to upload the aArtisanQ_PID code to the Arduino again.

The above profile loading only needs to be done if you are adding or updating profiles. Once they are in the EEPROM my aArduino code lets you select a profile using the optional TC4 buttons or by sending a serial command from Artisan. Otherwise it will use the first profile stored in the EEPROM which may be fine for some users.

I'll continue to update this thead if further developments are made.
Wow, you've put some major time and effort into this upgrade of Artisan! I didn't know you had added this many features to it.

So, before the work you did, there was no profile storing and running in any of the Artisan versions?

Also, can the TC4 with aArtisanQ_PID roast coffee via PID and run profiles without being connected to your computer?

Thanks for posting this update. greenman

1/2 lb and 1 lb drum, Siemens Sirocco fluidbed, presspot, chemex, cajun biggin brewer from the backwoods of Louisiana
Greencardigan wrote in a different thread:

"My current setup is doing phase angle control of my blower rather than the heater. But it is definitely possible to control the heater elements using phase angle control with my current set up. I'm just not sure if I could control both the heater and blower with phase control simultaneously. "

Being able to have the option of running the heat via phase angle control or regular duty cycling would be a nice feature.

I'm assuming this would require some additional code writing.

Edited by allenb on 05/30/2013 21:38
1/2 lb and 1 lb drum, Siemens Sirocco fluidbed, presspot, chemex, cajun biggin brewer from the backwoods of Louisiana
So, before the work you did, there was no profile storing and running in any of the Artisan versions?

That is correct. None of the other versions of aArtisan currently support PID control and profiles. And it should be noted that Jim did all the phase angle control code. I just borrowed the best bits from all his other versions and added the PID and profile code. I have also expanded Jim's serial command set to allow better integration with Artisan.

The only other code for the TC4 that supported profiles is Kona which was written from the scratch. I have tried hard to keep aArtisanQ_PID based on aArtisan. When Jim does updates to aArtisan I try to bring those changes across to mine.

I hope someday that my changes can be incorporated back into the base aArtisan code so there is the option for PID control and profiles without the phase angle control and associated zero-cross circuitry for those who don't want to go down that path.

Also, can the TC4 with aArtisanQ_PID roast coffee via PID and run profiles without being connected to your computer?

Yes, a computer connection is not necessary. There are currently 3 options.

1. Computer running Artisan or other software that can send serial data to the TC4.

2. An LCD using the LCDapter and the input buttons. I can use the buttons to activate the PID, select profiles etc.

3. A smart phone (Android) with a bluetooth connection. This is how I am currently roasting.

I have started developing an Android application that allows me to control my roaster from my phone and I hope to start a new thread about this sometime. I just need to sort out an issue with the data being recieved back from the TC4.

Being able to have the option of running the heat via phase angle control or regular duty cycling would be a nice feature.

I'm assuming this would require some additional code writing.

I think I kind of covered this above. It will either require either rolling my changes back into aArtisan or combining the two and letting the user specify what control method to use when uploading to the Arduino.
Edited by greencardigan on 05/30/2013 21:57
Also it would be good to hear from Jim as to whether we can have both outputs running with phase control simultaneously.
I have updated my code to include support for Roastlogger.

The Roastlogger mode isn't active by default but will become activated when it receives the LOAD command from Roastlogger. Otherwise the code can be tweaked to make it start in Roastlogger mode each time.

See the first post in the thread for other features.
I've been doing tons of searching and reading the past few days trying to understand the PID function in conjunction with Artisan. I'm waiting for all my parts to arrive before I can tinker and figure it out myself so I figured I'd just ask.

It seems that the PID function is completely separate from Artisan program if I understand correctly? I just can't seem to find any documentation or guides on how the temperature set point is actually set. I remember reading something about it coming from an EEPROM value?

So, how do I go about setting it? Also, I would like to avoid a physical button enabling the PID control. Is there anyway to set the button in Artisan over serial? With that thought in mind, is it possible to create a button/s that increases and decreases the PID set point?

Thanks for any help or guidance!
Yes, the PID functionality is built into the Arduino code.

The roast profiles (times and setpoints) are stored on the TC4's EEPROM. There is a small Arduino sketch (called Profile_Loader) included with my aArtisanQ_PID package that you load onto the Arduino. This little sketch will load a profile onto the EEPROM. Then the aArtisanQ_PID sketch is reloaded and can use the profile stored on the EEPROM. This is probably not the most elegant way to load a profile onto the TC4 but that's all I've implemented at this stage.

You can set up a button in Artisan to turn the PID on and off over the serial connection. You need to send one of the PID commands. The PID set of commands includes:
PID;ON - Turns PID on
PID;OFF - Turns PID off
PID;GO - Resets TC4 Timer and turns PID on
PID;STOP - Turns PID off, turns OT1 off and sets OT2 to auto cool level
PID;Px - Selects profile x
PID;T;p;i;d - Sets PID parameters p, i and d. This command needs a slight adjustment to the standard TC4 library.

At this stage the setpoint can't be adjusted from Artisan. I had discussions with the Artisan team some time ago about this but it was not implemented.

As I mentioned in a previous post, my code is now compatible with Roastlogger which can do it's own PID calculation and send a calculated heater output to the TC4.
Thanks for all the useful information! I knew I had to be missing something obvious and sure enough, I was. I wish Artisan would focus a bit more on the control side of things seeing as the datalogging is practically perfect IMO.
Did anyone get the 'PID' does not name a type error when they went to compile this code?
Is there a library for aArtisan_PID that I forgot to include?
You do need to have the PID_V1 library in with the other TC4 libraries.
Have there been any known issues with receiving serial prints? For example, I can send READ and get the values back in the serial monitor. When I send UNITS;F I don't get a response like the sketch indicates I should but when I send READ I can see that it did actually change the units.

Am I once again missing something obvious or do I not have something setup correctly?
In user.h, ACKS_ON is undefined by default. If you want to change the default behavior and receive responses to commands, uncomment the line in user.h to enable ACKS_ON.


PS - Brad: fantastic work on this code!! Please add the appropriate attributions in the code so people won't mistakenly expect similar quality from me in the future ;-)
Thank you. I feel like such an idiot! I think I've been spending too much time reading up on this stuff that I've been forgetting my coffee intake...
I seem to recall that I could not get the ACKS_ON code to work. I think it was causing my code to lock up or something but I never tried to debug.

Welcome back Jim!
Yeah, I tried with the ACKS_ON and the Arduino was completely unresponsive. So I tried commenting out all the #ifdef ACKS_ON and corresponding #endif's while leaving ACKS off and it still was unresponsive.
Try leaving ACKS OFF and only comment out the #ifdef ACKS_ON for the ones you need.
That's what I tried, it kept freezing up though. Not a big deal at the moment but I'll probably continue to play with it when I get the larger aspects taken care of.
I'll try to look into it if I get a chance.
Jump to Forum:
Similar Threads
Thread Forum Replies Last Post
TC4 aArtisanQ_PID or Standard Library Dataloggers/Controllers/Rate of Rise Meters 45 01/24/2016 11:17
aArtisanQ_PID 5,3 with TC4 display problem Dataloggers/Controllers/Rate of Rise Meters 14 01/23/2016 10:15
AartisanQ_PID 5.3 with TC4 and RoastLogger Dataloggers/Controllers/Rate of Rise Meters 6 12/14/2015 09:52
Member Poll
How much coffee do you drink on an average day; including espresso?

1 or 2 cups

3 or 4

5 or 6

6 or more

You must login to vote.
You must login to post a message.

04/23/2017 09:02
Welcome Chip welcome cup

04/22/2017 15:25
welcome2 Swiftflow

04/21/2017 13:16
Welcome Alec Logan

04/19/2017 15:11
yihsin Welcome

04/18/2017 13:46
Welcome TumiDonserenos

04/17/2017 15:28
Flavours Place beach

04/16/2017 03:05
welcome2 mariuscoffee

04/15/2017 04:28
Welcome ComputerElbow pouring

04/14/2017 00:49
Welcome Graeme Lindsay

04/11/2017 17:02
samdari welcome2

04/11/2017 17:00
onozcoffee welcome cup

04/10/2017 17:29
mick_in_oz Welcome

04/10/2017 17:28
Johnh Welcome

04/08/2017 16:01
welcome2 danielsyl

04/05/2017 17:16
keraputih Welcome