# PyCCSDS
---
PyCCSDS is a library to read a data packet coming from a space mission that follows the Consultative Committee for Space Data Systems (CCSDS) standard
Current version **0.1.0**
[[_TOC_]]
## Installation
```shell
python3 -m pip install Python-CCSDS
```
## Usage
```python
from PyCCSDS.ccsds import CCSDS
dat = CCSDS('BepiColombo',packet)
```
wehre *packet* is a string with the HEX rappresentation of the pachet
## Limitation
## Data Structure
The CCSDS Header is composed by two blocks:
+ the Source Packet Header
+ the Packet Data Field
The first one il long 48 bits the second one has a varble dimension and structure depending by the type and the content of the packet. in [Figure 1](#figure-1-telemetry-packet) is reported the structure for a Telemetry Packet.
The structure of the CCSDS class follow the structure of the packet header.
```mermaid
classDiagram
CCSDS --|> SPH
CCSDS --|> PDF
SPH --|> packetID
SPH--|> sequenceControl
PDF --|> DFHeader
class CCSDS{
+ str Data
}
class DFHeader{
+ uint PUSVersion
+ uint ServiceType
+ uint ServiceSubType
+ uint DestinationId
+ uint Synchronization
+ uint CorseTime
+ uint FineTime
+ str SCET
+ str UTCTime
}
class SPH{
+ uint packetLength
}
class packetID{
+ uint VersionNum
+ uint packetType
+ uint dataFieldHeaderFlag
+ uint Apid
+ uint Pid
+ uint Pcat
}
class sequenceControl{
+ bin SegmentationFlag
+ uint SSC
}
class PDF{
+str Data
}
```
![TM packet](docs/TM_Packet_Header.png "Telemetry packet")
#### Figure 1 - Telemetry Packet
Raw data
{
"_id": null,
"home_page": "",
"name": "Python-CCSDS",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "python,ccsds,nasa,esa,packets",
"author": "",
"author_email": "Romolo Politi <romolo.politi@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/b7/06/45546f0cec359fc1f43c90de272aa6bc0f1fea2b0e0f01e5d8b7cf4b0eb9/Python-CCSDS-0.1.0.tar.gz",
"platform": null,
"description": "# PyCCSDS\n\n---\n\nPyCCSDS is a library to read a data packet coming from a space mission that follows the Consultative Committee for Space Data Systems (CCSDS) standard\n\nCurrent version **0.1.0**\n\n[[_TOC_]]\n\n## Installation\n```shell\npython3 -m pip install Python-CCSDS\n```\n## Usage\n```python\nfrom PyCCSDS.ccsds import CCSDS\n\ndat = CCSDS('BepiColombo',packet)\n```\nwehre *packet* is a string with the HEX rappresentation of the pachet\n\n## Limitation\n\n## Data Structure\n\nThe CCSDS Header is composed by two blocks:\n+ the Source Packet Header \n+ the Packet Data Field\n\nThe first one il long 48 bits the second one has a varble dimension and structure depending by the type and the content of the packet. in [Figure 1](#figure-1-telemetry-packet) is reported the structure for a Telemetry Packet.\n\nThe structure of the CCSDS class follow the structure of the packet header.\n\n\n```mermaid\nclassDiagram\n CCSDS --|> SPH\n CCSDS --|> PDF\n SPH --|> packetID\n SPH--|> sequenceControl\n PDF --|> DFHeader\n class CCSDS{\n + str Data \n }\n class DFHeader{\n + uint PUSVersion\n + uint ServiceType\n + uint ServiceSubType\n + uint DestinationId\n + uint Synchronization\n + uint CorseTime\n + uint FineTime\n + str SCET\n + str UTCTime\n }\n class SPH{\n + uint packetLength\n }\n class packetID{\n + uint VersionNum\n + uint packetType\n + uint dataFieldHeaderFlag \n + uint Apid\n + uint Pid\n + uint Pcat\n }\n class sequenceControl{\n + bin SegmentationFlag\n + uint SSC\n }\n class PDF{\n +str Data\n }\n```\n\n![TM packet](docs/TM_Packet_Header.png \"Telemetry packet\")\n#### Figure 1 - Telemetry Packet\n",
"bugtrack_url": null,
"license": "GNU GPL ver3",
"summary": "",
"version": "0.1.0",
"split_keywords": [
"python",
"ccsds",
"nasa",
"esa",
"packets"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "9dce3b17dc13f82bebf0abac60d22cb76fc6d7986c2b06967b61350340e02975",
"md5": "cae63270cb04e6e4358191aa50e5b5b5",
"sha256": "b755d82b1c93b2bb6aebd5b95cfbb0a3a1c377bdb67a367562302fc080fc903f"
},
"downloads": -1,
"filename": "Python_CCSDS-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "cae63270cb04e6e4358191aa50e5b5b5",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 15896,
"upload_time": "2023-03-28T11:14:11",
"upload_time_iso_8601": "2023-03-28T11:14:11.827014Z",
"url": "https://files.pythonhosted.org/packages/9d/ce/3b17dc13f82bebf0abac60d22cb76fc6d7986c2b06967b61350340e02975/Python_CCSDS-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "b70645546f0cec359fc1f43c90de272aa6bc0f1fea2b0e0f01e5d8b7cf4b0eb9",
"md5": "9ebe43706e9f05a18e41423b9125faf3",
"sha256": "e5b4fcd33b24d09ec6154d4fb74801af2431f3190e758714ace235790525d93b"
},
"downloads": -1,
"filename": "Python-CCSDS-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "9ebe43706e9f05a18e41423b9125faf3",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 15690,
"upload_time": "2023-03-28T11:14:14",
"upload_time_iso_8601": "2023-03-28T11:14:14.158733Z",
"url": "https://files.pythonhosted.org/packages/b7/06/45546f0cec359fc1f43c90de272aa6bc0f1fea2b0e0f01e5d8b7cf4b0eb9/Python-CCSDS-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-03-28 11:14:14",
"github": false,
"gitlab": false,
"bitbucket": false,
"lcname": "python-ccsds"
}