Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
energy
bmon
Commits
86ef6a41
Commit
86ef6a41
authored
Feb 04, 2021
by
Alan Mitchell
Browse files
Renamed acceleration sensors to make more obvious.
parent
015476d7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
bmsapp/lora/decode_elsys.py
bmsapp/lora/decode_elsys.py
+3
-3
No files found.
bmsapp/lora/decode_elsys.py
View file @
86ef6a41
...
...
@@ -46,9 +46,9 @@ def decode(data: bytes) -> Dict[str, Any]:
return
1
def
acc
(
i
:
int
)
->
int
:
res
[
'x'
]
=
bin8dec
(
data
[
i
+
1
])
/
63.0
# converts to Gs
res
[
'y'
]
=
bin8dec
(
data
[
i
+
2
])
/
63.0
res
[
'z'
]
=
bin8dec
(
data
[
i
+
3
])
/
63.0
res
[
'
accel_
x'
]
=
bin8dec
(
data
[
i
+
1
])
/
63.0
# converts to Gs
res
[
'
accel_
y'
]
=
bin8dec
(
data
[
i
+
2
])
/
63.0
res
[
'
accel_
z'
]
=
bin8dec
(
data
[
i
+
3
])
/
63.0
return
3
def
light
(
i
:
int
)
->
int
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment