Skip to content

Commit ea2d81b

Browse files
committed
Addressed issue #35
Consistent ws port 9080 in code and documentation
1 parent a68739f commit ea2d81b

4 files changed

Lines changed: 7 additions & 6 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,3 +231,4 @@ pecan/src/assets/local.dbc
231231
# Test artifacts
232232
test-logs/
233233
.pytest_cache/
234+
*.dat

car-simulate/websocket_sender.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import time
77

88
# WebSocket server URL
9-
WS_URL = 'ws://localhost:8080/ws'
9+
WS_URL = 'ws://localhost:9080/ws'
1010

1111
# Path to the CAN data file (CSV format: timestamp,CAN,canId,data1,data2,data3,data4,data5,data6,data7,data8)
1212
DATA_FILE = '2025-01-01-00-07-00.csv' # Replace with the exact filename if different

pecan/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ npm install
2424
npm run dev
2525
```
2626

27-
The development server will start on `http://localhost:5173` with a WebSocket server on `ws://localhost:8080`.
27+
The development server will start on `http://localhost:5173` with a WebSocket server on `ws://localhost:9080`.
2828

2929
### Testing
3030

pecan/vite.config.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ const websocketPlugin = (): Plugin => ({
2424
function startWebSocketServer() {
2525
// Dynamic import to avoid build-time dependency issues
2626
import('ws').then(({ WebSocketServer }) => {
27-
const wss = new WebSocketServer({ port: 8080 });
27+
const wss = new WebSocketServer({ port: 9080 });
2828

2929
// eslint-disable-next-line no-console
30-
console.log('WebSocket server started on ws://localhost:8080');
30+
console.log('WebSocket server started on ws://localhost:9080');
3131

3232
wss.on('connection', (ws) => {
3333
// eslint-disable-next-line no-console
@@ -64,9 +64,9 @@ function startWebSocketServer() {
6464
});
6565

6666
// eslint-disable-next-line no-console
67-
console.log('WebSocket server is running on port 8080');
67+
console.log('WebSocket server is running on port 9080');
6868
// eslint-disable-next-line no-console
69-
console.log('Data Sender and Dashboard can connect to ws://localhost:8080');
69+
console.log('Data Sender and Dashboard can connect to ws://localhost:9080');
7070
}).catch((error) => {
7171
// eslint-disable-next-line no-console
7272
console.error('Failed to start WebSocket server:', error);

0 commit comments

Comments
 (0)