Code: Select all
modulelimcur = accurlim * 1.5;
Code: Select all
modulelimcur = parameters.currReq;
Code: Select all
modulelimcur = accurlim * 1.5;
Code: Select all
modulelimcur = parameters.currReq;
Yes I mean something like that but I wouldn't know how to code it unfortunately. If you would be willing to include this I would be happy to test
It is the code here for Damien's earlier boards with SAM3X chip:
Okay maybe got time this week, I have a due to test with.m.art.y wrote: ↑Wed Jan 04, 2023 9:27 pm It is the code here for Damien's earlier boards with SAM3X chip:
https://github.com/damienmaguire/Tesla- ... rgerV4.ino
Thanks, very excited, happy to test on my charger. I was just thinking maybe my guess was wrong that the jitter is causing the charger to keep dropping the current. Could it be that as the mcu is executing the calculation the accurlim parameter goes 'missing' somehow for a split second?
Well I have tested this new code with a 10A granny cable so far and I have to say this has made a difference. Previously the current had been dropping to 1.33Aac then rising up again, now it still drops but only to about 8A when cable is reporting 10A. This then seems apparent where the problem was: once every 5 accurlim readings or so a 0 is dropped in there from somewhere. When using accurlim directly to calculate modulelimcur this then resulted in charger dropping current right down. Rolling average only takes a dip by couple amps . Would you have any idea where this 0 is coming from or how to eliminate it?tom91 wrote: ↑Sat Jan 07, 2023 7:14 pm Updated code with an averaging filter. https://github.com/Tom-evnut/Tesla-Char ... aChargerV4