Presentation is loading. Please wait.

Presentation is loading. Please wait.

ATV INSTRUMENTATION DISPLAY System Software Design Ed Raezer.

Similar presentations


Presentation on theme: "ATV INSTRUMENTATION DISPLAY System Software Design Ed Raezer."— Presentation transcript:

1 ATV INSTRUMENTATION DISPLAY System Software Design Ed Raezer

2 General System Design  Motorola MC9S12C32 w/ 32k Bytes EEPROM, 2K Bytes RAM  16 MHz Bus Frequency  Memory Requirements for Project 8K ROM, 1K RAM

3 Kernel Selection  Kernel Choice: MicroC/OS-II Real-time preemptive multitasking kernel with a 1 ms tick period  Configured for my program Modify (os_cfg.h)

4 Task Priority 4- Start Task 5- User Interface 6- RPM Task 7- Speed Task 8- Clock Task

5 Start Task Description: -Initializations -Creates Tasks -Priority #4 -Period: once (at startup) -Execution time: 200 msec

6 Clock Task Description: -Retrieves time from RTC -Updates time buffer -Period: 1 sec (Periodic) -Execution Time: 35 usec -L =.000035

7 User Interface Task Description: -Monitors the buttons -Sets Clock -Activates LEDs -Changes Display Modes -Execution Time: 1 msec -Period: 10 ms -L =.1

8 RPM Task Description: -Retrieves pulse count from pulse accumulator and converts to RPMs -Updates RPM buffer -Period: 500 msec -Execution Time: 20 usec -L =.00004

9 Speed Task Description: -Monitors wheel sensor, counts pulses and converts to speed and distance -Updates odometer -Updates speed buffer -Execution time: 20 usec -Period: quick as 50msec (ISR driven) -L =.0004

10 ISR  Creates a semaphore everytime a wheel sensor pulse is detected so Wheel Task can run  Period: up to 50 msec  Execution time: 300 nsec  L =.000006

11 CPU Load L =.000035+.1+.00004+.0004+.000006 =.100481 L MAX = 10.05%

12 Modules and Functions TasksPublic Functions and Data Main.cStart Task, Speed Task RPM Task, User Int. Task Clock Task Lcd.c LcdInit(), LcdClrLine() written by Todd Morton LcdClrDisp(), LcdDispChar() LcdDispByte(), LcdDispStrg() LcdMoveCursor() LcdDispTime(), LcdFSpace() LcdCursor(), LcdBSpace() RTC_DRIVER.c RTCInit() written by Todd Morton RTCXfr() OCDelay.c OCDlyInit() written by Todd Morton OCDelay(),GetmSCnt() 9S12C32Start.c _Startup() written by Todd Morton

13 Dataflow Diagram


Download ppt "ATV INSTRUMENTATION DISPLAY System Software Design Ed Raezer."

Similar presentations


Ads by Google