I wonder how the TWC will react to something else issuing CAN commands and whether it would through it's internal state out. It'd be a lot of work to have to act as both devices and selectively pass certain messages back and forward (i.e. when you want to stop charging, send the car a 'zero current' message but at the same time send the TWC a 'car wants to stop charging' message). Anyway my first step is to get the RS485 piece working and control start and stop via the API and then look into CAN later if there's any motivation left.
I've been thinking of similar things about if I need the SWCAN comms.
Initially there has been a 'bug?' in the STOP_CHARGING (0xFCB2) command and as some people here had reported the TWC was able to suspend and restart charging, I was interested in how it did it - hence I started eaves dropping on the SWCAN comms.
The car was also not waking up via the charge port after it went to sleep (i.e. if you reapplied power to the contactor using START_CHARGING 0xFCB1). This has recently been fixed in 2020.24.6.x, but I need to test how it reacts with the TWC's START CHARGING command (Maybe this weekend).
I'm hoping this is all resolved and we only need RS-485 to turn on and off the charging.
My other motivation is I've signed up with AmberElectric as my electricity retailer. They pass through the wholesale price of electricity, so I can parse a JSON file and make a real time decision on when to charge my car based on the current 30 minute price of power. I can set a threshold and say I only want to charge when the price is under this threshold.
But it's not quite that easy. If my car is flat and the price is always above the threshold, then I'm stuck. Sometimes the price also goes negative and I get paid to charge the car. Therefore I want to keep a reserve in the battery for these opportunities.
I've worked out I can get the SoC via the SWCAN port, so I can have different decision making based on the state of charge. (I know I can do this via API, but I find it more logical to do it via the charging port. I can leave the car set to charge to 90% when I'm out on public chargers and have my TWC terminate the charge based on the reported SoC)
Hence, I'm wondering if I want to tap into the Pilot/SWCAN line for reading the SoC. I would never drive the line.
There is also a complication with the SWCAN line sharing the Pilot line. Under J1772/IEC61851-1 the car will switch in different resistor values to signal 'Vehicle Detected', 'Ready/Charging' etc. If you have the transceiver connected to the Pilot when the charge port is first plugged in, it will interfere. A Tesla will switch in (with a relay) the SWCAN Transceiver after a certain sequence:
New Tesla charger board - Page 3 - openinverter forum
Last edited: