File: /home/oboss/Users/gec/sources/PUS_Services/Large_Data_Transfer/large_data_transfer-service.ads
1 --% Compilation Unit: Large_Data_Transfer.Service
2 --
3 --% Category: Generic Package Declaration
4 --
5 --% Release: $Name: $
6 --
7 --% Version: $Revision: 1.3 $
8 --
9 --% Author: $Author: jhl $
10 --
11 --% Revision Log:
12 -- $Log: large_data_transfer-service.ads,v $
13 -- Revision 1.3 2003/10/13 11:05:44 jhl
14 -- Removed with's not needed.
15 --
16 -- Revision 1.2 2003/10/09 11:05:34 jhl
17 -- Added Service 13 And 19
18 --
19 -- Revision 1.1.2.2 2003/10/08 10:34:07 jhl
20 -- Large Data Transfer post review third update
21 --
22 -- Revision 1.1.2.1 2003/10/01 11:54:51 jhl
23 -- Initial version of service 13 Event Action, and 19 Large Data Transfer.
24 --
25 -- Revision 2.0 2003/04/04 10:08:58 gec
26 -- Initial release serving as baseline for OBOSS-III project.
27 --
28 -- Revision 1.1.1.1 2003/04/04 07:19:20 gec
29 -- Imported using TkCVS
30 --
31 --
32 --
33 --% Project: OBOSS
34 --
35 --% Copyright (C) 2003 by Terma A/S
36 -- Proprietary and intellectual rights of Terma A/S, Denmark,
37 -- are involved in the subject-matter of this material and
38 -- all manufacturing, reproduction, use, disclosure, and
39 -- sales rights pertaining to such subject-matter are
40 -- expressly reserved. This material is submitted for a
41 -- specific purpose as agreed, and the recipient by
42 -- accepting this material agrees that this material will
43 -- not be used, copied, or reproduced in whole or in part
44 -- nor its contents revealed in any manner or to any person,
45 -- except to meet the purpose for which it was submitted and
46 -- subject to the terms of the agreement.
47 --
48 --% Target Dependencies:
49 -- None
50 --% Compiler Dependencies:
51 -- None
52
53 --~-----------------------------------------------------------------------------
54
55 with PUS;
56
57 generic
58
59 --% Generic Parameter Constraints:
60 --> None
61
62 --
63 -- Supporting Receiving sub-service:
64 --
65 -- If the receiving sub-service is to be used, the following subprogram must
66 --+ be overridden with
67 -- the respective subprogram from an instance of the
68 --+ Large_Data_Transfer.Receiver
69
70 -- Handler for TC PUS Packets in the Large Data Transfer receiving
71 --+ sub-service.
72 with procedure Large_Data_Transfer_Receiver_Handle_TC_Packet
73 (PUS_Packet : in PUS.PUS_Packet) is
74 Large_Data_Transfer.Receiver_Not_Supported_Handle_TC_Packet;
75
76 --
77 -- Supporting Sending sub-service
78 --
79 -- If the sending sub-service is to be used, the following subprograms must
80 --+ be overridden with
81 -- the respective subprograms from an instance of the
82 --+ Large_Data_Transfer.Sender
83
84 -- Handler for TC PUS Packets in the Large Data Transfer sending
85 --+ sub-service.
86 with procedure Large_Data_Transfer_Sender_Handle_TC_Packet
87 (PUS_Packet : in PUS.PUS_Packet) is
88 Large_Data_Transfer.Sender_Not_Supported_Handle_TC_Packet;
89
90 -- Handler for depositing TM PUS Packets to the Large Data Transfer sending
91 --+ sub-service.
92 with function Large_Data_Transfer_Sender_Deposit_TM_Packet
93 (PUS_Packet : in PUS.Optional_PUS_Packet)
94 return Boolean is
95 Large_Data_Transfer.Sender_Not_Supported_Deposit_TM_Packet;
96
97 package Large_Data_Transfer.Service is
98
99 --% Library Package:
100 -- The Large Data Transfer service. This package is instantiated as a
101 --+ child of Large_Data_Transfer
102 --
103 -- If the sending sub-service is to be used in the Large Data Transfer,
104 --+ the subprograms
105 -- Large_Data_Transfer_Sender_Handle_TC_Packet, and
106 -- Large_Data_Transfer_Sender_Deposit_TM_Packet
107 -- shall be overridden with the equivalent subprograms from the instance
108 --+ of the sending sub-service.
109 --
110 -- If the receiving sub-service is to be used in the Large Data Transfer,
111 --+ the subprogram
112 -- Large_Data_Transfer_Receiver_Handle_TC_Packet
113 -- shall be overridden with the equivalent subprograms from the instance
114 --+ of the receiving sub-service.
115 --% Active Tasks:
116 --> None
117 --% Passive Tasks:
118 --> None
119
120 --% Subprogram:
121 -- Initialization of generic package instantiation.
122 --% Parameter Constraints:
123 --> None
124 --% Exceptions Raised:
125 --> None
126
127 procedure Initialize;
128
129 --% Subprogram:
130 -- Main handler for TC PUS Packets delivered to the Large Data Transfer
131 --+ service.
132 -- The TC PUS Packet is delivered to the correct sub-service, or a TC
133 --+ Verification failure is generated.
134 --% Parameter Constraints:
135 --> TC_Packet - Must be a TC PUS Packet
136 --% Exceptions Raised:
137 --> None
138
139 procedure Handle_PUS_Packet
140 (TC_Packet : in PUS.PUS_Packet);
141
142 --% Subprogram:
143 -- Optional Deposit function for all services sending TC and TM PUS
144 --+ Packets in the application proceess having an instance of the Large
145 --+ Data Transfer service.
146 --
147 -- Functionality:
148 --
149 -- * If the deposited PUS Packet is a TC it is deposited to the
150 --+ application process packet depositor.
151 -- * If the PUS Packet is a TM, and it shall NOT be send as an SDU, it is
152 --+ deposited to the application process packet depositor
153 -- * If the PUS Packet is a TM, and it shall be send as an SDU, it is
154 --+ deposited to the Large Data Transfer sending sub-service.
155 --
156 --% Parameter Constraints:
157 --> None
158 --% Exceptions Raised:
159 -->
160 --> In the case that the default handler for depositing TM PUS Packets to
161 --+ the Large Data Transfer sending sub-service is not overridden, and a
162 --+ TM PUS packet is deposited which shall be send as an SDU, the
163 --+ following exceptions can be raised :
164 -->
165 --> Satellite_Clock.Time_Not_CUC_Representable - Implementation flaw
166 --+ indicating that mission time format is inconsistent.
167 --> Source_Data_Stream.Write_Stream_Exhausted - Source_Data_Bit_Size is
168 --+ smaller than required for generation of telecommand verification
169 --+ packet.
170
171 function Optional_Deposit
172 (PUS_Packet : in PUS.Optional_PUS_Packet)
173 return Boolean;
174
175
176 end Large_Data_Transfer.service;
177
178 --~-----------------------------------------------------------------------------
179