A web-based application for simulating Electric Vehicle (EV) charging stations and testing OCPP communication with Charge Station Management Systems (CSMS).
- What is OCPP?
- Getting Started
- Creating a Charge Point Connection
- Connecting to CSMS
- Using OCPP Controls
- Monitoring Charging Status
- Network Traffic Monitoring
- Configuration Options
- Managing Charge Points
OCPP (Open Charge Point Protocol) is an open communication standard that enables EV charging stations (Charge Points) to communicate with a central management system (CSMS - Charge Station Management System).
This protocol allows:
- Remote monitoring and control of charging stations
- Transaction management and authorization
- Real-time meter value reporting
- Firmware updates and configuration management
- Status notifications and diagnostics
This simulator implements OCPP 1.6 and allows you to test your CSMS by simulating one or multiple charge points, sending OCPP messages, and monitoring the communication flow.
The application features a modern, intuitive interface for managing charge points and monitoring OCPP communication:
Charge Point Connection Interface - View real-time charging status, control OCPP messages, and manage connections
- Node.js (v18 or higher)
- Yarn package manager
- Install dependencies:
yarn install- Start the development server:
yarn dev- Open your browser and navigate to the URL shown in the terminal (typically
http://localhost:5173)
- Open the sidebar - Click the sidebar toggle button in the top-left corner if it's collapsed
- Click "New Connection" - Use the button in the sidebar footer or the "+" button next to "Connections"
- Fill in the connection details:
- Name (optional): A friendly name for this charge point (e.g., "Test Station 1")
- CSMS URL: The WebSocket URL of your CSMS server (e.g.,
ws://localhost:9000/ocpp/orwss://example.com/ocpp/) - CP ID: The unique identifier for this charge point (e.g.,
SIM_001)
- Click "Create" - The charge point will be created and you'll be automatically navigated to its connection page
The connection will attempt to auto-connect immediately after creation.
Once you've created a charge point, you can manage its connection:
-
View connection status - The status indicator shows:
- 🟢 Green: Connected
- 🟡 Yellow: Connecting
- ⚪ Gray: Disconnected
-
Manual connection:
- Click the "Connect" button in the top-right action bar
- Wait for the status to change to "connected"
-
Disconnect:
- Click the "Disconnect" button to close the WebSocket connection
The OCPP Controls panel provides buttons to send various OCPP messages to your CSMS:
- BootNotification: Registers the charge point with the CSMS. Should be sent after connection.
- Heartbeat: Keeps the connection alive and provides current timestamp.
- Status: Sends a StatusNotification with connector status (Available, Occupied, etc.).
- Authorize: Authorizes an RFID tag for charging.
-
StartTx:
- Authorizes the configured ID tag
- Starts a charging transaction
- Begins sending periodic MeterValues
- Changes connector status to "Charging"
-
MeterValues: Manually sends current meter readings (power, energy, voltage, current, SoC).
-
StopTx:
- Stops the active transaction
- Sends final meter values
- Changes connector status to "Finishing"
-
Unlock Cable: Changes connector status back to "Available" after charging.
A typical charging session flow:
- Connect to CSMS
- BootNotification - Register the charge point
- Authorize - Verify the RFID tag (optional, StartTx does this automatically)
- StartTx - Begin charging session
- Monitor MeterValues being sent automatically
- StopTx - End the charging session
- Unlock Cable - Make connector available again
The Charging Status panel displays real-time information:
- Status: Current charging state (Charging / Not Charging)
- Charging Type: AC or DC charging
- Device: Device name from configuration
- Transaction ID: Active transaction identifier
- Battery SoC (DC only): State of Charge percentage with progress bar
- Power: Current power draw in kW
- Current: Current in Amperes
- Voltage: Voltage in Volts
- Energy: Total energy delivered in kWh
- Session Progress (AC): Progress bar showing charging session completion
All values update automatically as MeterValues are received.
The Network Traffic panel shows all OCPP messages exchanged between the charge point and CSMS:
Real-time OCPP message monitoring with detailed JSON payload inspection
- Incoming messages (from CSMS): Displayed with incoming indicators
- Outgoing messages (to CSMS): Displayed with outgoing indicators
- Message details: Click on any message to view its full JSON payload
- Pause/Resume: Toggle to pause automatic scrolling when new messages arrive
- Copy: Copy all messages as JSON to clipboard
- Clear: Remove all messages from the log
This is useful for debugging and understanding the OCPP message flow.
Click "Basic Config" to edit:
- Name: Charge point display name
- CSMS URL: WebSocket server URL
- CP ID: Charge point identifier
- Protocol: OCPP version (1.6 or 2.0.1)
Click "Advanced Config" to configure:
Comprehensive configuration interface with modular sections for device settings and OCPP parameters
- Device Settings: Device name, power limits, voltage, current, connector types, AC/DC mode
- OCPP Configuration: Heartbeat interval, meter value intervals, feature profiles, authorization settings, and more
Changes to configuration are saved locally and persist across sessions.
- All created charge points appear in the sidebar under "Connections"
- Each entry shows:
- Connection status indicator (green/yellow/gray dot)
- Charge point name or label
- Click any charge point in the sidebar to navigate to its connection page
- You can have multiple charge points connected simultaneously
- Navigate to the charge point's connection page
- Click the "Delete" button in the top-right action bar
- Confirm deletion in the dialog
- The charge point will be removed and disconnected
- Open "Basic Config"
- Change the Name field
- Click "Save changes"
- Multiple Simulations: Create multiple charge points to simulate a charging network
- Testing Scenarios: Use different CP IDs and configurations to test various scenarios
- Network Debugging: Use the Network Traffic panel to inspect exact OCPP message formats
- Battery Simulation: The app simulates battery charging for DC mode with realistic SoC progression
- Auto-Connect: Charge points attempt to auto-connect when you navigate to their page
yarn buildyarn previewyarn lint

