| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- //,,,,,,
- // Example Test Script for ModScan Application,,,,,,
- // ,,,,,,
- // Each Script entry consists of the following,,,,,,
- // comma delimited data fields:,,,,,,
- //,,,,,,
- // TEST NAME, NODE, FUNCTION, ADDRESS, LENGTH, DATA, CONTROL CODE
- //,,,,,,
- // Double slashes on the front of a line denote comments,,,,,,
- //,,,,,,
- // The following Control Codes may be used (i.e. last field on each line),,,,,,
- "// \ -- Continue DATA fields on next line",,,,,,
- "// C -- Generate Bad CRC message to slave",,,,,,
- "// D -- Check response data quantity only", (ignore actual data),,,,,
- "// 1 -- Expect Exception Response 01",,,,,,
- "// 2 -- Expect Exception Response 02",,,,,,
- "// 4 -- Expect Exception Response 04",,,,,,
- "// R -- Expect no Response",,,,,,
- "// T (default) -- Verify Response Data",,,,,,
- //,,,,,,
- //,,,,,,
- // First Test:,,,,,,
- "// Write 20 Coils to Node 1 starting at address 100",,,,,,
- "// Data is alternating pattern of ones & zeros",,,,,,
- // (DATA field consists of 32-bits and may be specified,,,,,,
- "// as a decimal", hex or floating-point value),,,,,
- //,,,,,,
- Preset Multiple Coils,1,15,100,20,0xAAAAA,T
- //,,,,,,
- //,,,,,,
- // Second Test:,,,,,,
- "// Verify results of first test by reading the pattern back",,,,,,
- //,,,,,,
- Verify Coil Status,1,1,100,20,0xAAAAA,T
- //,,,,,,
- // Third Test:,,,,,,
- "// Read 100 Input Status values",,,,,,
- "// ignore the data and only verify proper quantity returned",,,,,,
- //,,,,,,
- Verify Input Status,1,2,100,100,0,D
- //,,,,,,
- //,,,,,,
- // Forth Test:,,,,,,
- "// Check Slave Response to request for 1000 registers",,,,,,
- "// (Should probably generate an exception response)",,,,,,
- //,,,,,,
- Test Exception 2,1,3,100,1000,0,2
- //,,,,,,
- // Fifth Test:,,,,,,
- "// Check Slave Response to bad CRC",,,,,,
- //,,,,,,
- Invalid Request,1,1,100,1,0,C
- //,,,,,,
- // Sixth Test:,,,,,,
- "// Query an unknown device & expect no response",,,,,,
- //,,,,,,
- Query Device 73,73,1,1,1,0,R
- //,,,,,,
- // Seventh Test:,,,,,,
- "// Write 6 Holding Registers with data",,,,,,
- // (Each floating point number represents,,,,,,
- "// two registers -- The NAME field on the",,,,,,
- "// continuation line is ignored)",,,,,,
- //,,,,,,
- Write Floats,1,16,100,6,1,\
- ,2,3,,,,T
- //,,,,,,
- // Eighth Test:,,,,,,
- "// Verify Test Seven by reading back the Registers",,,,,,
- //,,,,,,
- Read Floats,1,3,100,6,1,\
- ,2,3,,,,T
- //,,,,,,
- // END OF SCRIPT,,,,,,
- end,,,,,,
|