Skip to content

Commit

Permalink
Formatting updates; some links still broken (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
aywaldron committed May 11, 2019
1 parent 41471bf commit 71738d5
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 33 deletions.
73 changes: 44 additions & 29 deletions doc/source/ait_cfdp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,46 +4,61 @@ AIT's CFDP Implementation
This documentation of AIT's CFDP implementation assumes some familiarity with the `CFDP standard <https://public.ccsds.org/pubs/727x0b4.pdf>`_. The implementation closely follows the `Implementer's Guide <https://public.ccsds.org/Pubs/720x2g3ec1.pdf>`_.

Transmission Modes
------------------
^^^^^^^^^^^^^^^^^^
AIT currently provides an implementation of CFDP **Class 1** for *unreliable transfer* with a transmission mode of *unacknowledged*. An implementation of the protocol's **Class 2**, for *reliable transfer* with an *acknowledged* transmission mode, is in the works. Currently the toolkit will use **Class 1** no matter what transmission mode is requested. In the future, either **Class 1** or **Class 2** will be used based on the transmission mode specified in the :ref:`MIB configuration <MIB>`.

.. _MIB:
The MIB
--------
^^^^^^^
The MIB, or Management Information Base, is where configurations for the protocol, such as the transmission mode, timeouts and limits, are specified, stored and accessed. The default MIB contents are stored in :mod:`ait.dsn.cfdp.mib`.

Custom MIB Files
^^^^^^^^^^^^^^^^^
When a CFDP entity (:mod:`ait.dsn.cfdp.cfdp.CFDP`) is instantiated, it will look for custom MIB files in the directory specified by `dsn.cfdp.mib.path` in the AIT configuration file whose location is indicated by the `AIT_CONFIG` `environment variable<https://ait-core.readthedocs.io/en/master/installation.html#environment-configuration>`_ set during installation. If you have AIT-Core installed, the `AIT_CONFIG` will likely point to `/path/to/ait-core/config/config.yaml`, and if you have not changed `dsn.cfdp.mib.path` in this file, it will likely point to `/path/to/ait-core/config/mib`. If you would like to store your MIB files elsewhere, update this configuration. If `dsn.cfdp.mib.path` is not present in the config.yaml, the MIB location will default to `/tmp/cfdp/mib`.
""""""""""""""""
When a CFDP entity (:mod:`ait.dsn.cfdp.cfdp.CFDP`) is instantiated, it will look for custom MIB files in the directory specified by :mod:`dsn.cfdp.mib.path` in the AIT configuration file whose location is indicated by the **AIT_CONFIG** `environment variable <https://ait-core.readthedocs.io/en/master/installation.html#environment-configuration>`_ set during installation. If you have AIT-Core installed, the **AIT_CONFIG** will likely point to **/path/to/ait-core/config/config.yaml**, and if you have not changed :mod:`dsn.cfdp.mib.path` in this file, it will likely point to **/path/to/ait-core/config/mib**. If you would like to store your MIB files elsewhere, update this configuration. If :mod:`dsn.cfdp.mib.path` is not present in the config.yaml, the MIB location will default to **/tmp/cfdp/mib**.

If no custom MIB files are found in the specified location, the default MIB contents will be used. When an entity is disconnected, it will dump both its local and remote MIB contents to the MIB directory described above.

MIB Configuration
^^^^^^^^^^^^^^^^^

"""""""""""""""""
The local and remote configurable MIB fields and their defaults are described below.

#### Local MIB Fields

`'entity_id'`: the local CFDP entity ID; defaults to 1.
`'issue_eof_sent'`: whether or not to send an end-of-file sent indication to the CFDP user; defaults to True.
`'issue_eof_recv'`: whether or not to send an end-of-file received indication to the CFDP user; False.
`'issue_file_segment_recv'`: whether or not to send a file data segment received indication to the CFDP user; defaults to False.
`'issue_transaction_finished'`: whether or not to send a transaction finished indication to the CFDP user; defaults to False.
`'issue_suspended'`: whether or not to send a transaction suspended indication to the CFDP user; defaults to True.
`'issue_resumed'`: whether or not to send a transaction resumed indication to the CFDP user; defaults to True.
`'fault_handlers'`: fault handler overwritten by the metadata PDU of a transaction; defaults to Ignore.

#### Remote MIB Fields

`'entity_id'`: the remote CFDP entity ID; defaults to None.
`'ut_address'`: the UT address for transmitting to this remote entity; defaults to None.
`'ack_limit'`: the positive ACK count limit (number of expirations); defaults to 3.
`'ack_timeout'`: the ACK timeout time in seconds; defaults to 10.
`'inactivity_timeout'`: the inactivity time limit for a transaction; defaults to 30.
`'nak_timeout'`: the time interval for NAK; defaults to 10.
`'nak_limit'`: the limit on number of NAK expirations; defaults to 3.
`'maximum_file_segment_length'`: the maximum file segment length in octets; defaults to 4096.
`'transmission_mode'`: the transmission mode; defaults to NO_ACK.
`'crc_required_on_transmission'`: whether a CRC is required on each transmission; defaults to False.
**Local MIB Fields**

* ``'entity_id'`` - the local CFDP entity ID; defaults to 1.

* ``'issue_eof_sent'`` - whether or not to issue an end-of-file sent indication; defaults to True.

* ``'issue_eof_recv'`` - whether or not to issue an end-of-file received indication; defaults to False.

* ``'issue_file_segment_recv'`` - whether or not to issue a file data segment received indication; defaults to False.

* ``'issue_transaction_finished'`` - whether or not to issue a transaction finished indication; defaults to False.

* ``'issue_suspended'`` - whether or not to issue a transaction suspended indication; defaults to True.

* ``'issue_resumed'`` - whether or not to issue a transaction resumed indication; defaults to True.

* ``'fault_handlers'`` - fault handler overwritten by the metadata PDU of a transaction; defaults to Ignore.

**Remote MIB Fields**

* ``'entity_id'`` - the remote CFDP entity ID; defaults to None.

* ``'ut_address'`` - the UT address for transmitting to this remote entity; defaults to None.

* ``'ack_limit'`` - the positive ACK count limit (number of expirations); defaults to 3.

* ``'ack_timeout'`` - the ACK timeout time in seconds; defaults to 10.

* ``'inactivity_timeout'`` - the inactivity time limit for a transaction; defaults to 30.

* ``'nak_timeout'`` - the time interval for NAK; defaults to 10.

* ``'nak_limit'`` - the limit on number of NAK expirations; defaults to 3.

* ``'maximum_file_segment_length'`` - the maximum file segment length in octets; defaults to 4096.

* ``'transmission_mode'`` - the transmission mode; defaults to NO_ACK.

* ``'crc_required_on_transmission'`` - whether a CRC is required on each transmission; defaults to False.

12 changes: 9 additions & 3 deletions doc/source/cfdp.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Overview of CFDP
================

The CFDP (`CCSDS <https://public.ccsds.org/default.aspx>`_ File Delivery Protocol) defines a standard for space-to-ground, ground-to-space, and space-to-space file transfer, which may be initiated by a file sending or receiving entity. Using CFDP allows for communication between spacecraft or instruments through files rather than packets, which may simplify Ground Data System and Flight Software processes. Here we provide an overview of the protocol, including terms and concepts that will be helpful to know in using AIT's CFDP implementation.
`CFDP <https://public.ccsds.org/pubs/727x0b4.pdf>`_ (`CCSDS <https://public.ccsds.org/default.aspx>`_ File Delivery Protocol) defines a standard for space-to-ground, ground-to-space, and space-to-space file transfer, which may be initiated by a file sending or receiving entity. Using CFDP allows for communication between spacecraft or instruments through files rather than packets, which may simplify Ground Data System and Flight Software processes. Here we provide an overview of the protocol, including terms and concepts that will be helpful to know in using AIT's CFDP implementation.

Entities & File Delivery Units
------------------------------
Expand All @@ -10,10 +10,16 @@ A **CFDP protocol entity** is a functioning instance of a CFDP implementation, s

Protocol Data Units
-------------------
FDUs are usually transmitted in multiple **protocol data units (PDUs)**, which will all by tagged with the same **transaction ID**, which uniquely identifieds a single instance of FDU delivery and contains the ID of the source CFDP entity together with a sequence number specific to that entity. A PDU can be one of three types - a **file data PDU**, a **file directive PDU**, or a **metadata PDU**. A file data PDU contains the contents of the file being delivered, while a file directive PDU contains only metadata and other non-file information for the protocol. A metadata PDU contains the following:
FDUs are usually transmitted in multiple **protocol data units (PDUs)**, which will all by tagged with the same **transaction ID**, which uniquely identifieds a single instance of FDU delivery and contains the ID of the source CFDP entity together with a sequence number specific to that entity.

A PDU can be one of three types - a **file data PDU**, a **file directive PDU**, or a **metadata PDU**. A file data PDU contains the contents of the file being delivered, while a file directive PDU contains only metadata and other non-file information for the protocol. A metadata PDU contains the following:

1. an indication of whether the file contains records with boundaries to be respected when the file is segmented for transmission in file data PDUs;

2. the size of the file if known;

3. the source and destination path names of the file;

4. optional fault handler overrides, messages to user, filestore requests, and/or flow label.


Expand All @@ -24,6 +30,6 @@ The **offset** of a given octet of file data is the number of data octets that p

Configuration & Transmission Modes
----------------------------------
The **management information base (MIB)** contains protocol configurations such as default values for user communications requirements and for communication timer settings. It is stored within CFDP entities as system tables. For instructions on configuring AIT's MIB, see MIB_. One of CFDPs configurable settings is the **transmission mode**, which can be either **unacknowledged**, meaning data delivery failures are not reported to the sender and therefore can't be repaired, or **acknowledged**, where the receiver informs the sender of any undelivered file segments of ancillary data, which are then retransmitted, thereby guaranteeing complete file delivery.
The **management information base (MIB)** contains protocol configurations such as default values for user communications requirements and for communication timer settings. It is stored within CFDP entities as system tables. For instructions on configuring AIT's MIB, see :ref:`this section <MIB_>`. One of CFDPs configurable settings is the **transmission mode**, which can be either **unacknowledged**, meaning data delivery failures are not reported to the sender and therefore can't be repaired, or **acknowledged**, where the receiver informs the sender of any undelivered file segments of ancillary data, which are then retransmitted, thereby guaranteeing complete file delivery.

AIT currently provides an implementation of CFDP **Class 1** for *unreliable transfer* with a transmission mode of unacknowledged. An implementation of the protocol's **Class 2**, for *reliable transfer* with an acknowledged transmission mode, is in the works.
3 changes: 2 additions & 1 deletion doc/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ Table of Contents:
:maxdepth: 2

installation
cfdp
ait_cfdp
AIT DSN API Documentation <ait>



Indices and tables
==================

Expand Down

0 comments on commit 71738d5

Please sign in to comment.