Populate the PCB
This revision has an Atmega 32U4 AVR chip so there should be plenty of power to spare for anyone wanting to do some fancy touch filtering. The source code is in the Manga Screen repository.
Atmel stopped supporting FLIP for Linux on version 3.2.1, before they added support for Atmega 32U4, so in order to program the Atmega 32U4, I had to do the following:
sudo apt-get install dfu-programmer
dfu-programmer atmega32u4 erase
dfu-programmer atmega32u4 flash MangaScreen.hex
6436 bytes used (22.45%)
dfu-programmer atmega32u4 reset
The reset command sets the program counter (PC) to 0×00 so the user program starts. If you hit the reset button at any time, the PC will jump to the start of the bootloader code.
The USB driver is built on top of the LUFA library. It should populate as a USB with two devices, one serial port and on Human Interface Device (HID). The serial port will accept commands such as “set display on”, “set backlight 128″, “set gamma yadayada”. perhaps also Upload/download EDID etc. The HID will of course be the touch screen.
Software implementation of a slave EEPROM chip
A couple of weeks ago we did not know that the EEPROM chips that are present in all displays and supplies the host with EDID info can also be programmed through the HDMI cable. Therefore we thought the best thing to do would be to let the AVR chip handle the role of the EEPROM. The problem was that the I2C controller on the AVR had been reserved for the touch screen controller so we had to use two GPIO lines and handle the timing our selves. But there was only one interrupt line available so we gave that the the SCK line, when actually it is the SDA line that initiates the start and stop conditions. So if anyone ever decides to do make the same mistakes we did, you might enjoy the EEPROM.c and .h files found in the repository. However, my advice is: Spend that extra 10 cents on a real I2C EEPROM chip : )
The (almost) final result
As you can see in the picture below, the screen works fine and dandy. Right now it is run through the DVI interface of my Ubuntu box at the native resolution of 480×800@60Hz. The idea is that this screen will be used primarily with the HDMI interface for BeagleBone Black.
I also made a video as soon as I got the screen working. Here it is:
The next step
That is to get the touch functionality working by porting the Linux driver for the mXT224 to the AVR.