Universal Serial Device Manufacturing Test

From DP

Jump to: navigation , search



This is a simple utility intended for the manufacturers to test devices before releasing to the public to ensure that each device is free of defects.

How to Use

Before this little test utility can be use, you need to create a small script which consist of keywords/commands in this format:

KEYWORD text text text etc..

Once you have created or edited the config file (.ini) you can then execute the utility with the following syntax:

USDMT.exe -f config.ini

where: -f config.ini loads the configuration file.

The template.ini in the svn can be edited to suite every devices that can use the virtual com port.

Keywords and parts of the config file

The .ini file is grouped into two parts,


#keywords here




#keywords here


The first part which is enclosed in tags <Initialize> .. </Initialize> is where all the initialization takes place. This is where a device is initialized, by sending some bytes to the specified PORT COMn, using the command SEND_STRING hex1 hex2 hex3. Under this tag are some more commands to check for reply and display some message. The second part which is also enclosed within the tags <TestRoutine> and </TestRoutine> has the same as the first part, except that is is where all the test is performed.

You can have multiple <TestRoutine> and </TestRoutine> tags if there are more hex to be send, each group can have its own reply or display message.

First token is the keyword then a space separator followed by some text literals that is interpreted by the utility.

A template with all the keywords is also include in the SVN, which you can edit.

a '#' in the beginning of a line means its a comment and simply ignored


# Logic Shrimp Config file

Blank lines are also ignore

Keywords are case-sensitive.

KEYWORDS are all caps


#Logic Shrimp Config file

#Blank lines are ignored, '#' at first char in a line means remark, like this:

#Case Sensitive


Below is are the current keywords/commands used in the .ini file:

BOARD_NAME project name - Name of the board to test

PORT comn - name of port -this is mandatory ex. COM4

SPEED speed - 115200 bps is default, but can be increase or decrease

TEST_REPEAT n - defaults to 1, this makes the utility repeat the test n times

REPLY NO|YES - Setting this to NO means we are not expecting a reply when we do a SEND_STRING

SEND_STRING hex - Send a hex to the port

OK_REPLY 00 - If we are expecting a reply this should match the answer so that the app can display something

FAIL_MESS message - If it did not match the reply value in OK_REPLY then this message is displayed

SUCCESS_MESS message - If it match the reply value in OK_REPLY then this message is displayed

GEN_MESS message - this is a message to be display whether with or without reply -

GEN_MESS_EXTRA message -extra Message to be seen





FAIL_MESS Selt-Test Result:**FAIL** :(

SUCCESS_MESS Self-Test Result: **PASS** :)


GEN_MESS Message to be seen whether it fail or not at test

GEN_MESS_EXTRA extra Message to be seen here

Sample Output

These output where run from

USDMT -f irtoy.ini


USDMT -f logicshrimp.ini


Using the irtoy.ini configuration file


Using logicshrimp.ini configuration file


Download the script here