sot/mica

Cannot get ac_status_word and misc_status_bits ACA hdr3 MSIDs

Closed this issue · 5 comments

In [1]: from mica.archive import aca_hdr3

In [2]: aca_hdr3.Msid('ccd_temp', '2010:001', '2010:003')
Out[2]: <mica.archive.aca_hdr3.Msid at 0x2a751d0>

In [3]: aca_hdr3.Msid('ac_status_word', '2010:001', '2010:003')
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
<ipython-input-3-13de79729d4c> in <module>()
----> 1 aca_hdr3.Msid('ac_status_word', '2010:001', '2010:003')

/data/baffin/tom/git/mica/mica/archive/aca_hdr3.pyc in __init__(self, msid, start, stop)
    494 
    495     def __init__(self, msid, start, stop):
--> 496         super(Msid, self).__init__(msid, start, stop, filter_bad=True)
    497 
    498 

/data/baffin/tom/git/mica/mica/archive/aca_hdr3.pyc in __init__(self, msid, start, stop, msid_data, filter_bad)
    433     def __init__(self, msid, start, stop, msid_data=None, filter_bad=False):
    434         if msid_data is None:
--> 435             msid_data = MSIDset([msid], start, stop)[msid]
    436         self.msid = msid
    437         self.tstart = DateTime(start).secs

/data/baffin/tom/git/mica/mica/archive/aca_hdr3.pyc in __init__(self, msids, start, stop)
    589             full_data[fd_idx] = self.slot_data[slot]
    590             # make a data dictionary to feed to the MSID constructor
--> 591             slot_data = {'vals': HDR3_DEF[hdr3_msid]['value'](full_data),
    592                          'desc': HDR3_DEF[hdr3_msid]['desc'],
    593                          'longdesc': HDR3_DEF[hdr3_msid]['longdesc'],

KeyError: 'value'

This was using the hdr3-msids branch.

And I think this was just not-implemented.

What do we want as a return type? An integer, string, or dictionary? And do we have useful data or a previous use of these data to check that I got the endianness and the mapping right?

16 bit unsigned int. I think we'll just have to play around with the data to verify endianness etc.

Superceded by #35.