Best Way to Receive / Store Image Data using COSMOS v4 #1499
-
Hey all, I need a way to receive raw image data from a remote camera using COSMOS v4. The camera will send 100kB of raw image data and I need a way to 'catch' and store this data using COSMOS. We have a python program for decompressing the data and converting it into a viewable image format, so I really just need the raw data so I can store and export it to another file that our python program can read in. I got in contact with one of the COSMOS devs a while back about this same question and they said they created a Qt application that "gets raw image data from COSMOS, writes to a file, and then uses a Qt::Image and Qt::Pixmap.fromImage to set a Qt::Label.pixmap to the image". I have no experience in Qt app development and am wondering if there is just a simple way to define the image as a telemetry item in our tlm.txt file. Does anyone have any suggestions as to how I might go about defining the image as a telemetry item? Would the data type = BLOCK and size = 800000 (bits)? Any ideas/recommendations would be much appreciated! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Yes you want a BLOCK telemetry ITEM. Note you can have a variable length item if you need but you can only have 1 per packet. That item is designated with a length of 0. TlmExtractor should be able to extract the data but it will try to put it into a text file which probably won't work. You may need to implement your own subclass of PacketLogReader and write the data directly to a binary file. |
Beta Was this translation helpful? Give feedback.
Yes you want a BLOCK telemetry ITEM. Note you can have a variable length item if you need but you can only have 1 per packet. That item is designated with a length of 0. TlmExtractor should be able to extract the data but it will try to put it into a text file which probably won't work. You may need to implement your own subclass of PacketLogReader and write the data directly to a binary file.