1 / 15

Safety dB Meter Software Review

Safety dB Meter Software Review. ETec 474 By Polly Leung. Kernel Selection and Task/ISR Design. MicroC/OS-II StartTask KeyTask UITask OSTickISR. StartTask. Priority 4 Initialization Create other tasks Once only. KeyTask. Priority 5 It is for detecting and verifying key presses.

buck
Download Presentation

Safety dB Meter Software Review

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Safety dB Meter Software Review ETec 474 By Polly Leung

  2. Kernel Selectionand Task/ISR Design • MicroC/OS-II • StartTask • KeyTask • UITask • OSTickISR

  3. StartTask • Priority 4 • Initialization • Create other tasks • Once only

  4. KeyTask • Priority 5 • It is for detecting and verifying key presses. • Period=10ms • Average execution time =3.3us • Peak execution time=16.6us • It is written by Profession Morton, and I modified it to fit my project.

  5. UITask • Priority 7 • This task handles the data come from the ATD port. • It modulates the pulse width output to the LCD and turns LEDs on and off. • Periodic • Period=50ms • Estimated peak execution time= 1ms

  6. OSTickISR • MicroC/OS-II clock ticks • OSTimeDly()

  7. CPU Load • Worst case = 16.6us/10ms+ 1ms/50ms = 0.0217

  8. Module/Library Description • dBmeter.c • Key.c • PWM.c • AToD.c

  9. Main ( ) StartTask( ) UITask( ) Key Level Peak dBmeter.cFunctions Variables

  10. KeyInit( ) KeyPend( ) GetKey( ) KeyTask( ) KeyScan( ) KeyBuffer key cur_key button err Key.cFunctionsVariables

  11. PWMInit( ) ChangePWM( ) Intensity PWM.cFunctionsVariables

  12. AToDInit( ) AToDRead( ) level AToD.cFunctionsVariables

  13. Key Module Pushbuttons Functions Tp KeyInit( ) KeyTask( ) Key.buffer KeyPend( ) Key.flag

  14. KeyTask( ) KeyPend( ) UITask Key.buffer OSSemPost( ) Key.flag OSSemPend( )

  15. A-to-D I/O Function A to D converter AN0 AToDRead( ) ATDDR0 PAD00

More Related