A simple 128x32 graphical LCD program to quickstart with LCD on ARM mbed IoT Starter Kit. This requires mbed Applciation Shield with FRDM-K64F platform.

Dependencies:   C12832

Committer:
tushki7
Date:
Sun Apr 12 15:45:52 2015 +0000
Revision:
1:eb68c94a8ee5
Parent:
0:60d829a0353a
A simple 128x32 LCD program with ARM mbed IoT Starter Kit;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
tushki7 0:60d829a0353a 1 /* mbed Microcontroller Library
tushki7 0:60d829a0353a 2 * Copyright (c) 2006-2013 ARM Limited
tushki7 0:60d829a0353a 3 *
tushki7 0:60d829a0353a 4 * Licensed under the Apache License, Version 2.0 (the "License");
tushki7 0:60d829a0353a 5 * you may not use this file except in compliance with the License.
tushki7 0:60d829a0353a 6 * You may obtain a copy of the License at
tushki7 0:60d829a0353a 7 *
tushki7 0:60d829a0353a 8 * http://www.apache.org/licenses/LICENSE-2.0
tushki7 0:60d829a0353a 9 *
tushki7 0:60d829a0353a 10 * Unless required by applicable law or agreed to in writing, software
tushki7 0:60d829a0353a 11 * distributed under the License is distributed on an "AS IS" BASIS,
tushki7 0:60d829a0353a 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
tushki7 0:60d829a0353a 13 * See the License for the specific language governing permissions and
tushki7 0:60d829a0353a 14 * limitations under the License.
tushki7 0:60d829a0353a 15 */
tushki7 0:60d829a0353a 16 #ifndef MBED_GPIO_API_H
tushki7 0:60d829a0353a 17 #define MBED_GPIO_API_H
tushki7 0:60d829a0353a 18
tushki7 0:60d829a0353a 19 #include "device.h"
tushki7 0:60d829a0353a 20
tushki7 0:60d829a0353a 21 #ifdef __cplusplus
tushki7 0:60d829a0353a 22 extern "C" {
tushki7 0:60d829a0353a 23 #endif
tushki7 0:60d829a0353a 24
tushki7 0:60d829a0353a 25 /* Set the given pin as GPIO
tushki7 0:60d829a0353a 26 * @param pin The pin to be set as GPIO
tushki7 0:60d829a0353a 27 * @return The GPIO port mask for this pin
tushki7 0:60d829a0353a 28 **/
tushki7 0:60d829a0353a 29 uint32_t gpio_set(PinName pin);
tushki7 0:60d829a0353a 30
tushki7 0:60d829a0353a 31 /* Checks if gpio object is connected (pin was not initialized with NC)
tushki7 0:60d829a0353a 32 * @param pin The pin to be set as GPIO
tushki7 0:60d829a0353a 33 * @return 0 if port is initialized with NC
tushki7 0:60d829a0353a 34 **/
tushki7 0:60d829a0353a 35 int gpio_is_connected(const gpio_t *obj);
tushki7 0:60d829a0353a 36
tushki7 0:60d829a0353a 37 /* GPIO object */
tushki7 0:60d829a0353a 38 void gpio_init(gpio_t *obj, PinName pin);
tushki7 0:60d829a0353a 39
tushki7 0:60d829a0353a 40 void gpio_mode (gpio_t *obj, PinMode mode);
tushki7 0:60d829a0353a 41 void gpio_dir (gpio_t *obj, PinDirection direction);
tushki7 0:60d829a0353a 42
tushki7 0:60d829a0353a 43 void gpio_write(gpio_t *obj, int value);
tushki7 0:60d829a0353a 44 int gpio_read (gpio_t *obj);
tushki7 0:60d829a0353a 45
tushki7 0:60d829a0353a 46 // the following set of functions are generic and are implemented in the common gpio.c file
tushki7 0:60d829a0353a 47 void gpio_init_in(gpio_t* gpio, PinName pin);
tushki7 0:60d829a0353a 48 void gpio_init_in_ex(gpio_t* gpio, PinName pin, PinMode mode);
tushki7 0:60d829a0353a 49 void gpio_init_out(gpio_t* gpio, PinName pin);
tushki7 0:60d829a0353a 50 void gpio_init_out_ex(gpio_t* gpio, PinName pin, int value);
tushki7 0:60d829a0353a 51 void gpio_init_inout(gpio_t* gpio, PinName pin, PinDirection direction, PinMode mode, int value);
tushki7 0:60d829a0353a 52
tushki7 0:60d829a0353a 53 #ifdef __cplusplus
tushki7 0:60d829a0353a 54 }
tushki7 0:60d829a0353a 55 #endif
tushki7 0:60d829a0353a 56
tushki7 0:60d829a0353a 57 #endif