Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
H
HEV - High Energy Ventilator
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
5
Issues
5
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
HEV - High Energy Ventilator
Commits
58325a51
Commit
58325a51
authored
Jun 02, 2021
by
Karol Hennessy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix to data comms
parent
000c6b94
Pipeline
#1710
failed with stages
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
common.h
arduino/hev_prototype_v1/src/common.h
+3
-3
main.cpp
arduino/hev_prototype_v1/src/main.cpp
+2
-2
CommsCommon.py
raspberry-dataserver/CommsCommon.py
+3
-3
No files found.
arduino/hev_prototype_v1/src/common.h
View file @
58325a51
...
...
@@ -44,7 +44,7 @@
#include <Arduino_Due_pinout.h>
#endif
#define HEV_FORMAT_VERSION 0xB
6
#define HEV_FORMAT_VERSION 0xB
7
//
const
float
MAX_VALVE_FRAC_OPEN
=
0
.
74
;
...
...
@@ -335,8 +335,8 @@ struct readback_data_format {
uint16_t
duration_pause
=
0
;
uint16_t
duration_exhale
=
0
;
uint8_t
valve_air_in
=
0
;
//
uint8_t
valve_o2_in
=
0
;
float
valve_air_in
=
0
.
0
;
//
float
valve_o2_in
=
0
.
0
;
uint8_t
valve_inhale
=
0
;
uint8_t
valve_exhale
=
0
;
uint8_t
valve_purge
=
0
;
...
...
arduino/hev_prototype_v1/src/main.cpp
View file @
58325a51
...
...
@@ -151,8 +151,8 @@ void loop()
ui_loop
.
reportReadbackValues
();
ui_loop
.
reportCycleReadings
();
ui_loop
.
reportAlarms
();
ui_loop
.
reportIVTReadings
();
ui_loop
.
reportDebugValues
();
// data duplicated to fast and readback
//
ui_loop.reportIVTReadings();
//
ui_loop.reportDebugValues(); // data duplicated to fast and readback
ui_loop
.
reportTargets
();
// per cycle receiver
...
...
raspberry-dataserver/CommsCommon.py
View file @
58325a51
...
...
@@ -267,7 +267,7 @@ class HEVVersionError(Exception):
@
dataclass
class
PayloadFormat
:
# class variables excluded from init args and output dict
_RPI_VERSION
:
ClassVar
[
int
]
=
field
(
default
=
0xB
6
,
init
=
False
,
repr
=
False
)
_RPI_VERSION
:
ClassVar
[
int
]
=
field
(
default
=
0xB
7
,
init
=
False
,
repr
=
False
)
_dataStruct
:
ClassVar
[
Any
]
=
field
(
default
=
Struct
(
"<BIB"
),
init
=
False
,
repr
=
False
)
_byteArray
:
ClassVar
[
bytearray
]
=
field
(
default
=
None
,
init
=
False
,
repr
=
False
)
...
...
@@ -737,8 +737,8 @@ class TargetFormat(PayloadFormat):
# for receiving DataFormat from microcontroller
# fill the struct from a byteArray,
def
fromByteArray
(
self
,
byteArray
):
logging
.
warn
(
f
"bytearray size {len(byteArray)} "
)
logging
.
warn
(
binascii
.
hexlify
(
byteArray
))
#
logging.warn(f"bytearray size {len(byteArray)} ")
#
logging.warn(binascii.hexlify(byteArray))
tmp_payload_type
=
0
tmp_mode
=
0
(
...
...
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