onokje / node-red-contrib-tesla

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

No response to maxDefrost #15

Open elgeniskogen opened 3 years ago

elgeniskogen commented 3 years ago

I am able to to use most of the commands, but for MaxDefrodt the node gives no output. I have tried msg.commandArgs= { "onoff": true }

And a lot of other command.

frownbreaker commented 3 years ago

I'm not sure it works like that. I think the function is a toggle to turn the defrost setting to MAX or PREVIOUS value.

maxDefrost() toggles climate between Max Defrost and the previous setting

From: https://github.com/mseminatore/TeslaJS

If you want to defrost the car. Get the climate setting valid they are what you need, if not toggle maxDefrost() then call the climate on, and get climate info to track progress. You may also set steering wheel heating if fitted and enabled steeringHeater: commandArgs.level

Like maxDefrost() the steering heating is an option that when enabled will be activated when the climate control is engaged.

aurelien93 commented 2 years ago

Yes There is error in script need to modify in this projet tesla.js case 'maxDefrost': return tjs.maxDefrostAsync({authToken, vehicleID}); to case 'maxDefrost': return tjs.maxDefrostAsync({authToken, vehicleID}, commandArgs.onoff);

And in library teslaJS in file teslajs.js exports.maxDefrost = function steeringHeater(options, onoff, callback) { to exports.maxDefrost = function maxDefrost(options, onoff, callback) {

And it's work

TomNijsen commented 2 years ago

Still not working on my NodeRED flow... Would really like this function to provide winter conditioning to our shared car user group in the coming months...

takipo commented 2 years ago

i do have the same problem when i send commands. Response is {"reason":"","result":true} but nothing happens.

Vinisz commented 2 years ago

Reading the above, I'm not sure at the moment if it can work or if it is a bug. Can someone clarify ? do I need to change commands or wait for a fix ?