Programming Help

Describe your system and processes, and post your config file.
Post Reply
datamike
Posts: 36
Joined: Tue Jan 06, 2009 2:40 pm

Programming Help

Post by datamike »

I am going to be brewing on my new system in the next day or so. I have a general programming question:

Is there a way to automatically pause a process on a state change? Example: Process 1, state 0 is turn on a pump and use dif control to heat to 165f. I then want a pause so I can mash in the grain. Then state 1 would be triggered to turn on pump and use dif control to maintain 154f. I know I can just hit the pause button, but I am looking to pause automatically. Any help appreciated!

Thanks!
Michael
User avatar
ECC
Posts: 676
Joined: Fri Sep 12, 2008 12:29 pm
Bot?: No
Contact:

Re: Programming Help

Post by ECC »

Sure. You can program a Wait state. So in your example in Proc1 State0 you are controlling heat/pump, then use the exit condition you require to exit into the wait state. The condition for entering the wait state could be based on a timer, temperature reached, or user input. While in the wait state don't enable any outputs for control, so everything will shut down. You can stay in the wait state until whichever exit condition you'd like, usually a user input Win button, to signal that your done mashing in and transition to the 154f maintain state.

You can check out Process1 "Mash Process" on the demo BCS-460, http://ecc.webhop.org:8081 (user=admin, pw=bcsdemo), it has a "Mash In" state that is probably exactly what you're shooting for.

Also, the System Example 1 has a similar state:
Image
missing_link
Posts: 45
Joined: Sat Dec 20, 2008 2:44 pm

Re: Programming Help

Post by missing_link »

I have mine programmed this way.

State 0 = countdown timer. I currently have it set to 2 hours. This allows me to get things plugged in and my water into the tuns. If it went to pre-heat immediately I would risk burning an element. Exit = time getting to 0 Go to State 1 or click on win0 which I labeled "Next Step"

State 1 = Pre-heat. When this state starts, I have a timer that counts up. It stays in pre-heat mode until I hit win0 which I have labeled next step. This way it will remain at the pre-heat temp until I am ready to mash in.

State 2 = Mash in. In this state the HLT pump and HLT heater remain on, while the Mash is off. I dough in, stir and close the lid. I exit by hitting Win0 which is still labeled Next Step.

State 3 = Mash This step runs for 50 minutes on a 1 hour mash. Exit = Time is Zero. Goes to next step automatically.

State 4 = Mash out. Ramp mash to 168 for 15 minutes. Exit = Time is Zero. Goes to next step automatically.

State 5 = Swap hoses. Stop everything. No pumps no heaters. Exit = Win0 which is labeled next step.

State 6 = Sparge. Just the pumps, no heat. Exit when timer gets to zero

State 7 = Done.

I am working on figuring out how to incorporate my float switch to cycle the sparge pump on and off using the BCS and Din0. I'm not sure how to do it at this point.

Linc
datamike
Posts: 36
Joined: Tue Jan 06, 2009 2:40 pm

Re: Programming Help

Post by datamike »

Both posts very helpful!

Thanks!
Michael
User avatar
Viejo
Posts: 28
Joined: Fri Dec 06, 2013 6:23 pm
Bot?: No

Re: Programming Help

Post by Viejo »

Missing_Link -- Did you ever figure out how to program your float switch on DIN0 to activate your pump for fly sparging? I am just setting up my program, and I can't figure out how to associate a DIN with a function.

I'm not a programmer, but I've been reading and studying. This just isn't working for me yet.

Thanks!
JonW
Site Admin
Posts: 1726
Joined: Sun Jul 18, 2010 7:51 am
Bot?: No
Location: Huntington Beach, CA
Contact:

Re: Programming Help

Post by JonW »

The DIN's are used as state exit conditions. You would want to use two different states that you alternate between based on the DIN input to turn the pump on and off.

I don't personally think turning a pump on and off a lot during fly sparging would work well - you may lose the pump prime. You might be better off having the pump set to run continuously and use a valve that turns on and off to control the amount of sparge water. Just my opinion though.... try it with the pump first.
User avatar
Viejo
Posts: 28
Joined: Fri Dec 06, 2013 6:23 pm
Bot?: No

Re: Programming Help

Post by Viejo »

I was under the impression that controlling sparge water flow by a float switch and pump was pretty common. I could go either way, but I'd like to try the float switch first because I have one. However, I don't understand how you suggest setting up the DINs as exit conditions. It seems to me that a discrete input (turning a switch on via float switch) should enable a process to run (eg, a pump), the same way a temperature sensor turns on a process, but I don't see how.

Grateful for the help. Thanks!
JonW
Site Admin
Posts: 1726
Joined: Sun Jul 18, 2010 7:51 am
Bot?: No
Location: Huntington Beach, CA
Contact:

Re: Programming Help

Post by JonW »

You normally don't need to control the flow using programming logic. You can use a valve to set the flow rate from the MLT to the BK and then another valve to set the rate from the HLT to the MLT. It's not hard to manually match the rates.

As far as triggering a "process", I think you need to check out the Wiki for the examples as it sounds like you're confused about process/states. A temp probe or DIN does not usually trigger a "process", but rather, the DIN would trigger a "state". Also, the temp probe sometimes could be used to trigger a "state", but usually it is just used within the state to maintain temperature (not requiring a change in state to do it's job).
User avatar
Viejo
Posts: 28
Joined: Fri Dec 06, 2013 6:23 pm
Bot?: No

Re: Programming Help

Post by Viejo »

JonW wrote: As far as triggering a "process", I think you need to check out the Wiki for the examples as it sounds like you're confused about process/states. A temp probe or DIN does not usually trigger a "process", but rather, the DIN would trigger a "state". Also, the temp probe sometimes could be used to trigger a "state", but usually it is just used within the state to maintain temperature (not requiring a change in state to do it's job).
I think one of my biggest problems is understanding what things are called. It's hard to search the Wiki for an answer to a specific question, and since there's no user manual, it's taking me awhile to understand an unfamiliar language.

I want to use my HLT to heat water for a HERM System. For initial heating, I will use the HLT temp probe, but for mash and recirculation, I want to use the MLT temp probe to manage the HLT temp. I would then go back to the HLT temp probe to manage HLT temp for mash out and sparge. For some reason, I can get the second function to work (i.e., fire the burner to the HLT), but not the first and third. I have it set up this way:

Process 0: Heat HLT
State 0: Heat HLT to 154 F
HLT burner associated with HLT temp probe

Process 1: Mash
State 0: Maintain Mash Temp at 152 F (recirculating through HLT)
HLT burner associated with MLT temp probe

Process 2: Sparge
State 0: Heat HLT to 170 F (and maintain)
HLT burner associated with HLT temp probe

You see that I am switching which temp probe is associated with the HLT, the only burner I'm managing via the BCS. I set them up that way in the System Settings tab. Process 1 works (fires the HLT), but Process 0 and 2 don't. For the pump, I'm going to take your advice and skip the level switch and control the flow manually, at least for now. I will fire the MLT for strike and BK burner for boil manually. Any thoughts on what I did wrong?
Post Reply