mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-06-30 08:20:34 +08:00
ekf2: improve ring buffer sizing and dynamically allocate
This commit is contained in:
@@ -46,11 +46,11 @@ class EkfRingBufferTest : public ::testing::Test
|
||||
public:
|
||||
|
||||
sample _x, _y, _z;
|
||||
RingBuffer<sample> *_buffer;
|
||||
RingBuffer<sample> *_buffer{nullptr};
|
||||
|
||||
void SetUp() override
|
||||
{
|
||||
_buffer = new RingBuffer<sample>();
|
||||
_buffer = new RingBuffer<sample>(3);
|
||||
_x.time_us = 1000000;
|
||||
_x.data[0] = _x.data[1] = _x.data[2] = 1.5f;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user