calvinmclean / stagg-ekg-plus Goto Github PK
View Code? Open in Web Editor NEWPython for interacting with the Fellow Stagg EKG+ Electric Kettle
License: MIT License
Python for interacting with the Fellow Stagg EKG+ Electric Kettle
License: MIT License
Hello! This isn't really an issue per se but wanted to add this in case it helps anyone else. The iOS app at least (not sure about Android) doesn't tell you the MAC address so here's how I found it.
From a terminal on the Pi where I'm running homebridge I ran hcitool lescan
. and look for a line that looks something like "41:55:55:93:3A:79 FELLOW". That will be the MAC address you want to put into api.py.
With that setup the homebridge plugin is working, so thanks!
I keep getting the following in the homebridge log:
[4/2/2023, 8:30:10 PM] [Kettle] calling getTargetHeatingCoolingStateCharacteristicHandler
[4/2/2023, 8:30:10 PM] [Kettle] calling getCurrentTemperatureHandler
[4/2/2023, 8:30:10 PM] [Kettle] calling getTargetTemperatureHandler
[4/2/2023, 8:30:10 PM] [Kettle] calling getTemperatureDisplayUnitsHandler 1
[4/2/2023, 8:30:10 PM] [Kettle] getTargetHeatingCoolingState result: undefined
[4/2/2023, 8:30:10 PM] [homebridge-kettle] This plugin generated a warning from the characteristic 'Target Heating Cooling State': characteristic value expected valid finite number and received "undefined" (undefined). See https://homebridge.io/w/JtMGR for more info.
[4/2/2023, 8:30:10 PM] [Kettle] getCurrentTemperatureHandler result: undefined
[4/2/2023, 8:30:10 PM] [homebridge-kettle] This plugin generated a warning from the characteristic 'Current Temperature': characteristic value expected valid finite number and received "NaN" (number). See https://homebridge.io/w/JtMGR for more info.
[4/2/2023, 8:30:10 PM] [Kettle] getTargetTemperatureHandler result: undefined
[4/2/2023, 8:30:10 PM] [homebridge-kettle] This plugin generated a warning from the characteristic 'Target Temperature': characteristic value expected valid finite number and received "NaN" (number). See https://homebridge.io/w/JtMGR for more info.
Is there any way to confirm that the stagg-ekg-plus scrypt is connecting to the kettle via bluetooth? I put the mac address of the kettle into api.py.
Thank you! Would love to make this work.
Hey there!
I have successfully installed your plugin – thank you for making it, it works great!
I just have one question – every time I go into control center/the home app activate the kettle, the kettle is reporting as 'on' (e.g. 'heating to 212°'). I then have to press the button to turn it 'off', and then again to turn it on (which then, will actually turn it on).
Is this normal? I also find that when I go to IPADDRESS:8000/state, that it is always displaying '1'.
Cheers!
This seems to work for a short period of time but it loses connection. Is there something I am missing?
POST REQUEST RECEIVED
/state
Received request: {'value': '1'}
Turning kettle ON
----------------------------------------
Exception happened during processing of request from ('127.0.0.1', 41938)
Traceback (most recent call last):
File "/usr/lib/python3.7/socketserver.py", line 316, in _handle_request_noblock
self.process_request(request, client_address)
File "/usr/lib/python3.7/socketserver.py", line 347, in process_request
self.finish_request(request, client_address)
File "/usr/lib/python3.7/socketserver.py", line 360, in finish_request
self.RequestHandlerClass(request, client_address, self)
File "/usr/lib/python3.7/http/server.py", line 646, in __init__
super().__init__(*args, **kwargs)
File "/usr/lib/python3.7/socketserver.py", line 720, in __init__
self.handle()
File "/usr/lib/python3.7/http/server.py", line 426, in handle
self.handle_one_request()
File "/usr/lib/python3.7/http/server.py", line 414, in handle_one_request
method()
File "api.py", line 44, in do_POST
stagg.on()
File "/home/pi/stagg-ekg-plus/stagg_ekg_plus/ekg.py", line 78, in on
self.characteristic.write(bytes.fromhex("efdd0a0000010100"), withResponse=False)
File "/usr/local/lib/python3.7/dist-packages/bluepy/btle.py", line 200, in write
return self.peripheral.writeCharacteristic(self.valHandle, val, withResponse)
File "/usr/local/lib/python3.7/dist-packages/bluepy/btle.py", line 542, in writeCharacteristic
self._writeCmd("%s %X %s\n" % (cmd, handle, binascii.b2a_hex(val).decode('utf-8')))
File "/usr/local/lib/python3.7/dist-packages/bluepy/btle.py", line 302, in _writeCmd
raise BTLEInternalError("Helper not started (did you call connect()?)")
bluepy.btle.BTLEInternalError: Helper not started (did you call connect()?)
----------------------------------------
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.