Soundharrajan
Fork of mbed by
TARGET_ARCH_PRO/TARGET_NXP/TARGET_LPC176X/objects.h@85:024bf7f99721, 2014-06-11 (annotated)
- Committer:
- bogdanm
- Date:
- Wed Jun 11 15:14:05 2014 +0100
- Revision:
- 85:024bf7f99721
Release 85 of the mbed library
Main changes:
- K64F Ethernet fixes
- Updated tests
- Fixes for various mbed targets
- Code cleanup: fixed warnings, more consistent code style
- GCC support for K64F
There is a known issue with the I2C interface on some ST targets. If you
find the I2C interface problematic on your ST board, please log a bug
against this on mbed.org.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
bogdanm | 85:024bf7f99721 | 1 | /* mbed Microcontroller Library |
bogdanm | 85:024bf7f99721 | 2 | * Copyright (c) 2006-2013 ARM Limited |
bogdanm | 85:024bf7f99721 | 3 | * |
bogdanm | 85:024bf7f99721 | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
bogdanm | 85:024bf7f99721 | 5 | * you may not use this file except in compliance with the License. |
bogdanm | 85:024bf7f99721 | 6 | * You may obtain a copy of the License at |
bogdanm | 85:024bf7f99721 | 7 | * |
bogdanm | 85:024bf7f99721 | 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
bogdanm | 85:024bf7f99721 | 9 | * |
bogdanm | 85:024bf7f99721 | 10 | * Unless required by applicable law or agreed to in writing, software |
bogdanm | 85:024bf7f99721 | 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
bogdanm | 85:024bf7f99721 | 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
bogdanm | 85:024bf7f99721 | 13 | * See the License for the specific language governing permissions and |
bogdanm | 85:024bf7f99721 | 14 | * limitations under the License. |
bogdanm | 85:024bf7f99721 | 15 | */ |
bogdanm | 85:024bf7f99721 | 16 | #ifndef MBED_OBJECTS_H |
bogdanm | 85:024bf7f99721 | 17 | #define MBED_OBJECTS_H |
bogdanm | 85:024bf7f99721 | 18 | |
bogdanm | 85:024bf7f99721 | 19 | #include "cmsis.h" |
bogdanm | 85:024bf7f99721 | 20 | #include "PortNames.h" |
bogdanm | 85:024bf7f99721 | 21 | #include "PeripheralNames.h" |
bogdanm | 85:024bf7f99721 | 22 | #include "PinNames.h" |
bogdanm | 85:024bf7f99721 | 23 | #include "gpio_object.h" |
bogdanm | 85:024bf7f99721 | 24 | |
bogdanm | 85:024bf7f99721 | 25 | #ifdef __cplusplus |
bogdanm | 85:024bf7f99721 | 26 | extern "C" { |
bogdanm | 85:024bf7f99721 | 27 | #endif |
bogdanm | 85:024bf7f99721 | 28 | |
bogdanm | 85:024bf7f99721 | 29 | struct gpio_irq_s { |
bogdanm | 85:024bf7f99721 | 30 | uint32_t port; |
bogdanm | 85:024bf7f99721 | 31 | uint32_t pin; |
bogdanm | 85:024bf7f99721 | 32 | uint32_t ch; |
bogdanm | 85:024bf7f99721 | 33 | }; |
bogdanm | 85:024bf7f99721 | 34 | |
bogdanm | 85:024bf7f99721 | 35 | struct port_s { |
bogdanm | 85:024bf7f99721 | 36 | __IO uint32_t *reg_dir; |
bogdanm | 85:024bf7f99721 | 37 | __IO uint32_t *reg_out; |
bogdanm | 85:024bf7f99721 | 38 | __I uint32_t *reg_in; |
bogdanm | 85:024bf7f99721 | 39 | PortName port; |
bogdanm | 85:024bf7f99721 | 40 | uint32_t mask; |
bogdanm | 85:024bf7f99721 | 41 | }; |
bogdanm | 85:024bf7f99721 | 42 | |
bogdanm | 85:024bf7f99721 | 43 | struct pwmout_s { |
bogdanm | 85:024bf7f99721 | 44 | __IO uint32_t *MR; |
bogdanm | 85:024bf7f99721 | 45 | PWMName pwm; |
bogdanm | 85:024bf7f99721 | 46 | }; |
bogdanm | 85:024bf7f99721 | 47 | |
bogdanm | 85:024bf7f99721 | 48 | struct serial_s { |
bogdanm | 85:024bf7f99721 | 49 | LPC_UART_TypeDef *uart; |
bogdanm | 85:024bf7f99721 | 50 | int index; |
bogdanm | 85:024bf7f99721 | 51 | }; |
bogdanm | 85:024bf7f99721 | 52 | |
bogdanm | 85:024bf7f99721 | 53 | struct analogin_s { |
bogdanm | 85:024bf7f99721 | 54 | ADCName adc; |
bogdanm | 85:024bf7f99721 | 55 | }; |
bogdanm | 85:024bf7f99721 | 56 | |
bogdanm | 85:024bf7f99721 | 57 | struct dac_s { |
bogdanm | 85:024bf7f99721 | 58 | DACName dac; |
bogdanm | 85:024bf7f99721 | 59 | }; |
bogdanm | 85:024bf7f99721 | 60 | |
bogdanm | 85:024bf7f99721 | 61 | struct can_s { |
bogdanm | 85:024bf7f99721 | 62 | LPC_CAN_TypeDef *dev; |
bogdanm | 85:024bf7f99721 | 63 | int index; |
bogdanm | 85:024bf7f99721 | 64 | }; |
bogdanm | 85:024bf7f99721 | 65 | |
bogdanm | 85:024bf7f99721 | 66 | struct i2c_s { |
bogdanm | 85:024bf7f99721 | 67 | LPC_I2C_TypeDef *i2c; |
bogdanm | 85:024bf7f99721 | 68 | }; |
bogdanm | 85:024bf7f99721 | 69 | |
bogdanm | 85:024bf7f99721 | 70 | struct spi_s { |
bogdanm | 85:024bf7f99721 | 71 | LPC_SSP_TypeDef *spi; |
bogdanm | 85:024bf7f99721 | 72 | }; |
bogdanm | 85:024bf7f99721 | 73 | |
bogdanm | 85:024bf7f99721 | 74 | #ifdef __cplusplus |
bogdanm | 85:024bf7f99721 | 75 | } |
bogdanm | 85:024bf7f99721 | 76 | #endif |
bogdanm | 85:024bf7f99721 | 77 | |
bogdanm | 85:024bf7f99721 | 78 | #endif |