bae integrated final (may be)

Dependencies:   mbed-rtos mbed

Fork of BAE_FRDMTESIN2 by Seeker of Truth ,

fault.cpp

Committer:
sakthipriya
Date:
2014-12-03
Revision:
3:02b45de29c0f
Parent:
2:80b8a2e999f7
Child:
4:8f6c24eca109

File content as of revision 3:02b45de29c0f:

#include "fault.h"
#include "HK.h"


DigitalIn fault1(FAULT1);
DigitalIn fault2(FAULT2);
DigitalIn fault3(FAULT3);
DigitalIn fault4(FAULT4);
DigitalIn fault5(FAULT5);
DigitalIn fault6(FAULT6);
DigitalIn fault7(FAULT7);
DigitalIn fault8(FAULT8);


DigitalOut clear1(FAULT_CLEAR1);
DigitalOut clear2(FAULT_CLEAR2);
DigitalOut clear3(FAULT_CLEAR3);
DigitalOut clear4(FAULT_CLEAR4);
DigitalOut clear5(FAULT_CLEAR5);
DigitalOut clear6(FAULT_CLEAR6);
DigitalOut clear7(FAULT_CLEAR7);
DigitalOut clear8(FAULT_CLEAR8);


BusOut clear(FAULT_CLEAR1,FAULT_CLEAR2,FAULT_CLEAR3,FAULT_CLEAR4,FAULT_CLEAR5,FAULT_CLEAR6,FAULT_CLEAR7,FAULT_CLEAR8);
extern SensorData Sensor;

void FAULTS()
{
    
        printf("Entered Fault management \n");
        clear1 = !fault1; 
        clear2 = !fault2; 
        clear3 = !fault3; 
        clear4 = !fault4; 
        clear5 = !fault5; 
        clear6 = !fault6; 
        clear7 = !fault7; 
        clear8 = !fault8; 
        Sensor.fault = clear;
        printf(" %d \n",Sensor.fault);
        
}