Skip to content
Module · ntn-traffic

ntn-traffic: a measured 5G NR NTN data plane for ns-3

ntn-traffic is an ns-3 module that places a 5G NR cell (mmWave backend or 5G-LENA nr at FR1) under satellite mobility and measures delay, jitter and loss from an in-band header carried through the GTP tunnel. It also supplies 5QI-tagged traffic sources, a QoS-aware flow monitor that exports TS 28.552 KPM series, and a calibration example against the 3GPP TR 38.821 link budget.

Run it in the browser

Choose an example, set its parameters and run the real ns-3 binary on this server. The scene shows the configured geometry before the run and the results after it.

NRTV video over a point-to-point link

Near-real-time video streaming between a server and a client over one point-to-point link. Writes a gnuplot trace of the traffic the client receives.

~60 snrtv-p2p-example
Parameters
Simulated duration (s)
Transport protocol: TCP or UDP
Print trace information
nr (default: SGP4 satellite gNB, NR-NTN radio, EPC) or p2p (the original 5 Mb/s, 2 ms point-to-point link)
nr: satellite altitude (km)
nr: UE ground offset north of the t=0 sub-satellite point (km)
nr: feeder gateway ground distance north of the UE (km)
Scene: Traffic
The interactive 3D globe loads here.

What this module models

NtnRealStackHelper assembles an NR cell on either the mmWave backend or 5G-LENA nr at FR1, with a SpectrumPhy, an LDPC error model, RLC and PDCP with timers relaxed to the slant round trip, RRC, and an EPC with GTP tunneling. Satellite and ground nodes must already carry mobility (SGP4, 3GPP TR 38.811 terminal classes, or HAPS). Four payload options (transparent, regenerative RU, regenerative RU plus DU, full gNB) add processing delay on top of slant range over the speed of light, and the feeder delay is re-evaluated every second from live geometry. On the nr backend, opt-in K_offset consumption programs ceil(RTT / slot) + 1 into the UL DCI to PUSCH gap following 3GPP TS 38.213. Losses chain onto the live channel: TR 38.811 excess loss with the scenario shadow-fading tables, the TR 38.811 Section 6.4.1 circular-aperture (Airy) beam pattern, and a tapped delay line whose tap table is a documented stand-in rather than TR 38.811 Table 6.9.2.

Traffic comes from NtnOranApplication profiles tied to TS 23.501 5QI values: conversational voice (5QI 1), eMBB video (5QI 2), URLLC periodic (5QI 82), Poisson background (5QI 9), mMTC periodic and saturating CBR, plus platform command-and-control telemetry at 5QI 69. A 24-byte header with sequence number, transmit timestamp, 5QI, S-NSSAI and QFI rides inside the GTP tunnel, so NtnOranSink derives one-way delay, RFC 3550 jitter and sequence-gap loss per QoS flow. NtnOranAiFlowMonitor keys ns-3 FlowMonitor flows by QoS identity and publishes KPM series under TS 28.552 names. Every scenario writes a sim_health.csv record that tags each KPI as measured, modeled or configured. Classic 3GPP HTTP, NRTV and CBR generators remain available.

Outputs

  • sim_health.csv with provenance gates (transport blocks decoded, SINR from the PHY trace, active error model) and a measured/modeled/configured tag per KPI
  • <prefix>_kpm_series.csv and .lp per-flow KPM series under TS 28.552 names
  • FlowMonitor XML, CSV, InfluxDB line protocol and E2SM-KPM-shaped exports
  • Per-QoS-flow one-way delay, RFC 3550 jitter, loss and throughput from NtnOranSink
  • array_gain_calibration.csv and array_gain_summary.csv from the beam-pattern calibration
  • scalability_regimes.csv rows with offered load, wall clock and peak RSS

Standards

SpecificationWhat the module takes from it
3GPP TR 38.811NTN excess loss and shadow-fading tables, Section 6.4.1 Airy beam pattern, terminal classes
3GPP TR 38.821Set-1 LEO-600 link budget for SINR calibration; transparent-payload feeder delay (Table 4.2-2)
3GPP TS 38.101-5NTN FR1 bands n255 and n256
3GPP TS 38.213K_offset for the UL DCI to PUSCH gap (Section 4.2)
3GPP TS 38.104frequency ranges behind the air_interface health tag
3GPP TS 23.5015QI, QFI and S-NSSAI identities of the traffic profiles
3GPP TS 28.552KPM measurement names such as DRB.UEThpDl and DRB.RlcSduDelayDl
O-RAN E2SM-KPMKPM series names and E2-indication-shaped exporter
IETF RFC 3550interarrival jitter computed per QoS flow
3GPP TR 25.892basis of the inherited HTTP and NRTV traffic models

Key numbers

Stated in the module documentation, each with the conditions it was measured under.

offset of measured SINR over the TR 38.821 closed-form CNR
4.06 ± 0.22 dBntn-tr38821-calibration, Set-1 LEO-600, S-band downlink, handheld terminal, mmwave backend, SGP4 satellite at 600 km, --simSeconds=600, RngRun 1 to 10, elevation at or above 10 deg; mean with 95 % Student-t half-width across 10 seeds
within-run spread (standard deviation) of the SINR offset
2.47 dBsame 10-seed LEO-600 calibration campaign, elevation at or above 10 deg
SINR decay from zenith to 10 deg elevation, measured against the TR free-space prediction
10.47 ± 1.30 dB measured vs 9.97 dB predictedsame 10-seed LEO-600 calibration campaign; mean with 95 % Student-t half-width
RMS error of the recovered beam pattern against the TR 38.811 Airy pattern, fixed ground point, angles 1.90 to 5.73 deg
2.85 ± 0.24 dBntn-tr38821-array-gain-calibration --boresightMode=point, RngRun 1 to 10, 10 seeds x 118 pairs; bias 0.32 ± 0.58 dB
RMS error of the recovered beam pattern, nadir-fixed boresight, angles 1.27 to 50.5 deg
2.71 ± 0.21 dBntn-tr38821-array-gain-calibration --boresightMode=nadir, RngRun 1 to 10

Examples (11)

Run it

  • In the browser

    Pick an example in the run panel above, set its parameters and press Run. The console streams live and the result opens with KPI charts.

  • In the ns-3 console

    The browser console accepts ns-3 style commands, for example ns3 run "nrtv-p2p-example --PrintHelp".

  • Locally with Docker

    The public image has the whole toolkit prebuilt. This runs nrtv-p2p-example with its built-in defaults.

    shell
    docker run --rm -it uzairdocker69/ns3-ntn-toolkit:latest ./ns3 run "nrtv-p2p-example"

Cite this

If you use this module, please cite the article that describes the toolkit: doi:10.1109/OJCOMS.2026.3745010.

M. Uzair, B. G. Aldahlan, A. A. Albar, H. Althumali and A. Alghammas, "ns3-ntn-toolkit: An integrated ns-3 platform for 6G non-terrestrial networks," IEEE Open Journal of the Communications Society, vol. 7, pp. 13440-13467, 2026, doi: 10.1109/OJCOMS.2026.3745010.

BibTeX
@article{uzair2026ns3ntntoolkit,
  author  = {Uzair, Muhammad and Aldahlan, Bassma G. and Albar, Ali A. and
             Althumali, Huda and Alghammas, Adnan},
  title   = {ns3-ntn-toolkit: An Integrated ns-3 Platform for 6G
             Non-Terrestrial Networks},
  journal = {IEEE Open Journal of the Communications Society},
  volume  = {7},
  pages   = {13440--13467},
  year    = {2026},
  doi     = {10.1109/OJCOMS.2026.3745010}
}