cfdp-py 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. cfdp-py-0.1.0/CHANGELOG.md +14 -0
  2. cfdp-py-0.1.0/LICENSE +201 -0
  3. cfdp-py-0.1.0/MANIFEST.in +12 -0
  4. cfdp-py-0.1.0/NOTICE +3 -0
  5. cfdp-py-0.1.0/PKG-INFO +107 -0
  6. cfdp-py-0.1.0/README.md +77 -0
  7. cfdp-py-0.1.0/docs/Makefile +20 -0
  8. cfdp-py-0.1.0/docs/api/cfdp.handler.rst +34 -0
  9. cfdp-py-0.1.0/docs/api/cfdp.rst +59 -0
  10. cfdp-py-0.1.0/docs/api.rst +10 -0
  11. cfdp-py-0.1.0/docs/conf.py +77 -0
  12. cfdp-py-0.1.0/docs/examples.rst +18 -0
  13. cfdp-py-0.1.0/docs/index.rst +33 -0
  14. cfdp-py-0.1.0/docs/introduction.rst +82 -0
  15. cfdp-py-0.1.0/docs/make.bat +35 -0
  16. cfdp-py-0.1.0/docs/requirements.txt +1 -0
  17. cfdp-py-0.1.0/pyproject.toml +47 -0
  18. cfdp-py-0.1.0/requirements.txt +1 -0
  19. cfdp-py-0.1.0/setup.cfg +4 -0
  20. cfdp-py-0.1.0/src/__init__.py +0 -0
  21. cfdp-py-0.1.0/src/cfdp_py.egg-info/PKG-INFO +107 -0
  22. cfdp-py-0.1.0/src/cfdp_py.egg-info/SOURCES.txt +57 -0
  23. cfdp-py-0.1.0/src/cfdp_py.egg-info/dependency_links.txt +1 -0
  24. cfdp-py-0.1.0/src/cfdp_py.egg-info/requires.txt +6 -0
  25. cfdp-py-0.1.0/src/cfdp_py.egg-info/top_level.txt +2 -0
  26. cfdp-py-0.1.0/src/cfdppy/__init__.py +15 -0
  27. cfdp-py-0.1.0/src/cfdppy/defs.py +35 -0
  28. cfdp-py-0.1.0/src/cfdppy/exceptions.py +145 -0
  29. cfdp-py-0.1.0/src/cfdppy/filestore.py +257 -0
  30. cfdp-py-0.1.0/src/cfdppy/handler/__init__.py +12 -0
  31. cfdp-py-0.1.0/src/cfdppy/handler/common.py +61 -0
  32. cfdp-py-0.1.0/src/cfdppy/handler/crc.py +79 -0
  33. cfdp-py-0.1.0/src/cfdppy/handler/defs.py +24 -0
  34. cfdp-py-0.1.0/src/cfdppy/handler/dest.py +1219 -0
  35. cfdp-py-0.1.0/src/cfdppy/handler/source.py +1017 -0
  36. cfdp-py-0.1.0/src/cfdppy/mib.py +285 -0
  37. cfdp-py-0.1.0/src/cfdppy/request.py +131 -0
  38. cfdp-py-0.1.0/src/cfdppy/user.py +166 -0
  39. cfdp-py-0.1.0/tests/.pytest_cache/.gitignore +2 -0
  40. cfdp-py-0.1.0/tests/.pytest_cache/CACHEDIR.TAG +4 -0
  41. cfdp-py-0.1.0/tests/.pytest_cache/README.md +8 -0
  42. cfdp-py-0.1.0/tests/.pytest_cache/v/cache/lastfailed +3 -0
  43. cfdp-py-0.1.0/tests/.pytest_cache/v/cache/nodeids +1 -0
  44. cfdp-py-0.1.0/tests/.pytest_cache/v/cache/stepwise +1 -0
  45. cfdp-py-0.1.0/tests/__init__.py +0 -0
  46. cfdp-py-0.1.0/tests/cfdp_fault_handler_mock.py +28 -0
  47. cfdp-py-0.1.0/tests/cfdp_user_mock.py +57 -0
  48. cfdp-py-0.1.0/tests/common.py +23 -0
  49. cfdp-py-0.1.0/tests/test_checksum.py +65 -0
  50. cfdp-py-0.1.0/tests/test_dest_handler.py +358 -0
  51. cfdp-py-0.1.0/tests/test_dest_handler_acked.py +570 -0
  52. cfdp-py-0.1.0/tests/test_dest_handler_naked.py +365 -0
  53. cfdp-py-0.1.0/tests/test_filestore.py +97 -0
  54. cfdp-py-0.1.0/tests/test_lost_seg_tracker.py +83 -0
  55. cfdp-py-0.1.0/tests/test_request.py +74 -0
  56. cfdp-py-0.1.0/tests/test_src_handler.py +400 -0
  57. cfdp-py-0.1.0/tests/test_src_handler_acked.py +331 -0
  58. cfdp-py-0.1.0/tests/test_src_handler_nak_closure.py +188 -0
  59. cfdp-py-0.1.0/tests/test_src_handler_nak_no_closure.py +261 -0
@@ -0,0 +1,14 @@
1
+ Change Log
2
+ =======
3
+
4
+ All notable changes to this project will be documented in this file.
5
+
6
+ The format is based on [Keep a Changelog](http://keepachangelog.com/)
7
+ and this project adheres to [Semantic Versioning](http://semver.org/).
8
+
9
+ # [unreleased]
10
+
11
+ # [v0.1.0]
12
+
13
+ Initial release of the `cfdp-py` library which was split off the
14
+ [tmtccmd library](https://github.com/robamu-org/tmtccmd).
cfdp-py-0.1.0/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,12 @@
1
+ include LICENSE
2
+ include NOTICE
3
+ include CHANGELOG.md
4
+
5
+ graft docs
6
+ prune docs/_build
7
+
8
+ graft tests
9
+
10
+ include requirements.txt
11
+
12
+ recursive-exclude * *.pyc *.pyo
cfdp-py-0.1.0/NOTICE ADDED
@@ -0,0 +1,3 @@
1
+ cfdpy - A library for high level CCSDS File Delivery Protocol (CFDP) components.
2
+
3
+ This software contains code developed at the University of Stuttgart's Institute of Space Systems.
cfdp-py-0.1.0/PKG-INFO ADDED
@@ -0,0 +1,107 @@
1
+ Metadata-Version: 2.1
2
+ Name: cfdp-py
3
+ Version: 0.1.0
4
+ Summary: Library for high level CCSDS File Delivery Protocol (CFDP) components
5
+ Author-email: Robin Mueller <robin.mueller.m@gmail.com>
6
+ License: Apache-2.0
7
+ Project-URL: Homepage, https://github.com/us-irs/cfdp-py
8
+ Keywords: ccsds,space,communication,packet,file-transfer
9
+ Classifier: Development Status :: 5 - Production/Stable
10
+ Classifier: License :: OSI Approved :: Apache Software License
11
+ Classifier: Natural Language :: English
12
+ Classifier: Operating System :: POSIX
13
+ Classifier: Operating System :: Microsoft :: Windows
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.8
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Topic :: Communications
18
+ Classifier: Topic :: Software Development :: Libraries
19
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
20
+ Classifier: Topic :: Scientific/Engineering
21
+ Requires-Python: >=3.8
22
+ Description-Content-Type: text/markdown
23
+ License-File: LICENSE
24
+ License-File: NOTICE
25
+ Requires-Dist: spacepackets~=0.23.0
26
+ Requires-Dist: crcmod~=1.7
27
+ Requires-Dist: deprecation~=2.1
28
+ Provides-Extra: test
29
+ Requires-Dist: pyfakefs~=4.5; extra == "test"
30
+
31
+ [![ci](https://github.com/us-irs/cfdp-py/actions/workflows/ci.yml/badge.svg)](https://github.com/us-irs/cfdp-py/actions/workflows/ci.yml)
32
+ [![Documentation Status](https://readthedocs.org/projects/cfdp-py/badge/?version=latest)](https://cfdp-py.readthedocs.io/en/latest/?badge=latest)
33
+ [![codecov](https://codecov.io/gh/us-irs/cfdp-py/graph/badge.svg?token=FBL1NR54BI)](https://codecov.io/gh/us-irs/cfdp-py)
34
+ [![PyPI version](https://badge.fury.io/py/cfdppy.svg)](https://badge.fury.io/py/cfdppy)
35
+
36
+ cfdp-py - High level Python library for CFDP components
37
+ ======================
38
+
39
+ The `cfdp-py` library offers some high-level CCSDS File Delivery Protocol (CFDP) components to
40
+ perform file transfers according to the [CCSDS Blue Book 727.0-B-5](https://public.ccsds.org/Pubs/727x0b5.pdf).
41
+ The underlying base packet library used to generate the packets to be sent is the
42
+ [spacepackets](https://github.com/us-irs/spacepackets-py) library.
43
+
44
+ # Install
45
+
46
+ You can install this package from PyPI
47
+
48
+ Linux:
49
+
50
+ ```sh
51
+ python3 -m pip install cfdppy
52
+ ```
53
+
54
+ Windows:
55
+
56
+ ```sh
57
+ py -m pip install cfdppy
58
+ ```
59
+
60
+ # Examples
61
+
62
+ You can find all examples [inside the documentation](https://cfdp-py.readthedocs.io/en/latest/examples.html) and the `examples` directory of this repository.
63
+
64
+ # Tests
65
+
66
+ If you want to run the tests, it is recommended to install `pytest` and `coverage` (optional)
67
+ first. You also have to install the package with the optional `test` feature:
68
+
69
+ ```sh
70
+ pip install coverage pytest
71
+ pip install cfdppy[test]
72
+ ```
73
+
74
+ Running tests regularly:
75
+
76
+ ```sh
77
+ pytest .
78
+ ```
79
+
80
+ Running tests with coverage:
81
+
82
+ ```sh
83
+ coverage run -m pytest
84
+ ```
85
+
86
+ # Documentation
87
+
88
+ The documentation is built with Sphinx
89
+
90
+ Install the required dependencies first:
91
+
92
+ ```sh
93
+ pip install -r docs/requirements.txt
94
+ ```
95
+
96
+ Then the documentation can be built with
97
+
98
+ ```sh
99
+ cd docs
100
+ make html
101
+ ```
102
+
103
+ You can run the doctests with
104
+
105
+ ```sh
106
+ make doctest
107
+ ```
@@ -0,0 +1,77 @@
1
+ [![ci](https://github.com/us-irs/cfdp-py/actions/workflows/ci.yml/badge.svg)](https://github.com/us-irs/cfdp-py/actions/workflows/ci.yml)
2
+ [![Documentation Status](https://readthedocs.org/projects/cfdp-py/badge/?version=latest)](https://cfdp-py.readthedocs.io/en/latest/?badge=latest)
3
+ [![codecov](https://codecov.io/gh/us-irs/cfdp-py/graph/badge.svg?token=FBL1NR54BI)](https://codecov.io/gh/us-irs/cfdp-py)
4
+ [![PyPI version](https://badge.fury.io/py/cfdppy.svg)](https://badge.fury.io/py/cfdppy)
5
+
6
+ cfdp-py - High level Python library for CFDP components
7
+ ======================
8
+
9
+ The `cfdp-py` library offers some high-level CCSDS File Delivery Protocol (CFDP) components to
10
+ perform file transfers according to the [CCSDS Blue Book 727.0-B-5](https://public.ccsds.org/Pubs/727x0b5.pdf).
11
+ The underlying base packet library used to generate the packets to be sent is the
12
+ [spacepackets](https://github.com/us-irs/spacepackets-py) library.
13
+
14
+ # Install
15
+
16
+ You can install this package from PyPI
17
+
18
+ Linux:
19
+
20
+ ```sh
21
+ python3 -m pip install cfdppy
22
+ ```
23
+
24
+ Windows:
25
+
26
+ ```sh
27
+ py -m pip install cfdppy
28
+ ```
29
+
30
+ # Examples
31
+
32
+ You can find all examples [inside the documentation](https://cfdp-py.readthedocs.io/en/latest/examples.html) and the `examples` directory of this repository.
33
+
34
+ # Tests
35
+
36
+ If you want to run the tests, it is recommended to install `pytest` and `coverage` (optional)
37
+ first. You also have to install the package with the optional `test` feature:
38
+
39
+ ```sh
40
+ pip install coverage pytest
41
+ pip install cfdppy[test]
42
+ ```
43
+
44
+ Running tests regularly:
45
+
46
+ ```sh
47
+ pytest .
48
+ ```
49
+
50
+ Running tests with coverage:
51
+
52
+ ```sh
53
+ coverage run -m pytest
54
+ ```
55
+
56
+ # Documentation
57
+
58
+ The documentation is built with Sphinx
59
+
60
+ Install the required dependencies first:
61
+
62
+ ```sh
63
+ pip install -r docs/requirements.txt
64
+ ```
65
+
66
+ Then the documentation can be built with
67
+
68
+ ```sh
69
+ cd docs
70
+ make html
71
+ ```
72
+
73
+ You can run the doctests with
74
+
75
+ ```sh
76
+ make doctest
77
+ ```
@@ -0,0 +1,20 @@
1
+ # Minimal makefile for Sphinx documentation
2
+ #
3
+
4
+ # You can set these variables from the command line, and also
5
+ # from the environment for the first two.
6
+ SPHINXOPTS ?=
7
+ SPHINXBUILD ?= sphinx-build
8
+ SOURCEDIR = .
9
+ BUILDDIR = _build
10
+
11
+ # Put it first so that "make" without argument is like "make help".
12
+ help:
13
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14
+
15
+ .PHONY: help Makefile
16
+
17
+ # Catch-all target: route all unknown targets to Sphinx using the new
18
+ # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
+ %: Makefile
20
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@@ -0,0 +1,34 @@
1
+ CFDP Handler Package
2
+ =============================
3
+
4
+ Package Contents
5
+ -----------------
6
+
7
+ .. automodule:: cfdppy.handler
8
+ :members:
9
+ :undoc-members:
10
+ :show-inheritance:
11
+
12
+ Source Handler Module
13
+ -------------------------------------
14
+
15
+ .. automodule:: cfdppy.handler.source
16
+ :members:
17
+ :undoc-members:
18
+ :show-inheritance:
19
+
20
+ Destination Handler Module
21
+ -------------------------------------
22
+
23
+ .. automodule:: cfdppy.handler.dest
24
+ :members:
25
+ :undoc-members:
26
+ :show-inheritance:
27
+
28
+ Defintions Module
29
+ -------------------------------------
30
+
31
+ .. automodule:: cfdppy.handler.defs
32
+ :members:
33
+ :undoc-members:
34
+ :show-inheritance:
@@ -0,0 +1,59 @@
1
+ CFDP Package
2
+ =============
3
+
4
+ Module contents
5
+ ---------------
6
+
7
+ .. automodule:: cfdppy
8
+ :members:
9
+ :undoc-members:
10
+ :show-inheritance:
11
+
12
+ Filestore Module
13
+ -------------------------------
14
+
15
+ .. automodule:: cfdppy.filestore
16
+ :members:
17
+ :undoc-members:
18
+ :show-inheritance:
19
+
20
+
21
+ Management Information Base (MIB) Module
22
+ -------------------------------------------
23
+
24
+ .. automodule:: cfdppy.mib
25
+ :members:
26
+ :undoc-members:
27
+ :show-inheritance:
28
+
29
+ Request Module
30
+ -------------------------------
31
+
32
+ .. automodule:: cfdppy.request
33
+ :members:
34
+ :undoc-members:
35
+ :show-inheritance:
36
+
37
+ User Module
38
+ -------------------------------
39
+
40
+ .. automodule:: cfdppy.user
41
+ :members:
42
+ :undoc-members:
43
+ :show-inheritance:
44
+
45
+ Exceptions Module
46
+ -------------------------------------------
47
+
48
+ .. automodule:: cfdppy.exceptions
49
+ :members:
50
+ :undoc-members:
51
+ :show-inheritance:
52
+
53
+ Definitions Module
54
+ --------------------------
55
+
56
+ .. automodule:: cfdppy.defs
57
+ :members:
58
+ :undoc-members:
59
+ :show-inheritance:
@@ -0,0 +1,10 @@
1
+ ====
2
+ API
3
+ ====
4
+
5
+ .. toctree::
6
+ :maxdepth: 2
7
+ :caption: Contents:
8
+
9
+ api/cfdp
10
+ api/cfdp.handler
@@ -0,0 +1,77 @@
1
+ # Configuration file for the Sphinx documentation builder.
2
+ #
3
+ # This file only contains a selection of the most common options. For a full
4
+ # list see the documentation:
5
+ # https://www.sphinx-doc.org/en/master/usage/configuration.html
6
+
7
+ # -- Path setup --------------------------------------------------------------
8
+
9
+ # If extensions (or modules to document with autodoc) are in another directory,
10
+ # add these directories to sys.path here. If the directory is relative to the
11
+ # documentation root, use os.path.abspath to make it absolute, like shown here.
12
+ #
13
+ # import os
14
+ # import sys
15
+ # sys.path.insert(0, os.path.abspath('.'))
16
+
17
+
18
+ # -- Project information -----------------------------------------------------
19
+ from importlib.metadata import version
20
+
21
+ project = "cfdp-py"
22
+ copyright = "2024, Robin Mueller"
23
+ author = "Robin Mueller"
24
+
25
+ # The full version, including alpha/beta/rc tags
26
+ release = version = version("cfdp-py")
27
+
28
+
29
+ # -- General configuration ---------------------------------------------------
30
+
31
+ # Add any Sphinx extension module names here, as strings. They can be
32
+ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
33
+ # ones.
34
+ extensions = [
35
+ "sphinx.ext.autodoc",
36
+ "sphinx.ext.intersphinx",
37
+ "sphinx.ext.doctest",
38
+ "sphinx_rtd_theme",
39
+ ]
40
+
41
+ # Disable the doctests of the full package because those would require the explicit specification
42
+ # of imports. The doctests inside the source code are covered by pytest, using the --doctest-modules
43
+ # configuration option.
44
+ doctest_test_doctest_blocks = ""
45
+
46
+ # Add any paths that contain templates here, relative to this directory.
47
+ templates_path = ["_templates"]
48
+
49
+ # The language for content autogenerated by Sphinx. Refer to documentation
50
+ # for a list of supported languages.
51
+ #
52
+ # This is also used if you do content translation via gettext catalogs.
53
+ # Usually you set "language" from the command line for these cases.
54
+ language = "en"
55
+
56
+ # List of patterns, relative to source directory, that match files and
57
+ # directories to ignore when looking for source files.
58
+ # This pattern also affects html_static_path and html_extra_path.
59
+ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
60
+
61
+ # Mapping for external packages
62
+ intersphinx_mapping = {
63
+ "python": ("https://docs.python.org/3", None),
64
+ "crcmod": ("https://crcmod.sourceforge.net/", None),
65
+ }
66
+
67
+ # -- Options for HTML output -------------------------------------------------
68
+
69
+ # The theme to use for HTML and HTML Help pages. See the documentation for
70
+ # a list of builtin themes.
71
+ #
72
+ html_theme = "sphinx_rtd_theme"
73
+
74
+ # Add any paths that contain custom static files (such as style sheets) here,
75
+ # relative to this directory. They are copied after the builtin static files,
76
+ # so a file named "default.css" will overwrite the builtin "default.css".
77
+ html_static_path = ["_static"]
@@ -0,0 +1,18 @@
1
+ =====================
2
+ Example applications
3
+ =====================
4
+
5
+ You can find an example application inside the
6
+ `example directory <https://github.com/robamu-org/tmtccmd/tree/main/examples/cfdp-simple>`_
7
+ which shows an end-to-end file transfer on a host computer. This should give you a general idea of
8
+ how the source and destination handler work in practice.
9
+
10
+ There is also a
11
+ `test application <https://github.com/robamu-org/tmtccmd/tree/main/examples/cfdp-libre-cube-crosstest>`_
12
+ which cross-tests the `tmtccmd` CFDP implementation with the
13
+ `Libre Cube CFDP <https://gitlab.com/librecube/lib/python-cfdp>`_ implementation.
14
+
15
+ Finally, you can see a more complex example also featuring more features of the CFDP state machines
16
+ `here <https://github.com/robamu-org/tmtccmd/tree/main/examples/cfdp-cli-udp>`_. This example
17
+ uses UDP servers for communication and explicitely separates the local and remote entity
18
+ application.
@@ -0,0 +1,33 @@
1
+ .. cfdpy documentation master file, created by
2
+ sphinx-quickstart on Tue Jan 23 21:37:44 2024.
3
+ You can adapt this file completely to your liking, but it should at least
4
+ contain the root `toctree` directive.
5
+
6
+ .. _cfdp:
7
+
8
+ ==============================================================
9
+ cfdp-py - A library for the CCSDS File Delivery Protocol (CFDP)
10
+ ==============================================================
11
+
12
+ The ``cfdp-py`` library offers some high-level CCSDS File Delivery Protocol (CFDP) components to
13
+ perform file transfers according to the `CCSDS Blue Book 727.0-B-5`_. The underlying base packet
14
+ library used to generate the packets to be sent is the `spacepackets`_ library.
15
+
16
+ .. _`CCSDS Blue Book 727.0-B-5`: https://public.ccsds.org/Pubs/727x0b5.pdf
17
+ .. _`spacepackets`: https://github.com/us-irs/spacepackets-py
18
+
19
+ .. toctree::
20
+ :maxdepth: 2
21
+ :caption: Contents:
22
+
23
+ introduction
24
+ examples
25
+ api
26
+
27
+
28
+ Indices and tables
29
+ ==================
30
+
31
+ * :ref:`genindex`
32
+ * :ref:`modindex`
33
+ * :ref:`search`