piTest is a tool with which you can access the process image of your system. The code for this tool can be found on your RevPi in the “/home/pi/demo” folder and in the Downloads area.
You can use piTest in the command line. Open it with the command “piTest”.
Commands
In the following table you will find a list of all commands that you can use with piTest.
Command | Use |
---|---|
-1* | Single output, not continuous. |
-d | Outputs a list of the used devices. This can be useful e.g. if a device was not configured in PiCtory. |
-f* | Update firmware |
-g<o>,<b> | Reading bit b from offset 0. |
-l* | Wait for reset of the driver. |
-q* | Only the value is output without text. |
-r <var_Name> [<f>]* | Read l bytes from offset o. f* is the optional parameter for the output format (h = hexadecimal, d = decimal (standard), b = binary). |
-R <addr>,<bs>* | Reset the counters or encoders of a DIO or DI module. <addr> is the address of the module as in the output with –d <bs> is a bit field for selecting the affected inputs. If the counter at the Pin N input is to be reset, the bit number N must be set to 1. For example: -R 32.0×0014 Reset the counters for the inputs I_3 and I_5 of the module to address 32. |
-s <o>,<b>,<0|1> | Set bit b (0-7) from byte offset b with the value 0 or 1. |
-v <var_Name> | Outputs information about a variable, e.g.: offset and length. |
-w <var_Name>,<v> | Write the value in the variable. |
-w <o>,<l>,<v> | Write l bytes from offset o in hexadecimal format with the value v. Length can be 1, 2 or 4. |
-x | Driver reset, corresponds to restart of the piControl process. |