#ifndef _TUNE_UP_PLANE_H
#define _TUNE_UP_PLANE_H

#include "DSP281x_Device.h"

void WriteOper(unsigned char oper_mode1,unsigned char oper_mode2, unsigned char oper_mode3, unsigned char oper_mode4);
void pause_1000(unsigned long t);
void XintfZone0_Timing(void);
void XintfZone6_And7_Timing(void);
void XintfZone2_Timing(void);
void FlashInit();

//extern void DSP28x_usDelay(long LoopCount);

void Led1_Toggle();
void Led2_Toggle();

void i_led2_on_off(int i);
void i_led1_on_off(int i);

void i_led2_on_off_special(int i);
void i_led1_on_off_special(int i);


#define i_led1_on()   {EALLOW;GpioDataRegs.GPASET.bit.GPIOA10 = 1;EDIS;}
#define i_led1_off()   {EALLOW;GpioDataRegs.GPACLEAR.bit.GPIOA10 = 1;;EDIS;}

#define i_led2_on()   {EALLOW;GpioDataRegs.GPDSET.bit.GPIOD6 = 1;EDIS;}
#define i_led2_off()   {EALLOW;GpioDataRegs.GPDCLEAR.bit.GPIOD6 = 1;;EDIS;}

#define i_led1_toggle()   {EALLOW; GpioDataRegs.GPATOGGLE.bit.GPIOA10 = 1; EDIS;}
#define i_led2_toggle()   {EALLOW; GpioDataRegs.GPDTOGGLE.bit.GPIOD6  = 1; EDIS;}



void SetupLedsLine();

#endif
