Paul Paterson / mbed-dev

Fork of mbed-dev by mbed official

Committer:
ptpaterson
Date:
Thu Nov 03 16:21:53 2016 +0000
Revision:
150:cd63f849362a
Parent:
149:156823d33999
targets LPC11Cxx, LPC15xx:  can_api can_filter function properly returns 0 if handle argument is out of bounds (handle > 32).

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mbed_official 121:7f86b4238bec 1 /* mbed Microcontroller Library
mbed_official 121:7f86b4238bec 2 * Copyright (c) 2006-2013 ARM Limited
mbed_official 121:7f86b4238bec 3 *
mbed_official 121:7f86b4238bec 4 * Licensed under the Apache License, Version 2.0 (the "License");
mbed_official 121:7f86b4238bec 5 * you may not use this file except in compliance with the License.
mbed_official 121:7f86b4238bec 6 * You may obtain a copy of the License at
mbed_official 121:7f86b4238bec 7 *
mbed_official 121:7f86b4238bec 8 * http://www.apache.org/licenses/LICENSE-2.0
mbed_official 121:7f86b4238bec 9 *
mbed_official 121:7f86b4238bec 10 * Unless required by applicable law or agreed to in writing, software
mbed_official 121:7f86b4238bec 11 * distributed under the License is distributed on an "AS IS" BASIS,
mbed_official 121:7f86b4238bec 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
mbed_official 121:7f86b4238bec 13 * See the License for the specific language governing permissions and
mbed_official 121:7f86b4238bec 14 * limitations under the License.
mbed_official 121:7f86b4238bec 15 */
mbed_official 121:7f86b4238bec 16 #ifndef MBED_GPIO_OBJECT_H
mbed_official 121:7f86b4238bec 17 #define MBED_GPIO_OBJECT_H
mbed_official 121:7f86b4238bec 18
mbed_official 121:7f86b4238bec 19 #ifdef __cplusplus
mbed_official 121:7f86b4238bec 20 extern "C" {
mbed_official 121:7f86b4238bec 21 #endif
mbed_official 121:7f86b4238bec 22
mbed_official 121:7f86b4238bec 23 typedef struct {
mbed_official 121:7f86b4238bec 24 PinName pin;
mbed_official 121:7f86b4238bec 25 } gpio_t;
mbed_official 121:7f86b4238bec 26
mbed_official 121:7f86b4238bec 27 static inline int gpio_is_connected(const gpio_t *obj) {
mbed_official 121:7f86b4238bec 28 return obj->pin != (PinName)NC;
mbed_official 121:7f86b4238bec 29 }
mbed_official 121:7f86b4238bec 30
mbed_official 121:7f86b4238bec 31 #ifdef __cplusplus
mbed_official 121:7f86b4238bec 32 }
mbed_official 121:7f86b4238bec 33 #endif
mbed_official 121:7f86b4238bec 34
mbed_official 121:7f86b4238bec 35 #endif