How to convert a recorded signal in .bin file in int16 format to int8 without losing data?
5 次查看(过去 30 天)
显示 更早的评论
Hello everyone,
I have a recorded signal from GPS in .bin file which is stored in "int16" format. I want to convert the data into "int8" without losing the data.
I can't upload the file here for reference as it is too big (47 Gb).
For further clarification, I want the file to be replayed with a HackRF One connected directly to an ublox GNSS reciever via an SMA to SMA cable. I am currently studying GNSS interference monitoring and fully aware of what I am doing and all the risks of transmission in L-band therefore, I am conducting this experiment in a fully controlled situation.
0 个评论
回答(1 个)
Hornett
2024-9-2
To convert your GPS signal from `int16` to `int8`:
1. Scale and Normalize: Adjust the `int16` values to fit within the `int8` range. This involves dividing the `int16` values by the maximum possible value and scaling them to the `int8` range.
2. Clipping: Ensure that any values exceeding the `int8` limits are clipped to the maximum or minimum `int8` values.
3. Test and Validate: After conversion, test the data with your HackRF One and GNSS receiver to ensure it performs as expected.
This method helps minimize data loss inherent in reducing bit depth.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Signal Processing Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!