telescope-term 0.5.2 → 0.5.3
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.
- checksums.yaml +4 -4
- data/bin/telescope +35 -10
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6bccc053edff15e7f32e22c80a0cff25b3ffbc88155743eae29b4cfc1b0a6591
|
|
4
|
+
data.tar.gz: 6b94e933c3bf9b2f263940b5bded516e155972fea4b7cfe492dc9d59ca5b8899
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bad1524541bd4b94f2c8ea827860239ba74c3bb76fc0b0405828dde8c5c833f612b3cf403f86f8123eb2c4228e34922f00e057b58f9da7a73ef0ce57d542a934
|
|
7
|
+
data.tar.gz: 9c58155c752fc6b0bd24b6791be425d0b5c53b08ca7d0c5e01d9f94392ea3dfe751d48a015ab45740df4179468b0f6623f2ad3fcccd7af575bed79c779b1e0d8
|
data/bin/telescope
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
WELCOME TO TELESCOPE - A TERMINAL/CONSOLE PROGRAM FOR THE AMATEUR ASTRONOMER.
|
|
5
5
|
The top panel lists your telescopes with eyepieces in the lower panel. Add a telescope by pressing 't' and fill in the name, the
|
|
6
6
|
apperature (APP) and the focal length (FL) in the "command line" at the bottom and press ENTER. Add an eyepiece with 'e' and enter
|
|
7
|
-
a name, the focal length (FL) and apparent field of view (AFOV) and press ENTER. Select items by
|
|
7
|
+
a name, the focal length (FL) and apparent field of view (AFOV) and press ENTER. Select items by using the TAB/UP/DOWN cursor keys.
|
|
8
8
|
Press ENTER on a selected item to change the values in the command line. Delete an item by pressing 'D'. Move an with PgUP/PgDown keys.
|
|
9
9
|
Tag items with the SPACE key (untag all with 'u'), then press 'o' to create an observation log file (content shown in the lower panel).
|
|
10
10
|
Refresh all panels with the 'r' key. Escape the selected panels or the command line by pressing 'Ctrl-G'. Quit via 'q' (or 'Q' if you
|
|
@@ -54,6 +54,9 @@ end
|
|
|
54
54
|
class Numeric # NUMERIC CLASS EXTENSION
|
|
55
55
|
def deg
|
|
56
56
|
self * Math::PI / 180
|
|
57
|
+
end
|
|
58
|
+
def rad
|
|
59
|
+
self * 180 / Math::PI
|
|
57
60
|
end
|
|
58
61
|
def dec2
|
|
59
62
|
"%.2f" % self
|
|
@@ -246,15 +249,37 @@ def main_getkey # GET KEY FROM USER
|
|
|
246
249
|
end
|
|
247
250
|
when 'UP' # Examples of moving up and down in a window
|
|
248
251
|
if @tsmark
|
|
249
|
-
|
|
252
|
+
if @tsmark == 0
|
|
253
|
+
@tsmark = false
|
|
254
|
+
else
|
|
255
|
+
@tsmark -= 1
|
|
256
|
+
end
|
|
250
257
|
elsif @epmark
|
|
251
|
-
|
|
258
|
+
if @epmark == 0
|
|
259
|
+
@epmark = false
|
|
260
|
+
@tsmark = @ts.length - 1
|
|
261
|
+
else
|
|
262
|
+
@epmark -= 1
|
|
263
|
+
end
|
|
264
|
+
else
|
|
265
|
+
@epmark = @ep.length - 1
|
|
252
266
|
end
|
|
253
267
|
when 'DOWN'
|
|
254
268
|
if @tsmark
|
|
255
|
-
|
|
269
|
+
if @tsmark == @ts.length - 1
|
|
270
|
+
@tsmark = false
|
|
271
|
+
@epmark = 0
|
|
272
|
+
else
|
|
273
|
+
@tsmark += 1
|
|
274
|
+
end
|
|
256
275
|
elsif @epmark
|
|
257
|
-
|
|
276
|
+
if @epmark == @ep.length - 1
|
|
277
|
+
@epmark = false
|
|
278
|
+
else
|
|
279
|
+
@epmark += 1
|
|
280
|
+
end
|
|
281
|
+
else
|
|
282
|
+
@tsmark = 0
|
|
258
283
|
end
|
|
259
284
|
when 'PgUP'
|
|
260
285
|
if @tsmark
|
|
@@ -336,7 +361,7 @@ def observe
|
|
|
336
361
|
mag = (5 * Math::log(d/10, 10) + 7.5).truncate(1).to_s
|
|
337
362
|
obs += " Max MAG: " + mag
|
|
338
363
|
sepd = (115.824/d).truncate(2).to_s
|
|
339
|
-
sepr = (3600*Math::asin(671E-6/d)
|
|
364
|
+
sepr = (3600*Math::asin(671E-6/d).rad).truncate(2).to_s
|
|
340
365
|
obs += " Min SEP: " + sepd + "/" + sepr + "\n"
|
|
341
366
|
end
|
|
342
367
|
obs += "No telescope(s) chosen for the observation\n" if @tstag.empty?
|
|
@@ -383,7 +408,7 @@ def w_ts_show
|
|
|
383
408
|
@w_ts.fg = 15
|
|
384
409
|
@w_ts.bg = 0
|
|
385
410
|
@ts.each_with_index do |scope, i|
|
|
386
|
-
name = scope[0]
|
|
411
|
+
name = scope[0][0...15]
|
|
387
412
|
d = scope[1]
|
|
388
413
|
f = scope[2]
|
|
389
414
|
out = " " + name.ljust(15)
|
|
@@ -415,9 +440,9 @@ def w_ts_show
|
|
|
415
440
|
@w_ts.pa(189, 0, 0, out) # TGHT2*
|
|
416
441
|
out = (115.824/d).truncate(2).dec2.to_s.rjust(7)
|
|
417
442
|
@w_ts.pa(219, 0, 0, out) # DL-SEP
|
|
418
|
-
out = (3600*Math::asin(671E-6/d)
|
|
443
|
+
out = (3600*Math::asin(671E-6/d).rad).truncate(2).dec2.to_s.rjust(8)
|
|
419
444
|
@w_ts.pa(219, 0, 0, out) # RC-SEP
|
|
420
|
-
moon = (384E6*Math::tan((
|
|
445
|
+
moon = (384E6*Math::tan((115.824.deg/d)/3600))
|
|
421
446
|
out = moon.to_i.to_s.rjust(6) + "m"
|
|
422
447
|
@w_ts.pa(225, 0, 0, out) # MOON
|
|
423
448
|
out = (moon/2.5668).to_i.to_s.rjust(5) + "km"
|
|
@@ -452,7 +477,7 @@ def w_ep_show
|
|
|
452
477
|
@w_ep.fg = 15
|
|
453
478
|
@w_ep.bg = 0
|
|
454
479
|
@ep.each_with_index do |ep, i|
|
|
455
|
-
name = ep[0]
|
|
480
|
+
name = ep[0][0...15]
|
|
456
481
|
m = ep[1].truncate(1)
|
|
457
482
|
a = ep[2]
|
|
458
483
|
out = " " + name.ljust(15)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: telescope-term
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.5.
|
|
4
|
+
version: 0.5.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Geir Isene
|
|
@@ -32,8 +32,8 @@ dependencies:
|
|
|
32
32
|
version: 1.3.2
|
|
33
33
|
description: 'With this program you can list your telescopes and eyepieces and get
|
|
34
34
|
a set of calculations done for each scope and for the combination of scope and eyepiece.
|
|
35
|
-
Easy interface. Run the program, then hit ''?'' to show the help file. New in v0.5.
|
|
36
|
-
|
|
35
|
+
Easy interface. Run the program, then hit ''?'' to show the help file. New in v0.5.3:
|
|
36
|
+
Improved navigation.'
|
|
37
37
|
email: g@isene.com
|
|
38
38
|
executables:
|
|
39
39
|
- telescope
|