BrainBitSignalData.PackNum Unreliable Value
Hi!
The problem is that the field PackNum
of BrainBitSignalData
contains the same value for a couple of subsequent frames which are expected to be unique for every frame. Meanwhile the data of signal values are different.
C++, Windows 11 x64, libs 1.0.6.17 from the latest commit, BrainBit with SensorVersion
read as:
FwMajor = {unsigned int} 137
FwMinor = {unsigned int} 0
FwPatch = {unsigned int} 0
HwMajor = {unsigned int} 1
HwMinor = {unsigned int} 0
HwPatch = {unsigned int} 0
ExtMajor = {unsigned int} 65
Here is the example of data received:
void SignalCb(Sensor *sensor,
BrainBitSignalData *data,
int32_t data_size,
void *) {
for (int32_t i = 0; i < data_size; ++i) {
auto s = std::format("{} {} {} {} {}",
data[i].PackNum,
data[i].T3,
data[i].T4,
data[i].O1,
data[i].O2);
std::cout << s << std::endl;
}
}
[2023-12-22 03:03:18.399] [sdk_log] [debug] BLE device Power mode set: [ThroughputOptimized]
0 0.14436964451755954 0.13456281143456597 0.15059409198197554 0.1386906992823594
0 0.1318696325966192 0.12206279951362564 0.1380940800610352 0.12619068736141908
1 0.143609756097561 0.13382275945926614 0.14983229621152516 0.1379514102472403
1 0.1429402760889779 0.13313306153589397 0.1493607991798393 0.13730481844407888
2 0.14222921584054551 0.1324460339031543 0.1487489211549007 0.13660596523853802
2 0.14143690246286628 0.13175519156951102 0.14775481009942065 0.13579190806570823
3 0.14060682354624132 0.131054049543428 0.14667181651288655 0.1350034093889326
3 0.1399117850416041 0.13038876570583888 0.14600805855565888 0.13438046873137355
4 0.13931516582027992 0.12978718737334002 0.14560102996924398 0.13382581121998904
4 0.13866971842738957 0.12919934196409413 0.14510855208258827 0.13325284314426722
5 0.13801091958133657 0.12858021600743866 0.1442204897122285 0.13256085640035287
5 0.13728345611901868 0.12795994564051213 0.14322332689602557 0.13184788880146867
...
The only command issued for the repro was SensorCommand::CommandStartSignal
.