Tesla Charger alternative firmware
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
Thanks. I unpacked the file and it begins with a lower case ‘c’ already. I repacked it and sent it to my home computer for uploading when I’m back.
When I run index.html from my desktop in both safari and chrome, I don’t see anything on the page. I’m on my work Mac right now, JavaScript is indeed enabled, perhaps it’s time to try a windows machine.
When I run index.html from my desktop in both safari and chrome, I don’t see anything on the page. I’m on my work Mac right now, JavaScript is indeed enabled, perhaps it’s time to try a windows machine.
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
No gauges.html generates dynamically but index.html should show something. I have seen it working on Safari, not sure what the deal is.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
Ah yes index.html works normally but without the plot, thanks
Screen grab with error log from Chrome. Should I just load the unpacked file directly? The plot chart shows up when I unpack within the same directory and reload index.html
Screen grab with error log from Chrome. Should I just load the unpacked file directly? The plot chart shows up when I unpack within the same directory and reload index.html
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
ok, same as here. The other errors are just because its not running on the webserver.
What does the error log show when opening on 192.168...?
What does the error log show when opening on 192.168...?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
Javascript errors when connected to the ESP:
And after pressing Start Plot:
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
No error message about loading chart.min.js but then it doesn't find the "Chart" class.
Not finding subscription.js is normal when you're not subscribed to anything. Maybe add it as an empty file, see if that helps?
Not finding subscription.js is normal when you're not subscribed to anything. Maybe add it as an empty file, see if that helps?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
- Jack Bauer
- Posts: 3564
- Joined: Wed Dec 12, 2018 5:24 pm
- Location: Ireland
- Has thanked: 1 time
- Been thanked: 93 times
- Contact:
Re: Tesla Charger alternative firmware
Just to update from my end, full charge (about 8kwh) on the E39 this morning without a single drop off.
I'm going to need a hacksaw
Re: Tesla Charger alternative firmware
Mine is happily charge cycling as intended with no unwanted behavior after fixing my self induced SDO collisions. Cant really comment on the drop out as it's been charging overnight and my garage wifi connection hasnt been working well.
Formerly 92 E30 BMW Cabrio with Tesla power
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
Thats good news.
I hope Bryson gets the plot running so we can hunt the glitch down. I'm suspecting one of the chargers raises an error flag. Anyone know the conditions that raise the error bit?
Could it be a CAN problem? Bryson have you routed CAN externally? If so, is it properly terminated?
I hope Bryson gets the plot running so we can hunt the glitch down. I'm suspecting one of the chargers raises an error flag. Anyone know the conditions that raise the error bit?
Could it be a CAN problem? Bryson have you routed CAN externally? If so, is it properly terminated?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
I haven’t routed CAN externally - other than modifying the C3 capacitor I’m running an unchanged v5 board. I’ll boot into windows tonight and give that a shot, some googling shows that there can be many causes of not finding Chart, and sometimes it is related to browser choice.
Are you guys using PCs? IE browser?
Are you guys using PCs? IE browser?
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- Jack Bauer
- Posts: 3564
- Joined: Wed Dec 12, 2018 5:24 pm
- Location: Ireland
- Has thanked: 1 time
- Been thanked: 93 times
- Contact:
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
Troubles continue. I tried loading locally from a windows machine using Chrome, IE and firefox with the same net results:
- unpacking chart.min.js.gz in the local directory gets the plot to show (but doesn’t work when I load the unpacked file to SPIFFS)
- same errors from the console log in Firefox on my PC: At this point I’ll start investigating different ways of loading that source file, as it seems that’s where the immediate problem is. Maybe I can persuade a software dev at the office to help me out..
edit: GOT IT. I reprogrammed the ESP and it's working as designed now, finally. My guess is that I must not have left enough room for the file system in the flash. I went with 512KB for the filesystem this time around.
Tomorrow am I'll get the car on the charger for a proper log, whew.
- unpacking chart.min.js.gz in the local directory gets the plot to show (but doesn’t work when I load the unpacked file to SPIFFS)
- same errors from the console log in Firefox on my PC: At this point I’ll start investigating different ways of loading that source file, as it seems that’s where the immediate problem is. Maybe I can persuade a software dev at the office to help me out..
edit: GOT IT. I reprogrammed the ESP and it's working as designed now, finally. My guess is that I must not have left enough room for the file system in the flash. I went with 512KB for the filesystem this time around.
Tomorrow am I'll get the car on the charger for a proper log, whew.
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
Re: Tesla Charger alternative firmware
Re-configured my garage wifi extender. The log doesn't seem to show any drop out. The sample interval is every 10 seconds, so it may miss something.
Formerly 92 E30 BMW Cabrio with Tesla power
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
Jon, it looks like you're cutting your charge off while still at pretty high current. Are you going to >90% SOC? I didn't see the issue appear until later in the charge taper curve.
Johannes, a couple plot logs attached. I only logged phase 3 current to keep the plot a little cleaner: And logging state vs the three phase currents:
Johannes, a couple plot logs attached. I only logged phase 3 current to keep the plot a little cleaner: And logging state vs the three phase currents:
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
ah, it worked
So what we see in the top plot:
It charges 3A (presumably 9A total). The flags toggle between 1 and 5. Firmware adds 4 every 100ms and checks if the next CAN message resets it back to 1 (or 0 or 2). Timeout check. All normal so far, no timeouts, for that it would need to stay at 5 for 2s.
Then the current tapers down quite controlled and about 1-2s later charger 2 signals an error. State machine drops out of run mode, restarts all chargers and cycle begins again.
Next plot almost same but charger 3 signals an error, next plot also charger 3. Last plot doesn't show errors, must be outside of plotted range. Only charger that never shows an error is charger 1. Can you try enabling only charger 1? Type "set chargerena 1" into custom command. set chargerena 7 to enable all again.
What have you set udcspnt to? Could it be reaching that and actually it is not a set point but an over voltage limit? Can you
So what we see in the top plot:
It charges 3A (presumably 9A total). The flags toggle between 1 and 5. Firmware adds 4 every 100ms and checks if the next CAN message resets it back to 1 (or 0 or 2). Timeout check. All normal so far, no timeouts, for that it would need to stay at 5 for 2s.
Then the current tapers down quite controlled and about 1-2s later charger 2 signals an error. State machine drops out of run mode, restarts all chargers and cycle begins again.
Next plot almost same but charger 3 signals an error, next plot also charger 3. Last plot doesn't show errors, must be outside of plotted range. Only charger that never shows an error is charger 1. Can you try enabling only charger 1? Type "set chargerena 1" into custom command. set chargerena 7 to enable all again.
What have you set udcspnt to? Could it be reaching that and actually it is not a set point but an over voltage limit? Can you
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
Aha, more plots
So yes it seems charger 1 works good while the others drop out for some reason. Maybe it would be good to disable modules as AC current drops below x A. They might not be happy to charge at too little current?
So yes it seems charger 1 works good while the others drop out for some reason. Maybe it would be good to disable modules as AC current drops below x A. They might not be happy to charge at too little current?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
udcspnt is set to 430V, was 426V, I'm seeing udc on phase 1 get up to 425V via the plot before it ramps back down. I've also set udclim to the same 430 for now. Pack is currently sitting around 410V with no charge activity.
I agree with your suspicion about turning on fewer phases deliberately at lower current. The odd part is that it seemed to work fine when I had iac set to a lower number previously when I had the max stuck at 16. Here's a plot with just phase 1 turned on:
I agree with your suspicion about turning on fewer phases deliberately at lower current. The odd part is that it seemed to work fine when I had iac set to a lower number previously when I had the max stuck at 16. Here's a plot with just phase 1 turned on:
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
Ah ok so you're right on the edge of what the chargers can do. So with chargerena=1 you also don't get continuous charging but no error flags either.
I can write code for shutting down chargers later, will post the binary here.
I can write code for shutting down chargers later, will post the binary here.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
The flag does drop to 0 with chargerena=1, that would mean I’m still getting an error, right? Left side of the above plot
‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
-
- Posts: 179
- Joined: Sat Jan 25, 2020 6:22 am
- Location: California
- Has thanked: 1 time
- Been thanked: 4 times
Re: Tesla Charger alternative firmware
One more update. When I set aclim to 20A, I get the charge cycling again:
When I set aclim to 15A, I got a steady charge for a couple minutes (at 1.5A/phase = 4.5A?), then cycling began again. udc is showing about 420v when this happens:
Off to work now, I don't think I'll be able to test more until tonight or tomorrow. I'm left wondering if these can't actually charge above 420V‘70 jag XJ6, GS450h drivetrain, 102s Tesla pack
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
Possible, in a Tesla they would never go above 400V I suppose? Maybe if you lower udcspnt to 420V it will just do a CV charge. 4.12V per cell. I can also compile a software with the limit set to 440V, maybe it will accept that.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
- mdrobnak
- Posts: 692
- Joined: Thu Mar 05, 2020 5:08 pm
- Location: Colorado, United States
- Has thanked: 1 time
- Been thanked: 5 times
Re: Tesla Charger alternative firmware
They do go over 400, not sure about 420. I know the CHAdeMO adapter starts at 408V...
- Jack Bauer
- Posts: 3564
- Joined: Wed Dec 12, 2018 5:24 pm
- Location: Ireland
- Has thanked: 1 time
- Been thanked: 93 times
- Contact:
Re: Tesla Charger alternative firmware
I have designed a new controller for the Gen3 Tesla charger based on the STM32F103 which can use the new firmware. Will also be 100 euros cheaper for the full kit. Full sources for the board on github : https://github.com/damienmaguire/Tesla-Gen3-Charger
I'm going to need a hacksaw
- johu
- Site Admin
- Posts: 6227
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 228 times
- Been thanked: 1272 times
- Contact:
Re: Tesla Charger alternative firmware
Yay
Now I should increase the parameter limits so you can make use of the mighty 18 kW. What would be the new limits? Would be neat to be able to detect whether we are running gen2 or gen3.
Now I should increase the parameter limits so you can make use of the mighty 18 kW. What would be the new limits? Would be neat to be able to detect whether we are running gen2 or gen3.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9