This PR fixes what I would argue is a bug in maude_decom.get_raw_aca_packets. The problem was that I was calling this function with unusual arguments (frames inconsistent with the time range).
This function takes start/stop times and (optionally) the output from maude.get_frames. Using those frames, it should return all the full ACA packets within that time range (remember that the ACA telemetry comes split in four VCDU frames).
In the master version, it groups the packages using the VCDU frame counter, but instead of getting the counter from the frames themselves, it uses the requested time range to query MAUDE. Then it does not check whether the given frames match the frame counters from the time range, and proceeds happily, producing garbage (combining frames in groups of four, but starting at the wrong one).
There is no reason why this function should fail with inconsistent arguments, because the frame counter is in the frames themselves. By fixing this, I am also removing this extra call to MAUDE that is not necessary.
Other changes
This PR includes two other changes I made while working on this. One was cause for another error. The other one was just a relatively simple change:
Deal with the fact that sometimes IMGTYP can be 3 (code DNLD, "memory download") and we do not want things to crash in this case. I made minimal changes so the output is filled and client code can decide what to do. I added a small unit test that just checks that the function does not crash.
Enable dynamic background MSIDs PIXTLM and BGDTYP for blob decom, and change the type of PIXTLM and BGDTYP from int to string. This required changing one of the test data files.
Interface impacts
None
Testing
A new unit test was added for this (this PR is two commits, the first one is the test, so you can verufy the test fails before the change).
Unit tests
[x] Mac
Independent check of unit tests by Jean
[x] Linux
Functional tests
I have been using this with aca_view (PR sot/aca_view/pull/169), and there I am making many functional tests.
Description
This PR fixes what I would argue is a bug in
maude_decom.get_raw_aca_packets
. The problem was that I was calling this function with unusual arguments (frames inconsistent with the time range).This function takes start/stop times and (optionally) the output from
maude.get_frames
. Using those frames, it should return all the full ACA packets within that time range (remember that the ACA telemetry comes split in four VCDU frames).In the master version, it groups the packages using the VCDU frame counter, but instead of getting the counter from the frames themselves, it uses the requested time range to query MAUDE. Then it does not check whether the given frames match the frame counters from the time range, and proceeds happily, producing garbage (combining frames in groups of four, but starting at the wrong one).
There is no reason why this function should fail with inconsistent arguments, because the frame counter is in the frames themselves. By fixing this, I am also removing this extra call to MAUDE that is not necessary.
Other changes
This PR includes two other changes I made while working on this. One was cause for another error. The other one was just a relatively simple change:
Interface impacts
None
Testing
A new unit test was added for this (this PR is two commits, the first one is the test, so you can verufy the test fails before the change).
Unit tests
Independent check of unit tests by Jean
Functional tests
I have been using this with aca_view (PR sot/aca_view/pull/169), and there I am making many functional tests.