sinricpro / python-sdk

python3 sdk for sinric pro.
https://sinric.pro
23 stars 9 forks source link

Error on RaiseEvent setBrightness #33

Closed desdal closed 2 years ago

desdal commented 2 years ago

I can't send setBrightness raise event becose te file sinric/_events.py have a error.

on line 67:

65            elif event_name == JSON_COMMANDS.get('SETBRIGHTNESS'):
66                queue.put([jsnHandle("setBrightness", deviceId, {
67                    "powerLevel": data.get('brightness')
68                }), 'setBrightness_event_response'])

the solution is to change "powerLevel" to "brightness".

kakopappa commented 2 years ago

Can you raise a PR?

On Tue, 8 Feb 2022 at 8:34 AM desdal @.***> wrote:

I can't send setBrightness raise event becose te file sinric/_events.py have a error.

on line 67:

65 elif event_name == JSON_COMMANDS.get('SETBRIGHTNESS'): 66 queue.put([jsnHandle("setBrightness", deviceId, { 67 "powerLevel": data.get('brightness') 68 }), 'setBrightness_event_response'])

the solution is to change "powerLevel" to "brightness".

— Reply to this email directly, view it on GitHub https://github.com/sinricpro/python-sdk/issues/33, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZAZZW57ZCXVIHCSIPP6ETU2BXJZANCNFSM5NZCCI6A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you are subscribed to this thread.Message ID: @.***>