NASA-AMMOS / aerie-ui

The client application for Aerie.
https://nasa-ammos.github.io/aerie-docs/
MIT License
28 stars 5 forks source link

Finalize V1 DSL Grammar #1280

Closed joswig closed 4 months ago

joswig commented 5 months ago

Extension of seqN.txt grammar

Sample Sequence, with no qualifier commands are mapped to steps in seq.json


@METADATA "onboard_path" "/foo"
@METADATA "onboard_name" "a_sequence"
@METADATA "extra" "{\"key_a\": 1}"

@INPUT_PARAMS L0STR L0INT L1INT
R3:00:00 STEM_WITH_NO_ARGS
# Stand alone comment
C STEM_2 "Hi" 2 # Inline Comment
C STEM_3 "Hi" [ 2 6] "bye" [5 6 7]  # repeat args
@MODEL "foo" 'bar' `baz`
@MODEL "foo1" "bar1" "baz1"
@METADATA "valNum" 6
@METADATA "valStr" "string val"
@METADATA "valObj" "{\"nestedVal\": false}"

Sample Requests

@REQUEST C1 "request_name_1" # comment which maps to description
R1:00:00 NO_OP

Sample Load and Go Sequence, with no qualifier commands are mapped to steps in seq.json

@LOAD_AND_GO

R3:00:00 STEM_WITH_NO_ARGS
# Stand alone comment
C STEM_2 "Hi" 2 # Inline Comment
...

Sample Immediate Command File, the same structure as a hardware commands file. Both mirror sequences, but time tags are omitted.

@IMMEDIATE_COMMANDS
# Standalone comment
STEM_WITH_NO_ARGS
STEM_2 "Hi" 2 # Inline Comment

Sample Hardware Command File, a similar structure as an immediate commands file, but arguments are not allowed.

@HARDWARE_COMMANDS
HARDWARE_CMD_1 # inline comment
# standalone comment
HDW_CMD_4
@METADATA "valStr" "string val"

Should the syntax support mixing of sequence command, immediates, and hardwares, the syntax will look like this.

# Anything not preceded by an immediate commands or hardware commands directive is considered a sequence
R3:00:00 STEM_WITH_NO_ARGS
# Stand alone comment
C STEM_2 "Hi" 2 # Inline Comment

...

@IMMEDIATE_COMMANDS
STEM_2 "Hi" 2 # Inline Comment

...

@HARDWARE_COMMANDS
HARDWARE_CMD_1 # inline comment