Cypress WirelessUSB MTK User manual

WirelessUSB™
Manufacturing Test Kit
User’s Guide
Cypress Semiconductor
3901 North First Street
San Jose, CA 95134
408-943-2600
Cypress Semiconductor Corporation Page 1/20
April 28, 2005

Cypress Semiconductor Corporation Page 2/20
1. INTRODUCTION
The WirelessUSBTM Manufacturing Test Kit (MTK) is designed to
allow Cypress’ customers to test their WirelessUSB products, in a
manufacturing environment, without the use of expensive RF test
equipment.
The highly integrated nature of the WirelessUSB radio device is
such that there is very little that can go wrong in the assembly
process. The device itself is tested before it leaves the Cypress
factory. There are only a few critical components on the customer’s
board that affect the operation of the radio. Most of the likely
assembly level failures (missing components, open/cold solder
joints, and pin-to-pin shorts) will cause a large reduction in
transmitted power or receive sensitivity, if the unit functions at all.
As such, a simple functionality test at maximum range would
eliminate most bad units.
To keep from having to test each unit over a long distance, and to
prevent interference between multiple units that may be on the test
floor simultaneously, the MTK is designed to simulate a limit-of-
operation condition using shielded Test Fixture and enclosure.

2. KIT DESCRIPTION
The MTK contains the following items.
• MTK Test Fixture
• 12” SMA to SMA coaxial cable
• 24” SMA to SMA coaxial cable
• SMA-F to SMA-F adapter
• (6) Fixed 50 ohm attenuators: 1dB, 2dB, 4dB, 7dB, 15dB,
and 30dB
• SMA 2.4GHz antenna
• Power supply transformer
• CD-ROM with Firmware Source and documentation
Cypress Semiconductor Corporation Page 3/20
See Photo #1 – Manufacturing Test Kit Contents, below.
Not included but required for use are: the Device Under Test (DUT)
and an anechoic RF test chamber, sized appropriately for the DUT,
with SMA pass-through connectors.
Optional, not included, equipment includes: a variable 50-ohm
attenuator for calibration, an SMA torque wrench, a computer to
download configuration and/or test start commands and, optionally,
log test results, as well as an RS-232 serial cable or USB-to-serial
adapter cable for connecting the computer to the 9-pin D connector
of the MTK Test Fixture.

<Photo #1 – Manufacturing Test Kit Contents>
Cypress Semiconductor Corporation Page 4/20

3. HARDWARE SETUP
1) Attach the supplied antenna to the SMA pass-through connector of the test
chamber.
o Use the SMA pass-through that is furthest away from the sides of the
chamber if there is more than one.
o Orient the antenna at either 0 degrees or 90 degrees. (It is very important
that the relative position and orientation of the fixed antenna and the DUT be
kept the same for all tests. These can greatly affect the signal strength.)
o See Photo #2 – Fixed Antenna Mounting Example.
2) Attach one coaxial cable to the matching SMA on the outside of the chamber.
o Be sure to connect to the same pass-through that has the antenna installed.
3) Attach the other cable to the SMA on the MTK Test Fixture.
o Please use an appropriate SMA torque wrench on all SMA connections or
tighten finger tight, to avoid damaging the connectors. It is important that the
connections are tight enough that good contact is made. Loose connections
can greatly impact the repeatability of the test.
4) Place fixed or variable attenuators between the two cables.
o See the Appendix C, below for determination of the correct attenuation.
o If using the supplied fixed attenuators, use the female-to-female adapter to
connect the male end of the attenuators to the cable.
5) (Optional) Attach a serial cable (not included) between the MTK test fixture
and computer.
o If a computer will be used for set up or testing, attach it to the serial port with
a serial cable or a USB-to-serial adapter cable (not included).
o See Appendix B for the default setting of the serial port on the test fixture.
6) Insert power plug into the MTK test fixture.
Cypress Semiconductor Corporation Page 5/20
o The MTK Test Fixture will go through a power-on self-check, which will light
all of the LED indicators. Once the green PASS light is lit, the tester is ready
for use or to receive serial commands.

Fixed attenuator to extend
antenna beyond foam. Or use
SMA-M to SMA-F extender.
<Photo #2 – Fixed Antenna Mounting Example>
Cypress Semiconductor Corporation Page 6/20

<Photo #3 – Completed Installation>
Cypress Semiconductor Corporation Page 7/20

Cypress Semiconductor Corporation Page 8/20
4. EXECUTING THE STANDARD TEST
The Standard Test is defined by sending a number of packets over
one or more channels. The bit errors are counted and compared
against an error threshold number and the pass/fail result is
displayed. See Appendix B for instructions on changing the
Standard Test configuration.
Once the test environment is set up, put the device to be tested into
manufacturing test mode and place it in the shielded container.
The device under test (DUT) should respond to the Standard Test
executed by the Tester.
Note that the foam in some shielded test boxes is conductive. The
bare DUT board (if testing a bare PCB) should be placed in a
fixture, not directly on the foam of the box. This will also help
ensure that the DUT to antenna alignment is the same from test to
test, which can make a very large difference in signal strength at
the DUT. See photo #4 below:
<Photo #4 – DUT Fixture>
Press the START button on the Tester. The BUSY light should
come on for a short time. If the test is successful, then the PASS
light will come on when the test is completed. If the test exceeded
the error threshold settings, the Tester will indicate test failure by
lighting the FAIL light.

Cypress Semiconductor Corporation Page 9/20

APPENDIX A – FIRMWARE
1. FIRMWARE OVERVIEW
The MTK test firmware is divided into two parts, the Test Fixture
Firmware and the DUT Test Code. The DUT Test Code is a small
bit of additional code that resides in the DUT memory and can be
accessed only by placing the DUT into a special test mode. (See
below for more details.) Once in test mode, the DUT in the test
chamber exchanges packets with the Test Fixture. The data
packet from the Test Fixture to the DUT is checked for errors by the
DUT and the error count recorded. The DUT then sends a data
packet back to the Test Fixture that includes the error count
information. The Test Fixture uses this information, as well as
information it collects about errors in the received data packet from
the DUT, to determine if the test passes or fails.
Cypress Semiconductor Corporation Page 10/20
2. DUT TEST CODE
All packets received by the Device-Under-Test (DUT) are “echoed”
with the addition of an added byte that contains the count of invalid
bits for the received packet. Extra bytes in packets that are larger
than what the DUT can support are ignored. Received packets of
the correct length are then parsed for possible RF command
packets.
The RF command packets exchanged between the MTK Tester
and the MTK DUT contain two or more bytes. The first byte
contains the command type and the remaining bytes contain the
parameter value. All commands are executed after the received
packets are “echoed”.
The DUT Manufacturing Test code adds approximately 500-800
bytes depending on the device and firmware version.
The method to enter the Manufacturing Test Mode varies
depending on the device and firmware version. The CY4632 RDK
Bridge will enter the Manufacturing Test Mode when an SE1
condition (both D+ and D- are held high) is detected during power-
on on all firmware versions from 1.2 and higher. The CY4632 RDK
Mouse and Keyboard uses a compile time define to enter the test
mode by detecting a specific grounded pin or a special key

sequence during power-up. See below for details on specific
versions.
CY4632 RDK Keyboard Version 1.2, 1.21, 1.3
• MFG_ENTER_BY_KEY_NOT_PIN defined, enters
Manufacturing Test Mode when the bind button and the suspend
key are held during power-up.
• MFG_ENTER_BY_KEY_NOT_PIN not defined, enters
Manufacturing Test Mode when the PORT 0 Pin 6 is grounded
during power-up.
CY4632 RDK Keyboard Version 1.31 and higher
• MFG_ENTER_BY_PIN defined, enters Manufacturing Test Mode
when the PORT 0 Pin 6 is grounded during power-up.
• MFG_ENTER_BY_PIN not defined, enters Manufacturing Test
Mode when the bind button and the suspend key are held during
power-up.
CY4632 RDK Mouse Version 1.2, 1.21
• MFG_ENTER_BY_KEY_NOT_PIN defined, enters
Manufacturing Test Mode when the test mode 1 is selected.
Holding both the right and left buttons during power-up enters the
test selection mode. The LED turns off to indicated that the mouse
in the test selection mode. Releasing both buttons and pressing the
left button once to select the first test and then pressing the right
button to start the first test.
• MFG_ENTER_BY_KEY_NOT_PIN not defined, enters
Manufacturing Test Mode when the PORT 0 Pin 5 is grounded
during power-up.
CY4632 RDK Mouse Version 1.3, 1.31 and higher
• MFG_ENTER_BY_PIN defined, enters Manufacturing Test Mode
when the PORT 0 Pin 5 is grounded during power-up.
Cypress Semiconductor Corporation Page 11/20
• MFG_ENTER_BY_PIN not defined, enters Manufacturing Test
Mode when the test mode 1 is selected. Holding both the right and
left buttons during power-up enters the test selection mode. The
LED turns off to indicated that the mouse in the test selection
mode. Releasing both buttons and pressing the left button once to
select the first test and then pressing the right button to start the
first test.

3. TEST FIXTURE FIRMWARE
The Test Fixture Firmware controls the standard test that is
executed when the START button is pressed. It also provides for
communication over the serial port. See Appendix B for details
about the serial communication protocol. The source code for the
PSoC in the MTK Test Fixture is included in the kit CD-ROM. The
user may customize the test firmware as desired. The PSoC can
be reprogrammed using the ISSP header on the board. See Photo
#5 for the location of the header.
ISSP
Header
Pin 1 = VCC
<Photo #5 – Location of the ISSP Header>
Cypress Semiconductor Corporation Page 12/20

APPENDIX B – USING THE SERIAL INTERFACE
The default serial port settings for the Tester are 9600, N, 8, 1,
NONE, with local echo turned on in the terminal emulator of choice.
When power is applied to the Tester, the following welcome banner
should be seen in the terminal window.
******************************************************************************
WirelessUSB Tester - v1.0
For help, type: he
******************************************************************************
MTK>
If this banner is not displayed, then re-check the serial port
connection and settings.
All serial port commands are case insensitive. While the help menu
displays commands in uppercase, they may be entered in lower
case. The PD command requires parameters to be entered in
hexadecimal format without any prefix or postfix characters (see the
help menu for an example.) The letters in the hexadecimal
numbers may be lowercase as well.
A listing of all the supported commands with parameter limits is
displayed by typing the command HE as shown in the welcome
banner. Following is an output example of the help menu.
MTK> he
TESTER HELP MENU
******************************************************************************
All commands and parameters are case insensitive.
The following commands are executed immediately:
Show This Help Menu ........................... HE
Show Current Tester Settings .................. CS
Execute Standard Test ......................... ST
Set Channel, PN Code, Power, Correlator ....... SC <0-77> <0-7> <0-7> <0-16>
Transmit Carrier for N seconds, 0 = infinite .. TC <0-255>
Transmit Random for N seconds, 0 = infinite ... TR <0-255>
Send Data to DUT, e.g. PD 5A 00 0A FF 34 ...... PD <B1 B2 ... B15>
Tester Crystal Adjust (stored in EEPROM) ...... CA <0-63>
Crystal Clock Output ON=1/OFF=0 ............... XO <0-1>
Cypress Semiconductor Corporation Page 13/20
Restore Default Settings to EEPROM ............ RE

The following commands save values to EEPROM for Standard Test Configuration:
Configure Correlator Threshold ................ CO <0-16>
Configure Power Level ......................... CL <0-7>
Configure PN Code ............................. PN <0-7>
Configure First Channel, 255 to disable ....... C1 <0-77, 255>
Configure Second Channel, 255 to disable ...... C2 <0-77, 255>
Configure Third Channel, 255 to disable ....... C3 <0-77, 255>
Configure Tx Error Threshold .................. TT <0-65535>
Configure Rx Error Threshold .................. RT <0-65535>
Configure Packet Payload Length ............... CB <0-15>
Configure Number of Packets Sent on Channel ... CP <0-255>
All commands return one of the following:
OK ................. Command Success
CE ................. Command Error
Commands PD and ST also return:
TE <number> ........ DUT Receive Error Rate
RE <number> ........ Tester Receive Error Rate
******************************************************************************
OK
MTK>
All commands return either OK (successful command completion)
or CE (command error.) A successful command completion in the
case where DUT interaction is involved does not necessarily mean
that the DUT successfully completed the request.
The PD command and the Standard Test command ST both report
additional information of bit error rates. The TE result is the
number of bit errors counted by the DUT and is computed on the
Tester by using the contents of the returned packet from the DUT.
If a response to a data packet is not received by the Tester, then
100% bit error rate is assumed on the sent packet. The RE result
is computed using the received packet from the DUT.
Cypress Semiconductor Corporation Page 14/20
A portion of the commands are used to configure the Standard Test
that is executed by pressing the START button on the Tester.
These values are saved in non-volatile storage and remembered
across power cycles. The saved values only take affect when the
Standard Test is executed.

The current configuration of the Tester can be reported by typing
the command CS at the command prompt. Following is an
example of the output from this command.
MTK> cs
TESTER CONFIGURATION
******************************************************************************
Radio Configuration:
Channel .................. 2
PN Code .................. 1
Power Level .............. 7
Correlator threshold ..... 2
Crystal adjust ........... 3
Crystal clock output ..... OFF
Standard Test Configuration:
Channel 1 ................ 1
Channel 2 ................ 255
Channel 3 ................ 255
PN Code .................. 1
Power Level .............. 7
Correlator threshold ..... 2
Tx error threshold ....... 1000
Rx error threshold ....... 1000
Packet payload length .... 5
Packets per channel ...... 128
******************************************************************************
WUSB LS Radio Registers
Output format in hex: addr:val
00:07 01:04 02:4a 03:00 04:06 05:01 06:0b 07:03
08:00 09:00 0a:00 0b:00 0c:00 0d:01 0e:00 0f:00
10:ff 11:dc 12:c0 13:6b 14:b8 15:2b 16:09 17:bb
18:b2 19:02 1a:1e 1b:10 1c:00 1d:01 1e:00 1f:00
20:64 21:04 22:00 23:07 24:42 25:00 26:0f 27:00
28:00 29:00 2a:00 2b:10 2c:fa 2d:f0 2e:80 2f:00
30:00 31:00 32:41 33:41 34:f7 35:00 36:00 37:63
38:64 39:00 3a:00 3b:00 3c:d3 3d:8a 3e:d5 3f:3e
******************************************************************************
OK
MTK>
Cypress Semiconductor Corporation Page 15/20
The Standard Test can be executed from the PC by typing the ST
command at the command prompt in the terminal window. The first

channel set to 255 and all following channels will not be tested.
The results will be displayed in the terminal similar to the following.
MTK> st
TE 864
RE 1008
OK
MTK>
The above error results are typical of a non-responding DUT.
Also note that when pressing the START button on the tester that
the test results are displayed in the terminal window without the
command response and command prompt as follows.
TE 864
RE 1008
Cypress Semiconductor Corporation Page 16/20
The commands not related to the Standard Test configuration are
executed immediately from the command prompt. These are used
for interactive testing/debug or with a script for extended automated
testing.

APPENDIX C - CALIBRATION
The test station is calibrated by using one or more known good
reference devices to determine the maximum attenuation that the
system can have installed before the radio loses good contact.
This needs to be done periodically to compensate for
environmental effects, and at least once any time the DUT design is
changed or the test station is switched to testing a different device
model.
Since antenna distance and orientation, both to each other and to
the walls of the test chamber, play such an important role in signal
attenuation, it is vital that the calibration and test procedure be run
with the antenna and DUT installed in the same location and
orientation every time. It is recommended that a test fixture, or
some other means, be used to ensure proper placement of the
DUT each time. If alignment guides are added to the chamber,
they should be kept to as low a profile as possible and they should
be constructed out of a non-reflecting material. One option would
be to cut a shallow impression in the foam at the bottom of the
chamber that will hold the DUT in the proper alignment.
Note that the foam in some test chambers is conductive. If testing
bare boards, be sure to use a fixture or some other means to
insulate the board from the foam. A test fixture that will hold the
board in exactly the same place every time is strongly
recommended.
Any wires or battery packs that are placed in the chamber to power
the DUT also need to be in the same location every time, as these
can reflect the RF energy and change the overall attenuation of the
signal. Ideally, batteries should be used and placed in their final
location, as they will be in the finished product. The battery position
can greatly affect the result of the test. If the battery is not in the
finished product’s position, the test will work just fine, as long as the
batteries are in the same position each time the test is run.
Cypress Semiconductor Corporation Page 17/20
The initial calibration is most easily done using a variable attenuator
rather than the fixed attenuators provided in the kit. This is shown
in Photo #6 – Calibration Setup, below. If the variable attenuator
used does not have sufficient range, it may be necessary to install
both the variable and some fixed attenuation. The amount of fixed
attenuation will have to be determined by trial and error.

<Photo #6 – Calibration Setup>
The calibration begins by testing a known good DUT sample
(golden DUT) with a ‘best guess’ attenuation value. Based on our
experience, this will typically be in the 40dB range. The test starts,
and should pass at this initial setting. If it does not, the attenuation
may need to be reduced by 10dB. If a second test with this
reduced attenuation still does not pass, check all the connections to
be sure that everything is connected correctly. If this still does not
fix the problem, attach the antenna directly to the SMA on the MTK
Test Fixture and test the golden DUT in free air (no chamber). If
this still does not pass, make sure that the Test Fixture has power,
press the reset button (the self test should pass and the green LED
remain lit) and make sure that the golden DUT has good batteries
installed and is in MTK test mode.
Cypress Semiconductor Corporation Page 18/20
Once a base line is established by passing the test, the attenuation
is increased and the test repeated. Doing this several times,
increasing the attenuation each time, will eventually reach the level
where the golden DUT fails the test repeatedly at a given

attenuation. There may be an intermediate attenuation value at
which the test will pass only some of the time. It is up to the user’s
discretion how to determine the limit value. One option is to
consider the test passing (for calibration only) if it passes three or
more of five tests. As long as the method used is consistent, the
results will be consistent.
It may be helpful to repeat the test with additional known good units
recording the attenuation limit for each, especially for a new
product. Eventually, a “worst of the best” unit can be retained for
future calibration use. This is a unit that, while good and passing all
the requirements, exhibits the lowest attenuation limit ever seen in
a good unit.
Now that a limit has been found, the fixed attenuation should be
installed in the cable. The total attenuation should be selected
such that it is lower than the limit value found using the golden units
by some guard band (-3dB for example.) The type of defect we
expect to be encountered will result in far greater than 3dB of
reduction in either transmit power or receive sensitivity.
Cypress Semiconductor Corporation Page 19/20
Finally, the golden DUT should be tested once more with the fixed
attenuation installed to ensure that the setup is still working. The
test should pass repeatedly. If it does not, check the attenuation
value and all connections again.

APPENDIX D – TEST CHAMBERS
An anechoic RF test chamber, sized appropriately for the Device
Under Test (DUT), with SMA pass-through connectors is required.
There are several important factors to consider when buying a
chamber. The attenuation of RF energy that comes into the box
from outside, the attenuation of RF energy that is reflected from the
inside of the box, and the connectors for passing signals through
the walls.
Requirements:
• Attenuation of incoming RF energy: ≥30dB @ 2.4GHz
• Attenuation of reflected RF energy: ≥15dB @ 2.4GHz (≥
7.5dB each direction)
• Connectors: One (1) SMA minimum
Many vendors sell test chambers that will work. Below are some
examples of units that we have used before.
• Micronix model ME8662E
• Ramsey Electronics model STE2200 with optional
CONN157. (A small box nicely sized for a mouse or dongle,
or small bare boards.)
• Ramsey Electronics model STE3300 with optional
CONN157.
Cypress Semiconductor Corporation Page 20/20
• Ramsey Electronics model STE4400 with optional
CONN157. (Large enough for a full size keyboard in
plastic.)
Table of contents
Other Cypress Test Equipment manuals