Skip to content
This repository has been archived by the owner on Oct 3, 2022. It is now read-only.

Commit

Permalink
fix: update serialport API
Browse files Browse the repository at this point in the history
  • Loading branch information
coderbyheart committed Feb 14, 2022
1 parent 2854141 commit afe45b5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const SerialPort = require('serialport')
const { SerialPort } = require('serialport')
const { api } = require('./api')
const { EventCategory } = require('./utils')

Expand All @@ -8,7 +8,8 @@ const commandsWithoutPrefixedResponse = ['AT+CLAC', 'AT+CGSN', 'AT+CGMM', 'AT+CG

class ModemPort extends SerialPort {
constructor (port, opts) {
super(port, {
super({
path: port,
autoOpen: false,
baudRate: 115200,
dataBits: 8,
Expand Down

0 comments on commit afe45b5

Please sign in to comment.