Charles MacDonald's Home Page | |
|
News (1/18) 2010 already Wow, time flies when you are CUPL is a language used to describe the logic implemented in a PAL or GAL device, similar to other ones like ABEL and SNAP. Atmel offers a free compiler called WinCUPL which targets popular devices such as the 16V8 and 22V10. WinCUPL is a great program but was written quite a while ago and has a number of unusual quirks, perhaps related to using it with Windows XP. For example it commonly crashes with a "Automation error", something which you can remedy by saving your file with Ctrl+S after typing every line or two. I suspect it has something to do with accumulating too much Undo information (a feature which also does not work in XP) and trashing memory as a result. Editor issues aside, a bigger problem is that the statements which you write can become malformed during compilation, for example assigning an output enable term to a field may not result in all field elements having the same output enable setting. Problems like these are hard to track down and the ".sim" file which shows intermediate results isn't easy to read due to the lack of formatting. To resolve this issue, I developed a JEDEC to CUPL converter for 22V10 fusemaps. The output is directly compilable by WinCUPL and explicitly states all settings where possible to minimize the amount of guesswork WinCUPL has to do. All GAL22V10 features relating to combinatorial and registered modes are fully supported, including the electronic signature field (UES data).
The JEDEC fusemap loading may be too closely tied to WinCUPL's output, so if anyone has fusemaps written by another application that do not work correctly please let me know. I may add 16V8 support in the future, though oddly enough it is more complicated than the 22V10. Ideally I'd like jed2cupl to become a modern replacement for the old jed2eqn program National Semiconductor developed in the early 90's. Previously I had been working on an MP3 player for a project which unfortunately ran past the deadline and was not finished. It was the first time I had dealt with getting consistently bad parts from a single vendor, and was a good lesson in second-sourcing components as well as evaluating their reliability. I wrote a lot of code for file management, browsing, and a GUI with a variable width font system for LCD displays. On the hardware side I came up with circuitry for mixing 3.3V and 5V peripherals on a SPI bus and implemented a serial FRAM for configuration and a SD card interface for MP3 storage. Time allowing, I'll try to find suitable replacement components and put the finished design information online. | |
|
|