peterwoj / homebridge-blynk-platform

homebridge plugin to use Blynk
MIT License
10 stars 2 forks source link

High CPU load on Raspberry Pi #15

Closed mpw-eng closed 3 years ago

mpw-eng commented 3 years ago

Please update the sample configuration settings on the repository home page to include this setting ;-)


Hi Peter,

Thank you for developing this plugin!

I've noticed that my Raspberry Pi CPU load goes from 1% to 40% when the plugin is configured on Homebridge. Is this because the device polling frequency is too high?

There is another older blynk-homebridge plugin that is currently broken (I think because it's not exposing all the required characteristics for Homebridge 1.x.x). However, this version allowed the polling frequency for each device to be specified. Could you take a look and perhaps collaborate with the owner of this repository?

Thanks!

Plugin config;

{ "bridge": { "name": "Homebridge XXXX", "username": "xx:xx:xx:xx:xx:xx", "port": 51238, "pin": "000-00-000" }, "accessories": [], "platforms": [ { "name": "Config", "port": 8581, "auth": "form", "theme": "auto", "tempUnits": "c", "lang": "auto", "platform": "config" }, { "platform": "BlynkPlatform", "serverurl": "http://192.168.1.101:8080", "devices": [ { "manufacturer": "Me", "name": "LED Dimmer", "token": "*******************************", "deviceId": "*********", "discover": false, "accessories": [ { "model": "LED Dimmer", "name": "Light", "pintype": "VIRTUAL", "pinnumber": 0, "type": "SWITCH" } ] } ] } ] }

peterwoj commented 3 years ago

Should be fixed, this looks to have been caused by missing correct defaults for pollerseconds. It would default to 1ms

peterwoj commented 3 years ago

Caused by flood on the blynk.server due to not respecting how frequently the status should be checked.