I bought a 2022 FXE in early August with about 500 miles on it. It's been great, but I've found charging to be a bit inconvenient. To keep the battery healthy, I want to let the bike cool off before charging it, and I want to keep the battery at low charge. My commute uses about 35% of the battery, so if I was to charge it every day I'd have to get home, let the bike cool off, go out and plug it in, then come back and unplug it about three and a half hours later. That's a lot of trips out to my shed when I'd rather be in the AC or sleeping.
I put together a circuit that should help make my life easier. It's an ESP32C3 microcontroller with WiFi, a relay, and a USB brick to give me a 5V supply, plus a button and a couple of indicator LEDs. I cut up a 120V cable and ran it through the relay, which is only closed when the microcontroller switches it closed.The ESP hosts a webpage that I connect to and tell it a delay time, to let my bike cool off, and a charge time. So for example, I get home, immediately plug in my bike, and either hit the button for 2 hour cool-off delay and 3.5 hours charge, or fire up a web browser and put in numbers I like better. Then the microcontroller switches the relay on at the appropriate time and off again later.
Links to pics of box exterior and interior:
It's a very simple device, and I'm completely saved by the fact that the bike has an onboard charger that does all the actual thinking. If my device fails, the bike charges to 100% but nothing catastrophic happens, assuming my box doesn't burn my shed down. I'm still working on the code as I want to make the web interface more friendly. I'll upload to Gitlab when it's done, but I can share in advance if anyone's dying of curiosity. The circuit was simple enough that it was all done mentally, so no schematic to share. But I'm happy to answer any questions. Anyway, I'd recommend spinning a PCB if anyone decides to recreate this. The wiring turned out to be enough of a pain that it's worth the $15.
I realized after finishing it that I probably could have bought an off-the-shelf wifi-controlled outlet and set up a Raspberry Pi to host a web server and boss the outlet around. But then I wouldn't have had the button and LEDs. Not sure yet how much they'll affect the convenience of using this thing.
Total cost was around $20. Total time to build this was about 35 hours, which is about 1400 trips to the shed... so this will pay for itself in around two years
But what's more important is that I had fun. And the skills I learned messing with the ESP do actually seem like they'll be useful.
The next thing I want is to actually know the bike's charge percentage. That way I can stop charging at some target percentage, rather than a guess based on time. I think the Bluetooth interface and the CAN bus should be able to report charge percentage, but I don't know if they work while the bike is turned off and charging. Anyone know? If they don't work, how hard would it be to modify the bike and get them to be on in that mode (bike off but charging)? The alternative is to sense the current at 120V and from there try to estimate the charge, but that's a last resort. If anyone knows what sort of accuracy I could expect doing that, I'm interested in that information as well.