Embedded Systems Design - March 2008 - (Page 46) 0308esd.p41to46 2/13/08 8:03 PM Page 46 20 years ago programming languages, the If PLD design is a new thought to the are described is unimportant; essential difference being that embedded systems programmer, then all the commands in each HDLs offer declarative extenstate are executed simultaneit’s one that should be explored. sions and special data types. ously. Likewise, all the truthBoth features are illustrated in table lines and Boolean equaour ABEL examples. tions are evaluated In the state-machine descriptions of the traffic-light concurrently. The compiler will alert the erring programchanges, for example, the order in which the light changes mer who assigns more than one change to one signal under the same conditions. It will also automatically combine multiple Boolean equations into single AND/OR equations and optimize the combinatorial networks for the specified Listing 2 Making a four-bit counter out device architecture. of two register bits. Pin names are used to define signal descriptions into a. Truth-table description. and out of the PLD. These constitute one signal type. The TRUTH_TABLE IN control_lights aforementioned vector descriptions can also be used to de([Q0, Q1] :> [Q0,Q1]) scribe signals. The compiler will alert the programmer [0,0] :> [0.1] when a pin name is assigned as a state label or component [0,1] :> [1,0] name. It will also detect erroneous assignment of pins, such [1,0] :> [1,1] as the use of an input as an output. [1,1] :> [0,0] Writing an HDL description isn’t all that different from using a general-purpose programming language. The fact b. Long Boolean description. that the compiler generates a fusemap for the interconnecEQUATIONS IN control_lights tion of logic elements, rather than microcode for a procesQ1 = (Q0 & !Q1) # (!Q0 & Q1); sor, is hidden from the programmer. Q0 = (Q0 & Q1) # (!Q0 & Q1); c. Short Boolean description. EQUATIONS IN control_lights Q1 = Q0 $ Q1; Q0 = Q0 !$ Q1; d. State-machine description suitable for use in Listing 1. Q0, Q1 PIN 18,19 STATE_DIAGRAM count STATE delay_0 Q0 := 0; Q1 := 0; GOTO delay_1; STATE delay_1 Q0 := 1; Q1 := 0; GOTO delay_2; STATE delay_2 Q0 := 0; Q1 := 1; GOTO delay_3; STATE delay_3 Q0 := 1; Q1 := 1; IF greenA = on THEN Agreen_to_yellow ELSE Bgreen_to_yellow; WHEN TO TRY OUT A PLD If an application looks like it requires only a few pages of code, then a PLD can be a low-cost solution. Ideally, such an application should have less than eight states and require specific control lines for switches and indicators. PLDs are also efficient where speed is important, as the functions are evaluated logically rather than by a sequence of macroinstructions. PLDs are useful at the other end of the design spectrum, where high performance and functional complexity are more important aspects of the design than cost. If PLD design is a new thought to the embedded systems programmer, then it’s one that should be explored. Hardware designers can provide some assistance in this area, though to date only about 20% of all hardware designers have ever used a PLD (according to Data I/O surveys). PLD vendors offer instructional courses, but they’re usually aimed at hardware designers rather than software developers. Accordingly, most PLD vendors emphasize schematic rather than HDL design. HDLs are usually very simple, however, with less than a hundred commands and directives. I’ve found HDLs easier to learn than any other language. The only real issues are device selection and pin assignment, which are currently addressed only by Minc Inc. Next month: how software models can be used instead of in-circuit emulators for code development. ■ Ernest Meyer is an independent technical writer and former editor of VLSI Systems Design. 46 MARCH 2008 | embedded systems design | www.embedded.com http://www.embedded.com
Table of Contents Feed for the Digital Edition of Embedded Systems Design - March 2008 Embedded Systems Design - March 2008 Contents #Include Programming Pointers Designing DSP-based Motor Control Using Fuzzy Logic Hardware/Software Verification Enters the Atomic Age Efficient CRC Calculation with Minimal Memory Footprint Programming Your Own Microcontroller Advertising Index Break Points Marketplace Embedded Systems Design - March 2008 Embedded Systems Design - March 2008 - (Page BB1) Embedded Systems Design - March 2008 - (Page BB2) Embedded Systems Design - March 2008 - Embedded Systems Design - March 2008 (Page Cover1) Embedded Systems Design - March 2008 - Embedded Systems Design - March 2008 (Page Cover2) Embedded Systems Design - March 2008 - Embedded Systems Design - March 2008 (Page 1) Embedded Systems Design - March 2008 - Embedded Systems Design - March 2008 (Page 2) Embedded Systems Design - March 2008 - Contents (Page 3) Embedded Systems Design - March 2008 - #Include (Page 4) Embedded Systems Design - March 2008 - #Include (Page 5) Embedded Systems Design - March 2008 - #Include (Page 6) Embedded Systems Design - March 2008 - #Include (Page 7) Embedded Systems Design - March 2008 - #Include (Page 8) Embedded Systems Design - March 2008 - Programming Pointers (Page 9) Embedded Systems Design - March 2008 - Programming Pointers (Page 10) Embedded Systems Design - March 2008 - Programming Pointers (Page 11) Embedded Systems Design - March 2008 - Programming Pointers (Page 12) Embedded Systems Design - March 2008 - Programming Pointers (Page 13) Embedded Systems Design - March 2008 - Programming Pointers (Page 14) Embedded Systems Design - March 2008 - Programming Pointers (Page 15) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 16) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 17) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 18) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 19) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 20) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 21) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 22) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 23) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 24) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 25) Embedded Systems Design - March 2008 - Designing DSP-based Motor Control Using Fuzzy Logic (Page 26) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 27) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 28) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 29) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 30) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 31) Embedded Systems Design - March 2008 - Hardware/Software Verification Enters the Atomic Age (Page 32) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 33) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 34) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 35) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 36) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 37) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 38) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 39) Embedded Systems Design - March 2008 - Efficient CRC Calculation with Minimal Memory Footprint (Page 40) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 41) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 42) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 43) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 44) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 45) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 46) Embedded Systems Design - March 2008 - Programming Your Own Microcontroller (Page 47) Embedded Systems Design - March 2008 - Advertising Index (Page 48) Embedded Systems Design - March 2008 - Break Points (Page 49) Embedded Systems Design - March 2008 - Break Points (Page 50) Embedded Systems Design - March 2008 - Marketplace (Page 51) Embedded Systems Design - March 2008 - Marketplace (Page 52) Embedded Systems Design - March 2008 - Marketplace (Page Cover3) Embedded Systems Design - March 2008 - Marketplace (Page Cover4)
For optimal viewing of this digital publication, please enable JavaScript and then refresh the page. If you would like to try to load the digital publication without using Flash Player detection, please click here.