00001 /* 00002 * $Id: ex1_menu.h,v 1 2004/26/07 8:00:00 BorisK Exp $ 00003 * 00004 * Copyright (C) 2005 ONTRACK s.r.o. 00005 * 00006 * This program is free software; you can redistribute it and/or 00007 * modify it under the terms of the GNU General Public License 00008 * as published by the Free Software Foundation; either version 2 00009 * of the License, or (at your option) any later version. 00010 * 00011 * This program is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU Generae Public License 00017 * along with this program; if not, write to the Free Software 00018 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 00019 * 02111-1307, USA. 00020 * 00021 * [1] ARM-based Microcontroller LPC2119/2129/2194/2292/9994, "Preliminary User Manual", February 03, 2004 00022 * 00023 * Written by Boris Kralik <kralikbo@yahoo.com>, 2004. 00024 * 00025 */ 00026 00027 00028 00029 00030 00031 00032 00033 00034 #ifndef EX1_H 00035 #define EX1_H 00036 00037 #define PLLCFG 0x60 // P=2, M=2 00038 #define VPDIV 0x02 // VPBDIV = 2 00039 00040 #define DBG 1 00041 #define MAX 100 00042 // 100: 171 232Hz tr=8.84us 12.67% 00043 // tf=0.24us 00044 #define MIN 1 00045 #define INC 5 00046 00047 #define WD_TIME 0xFFFFF 00048 00049 #include "status.h" 00050 #include "types.h" 00051 #include "Ports.h" 00052 #include "lpc2119.h" 00053 #include "lpcVIC.h" 00054 #include "types.h" 00055 #include "uart.h" 00056 #include "CAN.h" 00057 #include "jtag.h" 00058 #include "pll.h" 00059 #include "sysTime.h" 00060 #include "Interrupt.h" 00061 #include "printf.h" 00062 #include "WD.h" 00063 #include "I2C.h" 00064 #include "AnalogDevices.h" 00065 #include "Ramtron.h" 00066 #include "maxim.h" 00067 #include "MAM.h" 00068 #include "./example1/delay/delay.h" 00069 #include "Directive.h" 00070 00071 #define UP1 1 //Philips 1 - Cabine front 00072 #define UP2 2 //Philips 2 - Cabine back 00073 00074 #define AI0 100 00075 #define AI1 101 00076 #define AI2 102 00077 #define AI3 103 00078 #define AI4 104 00079 #define AI5 105 00080 #define AI6 106 00081 #define AI7 107 00082 #define AD_OFFSET 0x64 // Vce(sat) 00083 #define FALSE 0 00084 #define TRUE 1 00085 00086 #define VER "1.3\x0" 00087 #define HELP "\n\rex1\n\r\ti[init]\n\r\t0[read temperature]\n\r\tr[CAN]\n\r\tm[Ramtron]\n\r\tt[StartTimer]\n\r\t+/-[delay+/-]\n\r\ts[stoptimer]\n\r\ta[AD5382/91]\n\r\t[d]digital output\n\r\t[l]AIMenu\n\r\t[o]Off\n\r\t[b]status\n\r\t[f]flash" 00088 00089 int iI2CStatus; //status peripherial, I2C, CAN 1,2,4 00090 /* 1/0 - true/false 00091 C1 - CAN1 00092 C2 - CAN2 00093 C4 - CAN4 00094 */ 00095 typedef struct tTemp{ 00096 short S1,S2; 00097 }pTemp; 00098 pCAN_R *CAN; 00099 00100 void LUT_interrupt(); 00101 void TIMER0_Int(); 00102 void TIMER1_Int(); 00103 void CAN1_Rx_IntRoutine(); 00104 void CAN1_Tx_IntRoutine(); 00105 pTemp T; 00106 int iAddress; 00107 uint16_t CansInit(uint16_t); 00108 uint16_t GetStatus(void); 00109 pCFI cfi; 00110 pJEDEC jedec; 00111 #endif
1.4.7