If your strategy transmits and receives serial data, you’ll want to try using OptoScript code. In standard PAC Control, forming and parsing (decoding) serial data can take several blocks. In OptoScript, string handling is much easier.
Here’s an example of a flowchart that sends the string request, “What type of plane?” and then parses the response.
Compare these blocks and instructions with the ones in OptoScript.
The OptoScript version of the String_Handler flowchart is more compact. The string request can be built more easily, and parsing the response takes up much less space.
References for Using Strings
Refer to the PAC Control User's Guide, Appendix E: OptoScript Language Reference, for more information about string syntax.
Learn more about using strings in the PAC Control in the PAC Control User's Guide, Chapter 10: Programming with Commands, Using Strings.