Protocol Developer

Aus Deutschmann Wiki
(Weitergeleitet von Protocol Developer/en)
Zur Navigation springen Zur Suche springen

Protocol Developer is a development environment for creating and editing device scripts for Deutschmann UNIGATE® devices.

Debug-Function

With Protocol Developer there is the possibilty to debug the programmed resp. created script. Therefore UNIGATE® has to be started in Data Exchange Mode and has to be connected via Debug-Interface or Application Interface (RS232) with the PC resp. Protocol Developer. Further detailed information is to be found under the link UNIGATE® interfaces.

Add language definition (XML-Datei)

The language range of the Deutschmann Script language is continually expanded. The Script-Revision [...] (number in square brackets after the version specification) indicates which level is supported by the device firmware and the Protocol Developer. The language definition is organized into XML files. New language definitions can be installed in the Protocol Developer as follows.

Up to V2.28

  1. Put the XML-file (z. B. ScriptRev*.xml) in the program folder.
  2. Via menue item "Options" --> "Settings" the window "Settings" opens.
  3. Here the menue item "ConfigFiles" has to be selected.
  4. In the following window, the desired configuration file can be selected or loaded via the "add" button and confirmed with the "OK" button.
  5. The following window (Restart required) has to be confirmed via the button "OK" and the Protocol Developer should be restarted.

From V3.0.0

Settings -> Config files

As of this version, the files are no longer loaded individually. They are searched for in the specified folder.

  1. Put the XML-file (z. B. ScriptRev*.xml) in a folder of your choice.
  2. Via menue item "Options" --> "Settings" the window "Settings" opens.
  3. Here the menue item "ConfigFiles" has to be selected.
  4. In the following window, the folder in which your configuration file resides can be selected via the "add" button and confirmed with the "OK" button.
  5. The following window (Restart required) has to be confirmed via the button "OK" and the Protocol Developer should be restarted.

Known Issues

If you encounter problems with the Protocol Developer. Please first check whether a more up-to-date version is already available for download.

V3.0.0

  • The Calculate command, when used in combination with the operator shl, does not get compiled correctly. Other operators are not affected. If necessary, the problem can be solved at short notice by importing (for procedure see above) an updated 'values.xml' file.
  • In case automatic type handling (Settings -> Compiler options) is activated the script won`t compile, if the statement if .. then .. else .. is spread over three lines. Example:
if b_b_0 greater b_const0   
 then :Bit_toa     
 else :Bit_tob
  • If more than about 40 bytes are assigned to a buffer variable with the MoveConst command (depending on the number of characters in the variable name), this leads to an error.
var aModbusBuf     : buffer[1024];
moveconst(aodbusBuf45304[0],#0x02#0x78#0x00#0x01#0xc5#0x16#0xe2#0x18#0x8b#0x1f#0x00#0x08#0x76#0xff#0x55#0x01#0x03#0x00#0xd4#0xed#0x4f#0x5b#0x30#0xdb#0x06#0x18#0x5e#0xe0#0x2b#0xf3#0xae#0x50#0xc9#0xdb#0x7c#0x76#0x5d#0xec#0xe6#0x92#0x26#0xd0#0xce#0x69#0x64#0x84#0x45#0xda#0xa1#0x05#0xd1#0xa0#0x6a#0x75#0x26#0xca#0xf8#0x84#0x0b#0xef#0x68#0x34#0x1a#0x43#0x2c#0x42#0xda#0x62#0xef#0xa4#0x89#0xb9#0x2f#0xe5#0x63#0xaf#0x76#0xcb#0x57#0x2e);

The problem can be avoided by filling the buffer with several consecutive moveConst commands. Example:

 var aModbusBuf45304     : buffer[1024];// RandomRegister
 moveconst( aModbusBuf[0], #0x02#0x78#0x00#0x01#0xc5#0x16#0xe2#0x18#0x8b#0x1f#0x00#0x08#0x76#0xff#0x55#0x01#0x02#0x78#0x00#0x01#0xc5#0x16#0xe2#0x18#0x8b#0x1f#0x00#0x08#0x76#0xff);
 moveconst( aModbusBuf[30], #0x04#0x70#0x01#0x01#0xc5#0x16#0xe2#0x18#0x8b#0x1f#0x00#0x08#0x76#0xff#0x55#0x01#0x02#0x78#0x00#0x01#0xc5#0x16#0xa2#0x18#0x8b#0x11#0x10#0x18#0x71#0x00);
 moveconst( aModbusBuf[60], #0x04#0x70#0x01#0x01#0xc5#0x16#0xe2#0x18#0x8b#0x1f#0x00#0x08#0x76#0xff#0x55#0x01#0x02#0x78#0x00#0x01#0xc5#0x16#0xa2#0x18#0x8b#0x11#0x10#0x18#0x71#0x00);

where 45 is the maximum number of bytes that can be assigned in one line of code without errors.

Adapt existing script to another Fieldbus or Industrial Ethernet system

Possible procedure:

  1. The existing script must be compared with the corresponding script template (template) of the Protocol Developer regarding the bus-specific parameters. These are marked in the script templates (Template) with „!!!“.
    • Via menu item „File“ -> „New“ -> „Source“ -> „Template“ can be called the corresponding script template.
  2. If the bus-specific parameters are identical, the script must not be adapted. However this applies only if at the initalization of the bus (:InitFieldbus;) further bus-specific, optional parameters have not been inserted. If this is the case, these optional parameters have to be compared with the appropriate script template (Example) from the Protocol Developer.
    • Via menu item „File“ -> „New“ -> „Source“ -> „Example“ -> „Include“ the appropriate script template can be called.

Weblinks