Make A Logic Analyzer Easy

 

      Recently I purchased a CY7C68013A project board, from eBay, that equipped all the parts for prototyping

your own project.  There are quite lot of discussions on the line that talk about how to convert it to a logic analyzer,

(Saleae-8 Logic Analyzer or USBee Logic Analyzer).  But some of them are vague and confusing or even not

correct that lead people to a  wrong way.  I spent some time to try it.  As the following pictures showing, the board

looks pretty descent in both manufacturing quality and design.

 

Simply speaking, everything you need to focus on is the on-board EEPROM!. The EEPROM is connected to CPU

through I2C bus as a 'slave' device, running at 100Kbps. In theory, the board can be turned into a logic without adding extra parts: 

[1] soldering off the EEPROM chip (AT24C128) and the jump (J1). It's a wrong chip for making our logic analyzer;

[2] replace with a 24C02 EEPROM which has 2048 bits or 256 bytes of memory, and accessed using one byte memory address (this is a key issue); 

[3] the EEPROM should be programmed with 8 bytes of VID and CID starting at address 0x00, leaving the rest of memory blank.

[4] Pin1 ~ Pin3 of  the EEPROM should be connected GND, because CPU will use I2C address 0xA0 communicating with the memory!

[5] WP pin of EPPROM might need to be disabled (see the reason mentioned below).

 

My solution is different than that above since I don't have such an EEPROM in hand and I don't want to spend extra money

for S/H to purchase from line.  What I did is using a CPU (PIC16F1455) to simulate the EEPROM and I2C communication

by firmware since I have that in hand and I can also add more features to it (put a jump that selects either Saleae-8 or USBee mode). 

More specific, I create a 256 bytes buffer in RAM that stores VID, CID.  The I2C simulation should be implemented carefully.  It should

be able to detect all START/STOP signals on I2C bus, and it should be able to handle both READ and WRITE operations

because I feel the console software will write some data into EEPROM when it starts running (not 100% sure). Plus it should

generate effective /ACK right away for responding the receiving.  PIC16F1455 is running at 16MHz, yielding 4MISP. The firmware

just uses 'bit-bang' method to simulate I2C communication as a 'slave'. You can use other type of CPU for that (ATtiny88, PIC16F1825, ...).