Skip to content

ev twin

The sub system ev twin defines the charging behavior of the electric vehicle (EV) and shows the highest level for definition. In the mask it contains predefined EV types with data collected from public data mostly from ADAC and EV-Database. These data mainly contain information defined in the tabs.

  • EV: car itself, e.g. mass, consumption, see details of the pre defined EV in section EV Models. It is also defined what high level communication is selected. Also debugging parameters can be defined.
  • AC: defines the on board charger (OBC). Beside maximum power also the type of converter can be selected with the check box asymmetric phase loading. If activate 3 single phase converters will be placed and e.g. 1 phase charging will be possible.
  • DC: Capacity, voltage level, maximum current depended on the SOC
  • HLC Timeout: all time outs for the different phases of ISO 15118 can be defined individually.
  • HIL Connect: organizes the interaction with the analog and digital inputs and outputs. It is important to define the pin setup if the HIL-Connect is connected to the top or bottom row of the HIL-computer.
    • The checkboxes sensor emulation emulate the sensors for temperature measurement and the lock actuator in the CCS-interface, this is e.g. useful for V-HIL only applications.
    • the checkboxes measurement include the evaluation of analog inputs for AC and DC measurements.
  • SCADA: defines all parameters for the SCADA svg visualization

The model is prepared for Power-HIL application.

component component dialog parameters
property tabs
  1. EV
  2. AC
  3. DC
  4. HLC Timeout
  5. HIL Connect
  6. SCADA
  7. Info

block diagram

The sub system ev twin contains several high level components that also can be used to model individual EV emulation. The block CCS organized interacting with the external equipment of the HIL-computer. Power Unit contains battery, on board charger and a simple battery management BMS. The charging is organized by the EV charge controller EVCC, which handles external communication to the EVSE, user interaction and the interaction with BMS. With the connected user interface EVCC UI data are available in SCADA for controlling the EV emulation.

input and output

ev twin has connection to the Power Grid, where it can be charged either with AC or DC. Signals can be collected from the single blocks using Signal Picker Source. Many signals of the EVCC are accessible via EVCC UI.

Note: All input and output values are executed with the lower execution rate.

input

Number Input Description Signal range Default
0 CCS_Switch locking (1) and unlocking (0) the CCS inlet 0 or 1 0
1 Start_Charge Starts charging if inp is 1. 0 or 1 0
2 I_request Charging current requested by the user. float 0
3 Bat_Condition Enables Conditioning of battery. 0 or 1 0
4 Bat_Reset Resets the battery control in case of a failure. 0 or 1 0
5 Stop_Charging Stops charging if inp is 1. 0 or 1 0
6 T amb ambient temperature float 20

output

Number Output Description
0 PP_connected digital output describing if the PP-contact is connected.
1 PP_Imax maximum current coded in the CCS plug for the the cable. This is needed for charging according to IEC61851, if there is no higher level communication.
2 PP_state integer variable coding the current state of the PP-contact
PP_STATE_ERROR = -1
PP_STATE_DISCONNECTED = 0
PP_STATE_CONNECTED = 1
PP_STATE_DEPRESSED = 2
3 CP_status integer variable coding the evaluated state of the CP-contact
CP_STATE_ERROR = -1
CP_STATE_A = 0
CP_STATE_B = 1
CP_STATE_C = 2
4 CP_Imax maximum current that is coded via the duty cycle on CP-contact [A]
5 CCS_locked digital output describing if the CCS-interface is locked
6 CC_Imax maximum current then the EVCC allows as a result of CP, PP and BMS
7 ch_enabled digital output describing if charging is enabled
8 Iset_a current settling value for phase A
9 Iset_b current settling value for phase B
10 Iset_c current settling value for phase C
11 SOC float value for the current battery state of charge [%/100]
12 Vbat battery voltage [V]
13 Ibat battery current [A]
14 DC_status integer variable coding the current state of the duty cycle on CP-contact
DC_STATE_ERROR = -1
DC_STATE_DC = 1 (maximum current is defined by duty cycle)
DC_STATE_HLC = 2 (high level communication necessary)
15 T bat battery temperature [°C]
16 Vrms a voltage RMS on AC side of OBC phase A [V]
17 Vrms b voltage RMS on AC side of OBC phase B [V]
18 Vrms c voltage RMS on AC side of OBC phase C [V]
19 P active power of OBC [W]
21 Q reactive power of OBC [var]
22 S apparent power of OBC [VA]
23 PF power factor of OBC
24 I dc DC current at the CCS-interface [A]
25 Cbat nominal capacity of the battery [Ah]
26 Vbat nom nominal voltage of the battery [V]
27 EV consumption consumption of the EV [Wh/km]
28 Imax OBC maximum current of OBC (AC side) [A]

SCADA

For the interaction with ev twin we suggest the of the SCADA widget with same name. It shows an animated animation and control of the EV as shown below. It also gives access to a couple of sub panels accessing the most relevant parts of the model. Parameterization is done in the schematic editor in the tab SCADA.

Component dialogue box and parameters

The ev twin subsystem is organized in six tabs defining the emulated EV.

Tab 1 - EV

Parameter Code Name Description
General
faster execution rate Tn The Faster execution rate at which control of power electronic of the inner signal processing of the component will be executed. Should be approximately 5 to 10 times faster than the Slower execution rate. [s]
slower execution rate Tslow The Slower execution rate, at which part of the inner signal processing of the communication components will be executed. This execution rate is identical by the connected UI subsystem. Should be approximately 5 to 10 times slower than the Faster execution rate. [s]
EV Brand ev_brand The EV model is selected by the manufacturer first, this defines the models in the following property.
EV Type ev_type This combo box finally defines the EV model.
EV Parameters
Consumption Wh_per_kWh Mean consumption of the EV is used in user interface to calculate charging speed. [Wh/km]
Mass mass Mass of the EV [kg]
Capacity bat_cap Nominal capacity of the battery [Wh]
Battery voltage bat_volt Nominal Voltage of the battery [V]
Maximum current bat_current_max maximum current of the battery [A]
Power limits points_power vector with power limits, corresponding to the SOC limits [W]
SOC limit points points_soc vector of state of charges as x-value for Power limit [%]
preview Button showing the Power limitation dependent on the SOC.
HL Communication
Ethernet Port HLC eth_port_iso combo box defining the ethernet port for high level communication.
HLC type HLC_type Drop down box defining which type of higher level communication should be used. Currently supported 'no HLC' and 'ISO 15118-2', 'ISO 15118-2 AC', 'ISO 15118-20 DC BPT'. In the mode 'ISO 15118-2 sim' the HL communication is simulated and pure VHIL-simulation is available.
Connection Type connection_type If high level communication is not simulated the can be chosen to 'Trusted connection' or 'Secured connection'.
Select Folder select certificate folder If 'Secure Connection' is activated, the folder for the certificates can be selected here.
Folder with certificates path folder_path_pr The selected folder for the certificates is shown here.
Log Level log_level Defines the log level for ISO 15118 communication
Log Output log_output Defines the log output for ISO 15118 communication

Tab 2 - AC

The tab AC defines the on board charger and its time behavior with ramps, etc..

Parameter Code Name Description
Grid Parameters
nominal grid voltage (line) Vgrid nominal grid voltage (phase to phase) for control of OBC [V]
nominal grid frequency fgrid nominal grid frequency for the control 0f OBC [Hz]
On-Board Charger Parameters
asymmetric phase loading single_ph Depending on the check box the OBC is exchanged. If value is True 3 single phase converters is integrated and asymmetric phase loading is possible. Otherwise the Bidirectional AC-DC Converter (Generic) is used.
Onboard charger active power onboard_charger_power maximum active power of the OBC [W]
Onboard charger apparent power Sn_ac maximum apparent power of the OBC [VA]
delay start charging Tstart delay time at beginning of charging until first set point is settled [s]
delay change power Tchange delay time at change of power until the change starts [s]
rate of change startup roc_start maximum rate of change to settle the first reference in case of start charging [1/s]
rate of change stop roc_stop minimum rate of change to control to 0 power in case of stop charging [1/s]
rate of change up roc_up maximum rate of change to settle a higher reference value during the charging process [1/s]
rate of change down roc_down minimum rate of change to settle a lower reference value during th charging process in case of start charging [1/s]

Tab 3 - DC

Parameter Code Name Description
General DC Charging Parameters
Voltage Accuracy voltage_accuracy voltage accuracy of DC voltage in case of ISO 15118 communication [V]
charging complete soc soc_full state of charge, when the battery is considered fully charged [%]
bulk charging soc soc_bulk state of charge , when the battery shall operate in bulk charge mode.Must be smaller than charge complete soc [%]
Pre Charging Current pre_charge_current Current in case of pre charging just in the initialization of the charging process
DC Charging Limits
min voltage limit Vmin minimal DC voltage limit [V]
max voltage limit Vmax maximal DC voltage limit [V]
DC max current limit Imax maximal DC current [A]
min charging current Imin_ch minimum DC charging current [A]
max charging current Imax_ch maximum DC charging current [A]
min discharging current Imin_dch minimum DC discharging current (only active for bidirectional charging) [A]
max discharging current Imax_dch maximum DC discharging current (only active for bidirectional charging) [A]
DC max charging power Pmax maximal DC charging power [W]
min charging power Pmin_ch minimum charging power [W]
max charging power Pmax_ch maximum charging power [W]
min discharging power Pmin_dch minimum discharging power (only active for bidirectional charging) [W]
max discharging power Pmax_dch maximum discharging power (only active for bidirectional charging) [W]
maximum energy charging Wmax maximum charging energy [Wh]

Tab 4 - HLC Timeout

Parameter Code Name Description
sdp response timeout sdp_response_timeout [ms]
supported app protocol supported_app_protocol [ms]
session setup session_setup [ms]
service discovery service_discovery [ms]
service detail service_detail [ms]
payment service selection payment_service_selection [ms]
payment details payment_details [ms]
authorization authorization [ms]
charge parameter discovery charge_parameter_discovery [ms]
charging status charging_status [ms]
metering receipt metering_receipt [ms]
power delivery power_delivery [ms]
cable check cable_check [ms]
pre charge pre_charge [ms]
current demand current_demand [ms]
welding detection welding_detection [ms]
session stop session_stop [ms]
certificate instalation certificate_instalation [ms]
certificate update certificate_update [ms]
v2g secc sequence timeout dc cl v2g_secc_sequence_timeout_dc_cl [ms]

Tab 5 - HIL Connect

Parameter Code Name Description
Connection to HIL
signal input sig_inp For connection to HIL it can be selected to use 'HIL-Connect' for analog and digital IO, or 'HIL-Connect - remote IO'. With option 'HIL-Connect - simulation' the model is able to run in VHIL.
eval CP PWM eval_pwm Combo box if the CP-Signal shall be evaluated on 'CCS-board' or inside the model applying the 'PWM analyzer'.
Pin out setting HIL Connect pout Combobox defining how the HIL Connect is connected to the HIL-Computer
internal T sensor emulation int_T Checkbox enabling internal temperature sensor emulation. If activated the temperature sensors of the CCS-interface are emulated in a temperature range that allows charging. This is mandatory for V-HIL.
internal Rlock emulation int_R Checkbox enabling internal emulation of the feedback from the CCS-interface. If activated the feedback follows the switching actions initiated by EVCC. This is mandatory for V-HIL.
Measurements
Core Marker id_cm if measurement unit is activated a core should be defined where they are running.
link to HIL device link_HIL in multi HIL applications it is necessary to force measurement to a HIL device as they are not physically connected to the model.
HIL device ID hil_id If 'link to HIL device' is activated here a HIL can be selected.
activate AC measurement AC checkbox activates the measurement of AC voltage and current by the HIL connect via analog signals
activate DC measurement DC checkbox activates the measurement of DC voltage and current by the HIL connect via analog signals
Spike Filtering on CP contact
steps steps steps for checking the limit and to ignore it.
delta delta maximum allowed delta in vertical direction
Threshold DC Com Status TH_DC_Status_s Time interval during the threshold for the CP status is evaluated. [s]
Threshold DC Com Imax TH_DC_Imax_s Time interval during the threshold for the maximum current coded through CP-signal is evaluated. [s]
Threshold Error TH_ERROR Time interval during the threshold for Error CP-signal is ignored. [s]
enable CP spike filter ena_spike_filter Enable the software filter for CP signal, this is recommended in some PHIL-applications.
Capacitors on CP contact
CP HW filter C3n2 C3n2 checkbox connects a capacitor with 3n2 to the CP-contact on CCS-board.
CP HW filter C1n6 C1n6 checkbox connects a capacitor with 1n6 to the CP-contact on CCS-board.
CP HW filter C800p C800p checkbox connects a capacitor with 800p to the CP-contact on CCS-board.
CP HW filter C400p C400p checkbox connects a capacitor with 400p to the CP-contact on CCS-board.
CP HW filter C200p C200p checkbox connects a capacitor with 200p to the CP-contact on CCS-board.
CP HW filter C100p C100p checkbox connects a capacitor with 100p to the CP-contact on CCS-board.
cut of frequency CP Vpeak fc_CP_Vp includes a cut off frequency for the measured peak of the CP signal [Hz]
rate limit CP duty cycle (+/-) rate_lim_dc limits the rate of change for the detected duty cycle of CP-signal

Tab 6 - SCADA

Parameter Code Name Description
Scale GUI scale factor for scaling the size of the visualization [0.7 ... 2.5]
color scheme col_scheme drop down list for selecting color scheme, so far 'black' is well tested.
Welcome Screen welcome if activated a Welcome screen with user name is shown. At stop of simulation this will be reset.
Duration Welcome welcome_time Time the welcome screen is shown. [s]
Update Time update_time Maximum time after rewriting and reloading the svg visualization image. Be carful, too short times will make the SCADA freezing. [s]

Tab 7 - Info

Parameter Code Name Description
Source source Source for the EV selected
Source bat voltage source_bat_v Source 2 for the EV selected