ChargeLink

VeriStand Signal Mapping

The ChargeLink kit for NI VeriStand delivers the complete channel layout and mapping; nothing has to be created or mapped in VeriStand. This page explains what the delivered files define, so that you can read a session's status and evidence and recognise the channels in VeriStand. The setup is in Set Up the VeriStand Bench; the prerequisites are listed on the NI VeriStand Bench page.

The files that define the mapping

The import copies the kit's project (project\ChargeLink_VeriStand) to Public Documents\ChargeLink\VeriStand; the session uses that copy.

FileDefines
ChargeLink_Blank_Windows.nivssdf in the projectThe VeriStand side: target Controller, the plant model, the User Channel folders and the 44 mappings between User Channels and model ports
The plant model (FMU) in the project's ChargeLink\Models folderThe FMI 2.0 plant model with 26 inputs, 18 outputs and 15 parameters
ChargeLink\OperatorWorkspace\ChargeLink_Operator.nivsscr in the projectThe ChargeLink Operator screen
charger\config\grpc_signal_mapping.json in the kitTen plant channels and the ChargeLink canonical signal each one corresponds to
charger\config\operator_channel_contract.json in the kitThe 14 operator channels: 7 commands and 7 status values

ChargeLink checks the system definition against both files when a session starts. Use these files as delivered: Start-ChargeLinkVeriStand.ps1 always points the session at them.

The system definition

The ChargeLink VeriStand project as it appears in System Explorer, with the mapping directions System Explorer: ChargeLink_Blank_Windows.nivssdf Targets └ Controller (Windows target, localhost) ├ Simulation Models │ └ ChargeLink ISO15118-20 DC EIM FMU │ ├ Inports (26) e.g. EV.TargetVoltage_V │ ├ Outports (18) e.g. EVSE.PresentVoltage_V │ └ Parameters (6) e.g. EV.MaximumPower_W ├ User Channels │ ├ ChargeLink ISO15118-20 DC EIM Plant (50) │ │ EV.* EVSE.* Safety.* Test.* Runtime.* │ └ ChargeLink Operator (14) │ Operator.StartSession … Operator.Heartbeat ├ System Channels (Actual Loop Rate, timing) └ System Mappings (44 ChargeLink mappings) Controller: Engine Rate 500 Hz, Data Rate 50 Hz. Model: base rate 1000 µs, decimation 1, 64-bit, watchdog filtering off. Loops on logical processors 10, 11 and 12. Mapping directions Plant User Channels26 inputs FMU Inports26 FMU Outports18 Plant User Channels18 outputs Plant User Channels6 parameters FMU Parametersnot mapped, start values Operator channels14 never mapped to the FMU;used by the owner host Rule: ChargeLink reads and writes only User Channels, never FMU ports directly. Ten plant channels are also mapped to canonical gRPC signals in grpc_signal_mapping.json, for example EV.TargetVoltage_V → Vehicle.TargetVoltageV.
The shipped system definition as System Explorer shows it, and the direction of every mapping group.
  • Target Controller: Windows, localhost, engine rate 500 Hz, data rate 50 Hz, watchdog filtering off; primary control loop on logical processor 10, model on 11, secondary loop on 12.
  • Model Targets/Controller/Simulation Models/Models/ChargeLink ISO15118-20 DC EIM FMU: 64-bit, base rate 1000 µs, decimation 1; the plant model (FMU) in the project's ChargeLink\Models folder, referenced by a relative path.
  • User Channels under Targets/Controller/User Channels/: 73 in all, 50 plant channels in ChargeLink ISO15118-20 DC EIM Plant, 14 operator channels in ChargeLink Operator and 9 MCS connection channels in ChargeLink MCS Connection (below).
  • Mappings: 44. Each of the 26 model inputs is fed from the plant User Channel of the same name (User Channel → Inport); each of the 18 model outputs feeds the plant User Channel of the same name (Outport → User Channel). The model's 15 parameters are not mapped and keep the model's start values; the six parameter channels in the plant folder are not mapped either. Operator channels are never mapped to the model.

ChargeLink reads and writes only User Channels, never model ports. You can open the .nivssdf in VeriStand's System Explorer to inspect it; do not save it from there, because a saved file changes its hash.

Plant channels

Folder Targets/Controller/User Channels/ChargeLink ISO15118-20 DC EIM Plant:

GroupInputs (written by ChargeLink, mapped to model inputs)Outputs (from the model)Parameters (not mapped)
Session stateEVSE.SessionActive, EVSE.ProtocolReady, EVSE.AuthorizationAccepted, EVSE.ChargeLoopActive, EVSE.StopRequested
VehicleEV.TargetVoltage_V, EV.TargetCurrent_AEV.BatteryVoltage_V, EV.BatteryCurrent_A, EV.BatterySOC_pctEV.MaximumVoltage_V, EV.MaximumCurrent_A, EV.MaximumPower_W
ChargerEVSE.VoltageCommand_V, EVSE.CurrentCommand_A, EVSE.PowerEnable, EVSE.ContactorCommand, EVSE.PrechargeCommandEVSE.PresentVoltage_V, EVSE.PresentCurrent_A, EVSE.PresentPower_W, EVSE.ContactorClosed, EVSE.PrechargeComplete, EVSE.OutputReadyEVSE.MaximumVoltage_V, EVSE.MaximumCurrent_A, EVSE.MaximumPower_W
SafetySafety.InterlockClosed, Safety.EmergencyStop, Safety.IsolationValidSafety.FaultActive
Fault injectionTest.InjectIsolationFault, Test.InjectContactorFault, Test.InjectVoltageDeviation_V, Test.InjectCurrentDeviation_A, Test.ForceCommunicationLoss, Test.ResetFaults
Command and sample identityRuntime.CommandAge_ms, Runtime.CommandSequence, Runtime.CommandEpoch, Runtime.CommandCrc32C, Runtime.CommandCrc32Runtime.SampleSequence, Runtime.AcceptedCommandSequence, Runtime.CommandAgeActual_ms, Runtime.ContractVersion, Runtime.SourceEpoch, Runtime.SourceTime_ms, Runtime.SourceCrc32C, Runtime.SourceCrc32

The Runtime.* channels carry the identity of each command and sample, which ChargeLink uses to detect stale or corrupted values. Do not write them yourself. The Safety.* inputs are the simulated plant's safety signals; they are not connected to any physical device. The operator screen shows the session-state, command, target and Runtime.* channels as display-only: writing one of them by hand latches a plant fault, which Reset plant clears.

Plant channels and canonical signals

charger\config\grpc_signal_mapping.json pairs ten plant channels with ChargeLink canonical signals (all paths under Targets/Controller/User Channels/ChargeLink ISO15118-20 DC EIM Plant/):

DirectionPlant channelCanonical signal
ChargeLink → plantEV.TargetVoltage_VVehicle.TargetVoltageV
EV.TargetCurrent_AVehicle.TargetCurrentA
EVSE.VoltageCommand_VCharger.MaxVoltageV
EVSE.CurrentCommand_ACharger.MaxCurrentA
Plant → ChargeLink (telemetry)EV.BatterySOC_pctVehicle.SocPct
EV.BatteryVoltage_VVehicle.BatteryVoltageV
EV.BatteryCurrent_AVehicle.BatteryCurrentA
EVSE.PresentVoltage_VCharger.PresentVoltageV
EVSE.PresentCurrent_ACharger.PresentCurrentA
EVSE.PresentPower_WPower.ActivePowerW

The other plant channels (session state, contactor and precharge, safety, fault injection, command and sample identity) have no canonical signal.

Operator channels

Folder Targets/Controller/User Channels/ChargeLink Operator, defined by charger\config\operator_channel_contract.json. ChargeLink writes the status channels while an operator session runs.

ChannelKindScreen buttonMeaning
Operator.ApplySafeStartupcommand, rising edgeApply safe startupApplies the safe start-up profile and pulses Test.ResetFaults
Operator.StartSession, Operator.StopSessioncommand, latchedStart session, Stop sessionStarts or stops the charging session
Operator.StartExternalEvccLane, Operator.StopExternalEvccLanecommand, latchedStart external EVCC, Stop external EVCCStarts or stops the charger's listener for the vehicle side
Operator.ResetPlantcommand, rising edgeReset plantRestores the safe start-up profile and clears latched faults
Operator.ShutdownWorkflowcommand, rising edgeShutdown workflowMakes the plant safe, disconnects ChargeLink, undeploys the project and closes VeriStand
Operator.EngineRunning, Operator.NativeGatewayConnected, Operator.GrpcHealthy, Operator.SessionRunning, Operator.ExternalEvccLaneRunningstatusstatus tiles1 while the VeriStand engine runs, the VeriStand connection is up, ChargeLink's local service is healthy, the session runs, or the listener runs
Operator.LastErrorCodestatusLast error0 when there is no error; otherwise the code of the last error (Error codes on the screen)
Operator.HeartbeatstatusHeartbeatAlternates while the operator session is alive

You set the command channels with the buttons of the ChargeLink Operator screen, in the order given in Running a session.

MCS connection channels

Folder Targets/Controller/User Channels/ChargeLink MCS Connection, shown on the screen's MCS page and used by the MCS stack (MCS). These channels have no model behind them: ChargeLink's simulated coupler model is their source. All are numeric values with unit 1.

ChannelWritten byMeaning
Connection.McsMatedthe operator (button Plug inserted)1 while the connector is inserted. The only MCS channel you write.
Connection.McsCeStateCodeChargeLinkThe CE state: 0 unknown, 1 A, 2 B0, 3 B0_Aux, 4 B, 5 B_Aux, 6 C, 7 C_Aux, 8 EC, 9 EC_Aux, 10 E
Connection.McsIdStateCodeChargeLinkThe ID state: 0 unknown, 1 inlet not present, 2 unmated, 3 mated without charger, 4 mated, 5 mated with EV auxiliary, 6 mated with charger auxiliary
Connection.DLinkReadyChargeLink1 once the data link is ready (D-LINK_READY)
Connection.EthernetLinkUpChargeLink1 while the coupler link to the EV is alive
PhysicalControl.McsSs3Command, Charger.McsSs3ClosedChargeLinkThe charger's connector switch: command and state
PhysicalControl.McsSv3Command, Vehicle.McsSv3ClosedChargeLink, from the EV over the coupler linkThe EV's connector switch: command and state

Do not write the channels ChargeLink writes. An emergency stop and plant faults use the same plant channels as the DC session.

Two optional MCS plant inputs

The signal dictionary 1.6.0 adds two optional MCS plant inputs: Connection.McsCeSupply (the CE supply: 1 present, 0 lost) and Connection.McsLinkAvailable (the 10BASE-T1S data link: 1 usable, 0 lost). A plant that never publishes them runs as before. Once a plant publishes them, 0 or a value older than 500 ms is a fault. No profile, VeriStand project or FMU change is needed.

Watching the channels during a session

The ChargeLink Operator screen shows the status tiles (engine, gateway, local service, session, external EVCC, output ready, fault, last error, heartbeat), the session progress, the charger voltage and current and the battery SOC while the session runs. You can also read any channel in VeriStand's own tools.

After every session, the session folder operator\Runs\<time>\ in the run folder holds the session's evidence and the charger's protocol trace with the ISO 15118-20 messages; see Reading the result.

Troubleshooting

SymptomCauseAction
Validation or session start fails on the channel contract or the signal mappingThe project's system definition, a contract file or the model folder was changed or movedDelete the project copy in Public Documents\ChargeLink\VeriStand and run the import again (setup step 4); unpack the kit again if its files were changed.
Deployment fails because the model is missingThe project's ChargeLink\Models folder with the plant model (FMU) is not next to the .nivssdfKeep the project folder as delivered; import it again.
Plant values stay at zero during the charge loopThe safe start-up state is held, or a safety input or fault injection is activePress Apply safe startup before Start session; press Reset plant after a fault; read the run folder's logs.
Operator.LastErrorCode is not 0ChargeLink rejected a command or hit an errorSee Error codes on the screen; read the logs in the run folder.
A plant fault is latched after a channel was changed by handA display-only channel was writtenPress Reset plant; change only the screen's buttons.

The canonical signal dictionary

chargelink.exe exposes one transport-neutral signal dictionary through the gRPC SignalService (gRPC Integration API). The ten canonical signals above belong to it. The dictionary has 94 signals in 17 namespaces. Bidirectional signals can be written by a client and read back; output signals are produced by ChargeLink and are read-only. Each sample carries a source identity (epoch, sequence, target_time_ms, applied_command_sequence) so that a consumer can detect stale values.

Signal IDUnitDirectionSignal IDUnitDirection
Battery.CapacityWhWhbidirectionalPhysicalControl.ContactorCommand—bidirectional
Battery.MaxChargePowerWWbidirectionalPhysicalControl.EnergyTransferEnable—bidirectional
Battery.MaxDischargePowerWWbidirectionalPhysicalControl.IntentGeneration—bidirectional
Battery.TemperatureC°CbidirectionalPhysicalControl.PowerEnable—bidirectional
Charger.ContactorClosed1bidirectionalPhysicalControl.PrechargeEnable—bidirectional
Charger.ContactorState—bidirectionalPhysicalControl.StopRequested—bidirectional
Charger.MaxCurrentAAbidirectionalPhysicalControl.TargetCurrentAAbidirectional
Charger.MaxPowerWWbidirectionalPhysicalControl.TargetVoltageVVbidirectional
Charger.MaxVoltageVVbidirectionalPower.ActivePowerWWbidirectional
Charger.Notification—bidirectionalPower.EnergyExportedWhWhoutput
Charger.PresentCurrentAAbidirectionalPower.EnergyImportedWhWhoutput
Charger.PresentVoltageVVbidirectionalPower.ReactivePowerVarvarbidirectional
Connection.CpState—bidirectionalProtocol.LastMessage—output
Connection.EthernetLinkState—bidirectionalProtocol.LastResponseCode—output
Connection.PlcLinkState—bidirectionalProtocol.MessageCountercountoutput
Connection.PlugLocked—bidirectionalProtocol.SecurityState—output
Connection.PlugPresent—bidirectionalProtocol.SelectedProtocol—output
Connection.PpState—bidirectionalProtocol.SelectedSchema—output
Contactor.NegativeState—bidirectionalProtocol.SessionState—output
Contactor.PositiveState—bidirectionalSecurity.AuthorizationMode—bidirectional
Fault.ActiveCountcountoutputSecurity.PeerCertificateValid—output
Fault.LastFault—outputSecurity.TlsState—output
Isolation.ResistanceOhmPerVΩ/VbidirectionalSession.ElapsedMsmsoutput
Metering.MeterReadingWhWhoutputSession.Id—output
Metering.ReceiptRequired—bidirectionalSystem.CpuUsagePct%output
Test.ActiveCampaign—outputSystem.DroppedEventscountoutput
Test.ActiveCase—outputSystem.HealthState—output
Test.CaseVerdict—outputSystem.MemoryBytesbytesoutput
Test.ExecutionProgress%outputThermal.CoolantTemperatureC°Cbidirectional
Vehicle.BatteryCurrentAAbidirectionalThermal.DeratingPct%bidirectional
Vehicle.BatteryVoltageVVbidirectionalVehicle.RequestedPowerWWbidirectional
Vehicle.ContactorState—bidirectionalVehicle.SocPct%bidirectional
Vehicle.IsolationStatus—bidirectionalVehicle.TargetCurrentAAbidirectional
Vehicle.TargetVoltageVVbidirectional

Units are SI base units: watts, not kilowatts; watt-hours, not kilowatt-hours. On the VeriStand bench, the gRPC service runs only while an operator session runs; do not write signals into a running bench session.