Skip to content

Commit 89bfec7

Browse files
committed
Merge branch 'v1.1.6' of https://github.com/HotNoob/PythonProtocolGateway into v1.1.6
2 parents a8ed0b6 + 2fbb733 commit 89bfec7

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

documentation/usage/creating_and_editing_protocols.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,32 @@ R = Read Only
6969
RD = Read Disabled
7070
W = Write
7171
```
72+
#### values / codes
73+
there are two main purposes for this column.
74+
1. defines possible values / ranges of values for protocol validation / safety
75+
for example:
76+
```0~100```
77+
78+
2. defines the values for flag data types, such as 16BIT_FLAGS; any data type can be used.
79+
the format for these flags is json. these flags / codes can also be defined via the .json file by naming them as such:
80+
"{{document_name}}_codes"
81+
82+
##### Bit Flag Example
83+
```
84+
{"b0" : "StandBy", "b1" : "On"}
85+
```
86+
87+
##### MultiBit Flag Example
88+
Some protocols utilize combinations of bits as flags.
89+
```
90+
{"b0" : "StandBy", "b0&b1" : "Operational", "b1" : "Error" }
91+
```
92+
93+
94+
##### uint / bits / other
95+
```
96+
{"75" : "Error", "50": "Warning"}
97+
````
7298
7399
74100

0 commit comments

Comments
 (0)