Monday, 28 January 2013

Dual-mode Logic Analyzer


I recently bought a Cypress FX2LP USB development board from ebay and thought it would be an interesting project to see if I could get it to function as a switchable Saleae/USBee logic analyzer.
The USB FX2LP dev mini board I bought was a product offering from LCSOFT. This comes with an onboard CYC68013A microcontroller and 128K EEPROM.

I originally came across SpiralBrains blog, which had some valuable information on the issues with getting it to work as a Saleae clone.

This solution switches between two EEPROMS to switch between the two pairs of VIDs and PIDs (vendor and product ids). I used the onboard AT24C128 EEPROM (for USBee ZX mode) and an external AT24LC01 EEPROM (for Saleae mode) for storing the corresponding VIDs and PIDs.

The beauty of this solution is that it requires no SMT soldering/desoldering. It requires just one external EEPROM which can be soldered to the rear of the PCB header pins, and a switch for sharing the SDA data line.
The schematic is shown below.


I mounted the LCSOFT mini board onto a plactic enclosure box, with a panel cutout for access to the underside of the PCB header pins for +3.3v,GND,SCL and SDA. This leaves the top header pins clutter free for external use. The AT24LC01 EEPRO, 8 pin DIL and mode-switch were also mounted externally, for ease of access.

The final prototype was assembled in an enclosure with the help of a soldering iron, hot glue gun and dremel.



For details on how to program the EEPROMs using the Cypress USB developers kit, read this article.

To program the onboard EEPROM. First remove the AT24LC01 from its DIL, and ensure J1 is connected.
You should program 0xA2 with ’C0-A9-08-05-00-84-23-00′. this is the VID:08A9 and PID:0005 for the USBee ZX device.

Then remove jumper J1 and insert the external 24LC01. Now program 0xA2 with 'C0-25-09-81-38-1B-00-00'. This is the VID:0925  and PID:3881 for the Saleae device.

I installed the "Cypress USB driver" assigning it the USBee VID and PID in the .INF file.

Switching between Saleae and Usbee modes is simple. Power off using the power button, slide switch to appropriate mode, Power on and startup your software. Always leave J1 connected. The logic channels are PB0-PB7.


2 comments:

  1. Hello, do the logic inputs accept 0-5v logic without damaging the analyzer?

    ReplyDelete
  2. From the CY7C68013A datasheet:
    * 3.3 V operation with 5 V tolerant inputs

    DC CHaracteristics
    VIH Input HIGH voltage 2 - 5.25 V


    Absolute maximum ratings:
    DC input voltage to any input pin[16] ............................ 5.25 V

    [16] Do not power I/O with chip power off.

    On the other hand, I'd put at least some resistance between the inputs and probes, to limit damage you might do to the circuit under test in case the pin mistakenly gets configured as an output.

    ReplyDelete