Bounty: Add Bus Pirate support to OpenOCD JTAG programmer

bpv3-2

We’re offering a bounty on the most-requested Bus Pirate features. The developer of each feature can have their choice of a Bus Pirate probe cable kit or our next monthly project.

Today we’re highlighting JTAG. It would be ideal to have Bus Pirate support in the popular open source JTAG programmer OpenOCD, but other solutions are also fine. It should be possible to adapt an existing parallel port or FTDI232 JTAG wiggler mode to flip bits in a byte and send it to the Bus Pirate bitbang binary mode. We could also develop a separate binary JTAG library if requested.

A JTAG programmer that supports the Bus Pirate is currently the most-requested feature addition. Early firmwares had a terminal-based XSFV programmer from Xilinx, but it required specially compiled XSFV programming files and funky flow control.

Firmware v2.x removed the XSFV programmer, but added a new binary access mode that can be used with PC-based JTAG programmers. This is a much better solution because it lets the PC do any heavy lifting, the Bus Pirate simply twiddles pins.

Thanks to bluesign2k for the unboxing picture.

Bus Pirate v3 unboxing

b[v3-unboxed

Bus Pirate v3 preorder 1 is starting to be delivered worldwide. There’s a discussion in this thread of the forum.

Learn about connecting the Bus Pirate for the first time in the Bus Pirate 101 tutorial. BPv3 shipped with a special firmware (v2.4-Seeed) that includes a manufacturer’s self-test mode. It’s a good idea to upgrade to the latest firmware (Windows, OSX, Python). You might want to run a self-test to verify the hardware.

The Bus Pirate manual has lots of links to get you started. Familiarize yourself with the IO pins, menu options, and syntax, then take a look at the the chip demonstrations. There’s also additional help in the forum.

There’s still time to get a Bus Pirate v3 for $30 including worldwide shipping.

Thanks to pandriod for a picture of the BPv3 hardware with a red PCB.

SMD parts in a kit?

pad-v2-hybrid

How comfortable are you with surface mount parts? Would you build a kit that included some or all surface mount components?

Seeed Studio will stock our next few projects as both a kit and assembled hardware.

Some kits will include all SMD parts in 0805, SSOP, and other small packages, like the Bus Pirate and #twatch. Others will use a mix of parts like the PCB shown above, it uses a large SIOC-sized surface mount IC and through-hole resistors.

Even if you don’t like the idea of an SMD kit, would you be willing to solder some larger SMD parts if the resistors and capacitors were a comfortable through-hole size?

Thanks for your feedback!

Ping the #twatch

ping

The #twatch has a simple ICMP (ping) server that shows if the #twatch is alive and kicking on your network, and how long it takes to respond.

First, get the #twatch IP address from the LCD screen or the announcement packet.

Next, start a ping client and ping the #twatch IP address. Windows has a built-in ping client that’s available from the command prompt (Start->run. Type ‘cmd’, press enter. Type ‘ping’, followed by the IP address).

The ping results show basic statistics like how many pings were successful, and how long the #twatch took to reply.

Bus Pirate firmware v3.0 released

bpf-v3

Bus Pirate firmware v3.0 is available for download. This release has a new logic analyzer function, improvements to the SPI and I2C bus sniffers, and many bug fixes. See the commit log for a complete list of updates.

The download includes English, Spanish, and Italian language firmware for hardware v3, v2go, and v1a. We’ve stopped compiling firmware for v2a and v0a because nobody reported using them. If you want a compile for these versions, just ask.

There’s a list of major updates since the last release after the break.

Continue reading “Bus Pirate firmware v3.0 released”

Free PCB Sunday: #twatch v1b

Twatch-v1b.render

We go through a lot of prototype PCBs, and end up with lots of extras that we’ll never use. Every Sunday we give away a few professionally-made PCBs from one of our past or future projects, or a related prototype.

Earlier we gave away a v1a #twatch PCB, now we’re giving away one of two existing 24FJ64GA002-based v1b #twatch development board PCBs. We’d like this go to someone interested in developing firmware for their v2 #twatch, but that’s at your discretion. Sorry there’s no photo, this is a bare, green PCB. PCB by Seeed Studio.

Get an assembled red #twatch for $45 at Seeed Studio, including LCD and worldwide shipping. Seeed also has #twatch v2 PCBs for $6, and the compatible ethernet jack for $1.90.

Continue reading “Free PCB Sunday: #twatch v1b”

Free PCB Sunday: #twatch v1a

twatchv1a-pcbs

We go through a lot of prototype PCBs, and end up with lots of extras that we’ll never use. Every Sunday we give away a few professionally-made PCBs from one of our past or future projects, or a related prototype.

This week we’re giving away one PCB for the 24FJ64GA002-based v1a #twatch development board. We’d like this go to someone interested in developing firmware for their v2 #twatch, but that’s at your discretion. PCB by Seeed Studio.

Get an assembled red #twatch for $45 at Seeed Studio, including LCD and worldwide shipping. Seeed also has #twatch v2 PCBs for $6, and the compatible ethernet jack for $1.90.

Continue reading “Free PCB Sunday: #twatch v1a”

#twatch network firmware upgrades

bootload

See the latest version on the documentation wiki.

The #twatch can be updated from a PC on the local network thanks to Microchip’s network bootloader. Bug fix updates, new features, and alternate functions can be programmed into the #twatch using the bootloader. The 18F ethernet PICs can only be programmed an average of 100 times, so upgrades are somewhat limited.

This guide is taken from the main #twatch article. Read about the update procedure after the break.

Continue reading “#twatch network firmware upgrades”

Compile the #twatch firmware

mplab

See the latest version on the documentation wiki.

You don’t need a Microchip programmer to develop firmware for the #twatch. You can use Microchip’s free development tools and upload code through the network bootloader. It’s a mini PIC 18F67J60 development board, but remember that the chip is only rated for 100 program cycles.

Compile instructions follow the break.

Continue reading “Compile the #twatch firmware”

View the #twatch IP announcement

MCHPdetect

The #twatch acquires an IP address automatically using the DHCP server on your network. It displays the IP address on the LCD screen, but it also sends an announcement packet to every computer on the network. The packet is directed to port 30303 at the broadcast address. Microchip provides a small Windows utility called MCHPDetect that displays these packets, source code is available in the TCP/IP stack download.

Bus Pirate I2C, SPI sniffer updates

sniffer

See the latest version in the documentation wiki.

With aphoticjezter’s confirmation that the undocumented I2C sniffer actually works, we tweaked the code to help get around the UART speed limitations. These updates are in the latest nightly build.

The I2C and SPI sniffers now use a 4096byte output ring buffer. Sniffer output goes into the ring buffer and gets pushed to the PC when the UART is free. This should eliminate problems with dropped bytes, regardless of UART speed or display mode. A long enough stream of data will eventually overtake the buffer, after which new bytes will be dropped until space is available.

Sniffer demos and documentation after the break.

Continue readingBus Pirate I2C, SPI sniffer updates”

#twatch backlight control from Python

twatch-sideiii

It looks like the #twatch is starting to arrive worldwide. WA5ZNU received a #twatch and wrote a Python script to control the backlight. You can use this thread to discuss your #twatch unboxing experience.

There’s still a few #twatches at Seeed Studio for immediate delivery, $45 including LCD and worldwide shipping.

Continue reading “#twatch backlight control from Python”

Bus Pirate I2C sniffer working?

i2csniff

It appears the I2C bus sniffer, macro (2) in the I2C library, may have been working all along. aphoticjezter writes in the forum:

I hacked the binary file to change the bitrate for one of the speeds to 230400, and I also used RAW mode as suggested.  So far I seem to be reliably sniffing the traffic…

The key is getting data from the Bus Pirate to the PC fast enough that we don’t miss any I2C signal changes. One way to increase the speed is to change the Bus Pirate display mode to RAW, and then have your terminal show the HEX equivalent of the raw byte values. In raw mode the Bus Pirate doesn’t have to shove 5 or 6 ASCII bytes up the wire for every byte snooped.