Our Valued Sponsor
OpinionsConsumer ReviewsGuides and How TosCoffeeGeek ReviewsResourcesForums
Espresso: Espresso Mods and Restorations
New Silvia Project - what would you add?
Cafe Espresso Machines
Video reviews, nationwide installation, leasing options... Nuova Simonelli, Rancilio, La Marzocco.
www.seattlecoffeegear.com
 
Not Logged in: Log In to Postlog in
New Topics updated topics   New Posts new posts   Unanswered Posts new unanswered  
Search Discussion Board search   Discussion Board FAQ faq   Signup sign up  
Discussions > Espresso > Espresso Mods > New Silvia...  
view previous topic | view next topic | view all topics
showing page 2 of 7 first page | last page previous page | next page
Author Messages
philipmc
Senior Member


Joined: 4 Oct 2011
Posts: 32
Location: Singapore
Expertise: I love coffee

Espresso: Silvia
Grinder: Rocky
Posted Mon Jan 2, 2012, 12:03am
Subject: Re: New Silvia Project - what would you add?
 

Thanks for the link, I'll have a read and digest it. It's starting to come together, but I've not quite hit the eurika yet. I guess the input to measurement lag is what makes the control loop tricky. Would a PID be needed if there was no delay? I guess not!

I looked at this youtube video for some timings to get a feel for the temperature. The timings are approximately:
  • 39s - thermostat triggers at 85C, turning on the element
  • 78s - thermostat cuts at 102C, turning off the element
  • 120s - temperature peaks at 107.7C

So accurate measurement of the final state is not possible until 42s after heating has stopped. Would I be correct in reasoning that this delay depends on the temperature differential being targeted? So a small heating duration would take longer to be detected (as the temperature differentials between components are lower, reducing the speed of transfer)?

What about for startup where we are initially at steady state? A linear approach should work, right? However I guess that is of really limited use, given that a user could turn a machine off and on, thus killing the steady state!

A quick pic is attached for anyone following this thread, they say a picture tells a thousand words!

philipmc: Duty Cycle.jpg
(Click for larger image)
back to top
 View Profile Link to this post
DNAofCoffee
Senior Member
DNAofCoffee
Joined: 10 Jan 2011
Posts: 66
Location: San Francisco, CA
Expertise: Just starting

Espresso: Rancilio Silvia
Grinder: Baratza Vario
Roaster: Behmor 1600
Posted Mon Jan 2, 2012, 2:19am
Subject: Re: New Silvia Project - what would you add?
 

Philip, First of all you are a fearless bad ass, but from your pictures (which explain your idea perfectly), it looks like there is a very small amount of potential time savings in return for the time invested in setting up and testing the algorithm and control function vs. just going with straight PID.  Have you considered playing with the PID values to optimize/minimize time to required boiler temp stability? Btw, I'm currently playing with some Phidget sensors and control boards (similar concept to Arduino) and might consider following in your wake depending on what happens.  Cheers.

 
Michael Silberg
San Francisco, CA
back to top
 View Profile Link to this post
JGG
Senior Member
JGG
Joined: 31 Mar 2006
Posts: 1,385
Location: Kentucky, US
Expertise: I like coffee

Espresso: PID Silvia; PID Alexia
Grinder: Mazzer SJ
Roaster: Hottop D w/HTC+TC4C
Posted Mon Jan 2, 2012, 4:47am
Subject: Re: New Silvia Project - what would you add?
 

A few observations and comments:
  • PID, as an algorithm, is pretty easy to implement, even on a micro controller.  I don't think you will reduce code size or complexity much by using a lookup table instead.
  • Neither overshoot nor a slow approach to set point is important on the initial warm up of the machine.  It won't be fully warmed up anyway for the first 45 minutes, so whether it takes 10 minutes or 6 minutes or 15 minutes to initially steady out at the set point doesn't really matter much.
  • Steady state control, i.e. while the machine is at idle, is a piece of cake.  My advice would be to not dwell on that part of the problem.  Instead, focus on the 2 to 3 minute period following a shot where all of the state variables are messed up and unpredictable.
  • Be sure to not overlook the fact that your algorithm will need to eventually resolve to a sorta constant duty cycle of around 7% while idling at set point.  My measurements show that somewhere around 60W is needed to keep up with heat losses.  In PID, the "I" contribution takes care of this (since both the P and D terms will be zero at steady state).

Jim
back to top
 View Profile Visit website Link to this post
philipmc
Senior Member


Joined: 4 Oct 2011
Posts: 32
Location: Singapore
Expertise: I love coffee

Espresso: Silvia
Grinder: Rocky
Posted Mon Jan 2, 2012, 5:04am
Subject: Re: New Silvia Project - what would you add?
 

DNA - just out of curiosity, why Phidget? I've only had  quick look, but it looks pricey and less well supported compared with Arduino. I'm sure it could work of course!

Jim - thank you - very valuable observations, especially around the machine warm up! =)

Do the parameters for the PID remain the same for different set points (shot vs steam)?

Someone has kindly written an arduino PID library! I'm sure I'll extend it a bit (debugging/tuning/datalogging for a start), but looks excellent for getting it off the mark.
back to top
 View Profile Link to this post
JGG
Senior Member
JGG
Joined: 31 Mar 2006
Posts: 1,385
Location: Kentucky, US
Expertise: I like coffee

Espresso: PID Silvia; PID Alexia
Grinder: Mazzer SJ
Roaster: Hottop D w/HTC+TC4C
Posted Mon Jan 2, 2012, 7:21am
Subject: Re: New Silvia Project - what would you add?
 

philipmc Said:

Do the parameters for the PID remain the same for different set points (shot vs steam)?

Posted January 2, 2012 link

I prefer to use ON/OFF control at the steam setpoint (same as PID with infinite proportional gain).

philipmc Said:

Someone has kindly written an arduino PID library! I'm sure I'll extend it a bit (debugging/tuning/datalogging for a start), but looks excellent for getting it off the mark.

Posted January 2, 2012 link

In addition, there is also an open source 4-channel thermocouple shield (hardware and software) that I and many others worked on for coffee roasters. This shield, and its Arduino-compatible controller cousin, also work well for espresso machine control.
http://code.google.com/p/tc4-shield/

Jim
back to top
 View Profile Visit website Link to this post
rsinger
Senior Member
rsinger
Joined: 25 Jan 2008
Posts: 188
Location: Boca Raton, Florida
Expertise: I like coffee

Espresso: Bezzera Strega
Grinder: OE Pharos - #136!!  ;)
Posted Mon Jan 2, 2012, 7:56am
Subject: Re: New Silvia Project - what would you add?
 

Philip:

The time / temp response curve that I posted is a real-time recording of a shot and recovery curve on an actual Silvia using an Arduino run PID algorithm (with tunable P,I,D parameters) that I used, and have the code for if you need it.

Just let me know.

Best,

Rick

 
New Bezzera Strega
OE Pharos: #136!!
Silvia's a virgin.....  again! (and sold)
Brasilia Cappuccino Del-1 Hx (sold too)
http://www.flickr.com/photos/66189160@N04/sets/72157628015297112/show/
http://espressoproject.blogspot.com/2008_10_01_archive.html
back to top
 View Profile Visit website Link to this post
philipmc
Senior Member


Joined: 4 Oct 2011
Posts: 32
Location: Singapore
Expertise: I love coffee

Espresso: Silvia
Grinder: Rocky
Posted Wed Jan 4, 2012, 7:13am
Subject: Re: New Silvia Project - what would you add?
 

Jim,
Thanks! That's a beautiful design. Everything I have been looking at uses a MAX6675 or similar to do the cold junction measurement on chip. This works out quite expensive (around $70 for a 4 thermocouple design). Using the MCP9800 for reference against a MCP3424 is a very elegant way to do this for a fraction of the cost. Out of curiosity, do you know what the digital resolution and accuracy are? Does thermocouple type play a significant role in accuracy?

Rick,
I'm still waiting on some components (and now the tc4 shield), but would love to have a look at your code. I had a look on CoffeeTronics, but your link there is out of service.

Thanks again everyone, I'm thoroughly enjoying this as a new hobby!
back to top
 View Profile Link to this post
JGG
Senior Member
JGG
Joined: 31 Mar 2006
Posts: 1,385
Location: Kentucky, US
Expertise: I like coffee

Espresso: PID Silvia; PID Alexia
Grinder: Mazzer SJ
Roaster: Hottop D w/HTC+TC4C
Posted Wed Jan 4, 2012, 10:39am
Subject: Re: New Silvia Project - what would you add?
 

philipmc Said:

That's a beautiful design. Everything I have been looking at uses a MAX6675 or similar to do the cold junction measurement on chip. This works out quite expensive (around $70 for a 4 thermocouple design). Using the MCP9800 for reference against a MCP3424 is a very elegant way to do this for a fraction of the cost.

Posted January 4, 2012 link

Bill Welch is the guy who deserves the credit for the design, and I agree it is very good for this purpose.

philipmc Said:

Out of curiosity, do you know what the digital resolution and accuracy are? Does thermocouple type play a significant role in accuracy?

Posted January 4, 2012 link

Most of the TC4 applications are set up to use the MCP3424's 18-bit mode and programmable gain = 8.  This ends up providing a theoretical resolution of slightly better than +/- 2uV on the thermocouple signal.  For a type K thermocouple, I think that's around 0.05C.

Of course, in the real world, you cannot achieve that.  What I've observed through a lot of non-rigorous testing is that the completed boards, uncalibrated, seem to be able to read incoming signals to within +/- 0.3% of reading +/- 3uV.  It's fairly easy to compensate for the linear portion of the error, though.  I doubt much can be done about the +/- 3uV.

The error in the MCP9800 is supposed to be +/-1C.  What I've observed, however, is that it is generally smaller than this (say 0.5C), and can also be compensated through calibration.

Under ideal conditions (TC4 inside an enclosure that maintains a relatively constant environmental temperature and isolated power supply) the boards that I have calibrated seem to be good to within +/- 1F, excluding thermocouple error.

Uncalibrated, I would expect the boards would usually be OK to within around +/- 2F, excluding thermocouple error.

Jim
back to top
 View Profile Visit website Link to this post
philipmc
Senior Member


Joined: 4 Oct 2011
Posts: 32
Location: Singapore
Expertise: I love coffee

Espresso: Silvia
Grinder: Rocky
Posted Thu Jan 5, 2012, 3:18am
Subject: Re: New Silvia Project - what would you add?
 

That's superb. Hats off to Bill and thank you for the detailed explanation. =)
back to top
 View Profile Link to this post
philipmc
Senior Member


Joined: 4 Oct 2011
Posts: 32
Location: Singapore
Expertise: I love coffee

Espresso: Silvia
Grinder: Rocky
Posted Fri Jan 6, 2012, 6:35am
Subject: Re: New Silvia Project - what would you add?
 

Another quick question, is the a simple way to detect the switch selections? I.e. have the switches operate normally, but somehow have parallel zero cross 5v TTL logic to the Arduino? The only way I know of would be to use relays (120/240v ac on the coil and 5v switched through the other side), but that seems clunky (excuse the pun).
back to top
 View Profile Link to this post
showing page 2 of 7 first page | last page previous page | next page
view previous topic | view next topic | view all topics
Discussions > Espresso > Espresso Mods > New Silvia...  
New Topics updated topics   New Posts new posts   Unanswered Posts new unanswered     Search Discussion Board search   Discussion Board FAQ faq   Signup sign up  
Not Logged in: Log In to Postlog in
Discussions Quick Jump:
Symbols: New Posts= New Posts since your last visit      No New Posts= No New Posts since last visit     Go to most recent post= Newest post
Forum Rules:
No profanity, illegal acts or personal attacks will be tolerated in these discussion boards.
No commercial posting of any nature will be tolerated; only private sales by private individuals, in the "Buy and Sell" forum.
No SEO style postings will be tolerated. SEO related posts will result in immediate ban from CoffeeGeek.
No cross posting allowed - do not post your topic to more than one forum, nor repost a topic to the same forum.
Who Can Read The Forum? Anyone can read posts in these discussion boards.
Who Can Post New Topics? Any registered CoffeeGeek member can post new topics.
Who Can Post Replies? Any registered CoffeeGeek member can post replies.
Can Photos be posted? Anyone can post photos in their new topics or replies.
Who can change or delete posts? Any CoffeeGeek member can edit their own posts. Only moderators can delete posts.
Probationary Period: If you are a new signup for CoffeeGeek, you cannot promote, endorse, criticise or otherwise post an unsolicited endorsement for any company, product or service in your first five postings.
Donate to Coffee Kids
Coffee Kids works with farming communities around the world, improving lives. Donate today.
www.coffeekids.org
Home | Opinions | Consumer Reviews | Guides & How Tos | CoffeeGeek Reviews | Resources | Forums | Contact Us
CoffeeGeek.com, CoffeeGeek, and Coffee Geek, along with all associated content & images are copyright ©2000-2014 by Mark Prince, all rights reserved, unless otherwise indicated. Content, code, and images may not be reused without permission. Usage of this website signifies agreement with our Terms and Conditions. (0.296813964844)
Privacy Policy | Copyright Info | Terms and Conditions | CoffeeGeek Advertisers | RSS | Find us on Google+