Oxford tester board commands
Always acknowledge commands
Command format
- Line by line
- Sequence number
- Command
- Data
0000|Command|Response\n
Match sequence number on response. Multiple responses to the same command from Java should have the same sequence number.
Acknowledge commands. If return data, include after |. Define format on a command-by-command basis
- 0000|ACK_OK|DATAFIELD - Message was received OK. Data field is optional. Note that almost all tests return at least one additional message with the same sequence number, described below.
- 0000|ACK_ERROR|DATAFIELD - A message was received, but there was a problem with it. Usually an error code will be included. Error codes are described in the table below:
Error code |
Description |
0 |
Missing/invalid sequence number |
1 |
Missing | separator |
2 |
Invalid command (command not recognised) |
3 |
Invalid message terminator (missing \n at end of message) |
4 |
Error message received |
5 |
No data in received message |
If the client receives an out-of-sequence command it should not execute the command but should instead reset its internal sequence number to match the received command and respond with
ACK_ERROR
and an error code.
The Java GUI may send a
NOP
(do nothing) command. The client should reset its internal sequence number to match the received command and respond with
ACK_OK
.
Commands and responses issued and returned to Java program
A summary of the commands sent by muDaq can be viewed
here
.
Note that the required format of a sequence number and | preceding the message and the the required \n message terminator are assumed in these descriptions