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

    Homebrewing Facebook Group

BrewPi@ESP8266, no need of RPI and Arduino.

Homebrew Talk

Help Support Homebrew Talk:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
Got it erased.

Can someone give me a more detailed how to for the Arduino part? I gotta be doing something wrong here...

Do i just open the brewpiless.ino and add the libraries via sketch?

Do i just open a new sketch "add file..." and use the .bin (https://github.com/vitotai/BrewPiLess/tree/master/bins)? flash that then flash the brewpiless.ino?

This is the first time I've used Arduino, clearly.
 
Got it erased.



Can someone give me a more detailed how to for the Arduino part? I gotta be doing something wrong here...



Do i just open the brewpiless.ino and add the libraries via sketch?



Do i just open a new sketch "add file..." and use the .bin (https://github.com/vitotai/BrewPiLess/tree/master/bins)? flash that then flash the brewpiless.ino?



This is the first time I've used Arduino, clearly.


Comment deleted. Read back a few comments and realised you're not using an arduino
 
Last edited:
Got it erased.

Can someone give me a more detailed how to for the Arduino part? I gotta be doing something wrong here...

Do i just open the brewpiless.ino and add the libraries via sketch?

Do i just open a new sketch "add file..." and use the .bin (https://github.com/vitotai/BrewPiLess/tree/master/bins)? flash that then flash the brewpiless.ino?

This is the first time I've used Arduino, clearly.

If you want to flash the binary only. You can use NodeMcu Flasher.
https://github.com/nodemcu/nodemcu-flasher

Or, if you are using Mac and have esptool.py installed, use esptool.py
Code:
sptool.py --port <serial-port-of-ESP8266> write_flash -fm <mode> 0x00000 <nodemcu-firmware>.bin

If you want to built the binary by yourself, setup the Arduino ID by following the instruction:
https://github.com/esp8266/arduino
 
Did you change some config files recently? I just tried upload bin through nodemcu flasher and later normal Arduino IDE flash and I can't see any AP from ESP anymore. It flashes ok. I do not remember if the blue led on ESP was active or not. I have wemos d1 mini.

Weird.
 
If the ESP8266 has connected to your network, it would connect to the same network without creating a network. The wifi credential is stored in a special region of the Flash. It won't be changed by flashing.
 
Or, if you are using Mac and have esptool.py installed, use esptool.py
Code:
sptool.py --port <serial-port-of-ESP8266> write_flash -fm <mode> 0x00000 <nodemcu-firmware>.bin

Used this, kinda:
sudo ./esptool.py --port /dev/cu.wchusbserialfd120 write_flash 0x00000 /Users/B/esptool/new.bin


Flashed fine and brewpiless started but same issue consistent "Controller not updating data..." fault.


I can select edit & update everything but it doesn't function due to the fault.
 
ok i connected ESP in the other way to my network and flashed brewpiless again and now it is working fine :)

What happened? How could you connect to it if it didn't form a network and didn't connect to your network?
 
Used this, kinda:
sudo ./esptool.py --port /dev/cu.wchusbserialfd120 write_flash 0x00000 /Users/B/esptool/new.bin


Flashed fine and brewpiless started but same issue consistent "Controller not updating data..." fault.


I can select edit & update everything but it doesn't function due to the fault.

It's weird. Would you please try open the Javascript Console first, then browse to

http://brewpi.local/lcd

Copy ALL the console output for me. Thank you.
 
I used your advice that credentials are stored somewhere else and are not erased. So I wrote a script that connect to my home network and then connected the ESP using this script. Then I flashed brewpiless and it was connected after flash to my home network. Dunno but works :) Although I had to figure out an IP address as the brewpi.local is not working on my PC (windows). I also must say that page looks much better in chrome than firefox.
 
If you install iTunes and setup firewall, mDNS will work with Chrome on Windows.
I didn't use firefox for a while. I only checked on Safari and Chrome.
 
iTunes?! Ugh.
That'd be a hell of a price to pay for network connectivity ;)

If you're looking for Bonjour I'm pretty sure you can find installable packages for it without having to have that POS iTunes installed...

Cheers!
yeah.
I learned that "Bonjour Print Services for Windows" and some other Apple's software might do the job. Given the popularity of iPhone/iPad, iTunes might be the most popular software. Then, a little tweaking will make mDNS work.
 
Signed out of Chrome to see if that would help, but no. See attached.
Also brewpi.local/ doesnt work now...


unrelated im sure but i get the below device & i dont think i should.

Screen Shot 2017-02-20 at 7.50.33 PM.png


Screen Shot 2017-02-20 at 7.56.31 PM.png
 
I actually just had the brewpi switch on the relay for the first time!

Then shortly faulted with the following:

POST http://192.168.0.111/putline net::ERR_CONNECTION_REFUSED
invoke @ bwf.js:2
send @ bwf.js:2
(anonymous) @ (index):11
(index):11 error
(index):11 error
(index):11 GET http://192.168.0.111/chart.php?offset=1072 404 (Not Found)
reqdata @ (index):11
(anonymous) @ (index):11
(index):11 Not logging
 
Is there any recommendation for "Device slot"? My sensor does not work on some low values, something 6 and up works fine though.
 
Is there any recommendation for "Device slot"? My sensor does not work on some low values, something 6 and up works fine though.

I don't know. What I know is that sometimes BrewPi fails to save the settings and ERASE of EEPROM is necessary. I sometimes have to erase EEPROM for multiple times.

I usually use 0 and 1 for sensors, however.
 
I actually just had the brewpi switch on the relay for the first time!

Then shortly faulted with the following:

POST http://192.168.0.111/putline net::ERR_CONNECTION_REFUSED
invoke @ bwf.js:2
send @ bwf.js:2
(anonymous) @ (index):11
(index):11 error
(index):11 error
(index):11 GET http://192.168.0.111/chart.php?offset=1072 404 (Not Found)
reqdata @ (index):11
(anonymous) @ (index):11
(index):11 Not logging

Well. A little explanation here.

BrewPiLess is comprised of three parts: BrewPi Core, Networking, and HTML/Javascript.

BrewPi core is ported from BrewPi on Arduino. (Thanks to Thorrax again.) The temperature management is performed by the BrewPi core.

The Networking part includes WebServer, and some small piece of code, including logging, beer profile keeping, and etc. It is created to replace the Raspberry PI of original BrewPi. A "virtual serial" interface was created so that BrewPi core thinks it is communicated through ordinary serial port. I've tried my best not to modify the BrewPi core.

HTML/Javascript runs on your browser, presents the interface, and sends commands to BrewPi core through WebServer.

That says, the BrewPi core should work fine even if you have errors on Networking and HTML/Javascript parts.

It's strange that your browser showed the chart but failed to got chart data. The more strange thing is that I don't respond 404 for "putline" and "chart.php".

Let's give it a last try by running it in AP mode.

Browse to
http://brewpi.local/erasewifisetting

If it succeeds, BrewPiLess will restart to wait for selection of WiFI network. Connect to it and choose "AP Mode" instead of choosing your network. After a while, you can connect to the "brewpi" network again.
Once connected, browse to
http://brewpi.com (mDNS doesn't work under AP mode. So, never brewpi.local.)

And see what happens.
 
I only have option of "Soft AP". tried it and couldn't get back to the brewpi page. tried the IP as well the brewpi.com & nothing. I think the soft AP mode switches back after a few minutes...?

Im going to leave it in my small bath room with a heater over night and see if it does any temp control and check the datalog in the am.
 
I only have option of "Soft AP". tried it and couldn't get back to the brewpi page. tried the IP as well the brewpi.com & nothing. I think the soft AP mode switches back after a few minutes...?

Im going to leave it in my small bath room with a heater over night and see if it does any temp control and check the datalog in the am.

No. It wouldn't. The WiFi information was erased and it has no way to connect to your network after that. But, I can't explain your situation. Therefore, I am not sure if I really know what happens.
 
No. It wouldn't. The WiFi information was erased and it has no way to connect to your network after that. But, I can't explain your situation. Therefore, I am not sure if I really know what happens.

I just wanted to say thanks for putting up with me, it's clearly a me issue and your help is much appreciated!

I do have a few other ESP8266 devices (Sonoff plugs) on my network that are connect to Smartthings. On my router they show as "ESP" including the brewpi...
 
I just wanted to say thanks for putting up with me, it's clearly a me issue and your help is much appreciated!

I do have a few other ESP8266 devices (Sonoff plugs) on my network that are connect to Smartthings. On my router they show as "ESP" including the brewpi...

What kind of power supply are you using? It seems like that ESP restarts itself.
 
Tried in Incognito mode today and got the following in JS just as it faulted. (actual web address replaced with XXXXXXXXXXXXX)

bwf.js:2 POST http://XXXXXXXXXXX.com/putline 502 (cannotconnect)invoke @ bwf.js:2send @ bwf.js:2(anonymous function) @ VM34:11
VM34:11 error
 
with new update the webpage looks fine under firefox now, I do not know why :)


EDIT: ok one problem, there is window on top of interface "Loading setting from BrewPi controller.." and I cannot get rid of it. On PC any browser and phone as well.

Screenshot_20170222-232738.jpg
 
with new update the webpage looks fine under firefox now, I do not know why :)


EDIT: ok one problem, there is window on top of interface "Loading setting from BrewPi controller.." and I cannot get rid of it. On PC any browser and phone as well.

oops. I found a trivial bug that doesn't cause error on safari and chrome. It clears a null timer, but Safari and Chrome don't complain about it.

Edit:
I've changed code. Please download again. Don't forget to reload the file.
BTW, I tried with Firfox for Mac, it didn't complain either.
 
Hey, no problem, I am just testing software and reporting bugs! :)

Chrome on windows did complain same as firefox here, I will check the new version after I get home. Thanks!
 
Today I got a comment from the creator of iSpindle, Sam.

I am happy to collaborate with him to make BrewPiLess "compatible" to iSpindle.

Accepting the data from iSpindle and putting gravity readings in the chart isn't a big deal. It could be done in the time of one beer.

Sam has an aggressive proposal: changing the temperature according to gravity reading instead of time. It's surely doable and interesting. However, I am very bad at UI design and need your inputs. Please let me know how you think about it.
 
Today I got a comment from the creator of iSpindle, Sam.

I am happy to collaborate with him to make BrewPiLess "compatible" to iSpindle.

Accepting the data from iSpindle and putting gravity readings in the chart isn't a big deal. It could be done in the time of one beer.

Sam has an aggressive proposal: changing the temperature according to gravity reading instead of time. It's surely doable and interesting. However, I am very bad at UI design and need your inputs. Please let me know how you think about it.


It makes perfect sense really adjusting temp by gravity.

Maybe as an a UI option set target FG at x% attenuation raise to y-temp.

What could also be good would be a RAG system for fermentation Red being OG and then Amber being expected attenuation and green being FG after 2-3 days but also indicating time for dry hop.

Just my starter for 10.

Would love this to merge with Thorraks too though
 
Sam has an aggressive proposal: changing the temperature according to gravity reading instead of time. It's surely doable and interesting. However, I am very bad at UI design and need your inputs. Please let me know how you think about it.

The way I've always envisioned it working is by defining "stabilization" and then making that the marker for the rest of the fermentation profile.

"1 day after SG stabilizes, move to 30 deg"
"3 days after SG stabilizes, move to 22 deg"
...etc.

The trick is defining what constitutes stabilization.

Alternatively, you could have the user enter an "expected FG" and then set points based on how close you are getting to the expected FG, but that assumes the user has some decent basis for specifying the expected FG. I've... had quite a few beers that I didn't come close to the expected FG on, unfortunately.

I'll be curious to see how you end up approaching this -- Integrating the Tilt Hydrometer into Fermentrack is a personal goal of mine. I have a Tilt sitting on my desk, but have yet to use it because I don't have a spare device to receive the data. :)

Would love this to merge with Thorraks too though

There's advantages to both systems, and having both available makes the BrewPi universe stronger overall IMO. I'd love to have the ability to directly control individual controllers via a web interface on the controller, but it would require some way for the controller to communicate with BrewPi-script (and then having BrewPi-script communicate with the web interface to some degree) in a way that isn't initiated by BrewPi-script. Certainly possible, but it's a paradigm shift from the way things are integrated now.

Of course - just because things would have to work differently in the future doesn't mean that's not the best way to go. That's one of the great things about open source software - given enough time you can take any of these projects anywhere you think they should be.
 
The way I've always envisioned it working is by defining "stabilization" and then making that the marker for the rest of the fermentation profile.

"1 day after SG stabilizes, move to 30 deg"
"3 days after SG stabilizes, move to 22 deg"
...etc.

The trick is defining what constitutes stabilization.

Alternatively, you could have the user enter an "expected FG" and then set points based on how close you are getting to the expected FG, but that assumes the user has some decent basis for specifying the expected FG. I've... had quite a few beers that I didn't come close to the expected FG on, unfortunately.

I would prefer letting user specify the gravity. The gravity doesn't have to be the FG. That's more flexible. I won't do "smart" things like guessing the finished FG because I am not smart enough and the code I write can't be smarter than me.

I have different view of "stabilization". From the charts I have seen on the internet, the gravity readings aren't very stable. Some kind of low-pass filter should be used.

One big pitfall for the programmer to design UI is that he will think the best way for implementation instead of the best way for user friendly. The problem I am thinking is how to use gravity readings in current implementation.
The way for BrewPi to specify Beer Profile is not like "hold T1 for X days", but
Day X @ T1
Day Y @ T2

Two advantages I know of:
1. easy to specify the speed of temperature change in the same way as holding temperature.
eg. Day 0 @ 68, Day 2 @ 34 => lower temperature form 68 to 34 in 2 days
Day 0 @ 68, Day 2 @ 68 => hold temperature at 68 for 2 days.
2. easy to implement by simple interpolation.

I usually only use Beer profile for control of temperature change. Changing temperature by time without checking gravity doesn't seem right to me.

The to-be-designed interface should be able to specify
- holding temperature for a duration
- changing temperature from T1 to T2 in N days when the gravity is lower than a value or after a duration

I haven't think of a good way to present the profile yet.

I'll be curious to see how you end up approaching this -- Integrating the Tilt Hydrometer into Fermentrack is a personal goal of mine. I have a Tilt sitting on my desk, but have yet to use it because I don't have a spare device to receive the data. :)

I thought that RPI could support bluetooth dongle. There's already hack to log Tilt data in BrewPi's log.
 
Did anyone try to use this system with battery or powerbank? Just for temperature logging? I have a nice place without electricity in the basement and seems to be stable in temperature and I would like to log a temperature of bucket there to test :)
Should 2000mah powerbank be good? I know there is no deep sleep implemented etc but maybe without it it does not drain a lot of battery?
 
Did anyone try to use this system with battery or powerbank? Just for temperature logging? I have a nice place without electricity in the basement and seems to be stable in temperature and I would like to log a temperature of bucket there to test :)
Should 2000mah powerbank be good? I know there is no deep sleep implemented etc but maybe without it it does not drain a lot of battery?

I bet 2000mah won't survive through 24 hr.
 
Could this be used on Sonoff? or is the Sonoff flash to small @ 8Mbite/1Mbyte?
 
Could this be used on Sonoff? or is the Sonoff flash to small @ 8Mbite/1Mbyte?

1M bytes is too small for local log. Even without local log, it barely fits.

The program is around 490k. Double space is needed for OTA update, and some configuration is stored in SPIFFS.

It's possible, but I don't recommend it.
 
Is there anyway to change the gpio's using the .bin? I cannot for the life of me get Arduino to work for me (I would just edit config.h) i get so many errors i don't know where to start.
 

Latest posts

Back
Top