Skip to content
69 changes: 35 additions & 34 deletions score/time_slave/docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,64 +15,65 @@
.. _time_slave:

Time Slave
#####################

.. note:: Document header
##########

.. document:: Time Slave
:id: doc__time_slave
:status: draft
:status: valid
:version: 1
:safety: ASIL_B
:safety: QM
:security: NO
:realizes: wp__cmpt_request
:tags: time_slave

.. note::
Work in progress: structure, titles, and needs IDs only. Content and req/comp/feat traceability links to follow in later PRs.

.. code-block:: rst

.. comp:: Time Slave
:id: comp__time_slave_template
:security: YES
:safety: ASIL_B
:status: invalid
:implements: logic_arc_int__feature_name__interface_name1
:consists_of: comp__component_name_internal_1, comp__component_name_internal_2, comp__component_name_internal_3
:belongs_to: feat__feature_name

.. attention::
The above directives must be updated according to your Component.
.. comp:: Time Slave
:id: comp__time_slave
:security: NO
:safety: QM
:status: valid
:version: 1
:belongs_to: feat__time[version==1]

- Adjust ``status`` to be ``valid``
- Adjust ``safety`` and ``tags`` according to your needs

Abstract
========

[A short (~200 word) description of the component.]

This component implements a gPTP (IEEE 802.1AS) time synchronization slave daemon that receives time synchronization data from network and sends it via ts_client to the time_daemon for validation.

Specification
=============

[Describe the requirements, architecture of any component.] or
The time_slave component provides IEEE 802.1AS synchronization handling, i.e. it receives gPTP network messages from time master, does path delay measurement, computes local clock correction values, and publishes synchronized time snapshots via ts_client shared memory IPC.

Runtime flow follows continuous loop:

How to Teach This
=================
1. **Initialization and setup**: Bind configured network interface, initialize gPTP engine and IPC publisher, enable hardware timestamping when platform supports it.
2. **Protocol processing**: Filter by configured gPTP domain, process Sync and Follow_Up pairs, compute offset and peer delay from protocol timestamps and correction fields.
3. **Clock adjustment and status tracking**: Apply PHC step or frequency adjustment based on offset behavior, detect synchronization timeout and forward/backward time leaps.
4. **Publishing**: Publish synchronized time snapshot, peer delay, rate deviation, and status flags to IPC at fixed 50 millisecond interval.

[How to teach users, new and experienced, how to apply the CR to their work.]
Key Behaviors
-------------

.. note::
For a CR that adds new functionality or changes behaviour, it is helpful to include a section on how to teach users, new and experienced, how to apply the CR to their work.
**Timestamping Strategy**: Hardware timestamping preferred; software timestamping fallback used when hardware capabilities are unavailable.

Footnotes
=========
**Clock Control Strategy**: Large offset handled by step adjustment; stable offset evolution handled by frequency slew adjustment.

**Fault and Quality Flags**: Timeout status set when no valid Sync/Follow_Up pair is processed within configured timeout window. Time leap future and time leap past flags track forward and backward master time discontinuities.

**Diagnostics**: Optional runtime instrumentation can record synchronization events into CSV output when diagnostics option is enabled.

**Platform Support**: Linux and QNX 8.0 SDP supported for raw Ethernet, timestamp acquisition, and PHC control.

[A collection of footnotes cited in the CR, and a place to list non-inline hyperlink targets.]
**Error Reporting**: Initialization, network, protocol, and timestamping fallback events are logged via score::mw::log.

Assumptions of Use
------------------

Users must configure and bring up network interface before starting time_slave. Exactly one time_slave instance per network interface is supported.

Footnotes
=========

Further Documentation of the component can be found in the following sections:

Expand Down
20 changes: 4 additions & 16 deletions score/time_slave/docs/requirements/chklst_req_inspection.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,12 @@
.. document:: Time Slave Requirements Inspection Checklist
:id: doc__time_slave_req_inspection
:status: draft
:version: 2
:safety: ASIL_B
:security: YES
:version: 1
:safety: QM
:security: NO
:realizes: wp__requirements_inspect
:tags: time_slave

.. note::
Work in progress: structure, titles, and needs IDs only. Content and req/comp/feat traceability links to follow in later PRs.

.. attention::
The above directive must be updated according to your Component.

- Adjust ``status`` to be ``valid``
- Adjust ``safety``, ``security`` and ``tags`` according to your needs

Requirement Inspection Checklist
================================

Expand Down Expand Up @@ -166,7 +157,7 @@ See also :need:`doc_concept__wp_inspections` for further information about revie
.. attention::
The above checklist entries must be filled according to your component requirements in scope.

Note: If a Review ID is not applicable for your requirement, then state ""n/a" in status and comment accordingly in remarks.
Note: If a Review ID is not applicable for your requirement, then state "n/a" in status and comment accordingly in remarks.

The following requirements in "valid" state and with "inspected" tag set are in the scope of this inspection:

Expand All @@ -189,6 +180,3 @@ And also the following AoUs in "valid" state and with "inspected" tag set (for t
:columns: id;status;tags
:colwidths: 25,25,25
:sort: title

.. attention::
The above tables filtering must be updated according to your Component.
Loading
Loading