You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to simulate a charge point and connect to the server. I think the server is working fine but the problem is how i connect to it.
I'm using this to connect
const newSocket = new WebSocket(${ocppJEndpointUrl}/${encodeURIComponent(chargePointIdentity)},['ocpp1.6', 'ocpp1.5']);
so it should look like this
ws://localhost:3000/ABCD with protocols [ocpp1.6,ocpp1.5]
this is the error i get
const err = Error(reason);
^
Error [AbortError]: Client disconnected
at Object.pendingCall.abort (/home/tarek/Desktop/ocpp_csms/server/node_modules/ocpp-rpc/lib/client.js:338:29)
at /home/tarek/Desktop/ocpp_csms/server/node_modules/ocpp-rpc/lib/client.js:440:63
at Array.forEach ()
at RPCServerClient._rejectPendingCalls (/home/tarek/Desktop/ocpp_csms/server/node_modules/ocpp-rpc/lib/client.js:440:48)
at RPCServerClient._handleDisconnect (/home/tarek/Desktop/ocpp_csms/server/node_modules/ocpp-rpc/lib/client.js:458:14)
at WebSocket. (/home/tarek/Desktop/ocpp_csms/server/node_modules/ocpp-rpc/lib/client.js:410:49)
at Object.onceWrapper (node:events:629:26)
at WebSocket.emit (node:events:526:35)
at WebSocket.emit (node:domain:489:12)
at WebSocket.emitClose (/home/tarek/Desktop/ocpp_csms/server/node_modules/ws/lib/websocket.js:258:10)
The text was updated successfully, but these errors were encountered:
I will use it to create a central system but i was just testing things out first and familiarizing myself with this module.
I have a simple ui with a connect button that tries to establish a web-socket connection, as a charge point, with the server i created using the example you gave in express
I'm trying to simulate a charge point and connect to the server. I think the server is working fine but the problem is how i connect to it.
I'm using this to connect
const newSocket = new WebSocket(
${ocppJEndpointUrl}/${encodeURIComponent(chargePointIdentity)}
,['ocpp1.6', 'ocpp1.5']);so it should look like this
ws://localhost:3000/ABCD with protocols [ocpp1.6,ocpp1.5]
this is the error i get
The text was updated successfully, but these errors were encountered: