.. |degc| unicode:: U+02103 .. DEGREE CELSIUS

Properties
==========

Configuration, status and telemetry download from the device is handled using a number of property variables. Each variable has a type (signed/unsigned integers, floating point numbers, strings, etc.) and a default value. Some properties are used for configuration and can be modified and stored in (optionally write-protected) non-volatile memory. Others are read-only and used for telemetry purposes. Some property changes take effect immediately, while others require a store and a system reset after update.

The system properties are divided into a number of property groups, each covering a specific part of the firmware. 

Property values can be listed, modified and stored using the ``prop`` debug shell commands or remotely through the :ref:`prop-client` library.  As an example, to change the CSP address of the device to 11 and the default interface to RS422/KISS, run:

.. code-block:: none

    [srs-3] prop get sys.csp.address
    21
    [srs-3] prop set sys.csp.address 11
    [srs-3] prop set sys.csp.routes "0/0 KISS"
    [srs-3] prop unlock sys
    [srs-3] prop save sys
    [srs-3] prop unlock -f sys
    [srs-3] prop save -f sys
    [srs-3] reboot
    ...
    [srs-3] prop get sys.csp.address
    11 
    [srs-3] prop get sys.csp.routes
    "0/0 KISS"

System Group
------------

The ``sys`` group contains system parameters that should remain fixed after launch. The group can be stored twice in ``boot`` and ``fallback`` configuration. Both are write-protected and must be unlocked using ``prop unlock`` before they can be written to.

=====================   =========   =============   =======================================
Property                Type        Default         Description
=====================   =========   =============   =======================================
sys.name                string      srs-3           String name for the system
sys.serial              uint32      ---             Serial number/ID of the device
sys.sw.version          uint32      ---             Running software version
sys.bootcount           uint32      ---             Number of times the system was booted
sys.gwdt.init           uint32      86400           Ground watchdog timer reset value
sys.gwdt.counter        uint32      ---             Ground watchdog timer current value
sys.gwdt.reset          uint32      ---             Ground watchdog timer trigger
sys.csp.address         uint8       21              CSP address of the device
sys.csp.routes          string      ---             Additional CSP routes in CIDR notation
sys.can.rate            uint32      1000000         CAN-bus bitrate
sys.can.promisc         bool        true            Accept all CSP/CFP CAN-frames
sys.uart.rate           uint32      1000000         RS422 baudrate
sys.net.enable          bool        false           Enable IP routing
sys.net.en.ip           string      192.168.100.2   Ethernet IP address
sys.net.en.prefix       uint8       24              Ethernet subnet mask bits
sys.net.en.gw           string      192.168.100.1   Ethernet gateway IP address
sys.net.rf.ip           string      192.168.200.2   Space link IP address
sys.net.rf.prefix       uint8       24              Space link subnet mask bits
sys.net.rf.gw           string      192.168.200.1   Space link gateway IP address
=====================   =========   =============   =======================================

Calibration Group
-----------------

The ``cal`` group contains factory calibration settings and should not be modified.

Configuration Group
-------------------

The ``conf`` group contains runtime settings.  The group can be stored to the ``boot`` configuration and is not write protected.

=====================   =========   ==========   =======================================
Property                Type        Default      Description
=====================   =========   ==========   =======================================
conf.reboot             uint16      0            Reboot timer
conf.led.enable         bool        false        Onboard LEDs enabled
conf.power.eth          bool        false        Ethernet power channel
=====================   =========   ==========   =======================================

Transmitter Group
-----------------

The ``tx`` group contains settings for the transmitter. The group can be stored twice in ``boot`` and ``fallback`` configuration. Both are write-protected and must be unlocked using ``prop unlock`` before they can be written to.

=====================   =========   ==========   =======================================
Property                Type        Default      Description
=====================   =========   ==========   =======================================
tx.freq                 uint32      2229500000   Transmit frequency
tx.rate                 uint32      512000       Transmit bitrate
tx.bt                   uint8       50           Transmit GMSK BT product
tx.pout                 float       25.00        Transmit power in dBm
tx.gain                 uint16      1000         Transmit gain manual setting
tx.alc.mode             uint8       2            ALC mode
tx.alc.kp               float       40.0         ALC Kp
tx.alc.limit            uint16      200          ALC maximum allowed gain adjust
tx.rs                   bool        true         Enable Reed-Solomon coding
tx.cc                   bool        true         Enable convolutional coding
tx.rand                 bool        true         Enable randomization
tx.crc                  bool        true         Enable CRC32C checksum
tx.size                 uint16      217          Maximum payload size
tx.frames               uint32      0            Number of transmitted frames
tx.pwd.fwd              float       ---          Measured forward power of last frame in dBm
tx.pwd.rfl              float       ---          Measured reflected power of last frame in dBm
tx.overpower            uint16      0            Number of overpower events
tx.pllnolock            uint16      0            Number of PLL lock lost events
=====================   =========   ==========   =======================================

Receiver Group
--------------

The ``rx`` group contains settings for the transmitter. The group can be stored twice in ``boot`` and ``fallback`` configuration. Both are write-protected and must be unlocked using ``prop unlock`` before they can be written to.

=====================   =========   ==========   =======================================
Property                Type        Default      Description
=====================   =========   ==========   =======================================
rx.freq                 uint32      2029500000   Receive frequency
rx.rate                 uint32      128000       Receive bitrate
rx.bw                   uint8       150          Receive bandwidth in percent of bitrate
rx.rs                   bool        true         Enable Reed-Solomon coding
rx.cc                   bool        true         Enable convolutional coding
rx.rand                 bool        true         Enable randomization
rx.crc                  bool        true         Enable CRC32C checksum
rx.size                 uint32      ---          Maximum payload size
rx.frames               uint32      0            Number of received frames
rx.detected             uint32      0            Number of detected frames
rx.rssi                 float       ---          Measured RSSI of last frame in dBm
rx.pllnolock            uint16      0            Number of PLL lock lost events
=====================   =========   ==========   =======================================

Telemetry Group
---------------

Telemetry values are stored in the ``tm`` group and updated once every second. The group does not support storage.

=====================   =========   =========   ===========================================
Property                Type        Default     Description
=====================   =========   =========   ===========================================
tm.temp.core            int16       0           MCU junction temperature in 1/100 |degc|
tm.temp.mcu             int16       0           MCU package temperature in 1/100 |degc|
tm.temp.power           int16       0           Power regulators temperature in 1/100 |degc|
tm.temp.lna             int16       0           LNA temperature in 1/100 |degc|
tm.temp.pa              int16       0           PA temperature in 1/100 |degc|
tm.volt.vin             uint16      0           Input voltage in mV
tm.volt.vreg            uint16      0           3.75 V rail voltage in mV
tm.volt.3v3             uint16      0           3.3 V rail voltage in mV
tm.cur.vin              int16       0           Input current in mA
tm.cur.vreg             int16       0           3.75 V rail current in mA
tm.cur.3v3              int16       0           3.3 V rail current in mA
tm.power.vin            uint16      0           Input power in mW
tm.power.vreg           uint16      0           3.75 V rail power in mW
tm.power.3v3            uint16      0           3.3 V rail power in mW
=====================   =========   =========   ===========================================
