Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set charge power #22

Open
Urs-Eppenberger opened this issue Oct 29, 2021 · 10 comments
Open

set charge power #22

Urs-Eppenberger opened this issue Oct 29, 2021 · 10 comments
Labels
enhancement New feature or request

Comments

@Urs-Eppenberger
Copy link

I just upgraded my Tesla Model 3 with SW version 2021.36.5.5
The release note states, that there is now the possibility to configure the charging power via the Tesla App. I checked and this seems true. There is now a new configuration option in the iPhone Tesla App.

If the App can control charging power, then this might be possible via the API used by this node-red node too.
Could you try to figure this out and update the implementation?
setChargePower as a new option name?

Kind regards,
Urs.

@onokje
Copy link
Owner

onokje commented Nov 1, 2021

It would have to be implemented in the TeslaJs library first. But if they have it then yes, i can add it easily here as well.

@onokje onokje added the enhancement New feature or request label Nov 1, 2021
@TomNijsen
Copy link

Someone did develop something => mseminatore/TeslaJS#282

@cramlr
Copy link

cramlr commented Dec 31, 2021

it's been added to teslaJS, and it appears in the list of available commands in node-red, but I get this error:

"TypeError: tjs.setChargingAmpsAsync is not a function"

@Urs-Eppenberger
Copy link
Author

Urs-Eppenberger commented Jan 3, 2022

I tested it today. It works with the most recent version of node-red-contrib-tesla.
Here is the very minimalistic flow I did:

[{"id":"6d1577b73768837c","type":"inject","z":"4e139d26.c717a4","name":"Charge Amps","props":[{"p":"commandArgs.amt","v":"8","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":130,"y":2220,"wires":[["5edb4b8f0e8f20e7"]]},{"id":"5edb4b8f0e8f20e7","type":"tesla-api","z":"4e139d26.c717a4","teslaConfig":"cca88314.8bcf68","command":"setChargingAmps","name":"","vehicleID":"xxxxxxxxxxxxxxx","autoWakeUp":true,"x":320,"y":2220,"wires":[["a6c93a1d65a24ee9"]]},{"id":"a6c93a1d65a24ee9","type":"debug","z":"4e139d26.c717a4","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":490,"y":2220,"wires":[]},{"id":"cca88314.8bcf68","type":"tesla-config","email":"bla.bla@bla.bla"}]

@Urs-Eppenberger
Copy link
Author

Since it works now, I close this issue.
Many thanks and congratulation to the developer.

@cramlr
Copy link

cramlr commented Jan 4, 2022

I'm still getting the error even running the sample flow above

"TypeError: tjs.setChargingAmpsAsync is not a function"

I'm using node-red 2.1.4, node-red-contrib-tesla 2.0.0, and my Tesla is up to date.

Other Tesla commands work fine in my tests (I have not tested many of them though)

Any ideas on what could be amiss?

@Urs-Eppenberger
Copy link
Author

I'm still running at node-red 2.1.3, with node-red-contrib-tesla 2.0.0
The system runs on a RaspberryPi with up-to-date SW.

The error message starts with tjs....
This looks like an abbreviation of Tesla Java Script, which is the underlying library used in this node.

If the author of the node does not react here, I suggest to take this over to the node-red forum. There are tons of javascript experts which might have an idea where to look. Their first answer might be, that you should take this up with the author of the node. I propose therefore, that you mention in your question to the expert pool there, that you already did that.

@cramlr
Copy link

cramlr commented Jan 5, 2022

thanks for the tip @Urs-Eppenberger - for some reason I had another version of teslaJS that was old and took precedence over the node-red version. All is good now

@demod-au
Copy link

demod-au commented Jan 5, 2022

All is good now

How did you fix it? I've still got the error "setChargingAmpsAsync is not a function". I've only ever installed node-red-contrib-tesla.

@demod-au
Copy link

so I got it working. teslajs will not magically update itself. maybe after a new install?

I did an "npm install teslajs"
Then rebooted the docker container.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants