Skip to content

๐Ÿ”„ A thread switching package which targets at Edsim51 simulator.

Notifications You must be signed in to change notification settings

kuanhungchen/Fall-2019-Operating-Systems

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Fall-2019-Operating-Systems

Implementation of a multi-threading package in C language and some test-cases.

Requirements

You need Edsim51 to simulate 8051 processor and SDCC to generate Edsim51-targeted files.

  • Edsim51

    • From http://edsim51.com/
    • Runs as a Java app
    • DI version simulates a complete embedded system
    • LCD, LEDs, keypad, bank of buttons, ADC, DAC
    • cycle-accurate processor
  • SDCC for Edsim51

Contents

ppc stands for programming project checkpoint.

  • ppc 1: cooperative thread-switching
  • ppc 2: preemptive thread-switching
  • ppc 3: semaphore + bounded-buffer example
  • ppc 4: two producers and one consumer example
  • ppc 5: delay function + parking lot example

Each ppc is based on the previous one.

Usage

  1. In each ppc directory, use make command to generate .hex file.

    1

    The warning 85 can be ignored.

  2. Click Load in Edsim51 simulator and select the generated .hex file.

    2

  3. Click Assm.

    3

  4. Now you can click Run to execute or Step to execute by one step.

    You can modify the Update Freq. to change the execution speed.

  5. If you modify the source code, then you need to use make clean to remove old .hex file and re-generate.

    4

Contact

Feel free to email me at khchen.me@gmail.com or open an issue here if you have any ideas.

About

๐Ÿ”„ A thread switching package which targets at Edsim51 simulator.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published