Skip to content
a low pin count sniffer for icestick
Branch: master
Clone or download
Latest commit c38d231 Dec 14, 2017
Type Name Latest commit message Commit time
Failed to load latest commit information.
parse top.v: set trigger led to decode postcode 0x34 Oct 29, 2017
test move helloworld into /test directory Aug 6, 2017
LICENSE add LICENSE: GPL v3 Dec 25, 2015
Makefile implement ftdi fast opto serial mode Nov 5, 2017 put script into ` Dec 8, 2017 update TODO Aug 6, 2017
ftdi.v ftdi: implement the ftdi fast opto mode Dec 13, 2017
mem2serial.v fixup! mem2serial: write out least significant bytes first Aug 6, 2017
pll.v add missing file pll.v Dec 13, 2017
power_on_reset.v pll + por Oct 29, 2017
ringbuffer.v ringbuffer.v: use simpler assign instead of a process for overflow/empty Nov 5, 2017
ringbuffer_tb.v ringbuffer_tb: use always clock and replace timings Aug 6, 2017
top_tb.v implement sync error, implement io read Oct 29, 2017

lpc sniffer (low pin count) for ice40 stick

Turn the ice40 stick into a LPC sniffer.


  • i/o read + writes
  • memory read + writes
  • sync errors

How to use

  1. modify EEPROM of the FTDI and enable OPTO mode on Channel B
  2. programm top.bin into your ice40 by iceprog lpc_sniffer.bin
  3. connect the LPC bus
  4. python3 ./parse/ /dev/ttyUSB1

what connectors are used on the IceStick?

  • J1 connector
	VCC 3.3|NC 1
	GND        2
	lpc_clock  3
	lpc_ad[0]  4
	lpc_ad[1]  5
	lpc_ad[2]  6
	lpc_ad[3]  7
	lpc_frame  8
	lpc_reset  9
  • uart output over the ftdi


	For orientation: the usb port points south:
	green in the middle: overflow_led

overflow_led when internal buffer is full. No more LPC frames are decoded

Uart protocol

The LPC sniffer will write out frames onto the second uart of FTDI with 921600 baud.


  • 4 byte: address
  • 1 byte: data
  • 1 byte: 0-3bits: direction+type, 4-7: errorcode
  • 2 byte: '\r\n'

error codes

An error code is decoded in 4 bits

  • 0001 - sync timeout.

Internal documentation

A LPC frame will:

  1. decoded by the LPC decoder
  2. saved into the internal memory
  3. padded by \r\n
  4. written onto uart

in memory layout

The internal memory is used as 48bit addressable memory. 48 bit is exact one lpc frame

  • 4 byte: address
  • 1 byte: data
  • 1 byte: direction/type + error code

internal buffer

The LPC sniffer is using an internal buffer. When the internal buffer is full, new frames will be discarded. The green LED in the middle will turn on. The internal buffer can save up to 2**10 lpc frames (1024).

You can’t perform that action at this time.