One of the developments above lead me to spend some time (about one and one-half years later) investing in my own technology base and to jump in and get my feet wet in a FPGA based design.
The board hosts a MC68332-GCFC processor system with flash, RAM, CPLD, etc. All of these parts are 5v while the FPGA system is new enough (Spartan-IIE family ) that it has 3.3v IO and a 1.8v core. This disjunct then dictates the implementation of level shifting circuitry (74ALVC164245 by Philips Semiconductor). There is a fourth power supply along the back edge of the board to provide higher voltage levels as input to an AC inverter module. The front edge of the board is populated completely with header pins and break out all the processor busses, as well as FPGA side busses and special outputs for interfacing to vision system prototypes and LCD displays.
The development code base for this project is fairly large. In a later (much later) section the reader will see that I used this board to interface to a number of LCDs driving prototype display panels. On top of holding the operating code and configuration code for the FPGA as well as fail safe duplicate backups for in-system programming with increased reliability, there is also a significant storage capacity requirement for graphics and fonts as well. This project was completed when monolithic flash memory was really starting to grow in capacity. The parts used in this design are AM29F032B parts that were originally produced by AMD before the memory division was split out to Spansion.
Board level technologies used:
- Motorola MC68332-GCFC embedded 32-bit microprocessor, cpu-32 core product.
- Xilinx XC2S-300E Spartan IIE FPGA.
- Dallas Semiconductor DS-1233 Power and reset monitor.
- Maxim Semiconductor MXD1210CSA Nonvolatile battery RAM controller
- Advanced Micro-Devices AM29F032B 5v 8bit flash (2Mx8).
- Samsung KM684000LI 512K x 8 static RAM.
- Alliance AS7C34096 high speed static ram 512Kx8
- Lattice Semiconductor ISPLSI-2032VE Complex Programmable Logic Device (CPLD).
- Maxim Semiconductor MAX233 with integral switch mode capacitors.
- Power Trends PT6304 Switching regulating 12V high efficency buck regulator module.
- Power Trends PT6303 Switching regulating 3.3V high efficency buck regulator module.
- Power Trends PT6302 Switching regulating 5V high efficency buck regulator module.
- Power Trends PT6406 Switching regulating 1.8V high efficency buck regulator module.
- Texas Instruments SN65ALS176 RS485 differential bus transceiver.
- Fairchild Semiconductor HPCL-2630 10M-bit Opto-Isolator.
- Phillips Semiconductor (NXP) 74ALVC164245 3.3V to 5V level translator
- Wall Industries LAN-E-505N switching isolated DC-DC converter.
- Fairchild Semiconductor MMBTA06 general purpose npn-transistor.
There is a pretty good amount going on in the circuitry outlined below. I have provided the schematic to the right to help guide the reader through that circuitry. Please pay particular attention to the note on one of the pages that outlines the need for a few cuts and jumps. In the rush of the moment I failed to back annotate the needed cuts and jumps from the paper red-lined design into the captured schematic. As such there are ~16 signals on the noted page that will need to be hand checked / verified prior to use. The signals that require checking are the connections to the /OE and DIR pins on the 5v <=> 3v level shifters.
The CPLD provides bus drive ability while the processor is coming out of reset. The board also hosts a standard 10-pin BDM interface to load the processor, external flash and to step through code and debug memory / registers. I've used a number of BDM pods including the one I developed to run inside CPLD for the CRC332. In this project I'm using a pod from the MRM (MiniRoboMind) project, pictured right.
The link to the left will take the reader to the files section of this web site where they can download a modified version of BD-32. This verison was modified by my friend Mark C. It allows for directly flash loading of S19 files across BDM. I've grabbed a screen shot, below...
The second link (right) is to the Mini-RoboMinds web site where, if the reader want's to play with some of this technology themselves, they can purchase a really great MRM 68332 based controller that will work with these tools.
So this work later went on to become a full color vision and display system. That work is pictured later on this site in Controllers-2, Section (54). If the reader looks closely, they can identify that all of the basic design features here flow from the CRC332 board design (section 00) and that the new technology here is built upon that foundation.
On the bottom of the board, roughtly underneath the FPGA is an Xilinx family flash-ROM. This flash-ROM device is inserted in the JTAG (IEEE-1149) chain with the FPGA. The two device progammers, pictured below, are used to download from a PC's serial port into the flash-ROM device. Since it is a RAM based device, upon boot, the FPGA serially shifts the information out of the flash to load it's configuration.
In the development of this project, there are many adapter boards and interface boards, used to level shift and interface the FPGA to a number of different devices. The interface board, shown right, is one such simple adapter. It provides level conversion and connectivity between the FPGA and RS232C levels. This conversion is done with a MAX3232 3.3v line driver w/integrated charge pump.
The two configuration cable devices below are both made by Xilinx. The one on the right is a parallel cable-3 that can be found for cheap on eBay these days. The one on the left is a Xilinx parallel cable-4 that is used with some of the more advanced FPGA features on their newer porducts like the Virtex family for simultaneously doing JTAG, Ethernet-PPP on JTAG, etc...
BDM SOFTWARE SCREEN-SHOT:
The next piece of code is the first Verilog code developed and run on this board. Often an exceedingly simple starting point is exactly that which is needed. In this case an oscilloscope was used to verify the output and proper board operation.
Through out these pages there exist numerous examples of complex Verilog implementations like the advanced color vision system and those boards used in the development of my robot named Dohn Joe, and others. It is somewhat fitting given the large size and complexity of those designs that this first test code is presented here, and the 2'nd simple instantiation of a block RAM, in the next example, below.
This next code snippet is an absolutely invaluable tool for anyone beginning the integration of a processor loaded FPGA project. I also have a *.hex <=> *.h conversion tool used to generate the *.h file containing the raw data set to be loaded into the FPGA and included into the *.C build. Note, this is the file included in line #2, below. I will attempt to get this utility app posted to the files area in the coming days. The 2'nd code snippet below shows the output of the *.h file processed by the hex2h.exe application.
While reading the below code, refer back to the graphic schematic snippet, provided right. This snippet is a chunk from the completed schematic near the beginning of this page. Note that these five signals, after level translation (5v<=>3.3v) connect directly between port F pins on the processor and the FPGA via a 74ALS164245 IC. Note, the pull up resistors shown in this schematic are not necessary as the data lines are always driven by the afore mentioned level translation IC.
The application executable, in the files section linked from the right, is designed to run native called from a command line on a PC. It requires a file titled fpgadata.hex and produces as its output a file titled fpgadata.h. To take advantage of this application the user should use the impact tool that ships with the Xilinx ISE tool set (web pack, foundation or other) and target that tool to create a PROM file in *.hex format with the name fpgadata.hex, or rename the file after it has been created. The input file must reside in the same directory as the application.
Files section 23:
This project was not only about developing FPGA based technologies for the fun of it. Sure there was a massive learning curve that I've undertaken and I'll now be able to apply this technology to other projects, however the immediate goal for this work was to develop LCD controller. The image below shows the Sharp LCD (LQ049B4DG01) that I was developing with mounted to the board. Some of these displays are designed for the automotive industry which means that they have incredible contrast performance in the high end brightness category.