Vadim Yanitskiy | 89fc14b | 2017-06-16 21:00:29 +0700 | [diff] [blame] | 1 | <?xml version="1.0"?> |
| 2 | <block> |
Vadim Yanitskiy | 99be625 | 2017-07-16 23:26:34 +0700 | [diff] [blame] | 3 | <name>TRX Interface</name> |
Vadim Yanitskiy | 89fc14b | 2017-06-16 21:00:29 +0700 | [diff] [blame] | 4 | <key>grgsm_trx_interface</key> |
| 5 | <import>import grgsm</import> |
| 6 | <make>grgsm.trx($remote_addr, $base_port)</make> |
| 7 | |
| 8 | <param> |
| 9 | <name>base_port</name> |
| 10 | <key>base_port</key> |
| 11 | <value>5700</value> |
| 12 | <type>string</type> |
| 13 | </param> |
| 14 | |
| 15 | <param> |
| 16 | <name>remote_addr</name> |
| 17 | <key>remote_addr</key> |
| 18 | <value>127.0.0.1</value> |
| 19 | <type>string</type> |
| 20 | </param> |
| 21 | |
| 22 | <sink> |
| 23 | <name>bursts</name> |
| 24 | <type>message</type> |
Vadim Yanitskiy | 780816d | 2017-07-19 03:06:17 +0700 | [diff] [blame] | 25 | <optional>1</optional> |
Vadim Yanitskiy | 89fc14b | 2017-06-16 21:00:29 +0700 | [diff] [blame] | 26 | </sink> |
| 27 | |
Vadim Yanitskiy | ac3a527 | 2017-07-19 03:05:07 +0700 | [diff] [blame] | 28 | <source> |
| 29 | <name>bursts</name> |
| 30 | <type>message</type> |
Vadim Yanitskiy | 780816d | 2017-07-19 03:06:17 +0700 | [diff] [blame] | 31 | <optional>1</optional> |
Vadim Yanitskiy | ac3a527 | 2017-07-19 03:05:07 +0700 | [diff] [blame] | 32 | </source> |
| 33 | |
Vadim Yanitskiy | 89fc14b | 2017-06-16 21:00:29 +0700 | [diff] [blame] | 34 | <doc> |
| 35 | OsmoTRX like UDP interface for external applications. |
| 36 | |
| 37 | There are three UDP sockets: CLCK, CTRL and DATA. |
| 38 | Give a base port B (5700 by default), the SCH clock |
| 39 | interface is at port P=B. The TRX-side control interface |
| 40 | is on port P=B+100+1 and the data interface is on an odd |
| 41 | numbered port P=B+100+2. |
| 42 | |
| 43 | Indications on the SCH Clock Interface (CLCK) |
| 44 | The SCH clock interface is output only (from the radio). |
| 45 | CLOCK gives the current value of the BTS clock to |
| 46 | be used by external applications. The indications are |
| 47 | sent whenever a transmission packet arrives that is too |
| 48 | late or too early. |
| 49 | |
| 50 | Commands on Control Interface (CTRL) |
| 51 | The control interface uses a command-response protocol. |
| 52 | Commands are NULL-terminated ASCII strings. Each command |
| 53 | has a corresponding response. This interface isn't handled |
| 54 | by this particular block, and should be implemented outside. |
| 55 | |
| 56 | Messages on the Data Interface |
| 57 | Messages on the data interface carry one radio burst per |
| 58 | UDP message. |
| 59 | |
| 60 | Received Data Burst: |
| 61 | 1 byte timeslot index |
| 62 | 4 bytes GSM frame number, big endian |
| 63 | 1 byte RSSI in -dBm |
| 64 | 2 bytes correlator timing offset in 1/256 symbol steps, |
| 65 | 2's-comp, big endian |
| 66 | 148 bytes soft symbol estimates, 0 -> definite "0", |
| 67 | 255 -> definite "1" |
| 68 | |
| 69 | Transmit Data Burst: |
| 70 | 1 byte timeslot index |
| 71 | 4 bytes GSM frame number, big endian |
| 72 | 1 byte transmit level wrt ARFCN max, -dB (attenuation) |
| 73 | 148 bytes output symbol values, 0 & 1 |
| 74 | </doc> |
| 75 | </block> |