I’ve been programming Bluetooth software to communicate with Govee thermometers for a couple of years now and still learning how Bluetooth works. I’ve been working with several devices, H5074, H5075, H5174, H5177, plus the meat thermometers H5182 and H5183. (I’ve got pictures of each at https://github.com/wcbonner/GoveeBTTempLogger/tree/master/DeviceImages)
I’ve liked the H5074 the most because of its compact size and the fact that it uses a CR2477 lithium battery for power and seems to run for close to two years without replacement. It also has been surprisingly robust when placed inside my freezer or outside on a balcony railing.
The thermometers broadcast their data over Bluetooth Low Energy (BLE) advertisements. Each of these thermometers stores the previous 20 days or more of data internally and can also be queried directly to retrieve the stored data. I only recently got the code for the direct connection download working. To connect directly the host must stop listening to advertisements, make the connection, download the data, close the connection, and then go back to scanning for advertisements.
There are two modes the host scanning can be set to, Active or Passive. Active mode is the mode I’ve been using for most of this time, and I only recently investigated the differences between Active and Passive.
Passive mode is exactly what it sounds like. The Bluetooth stack only listens for advertisements and makes them available to my program.
Active mode is more complicated. Every time the Bluetooth stack receives an advertisement, it sends a query message to the device that advertised asking for more details. This is all done by the stack with no visibility to my program. It may affect timing of messages arriving or even over the air collisions. I’ve not found detailed descriptions related to this.
The different Govee thermometers appear to operate differently. The H5075, H5174, and H5177 broadcast their temperature, humidity, and battery data while the H5074 only sends the data in a secondary response. This means that data can be gathered from the first three with a host running in passive mode, while a host running in active mode is required to get the data from the H5074. This is unfortunate in a noisy Bluetooth environment because it means that the host itself is adding to the Bluetooth noise.
Because I can’t seem to stop playing with the Govee line of Bluetooth thermometers, when this model came on sale for less than $20 I added it to my Amazon cart.
I knew that the Bluetooth protocol would be different purely based on multiple sensors, but I wanted to play with it anyway. With less than a month since I’d previously figured out a device, I was able to figure this one out in less than an hour, though I still don’t know the battery strength indicator in either this or the H5183 I decoded last month. I’ve added the code to my monitoring program https://github.com/wcbonner/GoveeBTTempLogger/ but have not yet published the changes. The existing code is designed around a single temperature, humidity, and battery reading per device. Even the H5183 broke the model slightly because it has two temperatures, current and alarm, and no humidity. I’m rethinking my data storage to be able to be more expandable, while still being backwards compatible as far as the log files, and will publish the new code when I’ve got it working.
This unit has the advantage of a display over the H5183. It can be used without connecting to a phone at all. You can turn it on, set the alarms, and monitor what’s going on. The one thing I did not figure out how to do using the buttons was to change the display from °F to °C, which I wanted to do to simplify debugging. Using the app I was able to update the settings and view the details.
Govee H5182 Settings
Details from Amazon:
Remote Monitoring: With this wireless grill meat thermometer, you can spend less time waiting and more time multitasking within a 230ft Bluetooth range, Pull out your phone and check the meat temperatures of your grill, smoker, and oven at any time
Meat Temperature Settings: Govee Home App offers USDA-recommended food temperatures with various doneness levels for foods such as beef, lamb, chicken, pork, turkey, and more, Grill more efficiently, whether you’re a beginner or a professional
Smart Alerts: Avoid the risk of overcooking your food, Once your preset temperature is out of range, your meat thermometer will beep and send an instant notification to your phone via the Govee Home App
Food Grade Probes: Our food grade 304 stainless steel thermometer probes have an accuracy of ±1.8°F/1°C to reliably monitor the doneness of your food (under 302℉) ,*Please remember not to touch the probes immediately after use
Easy to Place: This Bluetooth meat thermometer has a strong magnetic backing and a folding stand to easily set up on the grill, smoker and oven when barbecuing, There is also a large backlight screen to make it easier to read at night
There is also a single probe version of this thermometer. I expect it works similar to this unit, but the price savings made it less interesting to me since I already have the H5183 in my kitchen.
I was playing with a couple of brand new H5074 devices and realized that the iOS app now includes two new charts, Dew Point, and VPD.
VPD
The new devices report as hardware version 2.00.01 firmware version 1.00.01. My older devices all report hardware version 1.00.01 and firmware version 1.01.00.
The pressure and dew point are available in both the new and old H5074 devices, but not with any of the other units I’ve got connected. (H5177 or H5075)
I’ve not been able to find details on the data. I don’t know if it’s packed into the BLE advertising data, or only available in the connected download data.
The Bluetooth communication protocol is different from any of the other devices I’ve got, but after a day of staring at raw data I was able to figure out some of the details and add support to my monitoring program https://github.com/wcbonner/GoveeBTTempLogger/ . The Bluetooth announcements from the device include both the current temperature and the set alarm temperature. I’ve not yet figured out the battery strength data. The phone app displays the battery, so I know it should be available.
There’s an orange button on one side to turn the unit on. Hold for three seconds. It will beep indicating it’s on. The LED will start flashing green, and the device will periodically send Bluetooth announcements including the temperature and alarm temperature. If you connect to the device with the phone app, the LED will switch to flashing blue, indicating that it’s in a connected state. While the device is in a connected state, it doesn’t not send out announcements. To return it to standard mode, simply exit back to the top level of the app. The app will still alarm when the probe gets to set temperature. Holding the button for three seconds when it’s on will turn it off, with beeps to confirm the change.
A nice feature of this device is that it has a magnet built in, enough to hold the device to the front of a metal oven.
Details from the Amazon listing:
Useful Smart Alerts: If temperatures fall out of your preset range, an alarm will sound, and you will get a phone alerts notification via the Govee Home app. The probe measuring range is 0° to 300°C /32° to 572°F. Note: press and hold the orange button for 3 seconds to power on.
Convenient Remote Monitoring: Tired of waiting near a hot grill, With a 230ft/70m smart Bluetooth wireless control range(no obstructions), you are free to relax and check your temperatures on your smartphone at a glance. Remember to remove the protective tip before use.
Performance Review: Detailed temperature data and easy-to-read charts are generated within 2 hours. (Charts can’t be stored/downloaded) Perfect for a quick review or an in-depth analysis of temperature performance. Improve your cooking and temperature with calibration at ±5°C.
Temperature Made Easy: 28 temperature recommendations for 14 types of foods take the hassle out of cooking. Ideal for both beginner cooks and pro chefs.
Practical Features: Temperature switching between Fahrenheit and Celcius. (The default unit is Fahrenheit) Mute alarm function and countdown timer on the Govee Home app. The magnetic back can easily be attached to the refrigerator, oven or grill, or any other metal surface. Note: Please keep the meat thermometer unit safe from heat sources and very hot surfaces to protect its internal batteries and exterior shell.
After playing with Govee thermometers H5074 and H5075, I came across the H5177 model with similar specs but with a larger display including some buttons and backlight. I decided to give it a try, just to see if it used the same protocol as the previous units.
wim@WimPi4-dev:~ $ sudo ../visualstudio/projects/GoveeBTTempLogger/bin/ARM/Debug/GoveeBTTempLogger.out -v 2 | grep E3:5E:CC:21:5C:0F
[2020-11-09T00:26:34] 44 E3:5E:CC:21:5C:0F 06 (UUID) 0A18F5FE88EC (Name) Govee_H5074_5C0F
[2020-11-09T00:26:34] 26 E3:5E:CC:21:5C:0F 88EC000103DE106402 (Temp) 45.842°F (Humidity) 43.18% (Battery) 100%
[2020-11-09T00:26:35] 44 E3:5E:CC:21:5C:0F 06 (UUID) 0A18F5FE88EC (Name) Govee_H5074_5C0F
[2020-11-09T00:26:35] 42 E3:5E:CC:21:5C:0F 4C000215494E54454C4C495F524F434B535F485750740F5CC2 (Apple) (UUID) 494E54454C4C495F524F434B535F4857 (Major) 5074 (Minor) 0F5C (RSSI) C2
^C* SIGINT: Caught Ctrl-C, finishing loop and quitting. *
GoveeBTTempLogger Version 1.20201016-1 Built on: Oct 16 2020 at 12:13:28 (exiting)
wim@WimPi4-dev:~ $ sudo ../visualstudio/projects/GoveeBTTempLogger/bin/ARM/Debug/GoveeBTTempLogger.out -v 2 | grep A4:C1:38:13:AE:36
[2020-11-09T00:27:05] 46 A4:C1:38:13:AE:36 GVH5075_AE36 (UUID) 88EC (Flags) 05 (Manu) 88EC0002859F4900 (Temp) 61.7502°F (Humidity) 27.9% (Battery) 73%
[2020-11-09T00:27:05] 42 A4:C1:38:13:AE:36 4C000215494E54454C4C495F524F434B535F48575075F2FFC2 (Apple) (UUID) 494E54454C4C495F524F434B535F4857 (Major) 5075 (Minor) F2FF (RSSI) C2
^C* SIGINT: Caught Ctrl-C, finishing loop and quitting. *
GoveeBTTempLogger Version 1.20201016-1 Built on: Oct 16 2020 at 12:13:28 (exiting)
wim@WimPi4-dev:~ $ sudo ../visualstudio/projects/GoveeBTTempLogger/bin/ARM/Debug/GoveeBTTempLogger.out -v 2 | grep A4:C1:38:0D:3B:10
[2020-11-09T00:27:35] 46 A4:C1:38:0D:3B:10 GVH5177_3B10 (UUID) 88EC (Flags) 05 (Manu) 01000101029D1A64
[2020-11-09T00:27:35] 42 A4:C1:38:0D:3B:10 4C000215494E54454C4C495F524F434B535F48575177F2FFC2 (Apple) (UUID) 494E54454C4C495F524F434B535F4857 (Major) 5177 (Minor) F2FF (RSSI) C2
^C* SIGINT: Caught Ctrl-C, finishing loop and quitting. *
GoveeBTTempLogger Version 1.20201016-1 Built on: Oct 16 2020 at 12:13:28 (exiting)
While I was able to see the device data in Bluetooth advertisements, it’s got some differences. The code snippets above are cherry picked from one device each that I know how to interpret and the new device last.
The Manufacturer data in the new H5177 device doesn’t start with the same 88EC signature, but at least appears to be the same length as H5075, and one byte shorter than the data packet from the H5074.
17.1C 28% matches with (Manu) 01000101029D1664. If anyone can point me to a quick decode algorithm, I’ll update my project to support this device very quickly.
I’ve now learned some details on BLE, and have written a program that listens for BLE advertisements from either type of thermometer and logs the temperature and humidity in a text file. The code for my project is available on GitHub. https://github.com/wcbonner/GoveeBTTempLogger
The same program can also be called to get the last value from the log and produce output compatible with MRTG. MRTG is not the best method for graphing these temperatures, because all graphs start with zero on the Y axis, and neither the temperature or humidity is likely to be near zero.
MRTG graph of Temperature and Relative Humidity
My program seems to receive advertisements from each thermometer about every ten seconds. I’ve had a friend running the code in his location with a different set of thermometers and it doesn’t get advertisements nearly as frequently. I don’t know if that’s just because environment is different, or if there’s something else going on.
Last week I came across a deal on a small thermometer with display and Bluetooth access for under $10 so I had to give it a try. The fact that the data is available via bluetooth instead of via a web service was a major selling point for me. I am hoping to be able to to log the data via a Raspberry Pi4.
GVH5070 near my Raspberry Pi4
I installed the Govee Home app on my iPhone and it was able to find the device, communicate with it, and pull both current and accumulated data.
When I attempted to find it from my Pi4 it was much more difficult. I live in an apartment with units all around. I’m not just dealing with my own devices that may be visible, but my neighbors as well.
I managed to find the device using linux command line tools, but was not able to successfully connect. A friend suggested BLE Scanner 4.0 for my iPhone for discovering the details, and it was at least able to confirm what I should be looking for using the linux command line tools. I still had timeout issues with the iPhone app, but at least was able to confirm that I could connect to the device and retrieve GUID information.
This is my first time attempting to gather data from a Bluetooth device. I’m still in the research and test phase. I’m listing a bunch of the URLS I’ve found that have been helpful.
From the command line on my Pi4 I already had the tools installed to try several Bluetooth commands. I believe they were installed as part of the bluez package. The first two commands below get details on the Raspberry Pi Bluetooth hardware, then the hcitool lescan command produced a lot of devices, and I found the line referencing the GVH5075 so I could use the address in further commands.
Another command that I attempted before I used the hcitool command was the bluetoothctl command. It scrolls a lot of data, but now that I have an idea what I’m looking at, I may be able to see announcement data from the thermometer periodically in the stream by filtering just to see the data coming from the MAC address.