Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
On-Board Software
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Avionics
Software Development
On-Board Software
Commits
278e1612
Commit
278e1612
authored
11 months ago
by
Federico Mandelli
Browse files
Options
Downloads
Patches
Plain Diff
[SensorConfig] Changed bmx to not use a fifo
parent
7b7c3736
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/boards/MockupMain/Configs/SensorsConfig.h
+7
-5
7 additions, 5 deletions
src/boards/MockupMain/Configs/SensorsConfig.h
with
7 additions
and
5 deletions
src/boards/MockupMain/Configs/SensorsConfig.h
+
7
−
5
View file @
278e1612
...
...
@@ -44,7 +44,7 @@ namespace SensorsConfig
using
namespace
std
::
chrono_literals
;
// clang-format on
constexpr
unsigned
int
NUMBER_OF_SENSORS
=
6
;
constexpr
unsigned
int
NUMBER_OF_SENSORS
=
8
;
constexpr
uint32_t
MAG_CALIBRATION_PERIOD
=
100
;
// [ms]
// BMX160
...
...
@@ -55,8 +55,8 @@ constexpr Boardcore::BMX160Config::GyroscopeRange BMX160_GYRO_FSR_ENUM =
Boardcore
::
BMX160Config
::
GyroscopeRange
::
DEG_1000
;
constexpr
unsigned
int
BMX160_ACC_GYRO_ODR
=
50
;
constexpr
Boardcore
::
BMX160Config
::
OutputDataRate
BMX160_ACC_GYRO_ODR_ENUM
=
Boardcore
::
BMX160Config
::
OutputDataRate
::
HZ_
5
0
;
constexpr
unsigned
int
BMX160_MAG_ODR
=
10
0
;
Boardcore
::
BMX160Config
::
OutputDataRate
::
HZ_
10
0
;
constexpr
unsigned
int
BMX160_MAG_ODR
=
5
0
;
constexpr
Boardcore
::
BMX160Config
::
OutputDataRate
BMX160_MAG_ODR_ENUM
=
Boardcore
::
BMX160Config
::
OutputDataRate
::
HZ_100
;
...
...
@@ -125,8 +125,10 @@ constexpr float BATTERY_VOLTAGE_COEFF = (150 + 40.2) / 40.2;
// BMX160_SAMPLE_PERIOD: Sample before the fifo is full, but slightly after the
// watermark level (watermark + 30) ---> high slack due to scheduler
// imprecision, avoid clearing the fifo before the interrupt
constexpr
auto
BMX160_SAMPLE_PERIOD
=
std
::
chrono
::
milliseconds
(
BMX160_FIFO_FILL_TIME
*
(
BMX160_FIFO_WATERMARK
+
30
)
*
4
/
1024
);
// [ms]
constexpr
auto
BMX160_SAMPLE_PERIOD
=
50
_hz
;
/*std::chrono::milliseconds(
BMX160_FIFO_FILL_TIME * (BMX160_FIFO_WATERMARK + 30) * 4 / 1024); //
[ms]*/
constexpr
auto
LIS3MDL_SAMPLE_PERIOD
=
100
_hz
;
constexpr
auto
INTERNAL_ADC_SAMPLE_PERIOD
=
1
_hz
;
constexpr
auto
INTERNAL_TEMP_SAMPLE_PERIOD
=
1
_hz
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment