Hardware resource implications I2C requires the use of two port pins. This is considerably fewer than would be required to create a parallel interface to most peripheral devices. There is, however, a significant CPU load: see ‘Solution’ for details. Reliability and safety implications The I2C protocol incorporates only minimal error-checking mechanisms: detection of data corruption […]
Continue reading…
Uncategorized
Example: Displaying elapsed time on an LCD
Example: Displaying elapsed time on an LCD This example displays elapsed time on an LCD character panel (Listings 22.1 to 22.3). Hardware The required hardware is shown in Figure 22.2. Software
Continue reading…
Example: Displaying elapsed time on a multiplexed (4-digit) LED display
Example: Displaying elapsed time on a multiplexed (4-digit) LED display A common use for LED displays is to display the time. This simple example demon- strates the display of elapsed time on four multiplexed LEDs. The code is written for a standard 8051 (8052) device. The required hardware is illustrated in Figure 21.6. The key […]
Continue reading…
Example: LCD and keypad
Example: LCD and keypad In this example we demonstrate a combined LCD–keypad interface (Figure 22.4).
Continue reading…
Controlling LCD panels:Lcd character panel
Lcd character panel Context ● You are developing an embedded application using one or more members of the 8051 family of microcontrollers. ● The application has a time-triggered architecture, constructed using a scheduler. ● You are creating the user interface for your application. Problem How do you connect an LCD-based ‘character panel’ display to your […]
Continue reading…
Multiplexed LED displays:Mx led display
Introduction Many embedded applications contain user interfaces assembled from multi-segment LED displays. In this chapter, we consider how such displays may be interfaced to the 8051 family of microcontrollers. Mx led display Context ● You are developing an embedded application using one or more members of the 8051 family of microcontrollers. ● The application has […]
Continue reading…
Controlling LCD panels
Introduction We considered the creation of LED-based user interfaces in Chapter 21. Here we are concerned with the use of liquid crystal displays (LCDs) in such interfaces. Unlike LEDs, LCDs are based on passive display technology: this means that LCDs control the passage of light rather than emitting light. This fact directly contributes to the […]
Continue reading…
Multiplexed LED displays:Hardware resource implications
Hardware resource implications All the examples here require the use of a scheduler. The main resource implication is that, to update (say) four digits, you need a scheduler with a tick interval of around 5 ms. This is not usually a limiting factor. Overall, the LED update code will consume only around 1% of the […]
Continue reading…
Keypad interfaces:Hardware resource implications
Hardware resource implications While it does not require on-chip facilities (such as timers etc.), the keypad scanning process imposes both a CPU and memory load. Reliability and safety issues Keypad scanning is a software-based technique, closely related to SWITCH INTERF ACE ( SOFTW ARE ) [page 399]. In a hostile environment, use of a keypad […]
Continue reading…
Example: Using a dedicated baud rate generator
Example: Using a dedicated baud rate generator As we noted in ‘Solution’, some 8051 microcontrollers have a timer dedicated to baud rate generation. This can be a useful facility, since it leaves us (usually) with three free timers for use in the scheduler, creation of delays and so on. In this example, we present an […]
Continue reading…