Configuration Reference
Run the integrated runtime with a config directory:
cargo run --release -p cdma-nib -- --config-dir config
| Flag | Purpose |
|---|
--config-dir <DIR> | Directory containing per-node JSON config files (CDMA_CONFIG_DIR env fallback) |
--radio-config <FILE> | Override the radio config embedded in bts.json |
--null-radio | Run without SDR hardware (TX drops, no RX) |
--a1-addr <ADDR> | MSC A1 signaling listen address (default 127.0.0.1:17013) |
--msc-mgmt-addr <ADDR> | MSC management gRPC listen address (default 127.0.0.1:17017) |
BTS radio and PHY configuration.
| Field | Type | Default | Description |
|---|
pilot_offset | integer | 0 | Pilot PN offset in chips (0–511) |
Cell identity and system parameters broadcast on the paging channel.
| Field | Type | Default | Description |
|---|
sid | integer | 1 | System ID |
nid | integer | 1 | Network ID |
base_id | integer | 1 | Base station ID |
reg_zone | integer | 0 | Registration zone |
total_zones | integer | 1 | Total number of registration zones |
zone_timer | integer | 0 | Zone timer index |
max_slot_cycle_index | integer | 0 | Maximum slot cycle index |
page_chan | integer | 1 | Paging channel number (1–7) |
config_seq | integer | 23 | Configuration sequence number |
acc_config_seq | integer | 1 | Access configuration sequence number |
power_up_reg | boolean | true | Require power-up registration |
parameter_reg | boolean | false | Require parameter-change registration |
auth_mode | integer | 0 | Authentication mode (0–3) |
p_rev | integer | 6 | Protocol revision |
min_p_rev | integer | 3 | Minimum protocol revision accepted |
lp_sec | integer | 0 | Leap seconds offset |
ltm_off | integer | 0 | Local time offset from UTC (30-min units) |
daylt | integer | 0 | Daylight saving time indicator |
prat | integer | 0 | Paging rate |
cdma_freq | integer | 384 | CDMA channel number (CDMA frequency assignment) |
ext_cdma_freq | integer | 0 | Extended CDMA channel number |
PHY/MAC/LAC runtime settings.
| Field | Type | Default | Description |
|---|
spreading_rate | string | "sr1" | Spreading rate: "sr1" or "sr3" |
orthogonal_code_length | integer | 64 | Walsh code length |
chip_rate_hz | integer | 1228800 | Chip rate in Hz |
tx_sample_rate_hz | integer | 4915200 | TX SDR sample rate (4× chip rate for SR1) |
tx_bandwidth_hz | integer | 3000000 | TX RF bandwidth in Hz |
tx_center_frequency_hz | integer | 881520000 | TX center frequency in Hz |
tx_lo_offset_hz | integer | 0 | TX LO hardware offset in Hz |
tx_digital_backoff | float | 0.15 | TX amplitude scale factor (0.0–1.0) |
block_size_chips | integer | 64 | Internal processing block size in chips |
tx_batch_chips | integer | 3072 | TX batch size in chips (2× PCG = 3072 for SR1) |
short_code_length_chips | integer | 32768 | Short PN code period in chips |
max_tx_lookahead_ms | integer | 5 | Maximum TX lookahead in milliseconds |
| Field | Type | Default | Description |
|---|
walsh_code | integer | 0 | Walsh code for pilot channel (always W0) |
gain | float | 1.0 | Pilot channel amplitude gain |
| Field | Type | Default | Description |
|---|
walsh_code | integer | 32 | Walsh code for sync channel (always W32) |
walsh_repetition | integer | 4 | Walsh repetition factor |
data_rate_bps | integer | 1200 | Sync channel data rate |
symbol_repeat | integer | 2 | Symbol repetition count |
interleaver.block_size | integer | 128 | Interleaver block size |
interleaver.m | integer | 7 | Interleaver M parameter |
interleaver.j | integer | 1 | Interleaver J parameter |
gain | float | 0.6 | Sync channel amplitude gain |
availability_max_size_bits | integer | 32 | Max bits in sync availability buffer |
| Field | Type | Default | Description |
|---|
walsh_code | integer | 1 | Walsh code for paging channel (W1) |
paging_channel_number | integer | 1 | Paging channel number (1–7) |
data_rate_bps | integer | 9600 | Paging channel data rate |
interleaver.block_size | integer | 384 | Interleaver block size |
interleaver.m | integer | 6 | Interleaver M parameter |
interleaver.j | integer | 6 | Interleaver J parameter |
gain | float | 0.8 | Paging channel amplitude gain |
availability_max_size_bits | integer | 96 | Max bits in paging availability buffer |
Overhead messages broadcast on the paging channel. schedule controls which messages are transmitted and in what order.
extended_system_parameters — IMSI defaults and soft-handoff thresholds:
| Field | Type | Default | Description |
|---|
mcc | string | "310" | Mobile country code (3-digit string) |
imsi_11_12 | string | "55" | IMSI digits 11–12 (2-digit string) |
pref_msid_type | integer | 3 | Preferred mobile ID type |
p_rev | integer | 6 | Protocol revision |
min_p_rev | integer | 6 | Minimum protocol revision |
soft_slope | integer | 16 | Soft handoff slope |
add_intercept | integer | 8 | T_ADD intercept |
drop_intercept | integer | 6 | T_DROP intercept |
packet_zone_id | integer | 0 | Packet zone ID |
use_tmsi | boolean | false | TMSI assignment enabled |
delete_for_tmsi | boolean | false | Delete TMSI on reassignment |
system_parameters — core cell parameters:
| Field | Type | Default | Description |
|---|
home_reg | boolean | true | Home registration enabled |
for_sid_reg | boolean | true | Foreign SID registration enabled |
for_nid_reg | boolean | true | Foreign NID registration enabled |
power_down_reg | boolean | false | Power-down registration enabled |
reg_prd | integer | 29 | Registration period (timer index) |
base_lat | integer | — | Base station latitude (in units per spec) |
base_long | integer | — | Base station longitude |
reg_dist | integer | 0 | Registration distance |
srch_win_a | integer | 6 | Active set search window |
srch_win_n | integer | 8 | Neighbor set search window |
srch_win_r | integer | 9 | Remaining set search window |
t_add | integer | 18 | Pilot T_ADD threshold (0.5 dB units) |
t_drop | integer | 28 | Pilot T_DROP threshold |
t_comp | integer | 8 | T_COMP comparison threshold |
t_tdrop | integer | 3 | T_TDROP timer index |
pwr_rep_thresh | integer | 2 | Power report threshold |
pwr_rep_frames | integer | 9 | Power report frame count |
pwr_thresh_enable | boolean | true | Threshold-based power reporting |
pwr_period_enable | boolean | true | Periodic power reporting |
pwr_rep_delay | integer | 2 | Power report delay |
access_parameters — reverse access channel configuration:
| Field | Type | Default | Description |
|---|
acc_chan | integer | 0 | Access channel number |
nom_pwr | integer | 0 | Nominal TX power adjustment |
init_pwr | integer | 0 | Initial power offset |
pwr_step | integer | 3 | Power step size (dB) |
num_step | integer | 3 | Number of power steps per probe |
max_cap_sz | integer | 4 | Maximum access capsule size |
pam_sz | integer | 10 | Preamble length |
max_req_seq | integer | 3 | Maximum request sequences |
max_rsp_seq | integer | 3 | Maximum response sequences |
acc_tmo | integer | 3 | Access timeout |
probe_bkoff | integer | 0 | Probe backoff |
bkoff | integer | 0 | Sequence backoff |
Reverse link configuration.
| Field | Type | Default | Description |
|---|
access_channels_per_paging_channel | integer | 1 | R-ACH channels per paging channel |
access_channel_numbers | array | [0] | Access channel number list |
access_channel_rate_bps | integer | 4800 | Access channel data rate |
access_frame_ms | integer | 20 | Access frame duration in ms |
require_r_csch_f_csch_arq_ack | boolean | true | Require ACK on access channel messages |
arq_ack_timeout_ms | integer | 400 | ARQ ACK timeout (T1m) |
reverse_access_finger_pool_size | integer | 8 | Number of RAKE fingers for access channel |
global_finger_pool_size | integer | 1 | Global RAKE finger pool size |
Overhead channel scheduling.
| Field | Type | Default | Description |
|---|
fragment_availability_interval_chips | integer | 32768 | Paging fragment scheduling interval |
sync_superframe_interval_chips | integer | 98304 | Sync superframe interval |
t1b_ms | integer | 1280 | T1b timer period in ms |
require_spm | boolean | true | Require System Parameters Message |
require_apm | boolean | true | Require Access Parameters Message |
require_cclm | boolean | true | Require CDMA Channel List Message |
require_espm | boolean | true | Require Extended System Parameters Message |
Abis TCP signaling address (BTS side).
| Field | Type | Default | Description |
|---|
bind_addr | string | "127.0.0.1:5604" | Local TCP bind address for the BTS Abis signaling listener |
Abis UDP bearer addressing (BTS side).
| Field | Type | Default | Description |
|---|
bind_addr | string | "127.0.0.1:17014" | Local UDP bind address |
remote_addr | string | "127.0.0.1:17022" | BSC bearer address |
BSC radio access control and paging policy.
| Field | Type | Default | Description |
|---|
supported_for_rcs | array | [1, 3] | Supported forward radio configurations |
supported_rev_rcs | array | [1, 3] | Supported reverse radio configurations |
preferred_pairs | array | [{for_rc:3, rev_rc:3}] | Preferred forward/reverse RC pairs, tried in order |
idle_timeout_s | integer | 30 | Traffic channel idle timeout before release |
rev_fch_gating_mode | boolean | false | Reverse FCH gating mode |
| Field | Type | Default | Description |
|---|
ack_timeout_ms | integer | 400 | Traffic assignment ACK timeout (T1m) |
max_retries | integer | 3 | Maximum retransmissions |
| Field | Type | Default | Description |
|---|
ack_timeout_ms | integer | 10000 | Paging ACK timeout in ms |
max_retries | integer | 0 | Maximum paging retries |
BSC-side Abis timers per A.S0003-A §8 Table 8-1. Granularity is 100 ms; ranges are 0–1000 ms except tsetupb_ms (0–500).
| Field | Type | Default | Description |
|---|
tsetupb_ms | integer | 100 | §8.2 — Abis BTS Setup timer (range 0–500) |
tchanstatb_ms | integer | 500 | §8.3 — Abis Traffic Channel Status timer |
tdrptgtb_ms | integer | 500 | §8.5 — Abis BTS Release Ack timer |
tbstreqb_ms | integer | 500 | §8.6 — Abis Burst Response timer |
Abis TCP signaling address (BSC side).
| Field | Type | Default | Description |
|---|
remote_addr | string | "127.0.0.1:5604" | BTS Abis signaling endpoint the BSC connects to |
Abis UDP bearer addressing (BSC side).
| Field | Type | Default | Description |
|---|
bind_addr | string | "127.0.0.1:17022" | Local UDP bind address |
remote_addr | string | "127.0.0.1:17014" | BTS bearer address |
| Field | Type | Default | Description |
|---|
mobile_idle_timeout_s | integer | 3600 | Evict idle registered mobiles with no access activity and no active traffic channel after this many seconds. Set to 0 to disable. |
voice_bearer_bind_ip | string | "127.0.0.1" | Local IP that voice bearer UDP sockets bind to. Set to the host’s network-facing IP when BSC and voice gateway are on separate hosts. |
node_id | string | "bsc" | Stable identifier for this BSC node, written to the HLR on every registration and included in management events. Must be unique across BSC instances. |
MSC call control and voice policy.
| Field | Type | Default | Description |
|---|
a1_listen_addr | string | "127.0.0.1:17013" | A1 signaling listen address |
mgmt_grpc_addr | string | "127.0.0.1:17017" | MSC management gRPC listen address |
a1_peers | array | [] | Static A1 peer list (peer_id + addr) |
| Field | Type | Default | Description |
|---|
supported_service_options | array | [3, 68, 70] | Accepted EVRC service options. Shipped msc.json widens this to [3, 17, 68, 73]. |
wav_file | string | null | WAV audio file path for fallback playback |
media_ringback_enabled | boolean | false | Generate ringback tone in media path |
media_ringback_type | string | "nanp" | Ringback tone type: "nanp" or "etsi" |
answer_delay_ms | integer | 10000 | Delay before automatic answer in local simulation paths |
release_timeout_ms | integer | 5000 | Call release timeout in ms |
service_connect_timeout_ms | integer | 20000 | Service connect timeout in ms |
voice_bearer_bind_ip | string | "127.0.0.1" | Local IP that voice bearer UDP sockets bind to. Set to the host’s network-facing IP when MSC and voice gateway run on separate hosts. |
| Field | Type | Default | Description |
|---|
enabled | boolean | false | Enable external SIP voice gateway |
endpoint | string | "http://127.0.0.1:17015" | Voice gateway gRPC endpoint |
fallback_to_wav | boolean | true | Play WAV audio if gateway is unreachable |
| Field | Type | Default | Description |
|---|
enabled | boolean | false | Enable welcome SMS on registration |
text | string | "Welcome to 1xBTS!" | SMS body text |
originating_number | string | "0000" | Originating number shown to subscriber |
inactive_days_threshold | integer | 30 | Days of inactivity before re-sending |
Packet data transport configuration.
| Field | Type | Default | Description |
|---|
packet_grpc_listen_addr | string | "127.0.0.1:17021" | Packet service gRPC listen address |
| Field | Type | Default | Description |
|---|
transport | string | "tun" | Transport mode: "tun", "fou", or "fou_tcp" |
fou_remote | string | null | FOU or FOU-TCP remote endpoint (host:port) |
fou_local_port | integer | 17011 | Local FOU receive port |
tun_nat_interface | string | null | Network interface name for TUN NAT (required when transport="tun") |
Transport modes:
tun — kernel TUN device; packets routed via NAT on tun_nat_interface
fou — FOU (Foo-over-UDP) tunnel; direct UDP encapsulation
fou_tcp — FOU with TCP relay (for NAT traversal); connects to fou_remote
HLR subscriber database configuration.
| Field | Type | Default | Description |
|---|
grpc_listen_addr | string | "127.0.0.1:17019" | HLR service gRPC listen address |
postgres_dsn | string | null | null | PostgreSQL connection string. When unset, HLR runs without persistence. Shipped sample: "postgres://1xbts:1xbts@localhost:45432/1xbts". |
SMSC message store configuration.
| Field | Type | Default | Description |
|---|
grpc_listen_addr | string | "127.0.0.1:17020" | SMSC service gRPC listen address |
postgres_dsn | string | null | null | PostgreSQL connection string. When unset, SMSC runs without persistence. Shipped sample: "postgres://1xbts:1xbts@localhost:45432/1xbts". |
Management gRPC facade configuration.
| Field | Type | Default | Description |
|---|
grpc_listen_addr | string | "127.0.0.1:17016" | Management gRPC listen address |
tokio_console | boolean | false | Enable Tokio console on port 17018 |
iq_capture_dir | string | "capture-iq-wav" | Directory for IQ capture WAV output |
mtls | object | null | mTLS config (see below); omit for plaintext |
| Field | Type | Description |
|---|
cert_path | string | Path to PEM-encoded server certificate |
key_path | string | Path to PEM-encoded server private key |
client_ca_path | string | Path to PEM-encoded CA bundle for client certificate verification |
PCF-side packet service client configuration.
| Field | Type | Default | Description |
|---|
packet_grpc_endpoint | string | "http://127.0.0.1:17021" | Packet service endpoint consumed by the BSC-facing PCF client |
Real A8/A9 network transport is still planned work; this gRPC endpoint is the current local service boundary for packet sessions.
Radio config files are standalone JSON passed via --radio-config. They are independent of the config/ directory.
| Field | Type | Description |
|---|
kind | string | Backend: "uhd", "lime", "blade_rf", "soapy" |
device | string | Device selector string (empty = first found) |
channel | integer | RF channel index |
tx_antenna | string | TX antenna port name |
tx_gain_db | float | TX gain in dB |
rx_antenna | string | RX antenna port name |
rx_gain_db | float | RX gain in dB |
rx_freq_hz | integer | RX center frequency in Hz |
rx_sample_rate_hz | integer | RX sample rate (must be 4× chip rate = 4915200 for SR1) |
rx_bandwidth_hz | integer | RX RF bandwidth in Hz |
rx_sample_delay | integer | RX timing compensation in samples |
rx_batch_pcgs | integer | RX batch size in PCGs (default: 2) |
{
"kind": "uhd",
"device": "type=b200,num_recv_frames=1024,num_send_frames=1024",
"channel": 0,
"antenna": "TX/RX",
"tx_gain_db": 65.0,
"rx_antenna": "RX2",
"rx_gain_db": 50.0,
"rx_freq_hz": 836520000,
"rx_sample_rate_hz": 4915200,
"rx_bandwidth_hz": 5000000,
"rx_sample_delay": 50
}
{
"kind": "lime",
"device": "",
"channel": 0,
"tx_antenna": "BAND1",
"tx_gain_db": 60,
"rx_antenna": "LNAW",
"rx_gain_db": 20,
"rx_freq_hz": 836520000,
"rx_sample_rate_hz": 4915200,
"rx_bandwidth_hz": 5000000,
"rx_sample_delay": 97
}
rx_sample_delay compensates for LimeSDR hardware timing offset in the receive path.
{
"kind": "blade_rf",
"device": "",
"channel": 0,
"fpga_path": null,
"tx_antenna": "TXA",
"rx_antenna": "B_BALANCED",
"tx_gain_db": 50,
"rx_gain_db": 40,
"rx_freq_hz": 836520000,
"rx_sample_rate_hz": 4915200,
"rx_bandwidth_hz": 2500000,
"rx_reference_dbm": null,
"rx_sample_delay": 0,
"rx_batch_pcgs": 2,
"num_buffers": 16,
"buffer_size": 8192,
"num_transfers": 8,
"stream_timeout_ms": 3500
}
| Field | Description |
|---|
fpga_path | Path to .rbf FPGA image; null uses libbladeRF host auto-load (~/.config/Nuand/bladeRF/) |
rx_reference_dbm | Optional RX reference power level in dBm |
num_buffers | Stream buffer count |
buffer_size | Samples per buffer |
num_transfers | Concurrent USB transfers |
stream_timeout_ms | Stream transfer timeout |
{
"kind": "soapy",
"device": "",
"channel": 0,
"antenna": "TX/RX",
"tx_gain_db": 60.0,
"rx_antenna": "RX2",
"rx_gain_db": 50.0,
"rx_freq_hz": 836520000,
"rx_sample_rate_hz": 4915200,
"rx_bandwidth_hz": 5000000,
"rx_sample_delay": 0,
"rx_batch_pcgs": 2
}
| Port | Protocol | Owner | Purpose |
|---|
| 5604 | TCP | BTS/BSC | Abis signaling |
| 17013 | TCP | MSC | A1 signaling listener |
| 17014 | UDP | BTS | Abis bearer (BTS side) |
| 17015 | gRPC | Voice gateway | MSC-controlled SIP/RTP bridge |
| 17016 | gRPC | Management facade | Node-scoped APIs and compatibility APIs |
| 17017 | gRPC | MSC management | Call initiation, call list, SMS |
| 17018 | TCP | Tokio console | Optional async diagnostics |
| 17019 | gRPC | HLR service | Subscriber and registration persistence |
| 17020 | gRPC | SMSC service | SMS submission and delivery persistence |
| 17021 | gRPC | Packet service | Packet sessions and packet service RPCs |
| 17022 | UDP | BSC | Abis bearer (BSC side) |
| 17010 | UDP | PDSN | FOU remote default |
| 17011 | UDP | PDSN | FOU local default |
| 17012 | TCP | FOU-NAT | FOU-TCP relay (Docker service) |
| 45432 | TCP | PostgreSQL | HLR and SMSC (Docker service) |