dji_mqtt_connect 0.1.37 → 0.1.37.1
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 +4 -4
- data/lib/dji_mqtt_connect/factories/osd/flight_hub_drone.rb +1 -1
- data/lib/dji_mqtt_connect/messages/thing/product/osd/drone.rb +3 -1
- data/lib/dji_mqtt_connect/mixins/wind_direction.rb +14 -0
- data/lib/dji_mqtt_connect/types.rb +16 -0
- data/lib/dji_mqtt_connect/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b63b04b393954efa6f4d626c1caf75faf321e0535012be40119e73b7388eb87d
|
|
4
|
+
data.tar.gz: e5934e0efc77c1362fc1592941c3aa84dd25d8ef49efde4b612a3aeb68131284
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ba512329d2aa1dc4b92f96a177fc35afc34a548892cb37ffc01f3ffcd380b2f88c91ac71a99401308a499b7e9b24200b2009b00ff3ef9e9d8277b22bbe307584
|
|
7
|
+
data.tar.gz: 03e703f9148725fb109b472e8e7d8beb1274b699a2cface1f77878e56d24e90db1740d3d7d7fed14e293489d9604826fa30ffa99e703517a240d86dfe7e7b7ec
|
|
@@ -98,7 +98,9 @@ module DjiMqttConnect
|
|
|
98
98
|
attribute :total_flight_time, Types::JSON::Decimal
|
|
99
99
|
attribute? :track_id, Types::String | Types::Nil
|
|
100
100
|
attribute :vertical_speed, Types::JSON::Decimal
|
|
101
|
-
attribute :wind_direction, Types::
|
|
101
|
+
attribute :wind_direction, Types::WindDirection | Types::Integer
|
|
102
|
+
include Mixins::WindDirection
|
|
103
|
+
|
|
102
104
|
attribute :wind_speed, Types::JSON::Decimal
|
|
103
105
|
|
|
104
106
|
# M30 Fields
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module DjiMqttConnect
|
|
4
|
+
module Mixins
|
|
5
|
+
# Provides a conditional that returns false for wind directions that are not one of the
|
|
6
|
+
# compass points DJI documents. A drone reports 0 when it has no reading, and one that is
|
|
7
|
+
# not connected has been seen reporting 256 alongside its other placeholders
|
|
8
|
+
module WindDirection
|
|
9
|
+
def wind_direction?
|
|
10
|
+
Types::WindDirection.valid?(wind_direction)
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -499,6 +499,22 @@ module DjiMqttConnect
|
|
|
499
499
|
VIDEO_TYPE_ZOOM = "zoom"
|
|
500
500
|
)
|
|
501
501
|
|
|
502
|
+
# The compass point the wind is blowing from. A drone reports 0 when it has no reading,
|
|
503
|
+
# and firmware has been seen reporting values outside the documented range entirely, so
|
|
504
|
+
# the OSD messages leave the value unconstrained and offer a wind_direction? predicate
|
|
505
|
+
# to ask whether a reported one is a compass point
|
|
506
|
+
# {"1":"True north","2":"Northeast","3":"East","4":"Southeast","5":"South","6":"Southwest","7":"West","8":"Northwest"}
|
|
507
|
+
WindDirection = Types::Integer.enum(
|
|
508
|
+
WIND_DIRECTION_TRUE_NORTH = 1,
|
|
509
|
+
WIND_DIRECTION_NORTHEAST = 2,
|
|
510
|
+
WIND_DIRECTION_EAST = 3,
|
|
511
|
+
WIND_DIRECTION_SOUTHEAST = 4,
|
|
512
|
+
WIND_DIRECTION_SOUTH = 5,
|
|
513
|
+
WIND_DIRECTION_SOUTHWEST = 6,
|
|
514
|
+
WIND_DIRECTION_WEST = 7,
|
|
515
|
+
WIND_DIRECTION_NORTHWEST = 8
|
|
516
|
+
)
|
|
517
|
+
|
|
502
518
|
# Target device for dongle/eSIM operations
|
|
503
519
|
# {"dock":"Set dock dongle","drone":"Set aircraft dongle"}
|
|
504
520
|
TargetDeviceType = Types::String.enum(
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dji_mqtt_connect
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.37
|
|
4
|
+
version: 0.1.37.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Sphere Drones
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-09-
|
|
11
|
+
date: 2026-09-15 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|
|
@@ -474,6 +474,7 @@ files:
|
|
|
474
474
|
- lib/dji_mqtt_connect/mixins/timestamp_or_current.rb
|
|
475
475
|
- lib/dji_mqtt_connect/mixins/video_quality.rb
|
|
476
476
|
- lib/dji_mqtt_connect/mixins/video_type.rb
|
|
477
|
+
- lib/dji_mqtt_connect/mixins/wind_direction.rb
|
|
477
478
|
- lib/dji_mqtt_connect/railtie.rb
|
|
478
479
|
- lib/dji_mqtt_connect/railties/message_serializer.rb
|
|
479
480
|
- lib/dji_mqtt_connect/topic_repository.rb
|