onokje / node-red-contrib-tesla

Node red nodes to control Tesla vehicles and devices
MIT License
21 stars 11 forks source link

setScheduledCharging format #65

Open ihitsov opened 1 year ago

ihitsov commented 1 year ago

I am not sure how to send a message to the setScheduledCharging. I am sending this via a function: // msg.command = 'setScheduledCharging'; msg.commandArgs = { enable: 1, time: "2 AM" }; return msg;

It does seem to kind of work, but no matter what I send, in the app it changes it to 00:00. I tried different time formats (02:00, 2:00AM, 02:00 AM etc.), but same result. Any ideas what I am doing wrong? Also tried enable: true, didnt work either. Thanks in advance!

GaPhi commented 1 year ago

If I remember well, time is numeric (minutes since midnight local time)

Le mer. 5 juil. 2023 à 21:22, Ivaylo Hitsov @.***> a écrit :

I am not sure how to send a message to the setScheduledCharging. I am sending this via a function: // msg.command = 'setScheduledCharging'; msg.commandArgs = { enable: 1, time: "2 AM" }; return msg;

It does seem to kind of work, but no matter what I send, in the app it changes it to 00:00. I tried different time formats (02:00, 2:00AM, 02:00 AM etc.), but same result. Any ideas what I am doing wrong? Thanks in advance!

— Reply to this email directly, view it on GitHub https://github.com/onokje/node-red-contrib-tesla/issues/65, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADUNWNNJBMU4KXH2XWIPDCLXOW5IBANCNFSM6AAAAAAZ7L7VEE . You are receiving this because you are subscribed to this thread.Message ID: @.***>

ihitsov commented 1 year ago

Thank you, this works!

GaPhi commented 1 year ago

'enable' should also be a boolean