Bitbanger USB

The BitBanger board and device driver provide a simple method to quickly interface a wide variety of I2C components to a Windows 98 P.C. through a USB port. The design consists of the USB to I2C bridge hardware (BitBanger Board), and a Windows 98 compatible WDM device driver (BitBang.Sys). An example Visual Basic application (BitBanger.Exe) is provided to demonstrate how to communicate with the driver and hardware.

The I2C functionality is demonstrated with a simple external I2C circuit which provides a 7-segment display (8 bit output), 8 switches (8 bit input), and an eeprom. The BitBanger.exe example application reads the switch inputs and echoes the switch value to the 7-segment display. The BitBanger application code clearly demonstrates how to open and close a handle to the BitBang.sys device driver, continuously monitor the presence of the device, and perform I2C transactions.

There are many components available that incorporate I2C control interfaces, including eeproms, rams, DACs, ADC's, multiplexers, digital I/O, USB, etc. Because the I2C calls are not device specific, almost any combination of the currently available I2C components can be controlled by the BitBanger. The host P.C. application will send I2C transaction requests to the BitBanger via the USB connection.

The I2C transaction requests specify the address of the I2C device, whether a Read or Write operation is to be performed, and how many bytes to transfer. The PDIUSBD11 receives the specified I2C transaction requests (packaged up for USB) from the host and signals the processor via the nIRQ signal. The processor then communicates with the PDIUSBD11 via the I2C bus to service the interrupt and read the received requests from the PDIUSBD11's buffer(s).

The processor then executes the specified I2C transactions, issuing the corresponding Read or Write requests over the I2C bus to the external device(s) on the attached I2C bus.

DIAGRAM