00001 /* 00002 * Copyright (C) 2009 Libelium Comunicaciones Distribuidas S.L. 00003 * http://www.libelium.com 00004 * 00005 * This program is free software: you can redistribute it and/or modify 00006 * it under the terms of the GNU Lesser General Public License as published by 00007 * the Free Software Foundation, either version 2.1 of the License, or 00008 * (at your option) any later version. 00009 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU Lesser General Public License for more details. 00014 00015 * You should have received a copy of the GNU Lesser General Public License 00016 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00017 * 00018 * Version: 0.1 00019 * Design: David Gascón 00020 * Implementation: David Cuartielles, Alberto Bielsa 00021 */ 00022 00023 00024 #include <inttypes.h> 00025 #ifndef __WASPCONSTANTS_H__ 00026 #include "WaspConstants.h" 00027 #endif 00028 00029 /* EPR - Existing Peripheral Registers 00030 * contain information about which peripherals are 00031 * installed in the Wasp, the information should be 00032 * stored in the EEPROM coming from the factory 00033 */ 00034 00035 // EPRA contains LSB - PGPS|PSD|PACC|PXBEE|PRTC|PUSB|PSID|PSLOW_CLK - MSB 00036 uint8_t EPRA = 0; 00037 00038 // EPRB contains LSB - PGPRS|XX|XX|XX|XX|XX|XX|XX - MSB 00039 uint8_t EPRB = 0; 00040 00041 // Functions to read and test peripherals 00042 00043 // readEPRA copies the values from the EEPROM into the EEPRA register 00044 // answers 0 for normal operation 00045 uint8_t readEPRA() { 00046 } 00047 00048 // readEPRB copies the values from the EEPROM into the EEPRB register 00049 // answers 0 for normal operation 00050 uint8_t readEPRB() { 00051 } 00052 00053 // testPeripherals checks whether the information in the EEPROM corresponds 00054 // to the peripherals on the board through running a test on each one of them 00055 // the different test functions will print directly to the USB and one LED will 00056 // show through quick blinking if there was an error 00057 uint8_t testPeripherals() { 00058 }
1.5.6