openc3-cosmos-demo 5.19.0 → 5.20.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b81293bb997165f1b8c35dbd8cc4ec5a4de4b5810a6c746047662a89149e3950
4
- data.tar.gz: 70e36acc62a6be36a5c02dc6261a66da19069cc18cae3c1dfa9ff460587a8f4e
3
+ metadata.gz: fd81132780179ea8ece04e981e278f7fbd40613d15cbb08ca8854d9a995a1033
4
+ data.tar.gz: 78be70c4ea0c4c07d4be6a7b820319d4e4d0a67d0bc172799d05f85ce6656eb9
5
5
  SHA512:
6
- metadata.gz: 611c47f8a6ca07d7b7cb6064681d3a1732b08016136dc37d8ae4dea36bae37c451974b1048d4c1fc29336bfd8e794f7f11c28d134822ff76e4153b59418e8bae
7
- data.tar.gz: 9e078e3e96fb62130dcbcd4daf4fc0c53f903ed82fb8161be8279e361812a851e18d603bf60efa66be29bd336a9bc832386bddb053d7279d5e380f3c39cb66c9
6
+ metadata.gz: 77961d9be04287a2b42aa3c969a22ff50e5d6842ad18f771bd77553bca9cb62e3463e2f08f15eeca751654b24bd911abbaef6759cecf8dad3ea812788ba97b75
7
+ data.tar.gz: 3d659f81e25cf57046819e0007732dfec5e7c01b2588e7f4513214d078d1a9553855215c68566b840c517696cac6fc711f5b2c1c38bc96f41934f14edea47fee
data/requirements.txt ADDED
@@ -0,0 +1 @@
1
+ numpy==2.1.1
@@ -12,14 +12,14 @@ class ExampleTest < OpenC3::Test
12
12
  puts "continue past raise"
13
13
  end
14
14
 
15
- def test_2
15
+ def test_req2
16
16
  puts "Running #{OpenC3::Test.current_test_suite}:#{OpenC3::Test.current_test}:#{OpenC3::Test.current_test_case}"
17
17
  OpenC3::Test.puts "This test verifies requirement 2"
18
18
  helper()
19
19
  wait(2)
20
20
  end
21
21
 
22
- def test_3
22
+ def test_req3
23
23
  puts "Running #{OpenC3::Test.current_test_suite}:#{OpenC3::Test.current_test}:#{OpenC3::Test.current_test_case}"
24
24
  raise SkipTestCase
25
25
  end
@@ -1,12 +1,12 @@
1
1
  SCREEN AUTO AUTO 0.5
2
2
 
3
- VERTICAL
4
- TITLE "<%= target_name %> Commanding Examples"
3
+ TITLE "<%= target_name %> Commanding Examples"
5
4
 
6
- LABELVALUE <%= target_name %> HEALTH_STATUS COLLECTS
7
- LABELVALUE <%= target_name %> HEALTH_STATUS COLLECT_TYPE
8
- LABELVALUE <%= target_name %> HEALTH_STATUS DURATION
5
+ LABELVALUE <%= target_name %> HEALTH_STATUS COLLECTS
6
+ LABELVALUE <%= target_name %> HEALTH_STATUS COLLECT_TYPE
7
+ LABELVALUE <%= target_name %> HEALTH_STATUS DURATION
9
8
 
9
+ MATRIXBYCOLUMNS 2
10
10
  VERTICALBOX "Send Collect Command:"
11
11
  HORIZONTAL
12
12
  LABEL "Type: "
@@ -32,11 +32,13 @@ VERTICAL
32
32
  END
33
33
 
34
34
  VERTICALBOX "Parameter-less Commands:"
35
- NAMED_WIDGET GROUP RADIOGROUP 1 # Select 'Clear' initially, 0-based index
36
- RADIOBUTTON 'Abort'
37
- RADIOBUTTON 'Clear'
35
+ HORIZONTAL
36
+ NAMED_WIDGET GROUP RADIOGROUP 1 # Select 'Clear' initially, 0-based index
37
+ RADIOBUTTON 'Abort'
38
+ RADIOBUTTON 'Clear'
39
+ END
40
+ NAMED_WIDGET CHECK CHECKBUTTON 'Ignore Hazardous Checks' # No option is by default UNCHECKED
38
41
  END
39
- NAMED_WIDGET CHECK CHECKBUTTON 'Ignore Hazardous Checks' # No option is by default UNCHECKED
40
42
  BUTTON 'Send' "screen.getNamedWidget('GROUP').selected() === 0 ? " +
41
43
  "api.cmd('<%= target_name %> ABORT') : (screen.getNamedWidget('CHECK').checked() ? " +
42
44
  "api.cmd_no_hazardous_check('<%= target_name %> CLEAR') : api.cmd('<%= target_name %> CLEAR'))"
@@ -54,4 +56,16 @@ VERTICAL
54
56
  "var env = {}; env['TYPE'] = ctype;" \
55
57
  "runScript('<%= target_name %>/procedures/'+script, !screen.getNamedWidget('BG').checked(), env)"
56
58
  END
59
+
60
+ VERTICALBOX "Date / Time Chooser"
61
+ HORIZONTAL 5
62
+ NAMED_WIDGET DATE Date "Input Date"
63
+ NAMED_WIDGET TIME Time
64
+ END
65
+
66
+ BUTTON 'Alert' "var date=screen.getNamedWidget('DATE').text();" +
67
+ "var time=screen.getNamedWidget('TIME').text();" +
68
+ # You can have comments between string concatenations
69
+ "alert('DATE:'+date+' TIME:'+time)"
70
+ END
57
71
  END
@@ -16,6 +16,7 @@ VERTICAL
16
16
  VERTICALBOX "Temperatures"
17
17
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP1 WITH_UNITS
18
18
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 CONVERTED 25
19
+ SUBSETTING 2 WIDTH 160
19
20
  # LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 RAW 20 # RAW is not allowed for LIMITSBAR widgets
20
21
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 FORMATTED
21
22
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 WITH_UNITS
@@ -11,7 +11,7 @@ HORIZONTAL
11
11
  SETTING SCREEN <%= target_name %> LIMITS
12
12
  SETTING TLM <%= target_name %> HEALTH_STATUS TEMP1
13
13
  ROLLUP equipment "Processor" "CPU"
14
- SETTING SCREEN <%= target_name %> ADCS
14
+ # No SCREEN should display without pointer cursor
15
15
  SETTING TLM <%= target_name %> HEALTH_STATUS TEMP4
16
16
  ROLLUP satellite-transmit "Satellite" "all temps"
17
17
  SETTING SCREEN <%= target_name %> HS
@@ -13,7 +13,7 @@ class ExampleTest(Test):
13
13
  raise RuntimeError("error")
14
14
  print("continue past raise") # NOSONAR
15
15
 
16
- def test_2(self):
16
+ def test_req2(self):
17
17
  print(
18
18
  f"Running {Test.current_test_suite()}:{Test.current_test()}:{Test.current_test_case()}"
19
19
  )
@@ -21,7 +21,7 @@ class ExampleTest(Test):
21
21
  self.helper()
22
22
  wait(2)
23
23
 
24
- def test_3(self):
24
+ def test_req3(self):
25
25
  print(
26
26
  f"Running {Test.current_test_suite()}:{Test.current_test()}:{Test.current_test_case()}"
27
27
  )
@@ -0,0 +1,11 @@
1
+ # The standard way to import NumPy:
2
+ import numpy as np
3
+
4
+ # Create a 2-D array, set every second element in
5
+ # some rows and find max per row:
6
+ x = np.arange(15, dtype=np.int64).reshape(3, 5)
7
+ x[1:, ::2] = -99
8
+ print(x)
9
+ # array([[ 0, 1, 2, 3, 4],
10
+ # [-99, 6, -99, 8, -99],
11
+ # [-99, 11, -99, 13, -99]])
@@ -1,12 +1,12 @@
1
1
  SCREEN AUTO AUTO 0.5
2
2
 
3
- VERTICAL
4
- TITLE "<%= target_name %> Commanding Examples"
3
+ TITLE "<%= target_name %> Commanding Examples"
5
4
 
6
- LABELVALUE <%= target_name %> HEALTH_STATUS COLLECTS
7
- LABELVALUE <%= target_name %> HEALTH_STATUS COLLECT_TYPE
8
- LABELVALUE <%= target_name %> HEALTH_STATUS DURATION
5
+ LABELVALUE <%= target_name %> HEALTH_STATUS COLLECTS
6
+ LABELVALUE <%= target_name %> HEALTH_STATUS COLLECT_TYPE
7
+ LABELVALUE <%= target_name %> HEALTH_STATUS DURATION
9
8
 
9
+ MATRIXBYCOLUMNS 2
10
10
  VERTICALBOX "Send Collect Command:"
11
11
  HORIZONTAL
12
12
  LABEL "Type: "
@@ -32,11 +32,13 @@ VERTICAL
32
32
  END
33
33
 
34
34
  VERTICALBOX "Parameter-less Commands:"
35
- NAMED_WIDGET GROUP RADIOGROUP 1 # Select 'Clear' initially, 0-based index
36
- RADIOBUTTON 'Abort'
37
- RADIOBUTTON 'Clear'
35
+ HORIZONTAL
36
+ NAMED_WIDGET GROUP RADIOGROUP 1 # Select 'Clear' initially, 0-based index
37
+ RADIOBUTTON 'Abort'
38
+ RADIOBUTTON 'Clear'
39
+ END
40
+ NAMED_WIDGET CHECK CHECKBUTTON 'Ignore Hazardous Checks' # No option is by default UNCHECKED
38
41
  END
39
- NAMED_WIDGET CHECK CHECKBUTTON 'Ignore Hazardous Checks' # No option is by default UNCHECKED
40
42
  BUTTON 'Send' "screen.getNamedWidget('GROUP').selected() === 0 ? " +
41
43
  "api.cmd('<%= target_name %> ABORT') : (screen.getNamedWidget('CHECK').checked() ? " +
42
44
  "api.cmd_no_hazardous_check('<%= target_name %> CLEAR') : api.cmd('<%= target_name %> CLEAR'))"
@@ -50,8 +52,20 @@ VERTICAL
50
52
  BUTTON 'Run Script' "var script=screen.getNamedWidget('SCRIPTNAME').text();" \
51
53
  "var ctype=screen.getNamedWidget('COLLECT_TYPE').text();" \
52
54
  # Set some environment variables to be used by the script as ENV['TYPE']
53
- # See INST2/procedures/checks.rb for an example of usage
55
+ # See INST2/procedures/checks.py for an example of usage
54
56
  "var env = {}; env['TYPE'] = ctype;" \
55
57
  "runScript('<%= target_name %>/procedures/'+script, !screen.getNamedWidget('BG').checked(), env)"
56
58
  END
59
+
60
+ VERTICALBOX "Date / Time Chooser"
61
+ HORIZONTAL 5
62
+ NAMED_WIDGET DATE Date "Input Date"
63
+ NAMED_WIDGET TIME Time
64
+ END
65
+
66
+ BUTTON 'Alert' "var date=screen.getNamedWidget('DATE').text();" +
67
+ "var time=screen.getNamedWidget('TIME').text();" +
68
+ # You can have comments between string concatenations
69
+ "alert('DATE:'+date+' TIME:'+time)"
70
+ END
57
71
  END
@@ -16,6 +16,7 @@ VERTICAL
16
16
  VERTICALBOX "Temperatures"
17
17
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP1 WITH_UNITS
18
18
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 CONVERTED 25
19
+ SUBSETTING 2 WIDTH 160
19
20
  # LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 RAW 20 # RAW is not allowed for LIMITSBAR widgets
20
21
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 FORMATTED
21
22
  LABELVALUELIMITSBAR <%= target_name %> HEALTH_STATUS TEMP2 WITH_UNITS
@@ -11,7 +11,7 @@ HORIZONTAL
11
11
  SETTING SCREEN <%= target_name %> LIMITS
12
12
  SETTING TLM <%= target_name %> HEALTH_STATUS TEMP1
13
13
  ROLLUP equipment "Processor" "CPU"
14
- SETTING SCREEN <%= target_name %> ADCS
14
+ # No SCREEN should display without pointer cursor
15
15
  SETTING TLM <%= target_name %> HEALTH_STATUS TEMP4
16
16
  ROLLUP satellite-transmit "Satellite" "all temps"
17
17
  SETTING SCREEN <%= target_name %> HS
@@ -17,12 +17,6 @@ cmd("INST CLEAR")
17
17
  puts index
18
18
  end
19
19
 
20
- if false
21
- puts false
22
- else
23
- puts true
24
- end
25
-
26
20
  wait_expression('false', 10)
27
21
  wait(10)
28
22