queclink-parser 1.9.29 → 1.9.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/gv500.js CHANGED
@@ -23,7 +23,7 @@ const parse = raw => {
23
23
  imei: parsedData[2],
24
24
  protocolVersion: utils.getProtocolVersion(parsedData[1]),
25
25
  temperature: null,
26
- history: history,
26
+ history,
27
27
  sentTime: utils.parseDate(parsedData[parsedData.length - 2]),
28
28
  serialId: parseInt(parsedData[parsedData.length - 1], 16)
29
29
  }
@@ -660,5 +660,5 @@ const parse = raw => {
660
660
  }
661
661
 
662
662
  module.exports = {
663
- parse: parse
663
+ parse
664
664
  }
package/src/gv50p.js CHANGED
@@ -23,7 +23,7 @@ const parse = raw => {
23
23
  imei: parsedData[2],
24
24
  protocolVersion: utils.getProtocolVersion(parsedData[1]),
25
25
  temperature: null,
26
- history: history,
26
+ history,
27
27
  sentTime: utils.parseDate(parsedData[parsedData.length - 2]),
28
28
  serialId: parseInt(parsedData[parsedData.length - 1], 16)
29
29
  }
@@ -52,24 +52,24 @@ const parse = raw => {
52
52
  )[0] === '1',
53
53
  state: utils.states[parsedData[24].substring(0, 2)],
54
54
  input: {
55
- '1':
55
+ 1:
56
56
  utils.nHexDigit(
57
57
  utils.hex2bin(parsedData[24].substring(2, 4)),
58
58
  2
59
59
  )[1] === '1',
60
- '2':
60
+ 2:
61
61
  utils.nHexDigit(
62
62
  utils.hex2bin(parsedData[24].substring(2, 4)),
63
63
  2
64
64
  )[0] === '1'
65
65
  },
66
66
  output: {
67
- '1':
67
+ 1:
68
68
  utils.nHexDigit(
69
69
  utils.hex2bin(parsedData[24].substring(4, 6)),
70
70
  2
71
71
  )[1] === '1',
72
- '2':
72
+ 2:
73
73
  utils.nHexDigit(
74
74
  utils.hex2bin(parsedData[24].substring(4, 6)),
75
75
  2
@@ -132,12 +132,12 @@ const parse = raw => {
132
132
  raw: parsedData[18] + parsedData[19],
133
133
  sos: false,
134
134
  input: {
135
- '1': utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[1] === '1',
136
- '2': utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[0] === '1'
135
+ 1: utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[1] === '1',
136
+ 2: utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[0] === '1'
137
137
  },
138
138
  output: {
139
- '1': utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[1] === '1',
140
- '2': utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[0] === '1'
139
+ 1: utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[1] === '1',
140
+ 2: utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[0] === '1'
141
141
  },
142
142
  charge: parsedData[8] === '1'
143
143
  },
@@ -575,5 +575,5 @@ const parse = raw => {
575
575
  }
576
576
 
577
577
  module.exports = {
578
- parse: parse
578
+ parse
579
579
  }
package/src/gv55.js CHANGED
@@ -23,7 +23,7 @@ const parse = (raw, d) => {
23
23
  imei: parsedData[2],
24
24
  protocolVersion: utils.getProtocolVersion(parsedData[1]),
25
25
  temperature: null,
26
- history: history,
26
+ history,
27
27
  sentTime: utils.parseDate(parsedData[parsedData.length - 2]),
28
28
  serialId: parseInt(parsedData[parsedData.length - 1], 16)
29
29
  }
@@ -52,24 +52,24 @@ const parse = (raw, d) => {
52
52
  )[0] === '1',
53
53
  state: utils.states[parsedData[24].substring(0, 2)],
54
54
  input: {
55
- '1':
55
+ 1:
56
56
  utils.nHexDigit(
57
57
  utils.hex2bin(parsedData[24].substring(2, 4)),
58
58
  2
59
59
  )[1] === '1',
60
- '2':
60
+ 2:
61
61
  utils.nHexDigit(
62
62
  utils.hex2bin(parsedData[24].substring(2, 4)),
63
63
  2
64
64
  )[0] === '1'
65
65
  },
66
66
  output: {
67
- '1':
67
+ 1:
68
68
  utils.nHexDigit(
69
69
  utils.hex2bin(parsedData[24].substring(4, 6)),
70
70
  2
71
71
  )[1] === '1',
72
- '2':
72
+ 2:
73
73
  utils.nHexDigit(
74
74
  utils.hex2bin(parsedData[24].substring(4, 6)),
75
75
  2
@@ -132,12 +132,12 @@ const parse = (raw, d) => {
132
132
  raw: parsedData[18] + parsedData[19],
133
133
  sos: false,
134
134
  input: {
135
- '1': utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[1] === '1',
136
- '2': utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[0] === '1'
135
+ 1: utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[1] === '1',
136
+ 2: utils.nHexDigit(utils.hex2bin(parsedData[20]), 2)[0] === '1'
137
137
  },
138
138
  output: {
139
- '1': utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[1] === '1',
140
- '2': utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[0] === '1'
139
+ 1: utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[1] === '1',
140
+ 2: utils.nHexDigit(utils.hex2bin(parsedData[21]), 2)[0] === '1'
141
141
  },
142
142
  charge: parsedData[8] === '1'
143
143
  },
@@ -575,5 +575,5 @@ const parse = (raw, d) => {
575
575
  }
576
576
 
577
577
  module.exports = {
578
- parse: parse
578
+ parse
579
579
  }