Protocol simulator

OCPP Simulator

Connect a virtual OCPP 1.6J charge point to your CSMS. Verify boot registration, status updates and meter values.

Watch a virtual charger report changes to your CSMS

In Attributes, enable charging and adjust commanded current. Plot current, power and accumulated energy to see the effect. The chart shows the charger’s local state while your CSMS receives the corresponding OCPP messages.

SPX Attributes and chart show current, power and accumulated energy on a virtual OCPP charger.
When commanded current changes, simulated power follows and accumulated energy keeps rising on a separate axis.

Screenshot preview

When commanded current changes, simulated power follows and accumulated energy keeps rising on a separate axis. Open original image

Check the WebSocket connection and meter values

In Communication, open the OCPP adapter. Match the CSMS WebSocket URL and charge-point identity to your test server. The charge point initiates the connection. Use its message bindings to check which measurements go into MeterValues.

SPX Communication shows OCPP connection settings for the library charge point.
Communication for the library charge point used in the OCPP Quick Start.

Screenshot preview

Communication for the library charge point used in the OCPP Quick Start. Open original image

Show the MeterValues binding in YAML

Excerpt from the custom charger. The adapter screenshot above shows the library charger.

send_meter_values:
  direction: outbound
  frame_type: call
  action: MeterValues
  interval: 5.0
  payload:
    connectorId: 1
    meterValue: "#attr(meter_values)"

Check what the CSMS received

In SPX UI, open Communication → ocpp → bindings, select View Logs for send_meter_values and expand an outbound entry. Compare the payload with the sample received by the CSMS. In this run, both showed 20 A and 4,600 W.

An expanded outbound MeterValues entry in SPX UI shows the simulated charge point’s connector and its meter samples.
The custom charge point’s MeterValues binding shows the samples sent to the test CSMS.

Screenshot preview

The custom charge point’s MeterValues binding shows the samples sent to the test CSMS. Open original image

Try a ready-made charger

Connect a library charge point to a test CSMS and watch its boot messages, connector status and metering.

Test your CSMS with a virtual charger

Connect a simulated charge point to your charging station management system (CSMS). Observe its status and meter readings as the virtual charger changes state.

OCPP 1.6J communication

Connect a virtual charger to your CSMS

SPX · runtime

Virtual charger

Simulates state and changing meter readings.

Bindings

SPX · OCPP adapter

Charge point

Initiates an OCPP 1.6J WebSocket connection.

OCPP / WebSocket

Your integration

CSMS

Accepts the connection and responds to charge-point messages.

SPX initiates the connection to the CSMS. The messages available depend on the model and the CSMS.

Install SPX with OCPP support and SPX UI. The OCPP 1.6J adapter acts as a charge point and initiates a WebSocket connection to a reachable CSMS. A test CSMS can verify message exchange without a physical charging station.

Create a virtual charger with your AI agent

Ask an agent to create a new EVSE model with charging controls and changing measurements. The model describes a simulation; it is not a claim of compatibility with a particular commercial charger.

Open your SPX workspace in a local AI agent and use this prompt:

Prompt for your AI agent

Create and validate a new SPX EVSE model from scratch for OCPP 1.6J. Include configurable charge-point identity and CSMS endpoint, controls for charging enable and commanded current, and telemetry for current, power, and accumulated energy. Connect it to a separate test CSMS that is not an SPX instance. Preserve all existing instances. Verify that BootNotification receives Accepted, the CSMS receives StatusNotification and MeterValues, and changing commanded current changes the reported measurements. Do not claim or imply that an OCPP transaction was completed. Report the model, instance, and protocol checks performed.

Tested with GPT-6 Luna · Medium

Estimated API cost · $0.0185 per run

We tested this prompt in an independent GPT-6 Luna · Medium session. The agent generated and validated a new model, corrected its message bindings during the test, and verified the resulting protocol exchange with a temporary CSMS. Download the tested YAML. The estimate on the card covers a separate run, including a correction to its message bindings and a repeat of the CSMS checks. Review the bindings and reported results for each new model.

Connect and observe

Configure the CSMS WebSocket URL and charge-point identity reported by your agent. In our example, the virtual charger initiates a connection using the ocpp1.6 subprotocol. A CSMS responds to each request using its message ID.

MessageWhat to verify in the test
BootNotificationThe CSMS receives the charger identity and returns Accepted.
HeartbeatThe CSMS acknowledges the heartbeat with its current time.
StatusNotificationThe CSMS receives the simulated connector state, such as Available or Charging.
MeterValuesThe CSMS receives and acknowledges samples for energy, power, current and voltage.

In our test, we enabled charging and changed the commanded current locally in SPX. The CSMS received meter samples of 10 A / 2,300 W, followed by 20 A / 4,600 W; the energy register continued to rise. Those local controls are not OCPP remote-start or remote-stop commands.

The test CSMS ran on a private Docker network without host port mappings. It acknowledged the messages above, but the model did not exchange StartTransaction or StopTransaction. Boot registration and meter telemetry do not by themselves establish a complete OCPP transaction.

See the OCPP adapter guide for connection and message binding details.