RTOS homework 4

Dependencies:   C12832_lcd mbed

Files at this revision

API Documentation at this revision

Comitter:
gatedClock
Date:
Sun Aug 18 19:08:29 2013 +0000
Parent:
14:fb4c76ac43a1
Child:
16:d7bbd641929c
Commit message:
deleted mbed-rtos library, and things started working again.

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed-rtos.lib Show diff for this revision Revisions of this file
--- a/main.cpp	Sun Aug 18 19:02:25 2013 +0000
+++ b/main.cpp	Sun Aug 18 19:08:29 2013 +0000
@@ -32,8 +32,8 @@
 
 -----includes-----------------------------------//----------------------------*/
     #include "mbed.h"                           // mbed class.
+//  #include "rtos.h"
     #include "C12832_lcd.h"                     // LCD class.
-    #include "rtos.h"
 //---defines------------------------------------//------------------------------
     #define LCD1 lcd.locate(0, 0);              // LCD line 1.
     #define LCD2 lcd.locate(0,11);              // LCD line 2.
@@ -89,7 +89,6 @@
     void ISR_left_falling();
     void ISR_center();
     void turn_off_metronome();
-    void thread_start_display(void const *);
 //==============================================//==============================
     int main(void) 
     {
@@ -107,11 +106,10 @@
       initialization();
       
                                                       // metronome ticker.
-//      tickerMetronome.attach(&interrupt_service_M,fMetroDelay);
+      tickerMetronome.attach(&interrupt_service_M,fMetroDelay);
       
-      Thread threadDisplay(thread_start_display);
-      
-  
+                                                // LCD ticker.
+      tickerLCD.attach(&lcd_display,LCDSAMPLERATE);  
       
       while(1)
       {
@@ -302,12 +300,4 @@
     void led3_off(void) {led3 = 0;}             // turn off the LED.
 /*----------------------------------------------//----------------------------*/
     void led3_on( void) {led3 = 1;}             // turn on the led.
-/*----------------------------------------------//----------------------------*/
-    void thread_start_display(void const *)
-    {
-                                                    // LCD ticker.
-      tickerLCD.attach(&lcd_display,LCDSAMPLERATE);
-    
-    }
-/*----------------------------------------------//----------------------------*/
- 
\ No newline at end of file
+/*----------------------------------------------//----------------------------*/
\ No newline at end of file
--- a/mbed-rtos.lib	Sun Aug 18 19:02:25 2013 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-https://mbed.org/users/mbed_official/code/mbed-rtos/#869ef732a8a2