line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Astro::App::Satpass2::Locale::C; |
2
|
|
|
|
|
|
|
|
3
|
7
|
|
|
7
|
|
1188
|
use 5.008; |
|
7
|
|
|
|
|
28
|
|
4
|
|
|
|
|
|
|
|
5
|
7
|
|
|
7
|
|
46
|
use strict; |
|
7
|
|
|
|
|
14
|
|
|
7
|
|
|
|
|
211
|
|
6
|
7
|
|
|
7
|
|
49
|
use warnings; |
|
7
|
|
|
|
|
15
|
|
|
7
|
|
|
|
|
250
|
|
7
|
|
|
|
|
|
|
|
8
|
7
|
|
|
7
|
|
5297
|
use utf8; # Not actually needed for C locale, but maybe for others |
|
7
|
|
|
|
|
127
|
|
|
7
|
|
|
|
|
37
|
|
9
|
|
|
|
|
|
|
|
10
|
7
|
|
|
7
|
|
3595
|
use Astro::Coord::ECI::TLE 0.059 qw{ :constants }; |
|
7
|
|
|
|
|
239933
|
|
|
7
|
|
|
|
|
2237
|
|
11
|
7
|
|
|
7
|
|
73
|
use Astro::App::Satpass2::Utils qw{ @CARP_NOT }; |
|
7
|
|
|
|
|
18
|
|
|
7
|
|
|
|
|
652
|
|
12
|
7
|
|
|
7
|
|
68
|
use Scalar::Util (); |
|
7
|
|
|
|
|
32
|
|
|
7
|
|
|
|
|
5823
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
our $VERSION = '0.051'; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
my @event_names; |
17
|
|
|
|
|
|
|
$event_names[PASS_EVENT_NONE] = ''; |
18
|
|
|
|
|
|
|
$event_names[PASS_EVENT_SHADOWED] = 'shdw'; |
19
|
|
|
|
|
|
|
$event_names[PASS_EVENT_LIT] = 'lit'; |
20
|
|
|
|
|
|
|
$event_names[PASS_EVENT_DAY] = 'day'; |
21
|
|
|
|
|
|
|
$event_names[PASS_EVENT_RISE] = 'rise'; |
22
|
|
|
|
|
|
|
$event_names[PASS_EVENT_MAX] = 'max'; |
23
|
|
|
|
|
|
|
$event_names[PASS_EVENT_SET] = 'set'; |
24
|
|
|
|
|
|
|
$event_names[PASS_EVENT_APPULSE] = 'apls'; |
25
|
|
|
|
|
|
|
$event_names[PASS_EVENT_START] = 'strt'; |
26
|
|
|
|
|
|
|
$event_names[PASS_EVENT_END] = 'end'; |
27
|
|
|
|
|
|
|
$event_names[PASS_EVENT_BRIGHTEST] = 'brgt'; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
my @sun_quarters = ( |
30
|
|
|
|
|
|
|
'Spring equinox', |
31
|
|
|
|
|
|
|
'Summer solstice', |
32
|
|
|
|
|
|
|
'Autumn equinox', |
33
|
|
|
|
|
|
|
'Winter solstice', |
34
|
|
|
|
|
|
|
); |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
# Any hash reference is a true value, but perlcritic seems not to know |
37
|
|
|
|
|
|
|
# this. |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
{ ## no critic (Modules::RequireEndWithOne) |
40
|
|
|
|
|
|
|
'+message' => { |
41
|
|
|
|
|
|
|
}, |
42
|
|
|
|
|
|
|
'+template' => { |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
# Local coordinates |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
az_rng => <<'EOD', |
47
|
|
|
|
|
|
|
[% data.azimuth( arg, bearing = 2 ) %] |
48
|
|
|
|
|
|
|
[%= data.range( arg ) -%] |
49
|
|
|
|
|
|
|
EOD |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
azel => <<'EOD', |
52
|
|
|
|
|
|
|
[% data.elevation( arg ) %] |
53
|
|
|
|
|
|
|
[%= data.azimuth( arg, bearing = 2 ) -%] |
54
|
|
|
|
|
|
|
EOD |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
azel_rng => <<'EOD', |
57
|
|
|
|
|
|
|
[% data.elevation( arg ) %] |
58
|
|
|
|
|
|
|
[%= data.azimuth( arg, bearing = 2 ) %] |
59
|
|
|
|
|
|
|
[%= data.range( arg ) -%] |
60
|
|
|
|
|
|
|
EOD |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
equatorial => <<'EOD', |
63
|
|
|
|
|
|
|
[% data.right_ascension( arg ) %] |
64
|
|
|
|
|
|
|
[%= data.declination( arg ) -%] |
65
|
|
|
|
|
|
|
EOD |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
equatorial_rng => <<'EOD', |
68
|
|
|
|
|
|
|
[% data.right_ascension( arg ) %] |
69
|
|
|
|
|
|
|
[%= data.declination( arg ) %] |
70
|
|
|
|
|
|
|
[%= data.range( arg ) -%] |
71
|
|
|
|
|
|
|
EOD |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
# Main templates |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
almanac => <<'EOD', |
76
|
|
|
|
|
|
|
[% UNLESS data %] |
77
|
|
|
|
|
|
|
[%- SET data = sp.almanac( arg ) %] |
78
|
|
|
|
|
|
|
[%- END %] |
79
|
|
|
|
|
|
|
[%- FOREACH item IN data %] |
80
|
|
|
|
|
|
|
[%- item.date %] [% item.time %] |
81
|
|
|
|
|
|
|
[%= item.almanac( units = 'description' ) %] |
82
|
|
|
|
|
|
|
[% END -%] |
83
|
|
|
|
|
|
|
EOD |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
flare => <<'EOD', |
86
|
|
|
|
|
|
|
[% UNLESS data %] |
87
|
|
|
|
|
|
|
[%- SET data = sp.flare( arg ) %] |
88
|
|
|
|
|
|
|
[%- END %] |
89
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
90
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
91
|
|
|
|
|
|
|
[%- title.time %] |
92
|
|
|
|
|
|
|
[%= title.name( width = 12 ) %] |
93
|
|
|
|
|
|
|
[%= title.local_coord %] |
94
|
|
|
|
|
|
|
[%= title.magnitude %] |
95
|
|
|
|
|
|
|
[%= title.angle( 'Degrees From Sun' ) %] |
96
|
|
|
|
|
|
|
[%= title.azimuth( 'Center Azimuth', bearing = 2 ) %] |
97
|
|
|
|
|
|
|
[%= title.range( 'Center Range', width = 6 ) %] |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
[%- END %] |
100
|
|
|
|
|
|
|
[%- prior_date = '' -%] |
101
|
|
|
|
|
|
|
[% FOR item IN data %] |
102
|
|
|
|
|
|
|
[%- center = item.center %] |
103
|
|
|
|
|
|
|
[%- current_date = item.date %] |
104
|
|
|
|
|
|
|
[%- IF prior_date != current_date %] |
105
|
|
|
|
|
|
|
[%- prior_date = current_date %] |
106
|
|
|
|
|
|
|
[%- current_date %] |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
[%- END %] |
109
|
|
|
|
|
|
|
[%- item.time %] |
110
|
|
|
|
|
|
|
[%= item.name( units = 'title_case', width = 12 ) %] |
111
|
|
|
|
|
|
|
[%= item.local_coord %] |
112
|
|
|
|
|
|
|
[%= item.magnitude %] |
113
|
|
|
|
|
|
|
[%= IF 'day' == item.type( width = '' ) %] |
114
|
|
|
|
|
|
|
[%- item.appulse.angle %] |
115
|
|
|
|
|
|
|
[%- ELSE %] |
116
|
|
|
|
|
|
|
[%- item.appulse.angle( literal = 'night' ) %] |
117
|
|
|
|
|
|
|
[%- END %] |
118
|
|
|
|
|
|
|
[%= center.azimuth( bearing = 2 ) %] |
119
|
|
|
|
|
|
|
[%= center.range( width = 6 ) %] |
120
|
|
|
|
|
|
|
[% END -%] |
121
|
|
|
|
|
|
|
EOD |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
list => <<'EOD', |
124
|
|
|
|
|
|
|
[% UNLESS data %] |
125
|
|
|
|
|
|
|
[%- SET data = sp.list( arg ) %] |
126
|
|
|
|
|
|
|
[%- END %] |
127
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
128
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
129
|
|
|
|
|
|
|
[%- title.list %] |
130
|
|
|
|
|
|
|
[% END %] |
131
|
|
|
|
|
|
|
[%- FOR item IN data %] |
132
|
|
|
|
|
|
|
[%- item.list( arg ) %] |
133
|
|
|
|
|
|
|
[% END -%] |
134
|
|
|
|
|
|
|
EOD |
135
|
|
|
|
|
|
|
|
136
|
|
|
|
|
|
|
list_inertial => <<'EOD', |
137
|
|
|
|
|
|
|
[% data.oid( align_left = 0, arg ) %] [% data.name( arg ) %] |
138
|
|
|
|
|
|
|
[%= data.epoch( arg ) %] |
139
|
|
|
|
|
|
|
[%= data.period( arg, align_left = 1 ) -%] |
140
|
|
|
|
|
|
|
EOD |
141
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
list_fixed => <<'EOD', |
143
|
|
|
|
|
|
|
[% data.oid( align_left = 0, arg ) %] [% data.name( arg ) %] |
144
|
|
|
|
|
|
|
[%= data.latitude( arg ) %] |
145
|
|
|
|
|
|
|
[%= data.longitude( arg ) %] [% data.altitude( arg ) -%] |
146
|
|
|
|
|
|
|
EOD |
147
|
|
|
|
|
|
|
|
148
|
|
|
|
|
|
|
location => <<'EOD', |
149
|
|
|
|
|
|
|
[% UNLESS data %] |
150
|
|
|
|
|
|
|
[%- SET data = sp.location( arg ) %] |
151
|
|
|
|
|
|
|
[%- END -%] |
152
|
|
|
|
|
|
|
[% localize( 'Location' ) %]: [% data.name( width = '' ) %] |
153
|
|
|
|
|
|
|
[% localize( 'Latitude' ) %] [% data.latitude( places = 4, |
154
|
|
|
|
|
|
|
width = '' ) %], [% localize( 'longitude' ) %] |
155
|
|
|
|
|
|
|
[%= data.longitude( places = 4, width = '' ) |
156
|
|
|
|
|
|
|
%], [% localize( 'height' ) %] |
157
|
|
|
|
|
|
|
[%= data.altitude( units = 'meters', places = 0, |
158
|
|
|
|
|
|
|
width = '' ) %] m |
159
|
|
|
|
|
|
|
EOD |
160
|
|
|
|
|
|
|
|
161
|
|
|
|
|
|
|
pass => <<'EOD', |
162
|
|
|
|
|
|
|
[% UNLESS data %] |
163
|
|
|
|
|
|
|
[%- SET data = sp.pass( arg ) %] |
164
|
|
|
|
|
|
|
[%- END %] |
165
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
166
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
167
|
|
|
|
|
|
|
[%- format_detail( 'event', title ) %] |
168
|
|
|
|
|
|
|
|
169
|
|
|
|
|
|
|
[%- END %] |
170
|
|
|
|
|
|
|
[%- FOR pass IN data %] |
171
|
|
|
|
|
|
|
[%- events = pass.events %] |
172
|
|
|
|
|
|
|
[%- evt = events.first %] |
173
|
|
|
|
|
|
|
|
174
|
|
|
|
|
|
|
[%- evt.date %] [% evt.oid %] - [% evt.name( width = '' ) %] |
175
|
|
|
|
|
|
|
|
176
|
|
|
|
|
|
|
[%- FOREACH evt IN events %] |
177
|
|
|
|
|
|
|
[%- format_detail( 'event', evt ) %] |
178
|
|
|
|
|
|
|
|
179
|
|
|
|
|
|
|
[%- END %] |
180
|
|
|
|
|
|
|
[%- END -%] |
181
|
|
|
|
|
|
|
EOD |
182
|
|
|
|
|
|
|
'pass:event' => <<'EOD', |
183
|
|
|
|
|
|
|
[%- evt.time %] |
184
|
|
|
|
|
|
|
[%= evt.local_coord %] |
185
|
|
|
|
|
|
|
[%= evt.latitude %] |
186
|
|
|
|
|
|
|
[%= evt.longitude %] |
187
|
|
|
|
|
|
|
[%= evt.altitude %] |
188
|
|
|
|
|
|
|
[%= evt.illumination %] |
189
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) %] |
190
|
|
|
|
|
|
|
[%= evt.magnitude %] |
191
|
|
|
|
|
|
|
[%- END %] |
192
|
|
|
|
|
|
|
[%= evt.event %] |
193
|
|
|
|
|
|
|
EOD |
194
|
|
|
|
|
|
|
'pass:event:almanac' => <<'EOD', |
195
|
|
|
|
|
|
|
[%- evt.time %] [% evt.almanac %] |
196
|
|
|
|
|
|
|
EOD |
197
|
|
|
|
|
|
|
'pass:event:apls' => <<'EOD', |
198
|
|
|
|
|
|
|
[%- evt.time %] |
199
|
|
|
|
|
|
|
[%= evt.local_coord %] |
200
|
|
|
|
|
|
|
[%= evt.latitude %] |
201
|
|
|
|
|
|
|
[%= evt.longitude %] |
202
|
|
|
|
|
|
|
[%= evt.altitude %] |
203
|
|
|
|
|
|
|
[%= evt.illumination %] |
204
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) %] |
205
|
|
|
|
|
|
|
[%= evt.magnitude %] |
206
|
|
|
|
|
|
|
[%- END %] |
207
|
|
|
|
|
|
|
[%= evt.event %] |
208
|
|
|
|
|
|
|
[%- apls = evt.appulse %] |
209
|
|
|
|
|
|
|
|
210
|
|
|
|
|
|
|
[%- title.time( '' ) %] |
211
|
|
|
|
|
|
|
[%= apls.local_coord %] |
212
|
|
|
|
|
|
|
[%= apls.angle %] degrees from [% apls.name( width = '' ) %] |
213
|
|
|
|
|
|
|
EOD |
214
|
|
|
|
|
|
|
|
215
|
|
|
|
|
|
|
pass_events => <<'EOD', |
216
|
|
|
|
|
|
|
[% UNLESS data %] |
217
|
|
|
|
|
|
|
[%- SET data = sp.pass( arg ) %] |
218
|
|
|
|
|
|
|
[%- END %] |
219
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
220
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
221
|
|
|
|
|
|
|
[%- format_detail( 'event', title ) %] |
222
|
|
|
|
|
|
|
|
223
|
|
|
|
|
|
|
[%- END %] |
224
|
|
|
|
|
|
|
[%- FOREACH evt IN data.events %] |
225
|
|
|
|
|
|
|
[%- format_detail( 'event', evt ) %] |
226
|
|
|
|
|
|
|
[% END -%] |
227
|
|
|
|
|
|
|
EOD |
228
|
|
|
|
|
|
|
'pass_events:event' => <<'EOD', |
229
|
|
|
|
|
|
|
[%- evt.date %] [% evt.time %] |
230
|
|
|
|
|
|
|
[%= evt.oid %] [% evt.event %] |
231
|
|
|
|
|
|
|
[%= evt.illumination %] [% evt.local_coord %] |
232
|
|
|
|
|
|
|
EOD |
233
|
|
|
|
|
|
|
'pass_events:event:almanac' => <<'EOD', |
234
|
|
|
|
|
|
|
[%- evt.date %] [% evt.time %] [% evt.almanac %] |
235
|
|
|
|
|
|
|
EOD |
236
|
|
|
|
|
|
|
|
237
|
|
|
|
|
|
|
pass_ics => <<'EOD', |
238
|
|
|
|
|
|
|
[% UNLESS data %] |
239
|
|
|
|
|
|
|
[%- SET data = sp.pass( arg ) %] |
240
|
|
|
|
|
|
|
[%- END -%] |
241
|
|
|
|
|
|
|
BEGIN:VCALENDAR |
242
|
|
|
|
|
|
|
VERSION:2.0 |
243
|
|
|
|
|
|
|
[%- FOR pass IN data %] |
244
|
|
|
|
|
|
|
[%- events = pass.events %] |
245
|
|
|
|
|
|
|
[%- CALL events.fixed_width( 0 ) %] |
246
|
|
|
|
|
|
|
[%- tle_events = pass.tle_events %] |
247
|
|
|
|
|
|
|
[%- first = tle_events.first %] |
248
|
|
|
|
|
|
|
[%- last = tle_events.last %] |
249
|
|
|
|
|
|
|
[%- punct = '' %] |
250
|
|
|
|
|
|
|
BEGIN:VEVENT |
251
|
|
|
|
|
|
|
DTSTART:[% first.date( format = '%Y%m%dT%H%M%SZ', units = 'zulu' ) %] |
252
|
|
|
|
|
|
|
BEGIN:VALARM |
253
|
|
|
|
|
|
|
TRIGGER:-PT5M |
254
|
|
|
|
|
|
|
ACTION:DISPLAY |
255
|
|
|
|
|
|
|
END:VALARM |
256
|
|
|
|
|
|
|
BEGIN:VALARM |
257
|
|
|
|
|
|
|
TRIGGER:PT0M |
258
|
|
|
|
|
|
|
ACTION:DISPLAY |
259
|
|
|
|
|
|
|
END:VALARM |
260
|
|
|
|
|
|
|
SUMMARY:[% first.name %] |
261
|
|
|
|
|
|
|
DESCRIPTION: |
262
|
|
|
|
|
|
|
[%- FOREACH evt IN events %][% punct %] |
263
|
|
|
|
|
|
|
[%- format_detail( 'event', evt ) %] |
264
|
|
|
|
|
|
|
[%- punct = '\n' %] |
265
|
|
|
|
|
|
|
[%- END %] |
266
|
|
|
|
|
|
|
DTEND:[% last.date( format = '%Y%m%dT%H%M%SZ', units = 'z' ) %] |
267
|
|
|
|
|
|
|
END:VEVENT |
268
|
|
|
|
|
|
|
[%- END %] |
269
|
|
|
|
|
|
|
END:VCALENDAR |
270
|
|
|
|
|
|
|
EOD |
271
|
|
|
|
|
|
|
'pass_ics:event' => <<'EOD', |
272
|
|
|
|
|
|
|
[%- evt.event %] |
273
|
|
|
|
|
|
|
[%= evt.time %] [% localize( 'Az' ) %] |
274
|
|
|
|
|
|
|
[%= evt.azimuth( places = 0, bearing = 2 ) %] [% localize( 'Ele' ) %] |
275
|
|
|
|
|
|
|
[%= evt.elevation( places = 0 ) %] |
276
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) && '' != evt.magnitude %] |
277
|
|
|
|
|
|
|
[%= localize( 'Mag' ) %] [% evt.magnitude %] |
278
|
|
|
|
|
|
|
[%- END %] |
279
|
|
|
|
|
|
|
EOD |
280
|
|
|
|
|
|
|
'pass_ics:event:almanac' => <<'EOD', |
281
|
|
|
|
|
|
|
[%- evt.almanac %] [% evt.time %] |
282
|
|
|
|
|
|
|
EOD |
283
|
|
|
|
|
|
|
'pass_ics:event:apls' => <<'EOD', |
284
|
|
|
|
|
|
|
[%- evt.event %] |
285
|
|
|
|
|
|
|
[%- appulse = evt.appulse %] |
286
|
|
|
|
|
|
|
[%= appulse.angle %] |
287
|
|
|
|
|
|
|
[%= appulse.name %] |
288
|
|
|
|
|
|
|
[%= evt.time %] [% localize( 'Az' ) %] |
289
|
|
|
|
|
|
|
[%= evt.azimuth( places = 0, bearing = 2 ) %] |
290
|
|
|
|
|
|
|
[%= evt.elevation( places = 0 ) %] |
291
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) && '' != evt.magnitude %] |
292
|
|
|
|
|
|
|
[%= localize( 'Mag' ) %] [% evt.magnitude %] |
293
|
|
|
|
|
|
|
[%- END %] |
294
|
|
|
|
|
|
|
EOD |
295
|
|
|
|
|
|
|
'pass_ics:event:rise' => <<'EOD', |
296
|
|
|
|
|
|
|
[%- evt.event %] |
297
|
|
|
|
|
|
|
[%= evt.time %] [% localize( 'Az' ) %] |
298
|
|
|
|
|
|
|
[%= evt.azimuth( places = 0, bearing = 2 ) %] |
299
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) && '' != evt.magnitude %] |
300
|
|
|
|
|
|
|
[%= localize( 'Mag' ) %] [% evt.magnitude %] |
301
|
|
|
|
|
|
|
[%- END %] |
302
|
|
|
|
|
|
|
EOD |
303
|
|
|
|
|
|
|
'pass_ics:event:set' => <<'EOD', |
304
|
|
|
|
|
|
|
[%- evt.event %] |
305
|
|
|
|
|
|
|
[%= evt.time %] [% localize( 'Az' ) %] |
306
|
|
|
|
|
|
|
[%= evt.azimuth( places = 0, bearing = 2 ) %] |
307
|
|
|
|
|
|
|
[%- IF sp.want_pass_variant( 'brightest' ) && '' != evt.magnitude %] |
308
|
|
|
|
|
|
|
[%= localize( 'Mag' ) %] [% evt.magnitude %] |
309
|
|
|
|
|
|
|
[%- END %] |
310
|
|
|
|
|
|
|
EOD |
311
|
|
|
|
|
|
|
|
312
|
|
|
|
|
|
|
phase => <<'EOD', |
313
|
|
|
|
|
|
|
[% UNLESS data %] |
314
|
|
|
|
|
|
|
[%- SET data = sp.phase( arg ) %] |
315
|
|
|
|
|
|
|
[%- END %] |
316
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
317
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
318
|
|
|
|
|
|
|
[%- title.date( align_left = 0 ) %] |
319
|
|
|
|
|
|
|
[%= title.time( align_left = 0 ) %] |
320
|
|
|
|
|
|
|
[%= title.name( width = 8, align_left = 0 ) %] |
321
|
|
|
|
|
|
|
[%= title.phase( places = 0, width = 4 ) %] |
322
|
|
|
|
|
|
|
[%= title.phase( width = 16, units = 'phase', |
323
|
|
|
|
|
|
|
align_left = 1 ) %] |
324
|
|
|
|
|
|
|
[%= title.fraction_lit( title = 'Lit', places = 0, width = 4, |
325
|
|
|
|
|
|
|
units = 'percent', align_left = 0 ) %] |
326
|
|
|
|
|
|
|
|
327
|
|
|
|
|
|
|
[%- END %] |
328
|
|
|
|
|
|
|
[%- FOR item IN data %] |
329
|
|
|
|
|
|
|
[%- item.date %] [% item.time %] |
330
|
|
|
|
|
|
|
[%= item.name( width = 8, align_left = 0 ) %] |
331
|
|
|
|
|
|
|
[%= item.phase( places = 0, width = 4 ) %] |
332
|
|
|
|
|
|
|
[%= item.phase( width = 16, units = 'phase', |
333
|
|
|
|
|
|
|
align_left = 1 ) %] |
334
|
|
|
|
|
|
|
[%= item.fraction_lit( places = 0, width = 4, |
335
|
|
|
|
|
|
|
units = 'percent' ) %]% |
336
|
|
|
|
|
|
|
[% END -%] |
337
|
|
|
|
|
|
|
EOD |
338
|
|
|
|
|
|
|
|
339
|
|
|
|
|
|
|
position => <<'EOD', |
340
|
|
|
|
|
|
|
[% UNLESS data %] |
341
|
|
|
|
|
|
|
[%- SET data = sp.position( arg ) %] |
342
|
|
|
|
|
|
|
[%- END %] |
343
|
|
|
|
|
|
|
[%- CALL title.title_gravity( TITLE_GRAVITY_BOTTOM ) %] |
344
|
|
|
|
|
|
|
[%- data.date %] [% data.time %] |
345
|
|
|
|
|
|
|
[%- WHILE title.more_title_lines %] |
346
|
|
|
|
|
|
|
[%- title.name( align_left = 0, width = 16 ) %] |
347
|
|
|
|
|
|
|
[%= title.local_coord %] |
348
|
|
|
|
|
|
|
[%= title.epoch( align_left = 0 ) %] |
349
|
|
|
|
|
|
|
[%= title.illumination %] |
350
|
|
|
|
|
|
|
|
351
|
|
|
|
|
|
|
[%- END %] |
352
|
|
|
|
|
|
|
[%- FOR item IN data.bodies() %] |
353
|
|
|
|
|
|
|
[%- item.name( width = 16, missing = 'oid', align_left = 0 ) %] |
354
|
|
|
|
|
|
|
[%= item.local_coord %] |
355
|
|
|
|
|
|
|
[%= item.epoch( align_left = 0 ) %] |
356
|
|
|
|
|
|
|
[%= item.illumination %] |
357
|
|
|
|
|
|
|
|
358
|
|
|
|
|
|
|
[%- FOR refl IN item.reflections() %] |
359
|
|
|
|
|
|
|
[%- item.name( literal = '', width = 16 ) %] |
360
|
|
|
|
|
|
|
[%= item.local_coord( literal = '' ) %] MMA |
361
|
|
|
|
|
|
|
[%- IF refl.status( width = '' ) %] |
362
|
|
|
|
|
|
|
[%= refl.mma( width = '' ) %] [% refl.status( width = '' ) %] |
363
|
|
|
|
|
|
|
[%- ELSE %] |
364
|
|
|
|
|
|
|
[%= refl.mma( width = '' ) %] mirror angle [% |
365
|
|
|
|
|
|
|
refl.angle( width = '' ) %] magnitude [% |
366
|
|
|
|
|
|
|
refl.magnitude( width = '' ) %] |
367
|
|
|
|
|
|
|
[%- END %] |
368
|
|
|
|
|
|
|
|
369
|
|
|
|
|
|
|
[%- END -%] |
370
|
|
|
|
|
|
|
[% END -%] |
371
|
|
|
|
|
|
|
EOD |
372
|
|
|
|
|
|
|
|
373
|
|
|
|
|
|
|
tle => <<'EOD', |
374
|
|
|
|
|
|
|
[% UNLESS data %] |
375
|
|
|
|
|
|
|
[%- SET data = sp.tle( arg ) %] |
376
|
|
|
|
|
|
|
[%- END %] |
377
|
|
|
|
|
|
|
[%- FOR item IN data %] |
378
|
|
|
|
|
|
|
[%- item.tle -%] |
379
|
|
|
|
|
|
|
[% END -%] |
380
|
|
|
|
|
|
|
EOD |
381
|
|
|
|
|
|
|
|
382
|
|
|
|
|
|
|
tle_verbose => <<'EOD', |
383
|
|
|
|
|
|
|
[% UNLESS data %] |
384
|
|
|
|
|
|
|
[%- SET data = sp.tle( arg ) %] |
385
|
|
|
|
|
|
|
[%- END %] |
386
|
|
|
|
|
|
|
[%- CALL title.fixed_width( 0 ) -%] |
387
|
|
|
|
|
|
|
[% FOR item IN data -%] |
388
|
|
|
|
|
|
|
[% UNLESS item.tle -%] |
389
|
|
|
|
|
|
|
[% NEXT -%] |
390
|
|
|
|
|
|
|
[% END -%] |
391
|
|
|
|
|
|
|
[% CALL item.fixed_width( 0 ) -%] |
392
|
|
|
|
|
|
|
[% title.oid %]: [% item.oid %] |
393
|
|
|
|
|
|
|
[% title.name %]: [% item.name %] |
394
|
|
|
|
|
|
|
[% title.international %]: [% item.international %] |
395
|
|
|
|
|
|
|
[% title.epoch %]: [% item.epoch( units = 'zulu' ) %] GMT |
396
|
|
|
|
|
|
|
[% title.effective_date %]: [% |
397
|
|
|
|
|
|
|
item.effective_date( units = 'zulu', |
398
|
|
|
|
|
|
|
missing = '' ) %] GMT |
399
|
|
|
|
|
|
|
[% title.classification %]: [% item.classification %] |
400
|
|
|
|
|
|
|
[% title.mean_motion %]: [% item.mean_motion( places = 8 ) |
401
|
|
|
|
|
|
|
%] degrees/minute |
402
|
|
|
|
|
|
|
[% title.first_derivative %]: [% |
403
|
|
|
|
|
|
|
item.first_derivative( places = 8 ) %] degrees/minute squared |
404
|
|
|
|
|
|
|
[% title.second_derivative %]: [% |
405
|
|
|
|
|
|
|
item.second_derivative( places = 5 ) %] degrees/minute cubed |
406
|
|
|
|
|
|
|
[% title.b_star_drag %]: [% item.b_star_drag( places = 5 ) %] |
407
|
|
|
|
|
|
|
[% title.ephemeris_type %]: [% item.ephemeris_type %] |
408
|
|
|
|
|
|
|
[% title.inclination %]: [% item.inclination( places = 4 ) %] degrees |
409
|
|
|
|
|
|
|
[% title.ascending_node %]: [% item.ascending_node( |
410
|
|
|
|
|
|
|
places = 0 ) %] in right ascension |
411
|
|
|
|
|
|
|
[% title.eccentricity %]: [% item.eccentricity( places = 7 ) %] |
412
|
|
|
|
|
|
|
[% title.argument_of_perigee %]: [% |
413
|
|
|
|
|
|
|
item.argument_of_perigee( places = 4 ) |
414
|
|
|
|
|
|
|
%] degrees from ascending node |
415
|
|
|
|
|
|
|
[% title.mean_anomaly %]: [% |
416
|
|
|
|
|
|
|
item.mean_anomaly( places = 4 ) %] degrees |
417
|
|
|
|
|
|
|
[% title.element_number %]: [% item.element_number %] |
418
|
|
|
|
|
|
|
[% title.revolutions_at_epoch %]: [% item.revolutions_at_epoch %] |
419
|
|
|
|
|
|
|
[% title.period %]: [% item.period %] |
420
|
|
|
|
|
|
|
[% title.semimajor %]: [% item.semimajor( places = 1 ) %] kilometers |
421
|
|
|
|
|
|
|
[% title.perigee %]: [% item.perigee( places = 1 ) %] kilometers |
422
|
|
|
|
|
|
|
[% title.apogee %]: [% item.apogee( places = 1 ) %] kilometers |
423
|
|
|
|
|
|
|
[% END -%] |
424
|
|
|
|
|
|
|
EOD |
425
|
|
|
|
|
|
|
}, |
426
|
|
|
|
|
|
|
'-flare' => { |
427
|
|
|
|
|
|
|
string => { |
428
|
|
|
|
|
|
|
'Degrees From Sun' => 'Degrees From Sun', |
429
|
|
|
|
|
|
|
'Center Azimuth' => 'Center Azimuth', |
430
|
|
|
|
|
|
|
'Center Range' => 'Center Range', |
431
|
|
|
|
|
|
|
'night' => 'night', |
432
|
|
|
|
|
|
|
}, |
433
|
|
|
|
|
|
|
}, |
434
|
|
|
|
|
|
|
'-location' => { |
435
|
|
|
|
|
|
|
string => { |
436
|
|
|
|
|
|
|
'Location' => 'Location', |
437
|
|
|
|
|
|
|
'Latitude' => 'Latitude', |
438
|
|
|
|
|
|
|
'longitude' => 'longitude', |
439
|
|
|
|
|
|
|
'height' => 'height', |
440
|
|
|
|
|
|
|
}, |
441
|
|
|
|
|
|
|
}, |
442
|
|
|
|
|
|
|
'-pass_ics' => { |
443
|
|
|
|
|
|
|
string => { |
444
|
|
|
|
|
|
|
'Az' => 'Az', |
445
|
|
|
|
|
|
|
'Ele' => 'Ele', |
446
|
|
|
|
|
|
|
'Mag' => 'Mag', |
447
|
|
|
|
|
|
|
}, |
448
|
|
|
|
|
|
|
}, |
449
|
|
|
|
|
|
|
almanac => { |
450
|
|
|
|
|
|
|
title => 'Almanac', |
451
|
|
|
|
|
|
|
Moon => { |
452
|
|
|
|
|
|
|
horizon => [ 'Moon set', 'Moon rise' ], |
453
|
|
|
|
|
|
|
quarter => [ |
454
|
|
|
|
|
|
|
'New Moon', |
455
|
|
|
|
|
|
|
'First quarter Moon', |
456
|
|
|
|
|
|
|
'Full Moon', |
457
|
|
|
|
|
|
|
'Last quarter Moon', |
458
|
|
|
|
|
|
|
], |
459
|
|
|
|
|
|
|
transit => [ undef, 'Moon transits meridian' ], |
460
|
|
|
|
|
|
|
}, |
461
|
|
|
|
|
|
|
Sun => { |
462
|
|
|
|
|
|
|
horizon => [ 'Sunset', 'Sunrise' ], |
463
|
|
|
|
|
|
|
quarter => sub { |
464
|
|
|
|
|
|
|
my ( $key, $arg ) = @_; |
465
|
|
|
|
|
|
|
Scalar::Util::blessed( $arg ) |
466
|
|
|
|
|
|
|
and return $arg->__quarter_name( $key, |
467
|
|
|
|
|
|
|
\@sun_quarters ); |
468
|
|
|
|
|
|
|
return $sun_quarters[$key]; |
469
|
|
|
|
|
|
|
}, |
470
|
|
|
|
|
|
|
transit => [ 'local midnight', 'local noon' ], |
471
|
|
|
|
|
|
|
twilight => [ 'end twilight', 'begin twilight' ], |
472
|
|
|
|
|
|
|
}, |
473
|
|
|
|
|
|
|
}, |
474
|
|
|
|
|
|
|
altitude => { |
475
|
|
|
|
|
|
|
title => 'Altitude', |
476
|
|
|
|
|
|
|
}, |
477
|
|
|
|
|
|
|
angle => { |
478
|
|
|
|
|
|
|
title => 'Angle', |
479
|
|
|
|
|
|
|
}, |
480
|
|
|
|
|
|
|
apoapsis => { |
481
|
|
|
|
|
|
|
title => 'Apoapsis', |
482
|
|
|
|
|
|
|
}, |
483
|
|
|
|
|
|
|
apogee => { |
484
|
|
|
|
|
|
|
title => 'Apogee', |
485
|
|
|
|
|
|
|
}, |
486
|
|
|
|
|
|
|
argument_of_perigee => { |
487
|
|
|
|
|
|
|
title => 'Argument Of Perigee', |
488
|
|
|
|
|
|
|
}, |
489
|
|
|
|
|
|
|
ascending_node => { |
490
|
|
|
|
|
|
|
title => 'Ascending Node', |
491
|
|
|
|
|
|
|
}, |
492
|
|
|
|
|
|
|
azimuth => { |
493
|
|
|
|
|
|
|
title => 'Azimuth', |
494
|
|
|
|
|
|
|
}, |
495
|
|
|
|
|
|
|
bearing => { |
496
|
|
|
|
|
|
|
table => [ |
497
|
|
|
|
|
|
|
[ qw{ N E S W } ], |
498
|
|
|
|
|
|
|
[ qw{ N NE E SE S SW W NW } ], |
499
|
|
|
|
|
|
|
[ qw{ N NNE NE ENE E ESE SE SSE S SSW SW WSW W WNW NW |
500
|
|
|
|
|
|
|
NNW } ], |
501
|
|
|
|
|
|
|
], |
502
|
|
|
|
|
|
|
}, |
503
|
|
|
|
|
|
|
b_star_drag => { |
504
|
|
|
|
|
|
|
title => 'B Star Drag', |
505
|
|
|
|
|
|
|
}, |
506
|
|
|
|
|
|
|
classification => { |
507
|
|
|
|
|
|
|
title => 'Classification', |
508
|
|
|
|
|
|
|
}, |
509
|
|
|
|
|
|
|
date => { |
510
|
|
|
|
|
|
|
title => 'Date', |
511
|
|
|
|
|
|
|
}, |
512
|
|
|
|
|
|
|
declination => { |
513
|
|
|
|
|
|
|
title => 'Declination', |
514
|
|
|
|
|
|
|
}, |
515
|
|
|
|
|
|
|
eccentricity => { |
516
|
|
|
|
|
|
|
title => 'Eccentricity', |
517
|
|
|
|
|
|
|
}, |
518
|
|
|
|
|
|
|
effective_date => { |
519
|
|
|
|
|
|
|
title => 'Effective Date', |
520
|
|
|
|
|
|
|
}, |
521
|
|
|
|
|
|
|
element_number => { |
522
|
|
|
|
|
|
|
title => 'Element Number', |
523
|
|
|
|
|
|
|
}, |
524
|
|
|
|
|
|
|
elevation => { |
525
|
|
|
|
|
|
|
title => 'Elevation', |
526
|
|
|
|
|
|
|
}, |
527
|
|
|
|
|
|
|
ephemeris_type => { |
528
|
|
|
|
|
|
|
title => 'Ephemeris Type', |
529
|
|
|
|
|
|
|
}, |
530
|
|
|
|
|
|
|
epoch => { |
531
|
|
|
|
|
|
|
title => 'Epoch', |
532
|
|
|
|
|
|
|
}, |
533
|
|
|
|
|
|
|
event => { |
534
|
|
|
|
|
|
|
table => [ @event_names ], |
535
|
|
|
|
|
|
|
title => 'Event', |
536
|
|
|
|
|
|
|
}, |
537
|
|
|
|
|
|
|
first_derivative => { |
538
|
|
|
|
|
|
|
title => 'First Derivative', |
539
|
|
|
|
|
|
|
}, |
540
|
|
|
|
|
|
|
fraction_lit => { |
541
|
|
|
|
|
|
|
title => 'Fraction Lit', |
542
|
|
|
|
|
|
|
}, |
543
|
|
|
|
|
|
|
illumination => { |
544
|
|
|
|
|
|
|
title => 'Illumination', |
545
|
|
|
|
|
|
|
}, |
546
|
|
|
|
|
|
|
inclination => { |
547
|
|
|
|
|
|
|
title => 'Inclination', |
548
|
|
|
|
|
|
|
}, |
549
|
|
|
|
|
|
|
international => { |
550
|
|
|
|
|
|
|
title => 'International Launch Designator', |
551
|
|
|
|
|
|
|
}, |
552
|
|
|
|
|
|
|
latitude => { |
553
|
|
|
|
|
|
|
title => 'Latitude', |
554
|
|
|
|
|
|
|
}, |
555
|
|
|
|
|
|
|
longitude => { |
556
|
|
|
|
|
|
|
title => 'Longitude', |
557
|
|
|
|
|
|
|
}, |
558
|
|
|
|
|
|
|
magnitude => { |
559
|
|
|
|
|
|
|
title => 'Magnitude', |
560
|
|
|
|
|
|
|
}, |
561
|
|
|
|
|
|
|
maidenhead => { |
562
|
|
|
|
|
|
|
title => 'Maidenhead Grid Square', |
563
|
|
|
|
|
|
|
}, |
564
|
|
|
|
|
|
|
mean_anomaly => { |
565
|
|
|
|
|
|
|
title => 'Mean Anomaly', |
566
|
|
|
|
|
|
|
}, |
567
|
|
|
|
|
|
|
mean_motion => { |
568
|
|
|
|
|
|
|
title => 'Mean Motion', |
569
|
|
|
|
|
|
|
}, |
570
|
|
|
|
|
|
|
mma => { |
571
|
|
|
|
|
|
|
title => 'MMA', |
572
|
|
|
|
|
|
|
}, |
573
|
|
|
|
|
|
|
name => { |
574
|
|
|
|
|
|
|
title => 'Name', |
575
|
|
|
|
|
|
|
localize_value => { |
576
|
|
|
|
|
|
|
Sun => 'Sun', |
577
|
|
|
|
|
|
|
Moon => 'Moon', |
578
|
|
|
|
|
|
|
}, |
579
|
|
|
|
|
|
|
}, |
580
|
|
|
|
|
|
|
oid => { |
581
|
|
|
|
|
|
|
title => 'OID', |
582
|
|
|
|
|
|
|
}, |
583
|
|
|
|
|
|
|
operational => { |
584
|
|
|
|
|
|
|
title => 'Operational', |
585
|
|
|
|
|
|
|
}, |
586
|
|
|
|
|
|
|
periapsis => { |
587
|
|
|
|
|
|
|
title => 'Periapsis', |
588
|
|
|
|
|
|
|
}, |
589
|
|
|
|
|
|
|
perigee => { |
590
|
|
|
|
|
|
|
title => 'Perigee', |
591
|
|
|
|
|
|
|
}, |
592
|
|
|
|
|
|
|
period => { |
593
|
|
|
|
|
|
|
title => 'Period', |
594
|
|
|
|
|
|
|
}, |
595
|
|
|
|
|
|
|
phase => { |
596
|
|
|
|
|
|
|
table => [ |
597
|
|
|
|
|
|
|
[ 6.1 => 'new' ], |
598
|
|
|
|
|
|
|
[ 83.9 => 'waxing crescent' ], |
599
|
|
|
|
|
|
|
[ 96.1 => 'first quarter' ], |
600
|
|
|
|
|
|
|
[ 173.9 => 'waxing gibbous' ], |
601
|
|
|
|
|
|
|
[ 186.1 => 'full' ], |
602
|
|
|
|
|
|
|
[ 263.9 => 'waning gibbous' ], |
603
|
|
|
|
|
|
|
[ 276.1 => 'last quarter' ], |
604
|
|
|
|
|
|
|
[ 353.9 => 'waning crescent' ], |
605
|
|
|
|
|
|
|
], |
606
|
|
|
|
|
|
|
title => 'Phase', |
607
|
|
|
|
|
|
|
}, |
608
|
|
|
|
|
|
|
range => { |
609
|
|
|
|
|
|
|
title => 'Range', |
610
|
|
|
|
|
|
|
}, |
611
|
|
|
|
|
|
|
revolutions_at_epoch => { |
612
|
|
|
|
|
|
|
title => 'Revolutions At Epoch', |
613
|
|
|
|
|
|
|
}, |
614
|
|
|
|
|
|
|
right_ascension => { |
615
|
|
|
|
|
|
|
title => 'Right Ascension', |
616
|
|
|
|
|
|
|
}, |
617
|
|
|
|
|
|
|
second_derivative => { |
618
|
|
|
|
|
|
|
title => 'Second Derivative', |
619
|
|
|
|
|
|
|
}, |
620
|
|
|
|
|
|
|
semimajor => { |
621
|
|
|
|
|
|
|
title => 'Semimajor Axis', |
622
|
|
|
|
|
|
|
}, |
623
|
|
|
|
|
|
|
semiminor => { |
624
|
|
|
|
|
|
|
title => 'Semiminor Axis', |
625
|
|
|
|
|
|
|
}, |
626
|
|
|
|
|
|
|
status => { |
627
|
|
|
|
|
|
|
title => 'Status', |
628
|
|
|
|
|
|
|
}, |
629
|
|
|
|
|
|
|
time => { |
630
|
|
|
|
|
|
|
title => 'Time', |
631
|
|
|
|
|
|
|
}, |
632
|
|
|
|
|
|
|
tle => { |
633
|
|
|
|
|
|
|
title => 'TLE', |
634
|
|
|
|
|
|
|
}, |
635
|
|
|
|
|
|
|
type => { |
636
|
|
|
|
|
|
|
title => 'Type', |
637
|
|
|
|
|
|
|
}, |
638
|
|
|
|
|
|
|
}; |
639
|
|
|
|
|
|
|
|
640
|
|
|
|
|
|
|
__END__ |