Difference: LCDDisplay (1 vs. 5)

Revision 52017-11-27 - uli

Line: 1 to 1
 
META TOPICPARENT name="CourseExercises"

Exercise 11: The LCD Display

Goal:

Line: 56 to 56
 
META FILEATTACHMENT attachment="2linedisplay.png" attr="" comment="" date="1503219633" name="2linedisplay.png" path="2linedisplay.png" size="894036" user="uli" version="1"
META FILEATTACHMENT attachment="i2c_pcf8574.png" attr="" comment="" date="1503219642" name="i2c_pcf8574.png" path="i2c_pcf8574.png" size="1038370" user="uli" version="1"
META FILEATTACHMENT attachment="pcf8574ifce.png" attr="" comment="" date="1503219643" name="pcf8574ifce.png" path="pcf8574ifce.png" size="65250" user="uli" version="1"
Added:
>
>
META FILEATTACHMENT attachment="led.pdf" attr="" comment="" date="1511779006" name="led.pdf" path="led.pdf" size="68129" user="uli" version="1"

Revision 42017-11-12 - uli

Line: 1 to 1
 
META TOPICPARENT name="CourseExercises"

Exercise 11: The LCD Display

Goal:

Line: 27 to 27
 You find the description of the library either in its source code when running doxygen in its source directory or, when connected to the Raspberry Pi at this URL:

https://dcsit.twiki.ucc.edu.gh/html/libDoc/hd44780/

Added:
>
>

Exercise 2: The name display

 
Changed:
<
<
Then try to re-do the name display program we showed of during the Open Day: A program asks a visitor to type in his name.
>
>
Try to re-do the name display program we showed off during the Open Day: A program asks a visitor to type his name.
  Once he is done, the program writes:

DCSIT welcomes

name of the visitor

Changed:
<
<

Exercise 2: Hello World version 2

>
>
to the LCD display.

Exercise 3: Hello World version 2

  Try to write Hello World to the display but this time without passing through my library.

This “Hello World!” program is a bit more complex than what you may know from your C programming course. The goal is to display the text “Hello World!” on the LCD display.

Changed:
<
<

Exercise2: A small display library

>
>

Exercise 4: A small display library

  Create a display library, which allows its user to write any text to any of the 2 lines on the display. This library you will use in a later exercise, when you will build a voltmeter. Of course you must also write a test application to make sure your library calls all work as expected.

Revision 32017-11-06 - uli

Line: 1 to 1
 
META TOPICPARENT name="CourseExercises"

Exercise 11: The LCD Display

Goal:

Line: 26 to 26
  You find the description of the library either in its source code when running doxygen in its source directory or, when connected to the Raspberry Pi at this URL:
Changed:
<
<
file:///opt/ucc/exercises/solutions/hd44780/html/index.html
>
>
https://dcsit.twiki.ucc.edu.gh/html/libDoc/hd44780/
  Then try to re-do the name display program we showed of during the Open Day: A program asks a visitor to type in his name.

Revision 22017-10-25 - uli

Line: 1 to 1
 
META TOPICPARENT name="CourseExercises"

Exercise 11: The LCD Display

Goal:

Line: 20 to 20
 In order to be able to program the device we must of course know, how the pcf8578 is connected to the hd4478 and it is the circuit diagram which shows us all the connections:

pcf8574ifce.png

Changed:
<
<

Exercise 1: Hello World

>
>

Exercise 1: Hello World version 1

Use the hd44780 library which contains most of the calls you may need to access the 2-line display. Try to write "Hello World!" onto the first line of the display.

You find the description of the library either in its source code when running doxygen in its source directory or, when connected to the Raspberry Pi at this URL:

file:///opt/ucc/exercises/solutions/hd44780/html/index.html

Then try to re-do the name display program we showed of during the Open Day: A program asks a visitor to type in his name.

Once he is done, the program writes:

DCSIT welcomes

name of the visitor

Exercise 2: Hello World version 2

Try to write Hello World to the display but this time without passing through my library.

  This “Hello World!” program is a bit more complex than what you may know from your C programming course. The goal is to display the text “Hello World!” on the LCD display.

Exercise2: A small display library

Revision 12017-08-20 - uli

Line: 1 to 1
Added:
>
>
META TOPICPARENT name="CourseExercises"

Exercise 11: The LCD Display

Goal:

The main goal of this exercise is to prepare for an exercises on Analogue to Digital Conversion (ADC). In the ADC exercise we will convert analogue signal levels (or real time analogue signals) and the results must be displayed somehow. This can of course be done on a terminal display but it is much nicer to see the results on a dedicated LCD display.

In conjunction with analogue to digital conversion we can easily build our own voltmeter.

The display consists of 2 parts: The display proper controlled by a hd4478 and the interface part. It is possible to connect the display part straight to the GPIO lines of the Raspberry Pi, however this would require plenty of wiring. We therefore use a pcf8574 8-bit I/O expander, which can be considered a sort of serial to parallel converted. With only 4 connections (the usual I2C SDA SCL lines + power and gnd) we can generate 8 I/O lines to drive the hd4478 display controller.

2linedisplay.png

The LCD Display

i2c_pcf8574.png

The pcf8574 8bit I/O expander

In order to be able to program the device we must of course know, how the pcf8578 is connected to the hd4478 and it is the circuit diagram which shows us all the connections:

pcf8574ifce.png

Exercise 1: Hello World

This “Hello World!” program is a bit more complex than what you may know from your C programming course. The goal is to display the text “Hello World!” on the LCD display.

Exercise2: A small display library

Create a display library, which allows its user to write any text to any of the 2 lines on the display. This library you will use in a later exercise, when you will build a voltmeter. Of course you must also write a test application to make sure your library calls all work as expected.

-- Uli Raich - 2017-08-20

Comments

<--/commentPlugin-->

META FILEATTACHMENT attachment="2linedisplay.png" attr="" comment="" date="1503219633" name="2linedisplay.png" path="2linedisplay.png" size="894036" user="uli" version="1"
META FILEATTACHMENT attachment="i2c_pcf8574.png" attr="" comment="" date="1503219642" name="i2c_pcf8574.png" path="i2c_pcf8574.png" size="1038370" user="uli" version="1"
META FILEATTACHMENT attachment="pcf8574ifce.png" attr="" comment="" date="1503219643" name="pcf8574ifce.png" path="pcf8574ifce.png" size="65250" user="uli" version="1"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback