README
IQ_rec_OrigamiSat-2.grc

Overview
========
This GNU Radio Companion (.grc) file is used to record IQ data received with a USRP
in the IQ data format used by the Institute of Science Tokyo OrigamiSat-2 project.

The recorded IQ data can be used for post-processing, such as spectrogram display,
Doppler correction, and demodulation.


Requirements
============
Software
--------
・GNU Radio
・GNU Radio Companion
・UHD (USRP Hardware Driver)

Hardware
--------
・USRP-series SDR
  Operation has been confirmed with USRP B205mini-i.


How to Use
==========
1. Open IQ_rec_OrigamiSat-2.grc with GNU Radio Companion.

2. Specify the output file path in the File Sink block.

3. Set the center frequency, sampling rate, and receiver gain in the USRP Source block.

4. Run the flowgraph in GNU Radio Companion.

5. During execution, IQ data will be recorded to the specified output file.

6. Stop the flowgraph after recording for the required duration.


Recorded IQ Data Format
=======================
・Format: Binary
・Header: None
・Data type: int16
・Endianness: Little-endian
・Array format: I/Q interleaved

The data are stored in the following order:

I0, Q0, I1, Q1, I2, Q2, ...

Each complex sample consists of one int16 I component and one int16 Q component,
for a total of 4 bytes per complex sample.


OrigamiSat-2 5.8 GHz Downlink Signal
====================================
The following table shows the bandwidth for each data rate and example sampling
rate settings for IQ recording.

For details, refer to the following document:

ORI-2-0031-OPR_OrigamiSat-2_5.8GHz帯ダウンリンク通信データフォーマット.pdf

+-----------+-------------+------------+-----------+-------------------------------+
| Data rate | Symbol rate | Modulation | Bandwidth | Example sampling rate setting |
+-----------+-------------+------------+-----------+-------------------------------+
| 100 kbps  | 200 ksps    | BPSK       | 300 kHz   | 1 MS/s                        |
| 500 kbps  | 1 Msps      | BPSK       | 1.5 MHz   | 2 MS/s                        |
| 1 Mbps    | 2 Msps      | BPSK       | 3 MHz     | 4 MS/s                        |
| 5 Mbps    | 10 Msps     | BPSK       | 15 MHz    | 20 MS/s                       |
| 10 Mbps   | 10 Msps     | QPSK       | 15 MHz    | 20 MS/s                       |
| 20 Mbps   | 10 Msps     | QPSK       | 15 MHz    | 20 MS/s                       |
+-----------+-------------+------------+-----------+-------------------------------+
