• Please visit and share your knowledge at our sister communities:
  • If you have not, please join our official Homebrewing Facebook Group!

    Homebrewing Facebook Group

BruControl: Brewery control & automation software

Homebrew Talk

Help Support Homebrew Talk:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
Ah OK, I feel a little better now! I would also add that pulling the text script writing out of BC itself, decouples it from BC such that I don't have to RDP to the BC computer and I also don't have to install a copy of BC on every computer I might want to do some script editing. Granted you can do that without needing to have a license but it still seems unnecessary just to write some text. Notepad++ (as others are as well) is lightweight and can be portable if you want it to be.
 
I don’t want to derail the conversation, but I have a few quick questions on the Tilt. It is obvious that the current version is working quite well from what I have read in these threads, but as I looked around, I could not find out the details I need. Sorry if this has been asked/answered/


1- Can I use the temp value from the Tilt in BC as temp sensor device, to drive my ferm control (PID or Hyst)? Do I just add in a new device source (blacktilt etc)?

2- I have a mega 2560 running serial, what do I need to add to connect to the tilt?


Thanks!


KDAZ
 
I don’t want to derail the conversation, but I have a few quick questions on the Tilt. It is obvious that the current version is working quite well from what I have read in these threads, but as I looked around, I could not find out the details I need. Sorry if this has been asked/answered/


1- Can I use the temp value from the Tilt in BC as temp sensor device, to drive my ferm control (PID or Hyst)? Do I just add in a new device source (blacktilt etc)?

2- I have a mega 2560 running serial, what do I need to add to connect to the tilt?


Thanks!


KDAZ

Hi @kdaz,

1. No, not through the native Hysteresis devices, but you could via a script. We should be able to add that capability in the future though. It’s a good request.

2. Unfortunately, the MEGA does not Bluetooth LE support (or any BT for that matter), so it’s physically incapable of receiving TILT transmissions. The only interface that can do it currently is the ESP32. You can connect to it via serial or WiFi.
 
OK, I messed around a bit more and I have a version that looks much like the BC scripting window with the typical theme. The link below is for the updated UDL.xml file as well as a theme file that is needed to change the global background. Import the BruControl_UDL-R2.xml file as before and dump the theme xml into a folder you create in the notepad++ installation folder. Restart Notepad++ and go select the new BruControl theme. I find this new version easier on the eyes and good for working at night as it is "dark".

https://drive.google.com/uc?export=download&id=16FE-6hv9EAd1oPCjbVi0Q5XwlvmTCqJ6
 
Last edited:
you can drag it, but you have to have a super steady hand or hold the mouse steady with your other hand and get that half-pixel:

upload_2019-3-18_15-5-33.png
 
I did find it. I found I could do it if I hovered over the tiny little bar on the far left or right portion of the script window at the window border but not while hovering along the script window horizontal bar in the middle of the screen. That would be super hard with a touch screen I would think.
 
Last edited:
Can we change visibility of an element via a script? Not a super-critical need, but would be kind of cool to have things hidden unless the script makes them active.


Super easy...

"element" visibility = visible/hidden

I use for for all sorts of stuff, to declutter the brew day.
 
OK, I messed around a bit more and I have a version that looks much like the BC scripting window with the typical theme. The link below is for the updated UDL.xml file as well as a theme file that is needed to change the global background. Import the BruControl_UDL-R2.xml file as before and dump the theme xml into a folder you create in the notepad++ installation folder. Restart Notepad++ and go select the new BruControl theme. I find this new version easier on the eyes and good for working at night as it is "dark".

https://drive.google.com/uc?export=download&id=16FE-6hv9EAd1oPCjbVi0Q5XwlvmTCqJ6


Thanks for doing this. It's been on my list for awhile, but never got around to it.
 
I have used Notepad ++ for years and it is handy. Just like Notepad, but better with more bells and whistles. I particularly like when you highlight a "word" it highlights all instances.
 
So why does this not work? I have a switch to turn on/off the Hop Stand 1 and global items for the Hop Stand 1 Temp and the Hop Stand 1 Time. I have the two global's setup as a value for temp and a time for the, well time. Running the script pulls the state of the switch and the value set in the global for temp just fine but it throws this "Specified cast is not valid" error for the time and won't pull the 00:00:20:00 value that is set in the "Hop Stand 1 Time" global. I feel that this should work in some fashion but it isn't. What am I missing?

Screenshot.png
 
I have used Notepad ++ for years and it is handy. Just like Notepad, but better with more bells and whistles. I particularly like when you highlight a "word" it highlights all instances.


Do you think there a way we could set notepad++ up to color code things like BC does?

*edit: - it looks like it is through 'languages'... maybe a question for @BrunDog - has there already been a 'language' created for BruControl Scripting that could be used in Notepad ++, even if it requires some modification?
 
Last edited:
Yes. Check post #2124 above.

instructions not intuitive enough I guess... but I worked it out in about 45 minutes with google and reading back to prior post 2113

Step by step:
Rename a script to have the .bruscript extension
Import UDL file: Language --> Define your language --> Import --> BruControl_UDL-R2.xml
Copy BruControl.xml to a new folder named 'themes' - C:\Program Files (x86)\Notepad++\themes
Associate .bruscript with Notepad++ (right click and 'open with')
Double click .bruscript file and choose to associate
Set style: Settings --> Style Configurator --> Select Theme --> BruControl​

Looks nice!!!! Very happy, Thank you!!!

My only concern is this is not linked to BruControl... new features/commands will have to be manually added... A BIG ask, but if the BruControl Script editor were to be/have an external .xml file in the software zip file, we could import as a UDL file, it would be a little more sano..
 
FYI we are adjusting the next build so that it strips text formatting. This has been an issue when someone imports formatted text (not notepad).

I think we could add an import button to pull in remote text, but a sync to an external editor would be tricky.
 
I guess i was thinking more of the case when you someday add a feature that is recognized as a command and highlighted, where do those rules sit that would need to be modified? is it in an xml file like the UDL file?
 
I guess i was thinking more of the case when you someday add a feature that is recognized as a command and highlighted, where do those rules sit that would need to be modified? is it in an xml file like the UDL file?

They are in the application. I don’t think that is something we can easily pull out.
 
Thanks @VacationLand for the research and link.

The current is easy. Voltage... notsomuch. There are AC - DC voltage transducers, but a few more bucks than I’d like to see. These could be built but certainly turnkey is better.

I think current is much more important but it would be nice to have a voltage report.
 
Is there a volt/amp meter that can display on the brucontrol software?
The amp meter is the only one I ever found of any importance myself and I have 2 of them in my larger brucontrol panel because of the 2 power feeds into it. I use the CR magnetics brand transducers myself I find them extremely usful in seeing if any elements or pumps are running and drawing current and once its helped me see that one of my element breakers had popped without me hearing it causing me to actually be heating with 75% power.
 
Last edited:
Sorry if this has been asked multiple times, I looked over the hardware section of the brucontrol site but could not find a breakdown and time has become a valuable commodity for me these days..

Which ESP32 is ideal for a wifi network connection and bluetooth interface to use with the tilt devices? I see there are esp Dual boards now as well that may offer advantages? any that wont work?
thanks.
 
The amp meter is the only one I ever found of any importance myself and I have 2 of them in my larger brucontrol panel because of the 2 power feeds into it. I use the CR magnetics brand transducers myself I find them extremely usful in seeing if any elements or pumps are running and drawing current and once its helped me see that one of my element breakers had popped without me hearing it causing me to actually be heating with 75% power.
nvm
 
Sorry if this has been asked multiple times, I looked over the hardware section of the brucontrol site but could not find a breakdown and time has become a valuable commodity for me these days..

Which ESP32 is ideal for a wifi network connection and bluetooth interface to use with the tilt devices? I see there are esp Dual boards now as well that may offer advantages? any that wont work?
thanks.
I'm using this one with good success... no issues to report. I think when they say "Dual" its just saying it has a WiFi and Bluetooth radio available.
 
Has anyone else used the call/return subroutines in the latest rev? I tried setting up a simple one to play with, and it calls the sub fine, and as part of the subroutine I issue "return" but I get "ERROR: cannot return, call history empty".

Here is the simplified code:

[loop]

if "button" state == false
call "shutdown"
endif

goto loop

[shutdown]
"Status" value = "Shutting Down"
//other shutdown code here
return


Am I missing something obvious here?

Thanks,
Joe
 
Has anyone else used the call/return subroutines in the latest rev? I tried setting up a simple one to play with, and it calls the sub fine, and as part of the subroutine I issue "return" but I get "ERROR: cannot return, call history empty".

Here is the simplified code:

[loop]

if "button" state == false
call "shutdown"
endif

goto loop

[shutdown]
"Status" value = "Shutting Down"
//other shutdown code here
return


Am I missing something obvious here?

Thanks,
Joe

Do you perhaps need a sleep command in that loop to keep it from racing about the loop? I have found that things work but it doesn't appear to be working in the script window if things are happening too fast in certain simplified testing scenarios. I have not specifically used the call/return function yet but the goto function can appear to have the problem you mention if the loop is "racing".
 
What are usage scenarios for the call/return?

And yea I would bet for sure you need to sleep that as well.
 
A sleep is not required but its definitely a best practice to make sure the script execution isn’t unthrottled more than required. 1000 evaluations a second when a physical change takes 3 seconds isn’t a match and unnecessarily uses overhead.

That said, I’m not sure why the error is being issued. I’ll test it and report back.
 
What are usage scenarios for the call/return?

My use case is interlocks... I'm setting many boolean bits as I move through a script, so as an interlock bit is cleared or set I would like to jump to a single module to perform some tests but pickup where it left off. Order of bit checks in this case matters. I could and have done it with massive looped goto's... just trying to optimize the coding a bit and make it easier to read and troubleshoot.
 
All,

We posted an update to the v1.1 Release Candidate (v1.0.1.12). I think this is getting pretty close. Fixes in this build:
1. Fixed the Global Date/Time 'value' property in scripts.
2. Timers with alarms do not continually trigger the alarm when the time exceeds the alarm.
3. Updated info and grip icons to improve transparency and appearance.
4. Text formatting is stripped when pasting text into a script.

Feedback is appreciated!
 
Has anyone else used the call/return subroutines in the latest rev? I tried setting up a simple one to play with, and it calls the sub fine, and as part of the subroutine I issue "return" but I get "ERROR: cannot return, call history empty".

Here is the simplified code:

[loop]

if "button" state == false
call "shutdown"
endif

goto loop

[shutdown]
"Status" value = "Shutting Down"
//other shutdown code here
return


Am I missing something obvious here?

Thanks,
Joe

Tested this and confirmed. It's related to the if/endif block. The call/return works outside the block, not that this does your script and intention any good! This will be addressed in an upcoming update (not today's, sorry).
 
Another question as I plan my BruControl build. I have a conical fermenter that I use as a unitank with a spunding valve to carbonate near the end of fermentation. If I put a pressure sensor on my conical using one of the ports near the bottom, could I use that to determine the volume of wort that I end up with in my fermenter post boil? Then, once I have that volume and have started fermentation, when it comes time to put my conical under pressure, could I then "tare" out the valve reading to be 0 psi with whatever pressure it is under with that volume of liquid and then turn the valve into a basic psi pressure sensor?
 
Back
Top