balboa_worldwide_app 1.1.1 → 1.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a309cfe60e168cb56a8a95ebdc80c6107428f4a700fc279889f6e27443a6c6f3
4
- data.tar.gz: 9fcb57e4ea84ea69936eac347256df08af2bb0550efba9933487f7234160b8a7
3
+ metadata.gz: 8e24d4fa8787d36a34d66af9993561f237ecfdf7876e121176870ba93fdd4f67
4
+ data.tar.gz: f223828f21309f8742616ab27ee925ddc02eab02304220418a015f25b79802a2
5
5
  SHA512:
6
- metadata.gz: 97e1def1e19e8beb851d8a2db516720d3732fc05d36d8ac61b1f2c77c1c62db2b9b5f9aebf9516a2a881ba15f29c0740d94cd7dedcae9d207ca31717e562587c
7
- data.tar.gz: 236c323cc0fe8e108eb4099ae19a86f9389f5a5b6aa92d0bb89f77ff5f244cbcf9130c6d24631e460ac445fe604e1ac86f470499e886ac29f5b8dd21e1dd58d2
6
+ metadata.gz: 2c12165571d6d619af2019fa30d85bee8af5d6758ffd9829363614b4ddab16993706dde33e91b0d5bc76578734a053f12fdad73290018317ec618ef04a6e6beb
7
+ data.tar.gz: 8256ecee88d74681ed4b1f25d1b5d75b7f9d20ff3681b973f8ef9f1d80de08ca63c7c622cc60d0ec3394c2323e5013e8a5b073d23dce80dec08c25f7fb4c25f4
@@ -14,8 +14,8 @@ module BWA
14
14
  @io = Net::Telnet::RFC2217.new("Host" => uri.host, "Port" => uri.port || 23, "baud" => 115200)
15
15
  @queue = []
16
16
  else
17
- require 'serialport'
18
- @io = SerialPort.open(uri.path, "baud" => 115200)
17
+ require 'rubyserial'
18
+ @io = Serial.new(uri.path, 115200)
19
19
  @queue = []
20
20
  end
21
21
  @buffer = ""
@@ -27,9 +27,10 @@ module BWA
27
27
  message, bytes_read = Message.parse(@buffer)
28
28
  # discard how much we read
29
29
  @buffer = @buffer[bytes_read..-1] if bytes_read
30
+ method = @io.respond_to?(:readpartial) ? :readpartial : :read
30
31
  unless message
31
32
  begin
32
- @buffer.concat(@io.readpartial(64 * 1024))
33
+ @buffer.concat(@io.send(method, 64 * 1024))
33
34
  rescue EOFError
34
35
  @io.wait_readable
35
36
  retry
@@ -1,7 +1,7 @@
1
1
  module BWA
2
2
  module Messages
3
3
  class SetTemperature < Message
4
- MESSAGE_TYPE = "\x0a\xbf\x20".force_encoding(Encoding::ASCII_8BIT)
4
+ MESSAGE_TYPE = "\xbf\x20".force_encoding(Encoding::ASCII_8BIT)
5
5
  MESSAGE_LENGTH = 1
6
6
 
7
7
  attr_accessor :temperature
@@ -1,7 +1,7 @@
1
1
  module BWA
2
2
  module Messages
3
3
  class SetTime < Message
4
- MESSAGE_TYPE = "\x0a\xbf\x21".force_encoding(Encoding::ASCII_8BIT)
4
+ MESSAGE_TYPE = "\xbf\x21".force_encoding(Encoding::ASCII_8BIT)
5
5
  MESSAGE_LENGTH = 2
6
6
 
7
7
  attr_accessor :hour, :minute, :twenty_four_hour_time
@@ -1,3 +1,3 @@
1
1
  module BWA
2
- VERSION = '1.1.1'
2
+ VERSION = '1.1.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: balboa_worldwide_app
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-24 00:00:00.000000000 Z
11
+ date: 2020-09-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: digest-crc
@@ -53,19 +53,19 @@ dependencies:
53
53
  - !ruby/object:Gem::Version
54
54
  version: 0.0.3
55
55
  - !ruby/object:Gem::Dependency
56
- name: serialport
56
+ name: rubyserial
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 1.3.1
61
+ version: 0.6.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 1.3.1
68
+ version: 0.6.0
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: byebug
71
71
  requirement: !ruby/object:Gem::Requirement
@@ -94,7 +94,7 @@ dependencies:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: '13.0'
97
- description:
97
+ description:
98
98
  email: cody@cutrer.com'
99
99
  executables:
100
100
  - bwa_mqtt_bridge
@@ -128,7 +128,7 @@ homepage: https://github.com/ccutrer/bwa
128
128
  licenses:
129
129
  - MIT
130
130
  metadata: {}
131
- post_install_message:
131
+ post_install_message:
132
132
  rdoc_options: []
133
133
  require_paths:
134
134
  - lib
@@ -143,8 +143,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
143
143
  - !ruby/object:Gem::Version
144
144
  version: '0'
145
145
  requirements: []
146
- rubygems_version: 3.0.3
147
- signing_key:
146
+ rubygems_version: 3.1.2
147
+ signing_key:
148
148
  specification_version: 4
149
149
  summary: Library for communication with Balboa Water Group's WiFi module or RS-485
150
150
  test_files: []