Author Topic: Coming around to automation  (Read 33308 times)

Offline beananimal

  • Jr. Member
  • **
  • Solid or Perf: solid installed, performated available
  • Serial Number: 363
  • J or T : T (+J)
  • Charge Weight : 333g or 400g
Re: Coming around to automation
« Reply #30 on: June 15, 2017, 01:37:33 PM »
@Susan:
My hope is, that with some understanding of the TC4 basis (Arduino) I can better adapt the parameters or code for my stepper, and fan.

And the question for the far future is: what about that software PID in Artisan?
be an animal: be curious. trust you guts. play the game

Offline SusanJoM

  • Administrator
  • Hero Member
  • *****
  • Solid or Perf: both/either
  • Serial Number: 454 (perf) 1243 (solid)
  • J or T : J
  • Charge Weight : 350 gm
Re: Coming around to automation
« Reply #31 on: June 15, 2017, 07:41:06 PM »
So in everything I read about Arduino they talk about 'sketches'.  Are sketches basically programs ?  scripts ? flowsheets maybe? 

The hardest thing about learning something new is there is always an entirely new vocabulary to learn.
 ???
"There is a crack in everything, That's how the light gets in." Leonard Cohen.

Offline beananimal

  • Jr. Member
  • **
  • Solid or Perf: solid installed, performated available
  • Serial Number: 363
  • J or T : T (+J)
  • Charge Weight : 333g or 400g
Re: Coming around to automation
« Reply #32 on: June 15, 2017, 11:08:15 PM »
Yes
That is also my understanding about Sketches .
(And Python is a programming language, but not for the Arduino)
be an animal: be curious. trust you guts. play the game

Offline cgriffith

  • Newbie
  • *
  • Solid or Perf: Solid
  • Serial Number: 835
  • J or T : J
  • Charge Weight : 400gm
Re: Coming around to automation
« Reply #33 on: June 16, 2017, 05:50:26 AM »
When working with arduino, you write small programs in a C-like language.  That program is called a "sketch".  The IDE then converts that to binary code the micro processor understands (compiles).  Then you upload that binary to the chips internal memory so it can run. 
There are 10 kinds of people in the world; those that understand binary, and those that don't.

Offline SusanJoM

  • Administrator
  • Hero Member
  • *****
  • Solid or Perf: both/either
  • Serial Number: 454 (perf) 1243 (solid)
  • J or T : J
  • Charge Weight : 350 gm
Re: Coming around to automation
« Reply #34 on: June 16, 2017, 07:05:39 AM »
Thanks, guys.  Why they can't just call a program a program baffles me.  :-\ 
"There is a crack in everything, That's how the light gets in." Leonard Cohen.

Offline Chert

  • Sr. Member
  • ****
  • Solid or Perf: solid
  • Serial Number: 593
  • J or T : J
  • Charge Weight : 109-115, 400
Re: Coming around to automation
« Reply #35 on: June 17, 2017, 11:43:51 AM »
Two thoughts and a repeated word to the wise.

Automatic sensing of gas and air settings by artisan while one manually controls the roast is appealing.  If artisan fails - as it did for me three times today - the roaster can still salvage and possibly match the intended profile pretty closely.  (My TC4 LED continues to post temps even when the roasterscope is belly up.)

Automatic adjustment of settings via artisan is also appealing and more hands off, and may allow for PID like hugging a preset profile.  Way cool and possibly achieving a better roast, maybe not.  However with that type arrangement the roaster might waste beans when artisan doesn't cooperate.  OR one could built into the design, a failsafe manual control, not just a failsafe manual shutoff.


And as always NEVER leave a HUKY out of sight while roasting on it.
Cooperative / fundraising roasting with Huky 500

Offline beananimal

  • Jr. Member
  • **
  • Solid or Perf: solid installed, performated available
  • Serial Number: 363
  • J or T : T (+J)
  • Charge Weight : 333g or 400g
Re: Coming around to automation
« Reply #36 on: June 18, 2017, 07:20:54 AM »
It seems that my hot-start on automation will be in August, after MLG summertime.
Here a statement from greengardian, about automation:
So the ZCD is mandatory, at least for AC.

https://forum.homeroasters.org/forum/viewthread.php?forum_id=133&thread_id=3322&pid=59635#post_59635


A brief summary of each control option:

Phase Angle Control mode
- Requires a zero-cross detector on IO3
- Phase angle control on OT2 for an AC fan
- ICC control on OT1 for a heater
- No PWM output on IO3

PWM mode
- Slow PWM on OT1 for a heater (default 1Hz but adjustable)
- Fast PWM (analogue out) on IO3 for DC fan control
- Additional slow PWM on OT2

You can find the update here including a zip file containing the sketches, and latest TC4 libraries. https://github.co...nQ_PID_6_0

Or direct zip file download here. https://github.co...p?raw=true
be an animal: be curious. trust you guts. play the game

Offline SusanJoM

  • Administrator
  • Hero Member
  • *****
  • Solid or Perf: both/either
  • Serial Number: 454 (perf) 1243 (solid)
  • J or T : J
  • Charge Weight : 350 gm
Re: Coming around to automation
« Reply #37 on: June 19, 2017, 10:22:05 AM »
And this just in from Brian Burley (Phidgets) regarding kPa control

Generally I'd recommend a bipolar motor as they are better all around though the controller is more expensive and not multi-channel.  For reference:

http://www.phidgets.com/products.php?category=23&product_id=3323_0
http://www.phidgets.com/products.php?category=13&product_id=1067_0
"There is a crack in everything, That's how the light gets in." Leonard Cohen.

Offline monkey_lever

  • Jr. Member
  • **
  • Solid or Perf: Both. Solid Installed
  • J or T : T
Re: Coming around to automation
« Reply #38 on: June 20, 2017, 12:42:18 PM »
If you need some help either with the TC4 or the stepping motor feel free to contact me I can provide with some pictures of the wiring for the TC4 or the code python code for the motor.

I did not try to modify the TC4 code to connect the motor to the TC4. The artisan call program feature is easier to setup.

Rgds.

Offline Chert

  • Sr. Member
  • ****
  • Solid or Perf: solid
  • Serial Number: 593
  • J or T : J
  • Charge Weight : 109-115, 400
Re: Coming around to automation
« Reply #39 on: June 20, 2017, 01:31:22 PM »
If you need some help either with the TC4 or the stepping motor feel free to contact me I can provide with some pictures of the wiring for the TC4 or the code python code for the motor.

I did not try to modify the TC4 code to connect the motor to the TC4. The artisan call program feature is easier to setup.

Rgds.
  Would you suggest that the call program feature could be utilized with other hardware such as phidget or other stepper motor controller?  And thanks for your input.
Cooperative / fundraising roasting with Huky 500

Offline monkey_lever

  • Jr. Member
  • **
  • Solid or Perf: Both. Solid Installed
  • J or T : T
Re: Coming around to automation
« Reply #40 on: June 20, 2017, 02:50:26 PM »
Chert.

Im not familiar with the phidget communication protocol. But the call program philosophy is that you can send and receive serial commands between artisan and any device.

Example:

I have some buttons that call a python file like this one:

- C:/Python27/python.exe C:/Huky_phyton/Phyton_1.py MOTOR 30.  The button send a serial command that correspond to 30 % of the total gas KPA.

- The python_1.py writes a serial command to the arduino and the arduino moves the stepper motor.

In summary if you can send commands to the serial of the phidget or the stepper motor you can control it with artisan.






Offline beananimal

  • Jr. Member
  • **
  • Solid or Perf: solid installed, performated available
  • Serial Number: 363
  • J or T : T (+J)
  • Charge Weight : 333g or 400g
Re: Coming around to automation
« Reply #41 on: July 10, 2017, 12:08:02 PM »
Thanks for checking, and I'm sure others are interested, but my push towards automation has stalled.
Hello Susan,
a bit sad to hear this.

I am just hoping that you stay curious, and can stick to the role of the catalysator,
because I find every day that it will be a long way till contoling the Huky
and the frequency of posts here might be slow.
stay tuned
be an animal: be curious. trust you guts. play the game

Offline phischmi

  • Jr. Member
  • **
  • Solid or Perf: Solid
  • Serial Number: 693
  • J or T : T
  • Charge Weight : 333g
Re: Coming around to automation
« Reply #42 on: July 11, 2017, 04:28:23 AM »
Hey all,
didn't had the time to chime into this discussion sooner, but there's one thing i altered in my Arduino-Software regarding the gas-control via stepper.

I posted my ideas on controlling the fan and gas in this topic
https://www.hukyforum.com/index.php/topic,1080.0.html

After changing from pre-defined buttons (gas = 0%, 25% ... 100%) to sliders (for use with Artisan's PID) i had to alter my code to work with sliders.
This is easily done using the MultiMap function in your Arduino code.
https://playground.arduino.cc/Main/MultiMap

This function allows to interpolate values. You just have to determine two arrays which tell the function, how many steps to go to reach a pre-defined gas-flow.

E.g.
Code: [Select]
int in[]= {0,25,50,75,100};
int out[] = {0,350,450,650,950};

This means, the stepper has to go 650 steps to achieve approx. 75% of gas-flow.
With the above function and those arrays you can easily pick any value from 0-100%.

Maybe this helps :)

BTW
I'm still using the Noctua DC-Fan, which i can easily set to any desired value using the Arduino and PWM. Though i'm very interested in your thoughts using an SSR and the original AC-Fan.


Regards

Philipp

Offline monkey_lever

  • Jr. Member
  • **
  • Solid or Perf: Both. Solid Installed
  • J or T : T
Re: Coming around to automation
« Reply #43 on: July 15, 2017, 02:13:23 PM »
Philipp.

Thank you for your suggestion. I'll try the multimap function next time I play with the arduino code.

Can you explain how you setup artisan PID function to work with aruino?

Regards.

Offline slickrock

  • Newbie
  • *
  • Solid or Perf: Solid
  • Serial Number: 070
  • J or T : J
Re: Coming around to automation
« Reply #44 on: July 15, 2017, 10:47:05 PM »
Oh thank you.  I love this line of inquiry....someday with all your help I may even understand it.... ;)

Here's another thread that I haven't yet fully ingested, but that should be of interest to anyone else following me down the rabbit hole. http://www.home-barista.com/home-roasting/exploring-north-gas-roaster-automation-part-1-t47272.html

I should clarify that I'm not (yet....???) interested in following a background curve, or controlling a PID.  I just would like to be able to adjust kPa (most important) and maybe air (least important because I seldom change it at all) from Artisan....

Hi Susan,
Had some trouble getting registered on this forum for a while... been wanting to reply to this thread back when it got started.  When I wrote that post, I was actually thinking about the value of it to those who would want to automate any gas drum roaster; Huky included.

While it looks like there has been more traction going with a stepper motor approach, there are some clear advantages IMO to going with a proportional gas valve:

  • It's safer, in that if you lose power, the valve closes shut.  Also, there's a fair amount of friction to overcome with a needle valve when driving it with a stepper, so there may be drift over time.  And needle valves may not support a continuous or large on-off duty cycles that proportional gas vales are built for
  • It's easier to calibrate with a valve controller that can be used to trim the min/max settings
  • It's totally quiet, has minimal mechanics, and is miniaturized - small plunger pin actuates the valve
  • Easy PID support, which is the promise land of automation:  You can using existing Galt/Greencatigan sketches with the valve for full PID operation in Artisan.  Of course, if don't want PID control, you can use the built-in duty control to set the percentage of valve opening via buttons in Artisan

The downside is probably the additional cost.  But the plumbing can be far simplified compared to what I showed on my post, which in hindsight was over-designed. I plan to add another post that would provide a better explanation.

Cheers





[/list]

 

Resources

PRICING and FAQs

ARTISAN RESOURCES

PHIDGET INFORMATION

ROASTING GUIDES

ROASTING TERMINOLOGY

GREENS SOURCES

A FEW VIDEOS

Temperature Converter

Celsius:
Fahrenheit:
Kelvin:

Recent Topics

Rob Hoos article on Thermocouples by SusanJoM
August 31, 2017, 02:52:23 PM

CFM range for exhaust fan by edtbjon
August 30, 2017, 08:13:09 PM

Standard Stove - any ideas what to substitute it with at the European market? by hankua
August 30, 2017, 08:07:16 AM

Just Purchased, Hello from Claymont, DE! by hankua
August 30, 2017, 07:57:21 AM

Hello from Melbourne, Australia! by hankua
August 30, 2017, 07:55:07 AM

New to Roasting (opportunity to buy a Huky) by hankua
August 30, 2017, 07:52:18 AM

Hello from South Korea! by K.Brown
August 30, 2017, 05:40:09 AM

First Roast with Artisan, Feedback Appreciated by edtbjon
August 28, 2017, 04:17:34 AM

And another checklist to validate… by SusanJoM
August 25, 2017, 09:15:43 AM

Estimated Cost after Mods and Tools For Maintenance etc. etc. by edtbjon
August 25, 2017, 01:46:56 AM

Phidget 1048 Temperature() [Error 126] by MasterKraus
August 23, 2017, 06:41:08 PM

Any ordering at MLGP by jay
August 22, 2017, 06:44:05 AM

Powered by EzPortal