meshtastic 0.0.95 → 0.0.96

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: 97d144971ff7a74ca7623e32e95afca4d2436bb40dc8fec7c9d31d4570627752
4
- data.tar.gz: a00eeb6ed18164c2c3f2da207d01dd5e7dc76515b6e314fc38914e8b4e847748
3
+ metadata.gz: d024646f0fcbc4713e36a22e8fdf48abb6ad7472c09b73ec884eb7057bef5d54
4
+ data.tar.gz: 42bc2f49751ec4a262c0a106682f2ddc16d1dd2fb72972c266397fd5f36117b0
5
5
  SHA512:
6
- metadata.gz: a66fc870f5878bdc0e4602cedaae60de5692c131dcfbc3460c462c6907bfe11f099c84799d8f25957db6ba8a285b95c154ab5548c9195f2dcfd002cbd1f98ae1
7
- data.tar.gz: 1d3523d5f2ba4af1fefc6a5818cc3db7b8110dfa7de352b44581d88aac688162a72440793b2e97977ac634bc35585b783350ac88c3836521516f8100de43c0ca
6
+ metadata.gz: 342ae6d84dfc5321f8f95afaddf1127cfa95993480164d26c3fbc067e9503c4a26e547095bb42e8bfaa785a8e17941c758f1b70549110ddc132b38b05b7f81a5
7
+ data.tar.gz: 89b8383d56aa93a9209f50eb167b67c0be4bb65b8559408d289f42c127d0f18a2e382535f0bdc6af9b5da18f316f8479cebdb242c85921db0b77b9aa69344980
data/README.md CHANGED
@@ -44,7 +44,7 @@ mqtt_obj = Meshastic::MQTT.connect
44
44
  Meshtastic::MQTT.subscribe(
45
45
  mqtt_obj: mqtt_obj,
46
46
  region: 'US',
47
- channel_id_path: '2/e/LongFast/#',
47
+ channel_topic: '2/e/LongFast/#',
48
48
  psks: { LongFast: 'AQ==' }
49
49
  ) do |message|
50
50
  puts message.inspect
@@ -76,7 +76,7 @@ mqtt_obj = Meshastic::MQTT.connect
76
76
  Meshtastic::MQTT.subscribe(
77
77
  mqtt_obj: mqtt_obj,
78
78
  region: 'US',
79
- channel_id_path: '2/e/LongFast/#',
79
+ channel_topic: '2/e/LongFast/#',
80
80
  psks: { LongFast: 'AQ==' },
81
81
  filter: '!YOUR_CLIENT_ID'
82
82
  ) do |message|
@@ -48,7 +48,7 @@ module Meshtastic
48
48
  # mqtt_obj: 'required - mqtt_obj returned from #connect method'
49
49
  # root_topic: 'optional - root topic (default: msh)',
50
50
  # region: 'optional - region e.g. 'US/VA', etc (default: US)',
51
- # channel_id_path: 'optional - channel ID path e.g. "2/stat/#" (default: "2/e/LongFast/#")',
51
+ # channel_topic: 'optional - channel ID path e.g. "2/stat/#" (default: "2/e/LongFast/#")',
52
52
  # psks: 'optional - hash of :channel_id => psk key value pairs (default: { LongFast: "AQ==" })',
53
53
  # qos: 'optional - quality of service (default: 0)',
54
54
  # filter: 'optional - comma-delimited string(s) to filter on in message (default: nil)',
@@ -60,7 +60,7 @@ module Meshtastic
60
60
  mqtt_obj = opts[:mqtt_obj]
61
61
  root_topic = opts[:root_topic] ||= 'msh'
62
62
  region = opts[:region] ||= 'US'
63
- channel_id_path = opts[:channel_id_path] ||= '2/e/LongFast/#'
63
+ channel_topic = opts[:channel_topic] ||= '2/e/LongFast/#'
64
64
  # TODO: Support Array of PSKs and attempt each until decrypted
65
65
 
66
66
  public_psk = '1PG7OiApB1nwvP+rz05pAQ=='
@@ -77,7 +77,7 @@ module Meshtastic
77
77
  include_raw = opts[:include_raw] ||= false
78
78
 
79
79
  # NOTE: Use MQTT Explorer for topic discovery
80
- full_topic = "#{root_topic}/#{region}/#{channel_id_path}"
80
+ full_topic = "#{root_topic}/#{region}/#{channel_topic}"
81
81
  full_topic = "#{root_topic}/#{region}" if region == '#'
82
82
  puts "Subscribing to: #{full_topic}"
83
83
  mqtt_obj.subscribe(full_topic, qos)
@@ -276,7 +276,7 @@ module Meshtastic
276
276
  mqtt_obj: 'required - mqtt_obj object returned from #connect method',
277
277
  root_topic: 'optional - root topic (default: msh)',
278
278
  region: 'optional - region e.g. 'US/VA', etc (default: US)',
279
- channel_id_path: 'optional - channel ID path e.g. '2/stat/#' (default: '2/e/LongFast/#')',
279
+ channel_topic: 'optional - channel ID path e.g. '2/stat/#' (default: '2/e/LongFast/#')',
280
280
  psks: 'optional - hash of :channel_id => psk key value pairs (default: { LongFast: 'AQ==' })',
281
281
  qos: 'optional - quality of service (default: 0)',
282
282
  json: 'optional - JSON output (default: false)',
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Meshtastic
4
- VERSION = '0.0.95'
4
+ VERSION = '0.0.96'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: meshtastic
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.95
4
+ version: 0.0.96
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.