Forum

formulas with the t...
 
Notifications
Clear all

formulas with the time variable


(@thesleepydog)
Active Member
Joined: 5 years ago
Posts: 9
Topic starter  
Are formulas allowed with the time variable?

example:

[setup]
new time First_Hop
new time Boil_Time
[main]
Boil_Time = 0100
"Step" Type = CountDown
"Step" Value = Boil_Time
First_Hop = 0000
restart "Step"

[hop_loop]
if "Step" value <= First_Hop + 0000 //trying to test again value of 40mins
..
end if


Quote
(@pbruno3)
Reputable Member Admin
Joined: 5 years ago
Posts: 312
 

You can’t do online math so the if statement won’t work correctly. Create a new variable and perform the ten minute addition before the if statement. LMK if you need an example. 


ReplyQuote
(@thesleepydog)
Active Member
Joined: 5 years ago
Posts: 9
Topic starter  
So this could work?

example:

[setup]
new time First_Hop
new time First_Hop_Timing
new time Boil_Time
[main]
Boil_Time = 0100
"Step" Type = CountDown
"Step" Value = Boil_Time
First_Hop = 0000
First_Hop_Timing = First_Hop + 0000 restart "Step"

[hop_loop]
if "Step" value <= First_Hop_Timing //test against value of 40mins
..
end if
..

ReplyQuote
(@pbruno3)
Reputable Member Admin
Joined: 5 years ago
Posts: 312
 

That should work. It needs be tested to be sure. If it doesn’t, let us know and we can determine why not and figure out the fix. 


ReplyQuote
(@diebeerery)
Eminent Member
Joined: 3 years ago
Posts: 25
 

I do my hops with a variable that you can adjust here is my setup for that..

[setup]

new value FirstHop
new time FirstHopTime
new value SecondHop
new time SecondHopTime
new value ThirdHop
new time ThirdHopTime
new value FourthHop
new time FourthHopTime
new value FifthHop
new time FifthHopTime
new value SixthHop
new time SixthHopTime
new value SeventhHop
new time SeventhHopTime

FirstHopTime = 0000
SecondHopTime = 0000
ThirdHopTime = 0000
FourthHopTime = 0000
FifthHopTime = 0000
SixthHopTime = 0000
SeventhHopTime = 0001

[boil]
if "First Hop" state == true
wait "Boil Timer" value <= FirstHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Second Hop" state == true
wait "Boil Timer" value <= SecondHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Third Hop" state == true
wait "Boil Timer" value <= ThirdHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Fourth Hop" state == true
wait "Boil Timer" value <= FourthHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Fifth Hop" state == true
wait "Boil Timer" value <= FifthHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Sixth Hop" state == true
wait "Boil Timer" value <= SixthHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif
if "Seventh Hop" state == true
wait "Boil Timer" value <= SeventhHopTime
"Hop Addition" active = true
Status = "Add Hops"
"Continue" State = false
wait "Continue" State == true
"Hop Addition" active = false
Status = "Boiling"
endif

This post was modified 3 years ago 2 times by DieBeerery

ReplyQuote
(@texaswine)
New Member
Joined: 3 years ago
Posts: 3
 

Just sitting down this weekend to do some scripting. Almost done with my first pass, but the hop additions have me scratching my noggin and I'm kind of stuck.

Bryan, it looks like you and I have taken an almost identical approach to the hops. But what I'm wondering is how you kick over and do something like start the wort pump with 10 minutes remaining but you have a 5 minute hop addition. The way the script above is written the pump won't kick on until all the hops have been added, correct? Maybe the key is to not turn on the wort pump until the boil is over!

Would like to know how you fine folks are handling this.


ReplyQuote
Share: