Petras Saduikis
/
WiiNunchuckReader
A program allowing the output of one or two Wii Nunchucks to be read via I2C and decoded for use.
Embed:
(wiki syntax)
Show/hide line numbers
I2CConfig.h
00001 /* 00002 * WiiNunchuckReader. A program allowing the output of one or two 00003 * Wii Nunchucks to be read via I2C and decoded for use, using the mbed 00004 * microcontroller and its associated libraries. 00005 * 00006 * Copyright (C) <2009> Petras Saduikis <petras@petras.co.uk> 00007 * 00008 * This file is part of WiiNunchuckReader. 00009 * 00010 * WiiNunchuckReader is free software: you can redistribute it and/or modify 00011 * it under the terms of the GNU General Public License as published by 00012 * the Free Software Foundation, either version 3 of the License, or 00013 * (at your option) any later version. 00014 * 00015 * WiiNunchuckReader is distributed in the hope that it will be useful, 00016 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00017 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00018 * GNU General Public License for more details. 00019 * 00020 * You should have received a copy of the GNU General Public License 00021 * along with WiiNunchuckReader. If not, see <http://www.gnu.org/licenses/>. 00022 */ 00023 00024 #ifndef SNATCH59_I2CCONFIG_H 00025 #define SNATCH59_I2CCONFIG_H 00026 00027 #include <mbed.h> 00028 00029 class I2CPort_A 00030 { 00031 public: 00032 static const PinName SDA; 00033 static const PinName SCL; 00034 }; 00035 00036 00037 class I2CPort_B 00038 { 00039 public: 00040 static const PinName SDA; 00041 static const PinName SCL; 00042 }; 00043 00044 const PinName I2CPort_A::SDA = p9; 00045 const PinName I2CPort_A::SCL = p10; 00046 00047 const PinName I2CPort_B::SDA = p28; 00048 const PinName I2CPort_B::SCL = p27; 00049 00050 #endif
Generated on Tue Jul 12 2022 21:00:58 by 1.7.2