Skip to content

Commit

Permalink
First draft of new BSP interface. SIL is working,
Browse files Browse the repository at this point in the history
all other BSP drivers are broken for now.

add publish of capabilities for runtime changes

add MREC fault types for EvseManager and bsp interface

add more specific error codes for connector lock.

support A_63_3ph_70_1ph

add separate pp_ampacity var

add draft for connector lock interface

Allow non IEC compliant EVs to pause/resume

Start adding error definitions. SIL is still waiting for JS support for errors

Add errors for evse_manager

allow resume charging after everest restart

remove extra stop power on unplug. This may lead to a short pause state if C->A happens without going through B

move connector_type into hw_caps

Signed-off-by: Cornelius Claussen <[email protected]>
  • Loading branch information
corneliusclaussen committed Nov 22, 2023
1 parent 52a1184 commit b2f68eb
Show file tree
Hide file tree
Showing 62 changed files with 1,810 additions and 1,229 deletions.
1 change: 0 additions & 1 deletion config/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ generate_config_run_script(CONFIG sil-dc-sae-v2g)
generate_config_run_script(CONFIG sil-dc-sae-v2h)
generate_config_run_script(CONFIG sil-two-evse-dc)
generate_config_run_script(CONFIG sil-energy-management)
generate_config_run_script(CONFIG hil)
generate_config_run_script(CONFIG sil-gen-pm)
generate_config_run_script(CONFIG sil-ocpp)
generate_config_run_script(CONFIG sil-ocpp-custom-extension)
Expand Down
105 changes: 0 additions & 105 deletions config/config-hil.yaml

This file was deleted.

1 change: 0 additions & 1 deletion config/config-sil-dc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ active_modules:
config_module:
connector_id: 1
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*1
evse_id_din: 49A80737A45678
session_logging: true
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-energy-management.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*1
session_logging: true
session_logging_xml: false
Expand Down Expand Up @@ -48,7 +47,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*2
session_logging: true
session_logging_xml: false
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-ocpp-custom-extension.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "1"
session_logging: true
session_logging_xml: false
Expand Down Expand Up @@ -48,7 +47,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "2"
session_logging: true
session_logging_xml: false
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-ocpp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "1"
session_logging: true
session_logging_xml: false
Expand Down Expand Up @@ -48,7 +47,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "2"
session_logging: true
session_logging_xml: false
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-ocpp201.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "1"
session_logging: true
session_logging_xml: false
Expand Down Expand Up @@ -48,7 +47,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: "2"
session_logging: true
session_logging_xml: false
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-two-evse-dc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ active_modules:
config_module:
connector_id: 1
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*1
evse_id_din: 49A80737A45678
session_logging: true
Expand Down Expand Up @@ -52,7 +51,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*2
session_logging: true
session_logging_xml: false
Expand Down
2 changes: 0 additions & 2 deletions config/config-sil-two-evse.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*1
session_logging: true
session_logging_xml: false
Expand Down Expand Up @@ -48,7 +47,6 @@ active_modules:
three_phases: true
has_ventilation: true
country_code: DE
rcd_enabled: true
evse_id: DE*PNX*E12345*2
session_logging: true
session_logging_xml: false
Expand Down
4 changes: 3 additions & 1 deletion config/config-sil.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ active_modules:
max_current_export_A: 32
payment_enable_contract: true
payment_enable_eim: true
rcd_enabled: true
session_logging: true
session_logging_path: /tmp/everest-logs
session_logging_xml: false
Expand All @@ -80,6 +79,9 @@ active_modules:
slac:
- implementation_id: evse
module_id: slac
ac_rcd:
- implementation_id: rcd
module_id: connector_1_powerpath
module: EvseManager
telemetry:
id: 1
Expand Down
2 changes: 1 addition & 1 deletion config/nodered/config-sil-flow.json
Original file line number Diff line number Diff line change
Expand Up @@ -1809,7 +1809,7 @@
},
{
"label": "AC RCD Error",
"value": "sleep 1;rcd_current 10.3;sleep 10;rcd_current 0.1sleep 36000#unplug",
"value": "sleep 1;iec_wait_pwr_ready;sleep 1;draw_power_regulated 16,3;sleep 3;rcd_current 10.5;sleep 5;rcd_current 0.2;sleep 36000#unplug",
"type": "str"
},
{
Expand Down
27 changes: 27 additions & 0 deletions errors/connector_lock.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
description: >-
Errors for Connector Lock
These following error types give more details about connector lock errors.
You should consider setting a MREC_1_ConnectorLockFailure to indicated a generic lock failure with an MREC error code as well
as one of the more detailed but custom error codes to specify the reason:
All error codes that begin with MREC needs to be implemented to fulfill the Minimum Required Error Codes defined by the ChargeX consortium:
https://inl.gov/content/uploads/2023/07/ChargeX_MREC_Rev5_09.12.23.pdf
errors:
- name: ConnectorLockCapNotCharged
description: The capacitor for connector lock motor failed to charge within expected time
- name: ConnectorLockUnexpectedOpen
description: The connector lock feedback does return open while it should be close
- name: ConnectorLockUnexpectedClose
description: The connector lock feedback does return closed while it should be open
- name: ConnectorLockFailedLock
description: The connector lock failed to lock (feedback still returns open)
- name: ConnectorLockFailedUnlock
description: The connector lock failed to unlock (feedback still returns closed)
- name: MREC1ConnectorLockFailure
description: >-
Failure to lock or unlock connector on the vehicle side as per MREC definition.
How should that be implemented? We can only find out about locking on the EVSE side,
so we will use this error to report EVSE side lock failures. It is probably a mistake in the MREC definition.
50 changes: 50 additions & 0 deletions errors/evse_board_support.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
description: >-
Errors for the evse_board_support interface.
All error codes that begin with MREC needs to be implemented to fulfill the Minimum Required Error Codes defined by the ChargeX consortium:
https://inl.gov/content/uploads/2023/07/ChargeX_MREC_Rev5_09.12.23.pdf
errors:
- name: DiodeFault
description: The CP diode in the EV is shorted.
- name: VentilationNotAvailable
description: EV requested state D but no ventilation is available.
- name: BrownOut
description: The hardware/MCU detected a brown out.
- name: EnergyManagement
description: Energy could not be delivered because an (external) energy management failed.
- name: PermanentFault
description: The EVSE is permanently broken and requires repair.
- name: MREC2GroundFailure
description: Ground fault circuit interrupter has been activated.
- name: MREC3HighTemperature
description: High temperature inside the EVSE is derating power delivery.
- name: MREC4OverCurrentFailure
description: Over current protection device has tripped.
- name: MREC5OverVoltage
description: Input voltage to the vehicle has risen above an acceptable level.
- name: MREC6UnderVoltage
description: Input voltage to the vehicle has dropped below an acceptable level.
- name: MREC8EmergencyStop
description: Emergency stop is pressed by the user (required if equipped).
- name: MREC10InvalidVehicleMode
description: The vehicle is in an invalid mode for charging (Reported by IEC stack)
- name: MREC14PilotFault
description: The control pilot voltage is out of range.
- name: MREC15PowerLoss
description: The EVSE is unable to supply any power due to mains failure
- name: MREC17EVSEContactorFault
description: Contactors fail to open or close on EVSE's side. May also include welding related errors.
- name: MREC18CableOverTempDerate
description: Temperature of charging cable or connector assembly is too high, resulting in reduced power operation.
- name: MREC19CableOverTempStop
description: Temperature of charging cable or connector assembly is too high, resulting in a stopped charging session.
- name: MREC20PartialInsertion
description: Cable latch is raised due to incomplete insertion into the vehicle charging port.
- name: MREC23ProximityFault
description: The proximity voltage is out of range.
- name: MREC24ConnectorVoltageHigh
description: The output voltage of EVSE is high before charging starts or after charging ends.
- name: MREC25BrokenLatch
description: The latch on the connector is broken.
- name: MREC26CutCable
description: The output cable has been severed from the EVSE.
11 changes: 11 additions & 0 deletions errors/evse_manager.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
description: >-
Errors for EvseManager
All error codes that begin with MREC needs to be implemented to fulfill the Minimum Required Error Codes defined by the ChargeX consortium:
https://inl.gov/content/uploads/2023/07/ChargeX_MREC_Rev5_09.12.23.pdf
errors:
- name: Internal
description: Internal error of the state machine
- name: MREC4OverCurrentFailure
description: Over current event
27 changes: 27 additions & 0 deletions interfaces/ac_rcd.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
description: >-
This interface defines an AC Residual Current Monitor (RCD). Actual emergency switch off is done in HW directly,
but this interface allows some control and telemetry.
cmds:
self_test:
description: >-
Executes a self test of the RCD. Once finished, the var self_test_result should be published. Since
the test can take quite long we do not use a synchronous return value here.
reset:
description: >-
Resets the RCD after a trigger. May not be supported by actual hardware.
result:
description: 'True: Reset successfull, False: Reset failed.'
type: boolean
vars:
rcd_current_mA:
description: Residual current in mA. Note that this does not trigger anything, it is merely for reporting.
type: number
fault_ac:
description: Indicates an AC residual current fault (informational only, hardware needs to shut down power on its own)
type: 'null'
fault_dc:
description: Indicates an DC residual current fault (on the AC wires, informational only, hardware needs to shut down power on its own).
type: 'null'
self_test_result:
description: Result of a triggered self test
type: boolean
Loading

0 comments on commit b2f68eb

Please sign in to comment.