opencrbasic 1.0.0__py3-none-any.whl

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 (117) hide show
  1. opencrbasic/__init__.py +3 -0
  2. opencrbasic/__main__.py +5 -0
  3. opencrbasic/analysis.py +184 -0
  4. opencrbasic/bindings.py +1034 -0
  5. opencrbasic/catalog.py +173 -0
  6. opencrbasic/checkconfig.py +144 -0
  7. opencrbasic/checker/__init__.py +977 -0
  8. opencrbasic/checker/cr3xx.py +3118 -0
  9. opencrbasic/checker/ess.py +81 -0
  10. opencrbasic/checker/expressions.py +3581 -0
  11. opencrbasic/checker/instr_data.py +1802 -0
  12. opencrbasic/checker/instr_measure.py +1547 -0
  13. opencrbasic/checker/instr_rules.py +3540 -0
  14. opencrbasic/checker/instructions.py +17 -0
  15. opencrbasic/checker/intervals.py +678 -0
  16. opencrbasic/checker/longconv.py +133 -0
  17. opencrbasic/checker/scan_time.py +580 -0
  18. opencrbasic/checker/storage.py +456 -0
  19. opencrbasic/checker/structs.py +240 -0
  20. opencrbasic/checker/structure.py +6213 -0
  21. opencrbasic/checker/symbols.py +609 -0
  22. opencrbasic/checker/terminals.py +249 -0
  23. opencrbasic/checker/unused.py +186 -0
  24. opencrbasic/checker/var_types.py +564 -0
  25. opencrbasic/checker/warnings.py +661 -0
  26. opencrbasic/checks.py +491 -0
  27. opencrbasic/cli.py +391 -0
  28. opencrbasic/commands.py +128 -0
  29. opencrbasic/compiler.py +320 -0
  30. opencrbasic/consteval.py +327 -0
  31. opencrbasic/data/background_calibration.json +4 -0
  32. opencrbasic/data/before_beginprog.json +99 -0
  33. opencrbasic/data/cr1000x/background_calibration.json +4 -0
  34. opencrbasic/data/cr1000x/before_beginprog.json +138 -0
  35. opencrbasic/data/cr1000x/ess_variables.json +1087 -0
  36. opencrbasic/data/cr1000x/fnotch.json +29 -0
  37. opencrbasic/data/cr1000x/functions.json +1337 -0
  38. opencrbasic/data/cr1000x/instructions.json +4836 -0
  39. opencrbasic/data/cr1000x/measure.json +121 -0
  40. opencrbasic/data/cr1000x/mode.json +111 -0
  41. opencrbasic/data/cr1000x/pipeline_tasks.json +88 -0
  42. opencrbasic/data/cr1000x/settings_fields.json +321 -0
  43. opencrbasic/data/cr1000x/status_members.json +318 -0
  44. opencrbasic/data/cr1000x/symbols.json +872 -0
  45. opencrbasic/data/cr1000x/terminals.json +225 -0
  46. opencrbasic/data/cr300/before_beginprog.json +42 -0
  47. opencrbasic/data/cr300/ess_variables.json +1087 -0
  48. opencrbasic/data/cr300/fnotch.json +22 -0
  49. opencrbasic/data/cr300/functions.json +1261 -0
  50. opencrbasic/data/cr300/instructions.json +2837 -0
  51. opencrbasic/data/cr300/measure.json +33 -0
  52. opencrbasic/data/cr300/mode.json +121 -0
  53. opencrbasic/data/cr300/settings_fields.json +259 -0
  54. opencrbasic/data/cr300/status_members.json +303 -0
  55. opencrbasic/data/cr300/symbols.json +584 -0
  56. opencrbasic/data/cr300/terminals.json +193 -0
  57. opencrbasic/data/cr350/before_beginprog.json +44 -0
  58. opencrbasic/data/cr350/ess_variables.json +1087 -0
  59. opencrbasic/data/cr350/fnotch.json +22 -0
  60. opencrbasic/data/cr350/functions.json +1262 -0
  61. opencrbasic/data/cr350/instructions.json +2848 -0
  62. opencrbasic/data/cr350/measure.json +35 -0
  63. opencrbasic/data/cr350/mode.json +121 -0
  64. opencrbasic/data/cr350/settings_fields.json +292 -0
  65. opencrbasic/data/cr350/status_members.json +303 -0
  66. opencrbasic/data/cr350/symbols.json +572 -0
  67. opencrbasic/data/cr350/terminals.json +190 -0
  68. opencrbasic/data/ess_variables.json +1087 -0
  69. opencrbasic/data/fnotch.json +34 -0
  70. opencrbasic/data/functions.json +1337 -0
  71. opencrbasic/data/instructions.json +4965 -0
  72. opencrbasic/data/measure.json +123 -0
  73. opencrbasic/data/mode.json +121 -0
  74. opencrbasic/data/notices_cr6.json +890 -0
  75. opencrbasic/data/pipeline_tasks.json +84 -0
  76. opencrbasic/data/settings_fields.json +322 -0
  77. opencrbasic/data/status_members.json +319 -0
  78. opencrbasic/data/status_table.json +684 -0
  79. opencrbasic/data/symbols.json +902 -0
  80. opencrbasic/data/terminals.json +195 -0
  81. opencrbasic/data/type_codes.json +249 -0
  82. opencrbasic/diagnostics.py +196 -0
  83. opencrbasic/editing.py +827 -0
  84. opencrbasic/formatting.py +310 -0
  85. opencrbasic/helpdocs.py +677 -0
  86. opencrbasic/hover.py +667 -0
  87. opencrbasic/inlay.py +169 -0
  88. opencrbasic/lexer.py +183 -0
  89. opencrbasic/lsp/__init__.py +5 -0
  90. opencrbasic/lsp/__main__.py +7 -0
  91. opencrbasic/lsp/config.py +202 -0
  92. opencrbasic/lsp/features.py +602 -0
  93. opencrbasic/lsp/server.py +741 -0
  94. opencrbasic/lsp/session.py +1189 -0
  95. opencrbasic/lsp/worker.py +128 -0
  96. opencrbasic/mode.py +143 -0
  97. opencrbasic/navigation.py +401 -0
  98. opencrbasic/parser.py +3264 -0
  99. opencrbasic/positions.py +274 -0
  100. opencrbasic/preprocess.py +269 -0
  101. opencrbasic/profiles.py +266 -0
  102. opencrbasic/provenance.py +17 -0
  103. opencrbasic/quickfix.py +331 -0
  104. opencrbasic/rename.py +662 -0
  105. opencrbasic/signature.py +33 -0
  106. opencrbasic/source.py +600 -0
  107. opencrbasic/sources.py +125 -0
  108. opencrbasic/syntax.py +337 -0
  109. opencrbasic/tables.py +2173 -0
  110. opencrbasic/tables_hook.py +14 -0
  111. opencrbasic/tdf.py +142 -0
  112. opencrbasic/timing.py +565 -0
  113. opencrbasic-1.0.0.dist-info/METADATA +223 -0
  114. opencrbasic-1.0.0.dist-info/RECORD +117 -0
  115. opencrbasic-1.0.0.dist-info/WHEEL +4 -0
  116. opencrbasic-1.0.0.dist-info/entry_points.txt +3 -0
  117. opencrbasic-1.0.0.dist-info/licenses/LICENSE +21 -0
@@ -0,0 +1,225 @@
1
+ {
2
+ "channels": {
3
+ "current_chan_cr1000x": {
4
+ "ranges": [[401, 402], [-402, -401]],
5
+ "transform": "none",
6
+ "truncate": true,
7
+ "skip_nonpositive": false,
8
+ "message": "Invalid channel {v}, must be RG1 or RG2.",
9
+ "string_int_min": true
10
+ },
11
+ "diff_chan": {
12
+ "span": {"message": "Channel {v} exceeds number of valid channels."},
13
+ "overflow_add": 7,
14
+ "min": 0,
15
+ "max": 8,
16
+ "transform": "abs",
17
+ "skip_nonpositive": false,
18
+ "message": "Invalid channel {v}, must use 1..8."
19
+ },
20
+ "se_chan": {
21
+ "span": {"message": "Channel {v} exceeds number of valid channels."},
22
+ "huge_int_min": true,
23
+ "min": 1,
24
+ "max": 16,
25
+ "transform": "abs",
26
+ "skip_nonpositive": false,
27
+ "message": "Invalid channel {v}, must use 1..16.",
28
+ "string_int_min": true
29
+ },
30
+ "port_c1c8": {
31
+ "ranges": [[101, 108]],
32
+ "transform": "none",
33
+ "skip_nonpositive": false,
34
+ "message": "Invalid port {v}, use C1..C8.",
35
+ "string_int_min": true
36
+ },
37
+ "sdi_port_cr1000x": {
38
+ "ranges": [[101, 107]],
39
+ "transform": "none",
40
+ "skip_nonpositive": false,
41
+ "odd_only": true,
42
+ "message": "Invalid SDI-12 port, must be C1, C3, C5, or C7",
43
+ "string_int_min": true,
44
+ "odd_message": "Invalid SDI-12 port, must be C1, C3, C5, or C7"
45
+ },
46
+ "port_c1c8_bare": {
47
+ "ranges": [[101, 108]],
48
+ "transform": "none",
49
+ "skip_nonpositive": false,
50
+ "message": "Invalid port."
51
+ },
52
+ "i2c_port_cr1000x": {
53
+ "ranges": [[101, 108]],
54
+ "transform": "none",
55
+ "skip_nonpositive": false,
56
+ "message": "Invalid port {v}, use C1..C8.",
57
+ "odd_only": true,
58
+ "odd_message": "I2C port must be 1,3,5,7...",
59
+ "secondary_when_invalid": true
60
+ },
61
+ "spi_open_cr1000x": {
62
+ "ranges": [[101, 108]],
63
+ "transform": "none",
64
+ "skip_nonpositive": false,
65
+ "message": "Invalid port {v}, use C1..C8.",
66
+ "allowed": [101, 105],
67
+ "allowed_message": "SPI Port must be C1, U1, U5, or U9.",
68
+ "secondary_when_invalid": true,
69
+ "string_int_min": true
70
+ },
71
+ "spi_port_cr1000x": {
72
+ "ranges": [[101, 108]],
73
+ "transform": "none",
74
+ "skip_nonpositive": false,
75
+ "message": "Invalid port {v}, use C1..C8.",
76
+ "allowed": [101, 105],
77
+ "allowed_message": "SPI Port must be C1 or C5.",
78
+ "secondary_when_invalid": true
79
+ },
80
+ "timer_port_cr1000x": {
81
+ "ranges": [[101, 108]],
82
+ "transform": "none",
83
+ "skip_nonpositive": false,
84
+ "message": "Invalid port {v}, use C1..C8.",
85
+ "allowed": [101],
86
+ "allowed_message": "TimerInput starting channel must be C1.",
87
+ "secondary_when_invalid": true
88
+ },
89
+ "waitdigtrig_port_cr1000x": {
90
+ "ranges": [[101, 108]],
91
+ "transform": "none",
92
+ "skip_nonpositive": false,
93
+ "message": "Invalid port {v}, use C1..C8.",
94
+ "allowed": [101, 102, 103, 104, 105, 106, 107, 108],
95
+ "allowed_message": "WaitDigTrig must use edge triggering in Scan..NextScan.",
96
+ "secondary_when_invalid": true
97
+ },
98
+ "quadrature_port_cr1000x": {
99
+ "ranges": [[101, 108]],
100
+ "transform": "none",
101
+ "skip_nonpositive": false,
102
+ "message": "Invalid port {v}, use C1..C8.",
103
+ "allowed": [101, 103, 105, 107],
104
+ "allowed_message": "Quadrature must use C1, C3, C5, or C7",
105
+ "secondary_when_invalid": true
106
+ },
107
+ "pulse_chan_cr1000x": {
108
+ "span": {"message": "Invalid PulseCount reps."},
109
+ "ranges": [[101, 108], [301, 302]],
110
+ "transform": "none",
111
+ "truncate": true,
112
+ "skip_nonpositive": false,
113
+ "message": "Invalid PulseCount channel, must be P1, P2, or C1..C8."
114
+ }
115
+ },
116
+ "instructions": {
117
+ "TCDIFF": [
118
+ [4, "diff_chan", 2]
119
+ ],
120
+ "TCSE": [
121
+ [4, "se_chan", 2]
122
+ ],
123
+ "CURRENTSE": [
124
+ [4, "current_chan_cr1000x"]
125
+ ],
126
+ "VOLTSE": [
127
+ [4, "se_chan", 2]
128
+ ],
129
+ "VOLTDIFF": [
130
+ [4, "diff_chan", 2]
131
+ ],
132
+ "BRHALF": [
133
+ [4, "se_chan", 2]
134
+ ],
135
+ "BRHALF3W": [
136
+ [4, "se_chan", 2, 2]
137
+ ],
138
+ "BRFULL": [
139
+ [4, "diff_chan", 2]
140
+ ],
141
+ "BRHALF4W": [
142
+ [5, "diff_chan", 2, 2]
143
+ ],
144
+ "BRFULL6W": [
145
+ [5, "diff_chan", 2, 2]
146
+ ],
147
+ "THERM107": [
148
+ [3, "se_chan", 2]
149
+ ],
150
+ "THERM108": [
151
+ [3, "se_chan", 2]
152
+ ],
153
+ "THERM109": [
154
+ [3, "se_chan", 2]
155
+ ],
156
+ "PORTSET": [
157
+ [1, "port_c1c8"]
158
+ ],
159
+ "PORTGET": [
160
+ [2, "port_c1c8_bare"]
161
+ ],
162
+ "CS616": [
163
+ [4, "port_c1c8"]
164
+ ],
165
+ "SDI12RECORDER": [
166
+ [2, "sdi_port_cr1000x"]
167
+ ],
168
+ "I2COPEN": [
169
+ [1, "i2c_port_cr1000x"]
170
+ ],
171
+ "I2CREAD": [
172
+ [1, "i2c_port_cr1000x"]
173
+ ],
174
+ "I2CWRITE": [
175
+ [1, "i2c_port_cr1000x"]
176
+ ],
177
+ "MUXSELECT": [
178
+ [1, "port_c1c8"],
179
+ [2, "port_c1c8"]
180
+ ],
181
+ "PWM": [
182
+ [2, "port_c1c8"]
183
+ ],
184
+ "PORTPAIRCONFIG": [
185
+ [1, "port_c1c8"]
186
+ ],
187
+ "PULSEPORT": [
188
+ [1, "port_c1c8"]
189
+ ],
190
+ "SPIOPEN": [
191
+ [1, "spi_open_cr1000x"]
192
+ ],
193
+ "SPIREAD": [
194
+ [1, "spi_port_cr1000x"]
195
+ ],
196
+ "SPIWRITE": [
197
+ [1, "spi_port_cr1000x"]
198
+ ],
199
+ "TIMERINPUT": [
200
+ [2, "timer_port_cr1000x"]
201
+ ],
202
+ "WAITDIGTRIG": [
203
+ [1, "waitdigtrig_port_cr1000x"]
204
+ ],
205
+ "CWB100RSSI": [
206
+ [1, "sdi_port_cr1000x"]
207
+ ],
208
+ "CWB100DIAGNOSTICS": [
209
+ [1, "sdi_port_cr1000x"]
210
+ ],
211
+ "SDI12SENSORSETUP": [
212
+ [2, "sdi_port_cr1000x"]
213
+ ],
214
+ "AM25T": [
215
+ [8, "port_c1c8"],
216
+ [9, "port_c1c8"]
217
+ ],
218
+ "QUADRATURE": [
219
+ [2, "quadrature_port_cr1000x"]
220
+ ],
221
+ "PULSECOUNT": [
222
+ [3, "pulse_chan_cr1000x", 2]
223
+ ]
224
+ }
225
+ }
@@ -0,0 +1,42 @@
1
+ {
2
+ "instructions": [
3
+ "AVGRUN",
4
+ "AVW200",
5
+ "BATTERY",
6
+ "BROADCAST",
7
+ "CALFILE",
8
+ "CALIBRATE",
9
+ "CALLTABLE",
10
+ "DELAY",
11
+ "DNP",
12
+ "DNPUPDATE",
13
+ "ERASE",
14
+ "ESSINITIALIZE",
15
+ "EXIT",
16
+ "GETVARIABLES",
17
+ "GOESGPS",
18
+ "GOESSETUP",
19
+ "MATRIX",
20
+ "MOVEBYTES",
21
+ "PANELTEMP",
22
+ "PORTSCONFIG",
23
+ "PORTSET",
24
+ "RANDOMIZE",
25
+ "READ",
26
+ "REALTIME",
27
+ "ROUTERSNEIGHBORS",
28
+ "SDI12RECORDER",
29
+ "SEMAPHOREGET",
30
+ "SEMAPHORERELEASE",
31
+ "SENDDATA",
32
+ "SENDTABLEDEF",
33
+ "SERIALIN",
34
+ "SPLITSTR",
35
+ "TCPACTIVECONNECTIONS",
36
+ "THERM107",
37
+ "THERM109",
38
+ "TOTALRUN",
39
+ "TRIGGERSEQUENCE",
40
+ "WAITTRIGGERSEQUENCE"
41
+ ]
42
+ }