Optical power budget calculator

Use it from Python

Every result on this site comes from ictdesigntools, an open-source (MIT) Python library.

pip install ictdesigntools
from ictdesigntools.optical.budget import POWER_PRESETS, PowerInput, calculate_power

b_plus = POWER_PRESETS["gpon-b-plus"]
r = calculate_power(
    PowerInput(
        "gpon-b-plus",
        b_plus.launch_power_min_dbm,
        b_plus.launch_power_max_dbm,
        b_plus.rx_sensitivity_dbm,
        b_plus.rx_overload_dbm,
        attenuation_max_db=27.8,
        attenuation_min_db=20,
    )
)
r.min_attenuation_db  # 13
r.max_attenuation_db  # 29.5
r.rx_power_min_dbm  # -26.3
r.rx_power_max_dbm  # -15
round(r.sensitivity_margin_db, 2)  # 1.7
r.overload_headroom_db  # 7
r.passes  # True

Input it can't use raises OpticalError, whose message says what to fix.

Result fields

Field Example Notes
inp, preset PowerInput(…), PowerPreset(…)
min_attenuation_db, max_attenuation_db 13, 29.5 The range the equipment allows
range_valid True False when the maximum is below the minimum
has_link True Whether a path attenuation was given
rx_power_min_dbm, rx_power_max_dbm -26.3, -15 Received power at R
sensitivity_margin_db, overload_headroom_db 1.7, 7
too_lossy, overloaded, passes False, False, True
problem None What is wrong, in words, or None
used_pct 94.2 Path attenuation as a share of the maximum

Web API

A web API with the same inputs and results is planned as an invite-only beta. Until then, a result's link is the way to share one.