mbed library for NZ32-SC151

Committer:
modtronix-com
Date:
Thu Sep 10 20:14:29 2015 +1000
Revision:
11:8123a070ade6
Parent:
1:71204b8406f2
Added .hgignore

Who changed what in which revision?

UserRevisionLine numberNew contents of line
modtronix 1:71204b8406f2 1 /* mbed Microcontroller Library
modtronix 1:71204b8406f2 2 * Copyright (c) 2006-2013 ARM Limited
modtronix 1:71204b8406f2 3 *
modtronix 1:71204b8406f2 4 * Licensed under the Apache License, Version 2.0 (the "License");
modtronix 1:71204b8406f2 5 * you may not use this file except in compliance with the License.
modtronix 1:71204b8406f2 6 * You may obtain a copy of the License at
modtronix 1:71204b8406f2 7 *
modtronix 1:71204b8406f2 8 * http://www.apache.org/licenses/LICENSE-2.0
modtronix 1:71204b8406f2 9 *
modtronix 1:71204b8406f2 10 * Unless required by applicable law or agreed to in writing, software
modtronix 1:71204b8406f2 11 * distributed under the License is distributed on an "AS IS" BASIS,
modtronix 1:71204b8406f2 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
modtronix 1:71204b8406f2 13 * See the License for the specific language governing permissions and
modtronix 1:71204b8406f2 14 * limitations under the License.
modtronix 1:71204b8406f2 15 */
modtronix 1:71204b8406f2 16 #ifndef MBED_PINMAP_H
modtronix 1:71204b8406f2 17 #define MBED_PINMAP_H
modtronix 1:71204b8406f2 18
modtronix 1:71204b8406f2 19 #include "PinNames.h"
modtronix 1:71204b8406f2 20
modtronix 1:71204b8406f2 21 #ifdef __cplusplus
modtronix 1:71204b8406f2 22 extern "C" {
modtronix 1:71204b8406f2 23 #endif
modtronix 1:71204b8406f2 24
modtronix 1:71204b8406f2 25 typedef struct {
modtronix 1:71204b8406f2 26 PinName pin;
modtronix 1:71204b8406f2 27 int peripheral;
modtronix 1:71204b8406f2 28 int function;
modtronix 1:71204b8406f2 29 } PinMap;
modtronix 1:71204b8406f2 30
modtronix 1:71204b8406f2 31 void pin_function(PinName pin, int function);
modtronix 1:71204b8406f2 32 void pin_mode (PinName pin, PinMode mode);
modtronix 1:71204b8406f2 33
modtronix 1:71204b8406f2 34 uint32_t pinmap_peripheral(PinName pin, const PinMap* map);
modtronix 1:71204b8406f2 35 uint32_t pinmap_function(PinName pin, const PinMap* map);
modtronix 1:71204b8406f2 36 uint32_t pinmap_merge (uint32_t a, uint32_t b);
modtronix 1:71204b8406f2 37 void pinmap_pinout (PinName pin, const PinMap *map);
modtronix 1:71204b8406f2 38 uint32_t pinmap_find_peripheral(PinName pin, const PinMap* map);
modtronix 1:71204b8406f2 39 uint32_t pinmap_find_function(PinName pin, const PinMap* map);
modtronix 1:71204b8406f2 40
modtronix 1:71204b8406f2 41 #ifdef __cplusplus
modtronix 1:71204b8406f2 42 }
modtronix 1:71204b8406f2 43 #endif
modtronix 1:71204b8406f2 44
modtronix 1:71204b8406f2 45 #endif