This page is located in archive. Go to the latest version of this course pages. Go the latest version of this page.

OLD_HW 05 - Multi-thread computation

  • Develop an app with threads, e.g.: lab06, where:
  • One (first) thread communicates with the user and manages the other threads:
    • Prints on the display and reads the keyboard.
    • Signals the other thread to finish.
    • Etc.
    • For this task, the main process thread can be used.
  • Another (second) thread should take care about communication over the serial line. This means mainly
    • Sending the commands.
    • Receiving data and assembling the responses and asynchronous data from the device.
    • Managing synchronization with the main app, and the data flow control thread.
  • Another (third) thread should be able to read the flow control file. This means mainly:
    • Properly process the directives: #label:,#include:, #wait_for_joystick:, #if:, #else, #goto, etc. - lab09.
    • Provide synchronization with the first thread and the main application.

These parameters of the program will be evaluated:

  • 2 points - the PC application is capable to start at least two threads - one for data reception from serial line and one capable to open a display a text file.
  • 1 point - the PC application will show the menu and it is able to react on the keyboard selections, a command to be send is “*IDN?”
  • 1 point - the PC program ends based on 'e' (exit] option selection - all the threads are properly finished (a signal is sent to the threads)
  • 1 point - the thread to receive data from the serial line is capable to recognize the events from the joystick (send by Nucleo) and signal the thread depicting the menu to the user the data from the Nucleo arrived.
  • 1 point - the menu interface is capable to pass a name of the file to a thread (designated to read commands from file) and this thread is capable to read commands line by line from the file.
  • 1 point - the thread reading data/commands from the file can pass the data to the communication thread and this thread will send them over serial line to the Nucleo.
  • 3 points - the fiel reading thread can process #label, #include and #goto directives.
courses/be5b99cpl/hw/hw05.txt · Last modified: 2020/09/22 22:16 by pacesp