Skip to content

Commit 9b05270

Browse files
authored
Merge pull request #117 from skliper/fix99-guide-format-fix
Fix #99, Guide format fix
2 parents 2cdf182 + 8fb7f4a commit 9b05270

File tree

2 files changed

+58
-218
lines changed

2 files changed

+58
-218
lines changed

Guide-GroundSystem.md

+58-49
Original file line numberDiff line numberDiff line change
@@ -50,33 +50,37 @@ The `CHeaderParser.py` program that should be found in:
5050
Is an interactive, command-line based program to help walk developers through the process of adding custom cFS applications to the Ground System. Along with `CHeaderParser.py` is a configuration file that CHeaderParser uses to find the proper header files for your "new" cFS application. This file is named `CHeaderParser-hdr-paths.txt`, and should be placed in the same directory as `CHeaderParser.py`.
5151

5252
Expected file structure:
53-
````
54-
55-
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CHeaderParser.py cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CHeaderParser-hdr-paths.txt cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CommandFiles/ cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/ParameterFiles/ cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/command-pages.txt
5653

5754
```
55+
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CHeaderParser.py
56+
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CHeaderParser-hdr-paths.txt
57+
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/CommandFiles/
58+
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/ParameterFiles/
59+
cFE-6.4.x-OSS-release/cfe/tools/cFS-GroundSystem/Subsystems/cmdGui/command-pages.txt
60+
```
61+
5862
Steps to adding application commands to the Ground System:
5963

60-
1\. Edit `CHeaderParser-hdr-paths.txt`:
61-
1\. Locate any header files that contain command code definitions or command structure definitions. These files typically end in `*app_msg.h` or `*app_msgdefs.h` but could be named anything.
62-
1\. Add each one of the paths to a new line in `CHeaderParser-hdr-paths.txt`.
63-
1\. Comment out any paths/lines that aren't needed with `#` (at the beginning of the line).
64-
65-
1\. Run CHeaderParser:
66-
1\. Call CHeaderParser using python: `python3 CHeaderParser.py`
67-
1\. The program will prompt you to enter a filename for the application. This will create a pickle file for your application named `CommandFiles/<user_defined_name>`. Notice that this file will be stored in the `CommandFiles` directory. This same filename will be used in `command-pages.txt` later.
68-
1\. Type `yes` if any commands in your application have parameters. The program will then look through the provided header files for `definitions.pick` which-ever definitions describe related command codes (one at a time, the program will prompt you for the next command code after all parameters have been added for the current command).
69-
1\. Select the appropriate command structure for the selected command. The program will show all structures that it could find in the provided header files. Enter the index of the command structure (the corresponding index should be above the command structure).
70-
1\. Select any parameters from the structure that apply. Once you have selected all applicable lines from the command structure, enter `-1` to finish. This will create a pickle file for the command/parameters named `ParameterFiles/<command_name>`. Notice that this file will be stored in the `ParameterFiles` directory.
71-
72-
1\. Update `command-pages.txt` (CSV):
73-
1\. Column 1 - Title of your application (whatever you want it called).
74-
1\. Column 2 - filename of your application (chosen in Step 2.ii) under `CommandFiles` directory.
75-
1\. Column 3 - Message ID for Application Commands (typically defined in `mission_msgids.h`).
76-
1\. Column 4 - Endianess (default little endian: `LE`).
77-
1\. Column 5 - PyGUI Page (default: `UdpCommands.py`).
78-
1\. Column 6 - Command Send Address (default: `127.0.0.1`).
79-
1\. Column 7 - Command Send Port (default: `1234`).
64+
1. Edit `CHeaderParser-hdr-paths.txt`:
65+
1. Locate any header files that contain command code definitions or command structure definitions. These files typically end in `*app_msg.h` or `*app_msgdefs.h` but could be named anything.
66+
1. Add each one of the paths to a new line in `CHeaderParser-hdr-paths.txt`.
67+
1. Comment out any paths/lines that aren't needed with `#` (at the beginning of the line).
68+
69+
1. Run CHeaderParser:
70+
1. Call CHeaderParser using python: `python3 CHeaderParser.py`
71+
1. The program will prompt you to enter a filename for the application. This will create a pickle file for your application named `CommandFiles/<user_defined_name>`. Notice that this file will be stored in the `CommandFiles` directory. This same filename will be used in `command-pages.txt` later.
72+
1. Type `yes` if any commands in your application have parameters. The program will then look through the provided header files for `definitions.pick` which-ever definitions describe related command codes (one at a time, the program will prompt you for the next command code after all parameters have been added for the current command).
73+
1. Select the appropriate command structure for the selected command. The program will show all structures that it could find in the provided header files. Enter the index of the command structure (the corresponding index should be above the command structure).
74+
1. Select any parameters from the structure that apply. Once you have selected all applicable lines from the command structure, enter `-1` to finish. This will create a pickle file for the command/parameters named `ParameterFiles/<command_name>`. Notice that this file will be stored in the `ParameterFiles` directory.
75+
76+
1. Update `command-pages.txt` (CSV):
77+
1. Column 1 - Title of your application (whatever you want it called).
78+
1. Column 2 - filename of your application (chosen in Step 2.ii) under `CommandFiles` directory.
79+
1. Column 3 - Message ID for Application Commands (typically defined in `mission_msgids.h`).
80+
1. Column 4 - Endianess (default little endian: `LE`).
81+
1. Column 5 - PyGUI Page (default: `UdpCommands.py`).
82+
1. Column 6 - Command Send Address (default: `127.0.0.1`).
83+
1. Column 7 - Command Send Port (default: `1234`).
8084

8185
Notes:
8286
- USE ONLY SPACES, NO TABS (Remember, it's Python).
@@ -90,61 +94,66 @@ After completing these steps, restart the Ground System and the changes should h
9094

9195
Traceback:
9296
```
93-
9497
Calling cmdUtil from Parameter.py Traceback (most recent call last): File "Parameter.py", line 100, in ProcessSendButton subprocess.Popen(cmd_args, stdout=subprocess.PIPE) File "/usr/lib/python3.7/subprocess.py", line 642, in __init__ errread, errwrite) File "/usr/lib/python3.7/subprocess.py", line 1234, in _execute_child raise child_exception OSError: [Errno 8] Exec format error
95-
9698
```
9799
Fix: This problem is most likely caused by calling `cmdUtil` without compiling it. This issue has also been found to occur when the `cmdUtil` executable has been compressed/decompressed. To fix this problem, use the `Makefile` inside of the `cmdUtil` directory to compile or recompile (in the case after decompressing).
98100
```
99-
100101
$ cd Subsystems/cmdUtil $ make $ cd ../.. $ python3 GroundSystem.py
101-
102102
```
103103
## Historically included instructions for running on macOS or CentOS
104104

105+
These are NOT kept up-to-date, but included for historical reference (may be easier than starting from scratch)
106+
105107
### Installing and running cFS Ground System on macOS, using Homebrew
106108
```
107-
108-
$ brew install pyqt $ brew install zeromq $ ( cd Subsystems/cmdUtil/ && make ) $ python GroundSystem.py
109-
109+
$ brew install pyqt
110+
$ brew install zeromq
111+
$ ( cd Subsystems/cmdUtil/ && make )
112+
$ python GroundSystem.py
110113
```
111114
### Installing and running cFS Ground System on CentOS 6
112115

113116
#### Update yum
114117
```
115-
116-
$ su $
117-
118-
<type password="">
118+
$ su
119+
$ <type password="">
119120
$ yum -y update</type>
120-
121121
```
122122
#### Install pip and python-development ####
123123
If you are on a 64-bit CentOS / RHEL based system:
124124
```
125-
126-
$ wget <http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm> $ rpm -ivh epel-release-6-8.noarch.rpm
127-
125+
$ wget <http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm>
126+
$ rpm -ivh epel-release-6-8.noarch.rpm
128127
```
129128
If you are on a 32-bit CentOS / RHEL based system:
130129
```
131-
132-
$ wget <http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm> $ rpm -ivh epel-release-6-8.noarch.rpm $ yum install -y python-pip $ yum install -y python-devel
133-
130+
$ wget <http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm>
131+
$ rpm -ivh epel-release-6-8.noarch.rpm
132+
$ yum install -y python-pip
133+
$ yum install -y python-devel
134134
```
135135
#### Install zeroMQ and pyZMQ messaging system ####
136136
```
137-
138-
$ yum install -y uuid-devel $ yum install -y pkgconfig $ yum install -y libtool $ yum install -y gcc-c++ $ wget <http://download.zeromq.org/zeromq-4.0.5.tar.gz> $ tar xzvf zeromq-4.0.5.tar.gz $ cd zeromq-4.0.5 $ ./configure $ make $ make install $ echo /usr/local/lib > /etc/ld.so.conf.d/local.conf $ ldconfig $ pip install pyzmq
139-
137+
$ yum install -y uuid-devel
138+
$ yum install -y pkgconfig
139+
$ yum install -y libtool
140+
$ yum install -y gcc-c++
141+
$ wget <http://download.zeromq.org/zeromq-4.0.5.tar.gz>
142+
$ tar xzvf zeromq-4.0.5.tar.gz
143+
$ cd zeromq-4.0.5
144+
$ ./configure
145+
$ make
146+
$ make install
147+
$ echo /usr/local/lib > /etc/ld.so.conf.d/local.conf
148+
$ ldconfig
149+
$ pip install pyzmq
140150
```
141151
#### Install pyQT4 ####
142152
```
143-
144-
$ yum install -y PyQt4 $ yum install -y qt qt-demos qt-designer qt4 qt4-designer
145-
153+
$ yum install -y PyQt4
154+
$ yum install -y qt qt-demos qt-designer qt4 qt4-designer
146155
```
147156
#### Running Ground System ###
148157
```
149-
150-
$ python GroundSystem.py ```
158+
$ python GroundSystem.py
159+
```

Guide-GroundSystem.txt

-169
This file was deleted.

0 commit comments

Comments
 (0)