Assignment 1

Software programming a LED display

Assume the following hardware device is connected to the parallel port of the PC, with the data lines to the data bits (D0-D7), and the three decoding + one chip-select/enable lines to four control lines of the PC port.



The exact pinout is to be established in the lab.

  1. create the controlling software in order to display a decimal number (up to 10 digits). The display has to be refreshed more than 25 times/second in order to be perceived flicker-free (at least 60Hz would be better). Optionally, the software may display the numbers in hexadecimal base or letters.
  2. split the code into logical components such as sensors, tasks, actuators.
  3. write the E-Code of the application using the logical components previously defined (TDL source code is optional).

Notes:
The software must be easily portable to an embedded platform based on the MPC555 processor running OSEKWorks (OSEK/VDX compliant RTOS).

Hints:
Separate platform specific code such as IO Port addresses, bitmasks, timing code, in platform specific sections using macros (#define, #ifdef), or similar techniques. Testing sensors could be implemented as simple functions that return a random number.