Skip to content

Commit

Permalink
docs: updare readme
Browse files Browse the repository at this point in the history
  • Loading branch information
kybarg committed Jul 15, 2024
1 parent 44373b0 commit 78bc7ff
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,21 @@ eSSP.command('GET_SERIAL_NUMBER').then(result => {
console.log('Serial number:', result.info.serial_number)
return
})

const portOptions = { baudRate: 9600 }

eSSP.open('COM1', portOptions)
```

## Config values
```javascript
const options = {
fixedKey: '123', // device internal encryption key
encryptAllCommand: true, // should command commands also be encrypted
id: 0, // device id in case multiple acceptors connected to the host
timeout: 1000, // command response timeout after wich command considered failed
commandRetries: 20 // how many time to retry before throwing error or emitting ERROR event
}
```

## Methods
Expand Down
1 change: 0 additions & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ class SSP extends EventEmitter {
// Initialize config
const { fixedKey = '0123456701234567', ...otherConfig } = config
this.config = {
debug: false,
encryptAllCommand: true,
id: 0,
timeout: 1000,
Expand Down

0 comments on commit 78bc7ff

Please sign in to comment.