Running multiple threads on mbed using RTOS

Dependencies:   4DGL-uLCD-SE SDFileSystem mbed-rtos mbed wave_player_appbd

Committer:
wschon
Date:
Sun Feb 28 22:40:13 2016 +0000
Revision:
1:2129bb91c172
Added USB libraries;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
wschon 1:2129bb91c172 1 /* mbed USBHost Library
wschon 1:2129bb91c172 2 * Copyright (c) 2006-2013 ARM Limited
wschon 1:2129bb91c172 3 *
wschon 1:2129bb91c172 4 * Licensed under the Apache License, Version 2.0 (the "License");
wschon 1:2129bb91c172 5 * you may not use this file except in compliance with the License.
wschon 1:2129bb91c172 6 * You may obtain a copy of the License at
wschon 1:2129bb91c172 7 *
wschon 1:2129bb91c172 8 * http://www.apache.org/licenses/LICENSE-2.0
wschon 1:2129bb91c172 9 *
wschon 1:2129bb91c172 10 * Unless required by applicable law or agreed to in writing, software
wschon 1:2129bb91c172 11 * distributed under the License is distributed on an "AS IS" BASIS,
wschon 1:2129bb91c172 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
wschon 1:2129bb91c172 13 * See the License for the specific language governing permissions and
wschon 1:2129bb91c172 14 * limitations under the License.
wschon 1:2129bb91c172 15 */
wschon 1:2129bb91c172 16
wschon 1:2129bb91c172 17 #ifndef USB_DEBUG_H
wschon 1:2129bb91c172 18 #define USB_DEBUG_H
wschon 1:2129bb91c172 19
wschon 1:2129bb91c172 20 //Debug is disabled by default
wschon 1:2129bb91c172 21 #define DEBUG 0
wschon 1:2129bb91c172 22 #define DEBUG_TRANSFER 0
wschon 1:2129bb91c172 23 #define DEBUG_EP_STATE 0
wschon 1:2129bb91c172 24 #define DEBUG_EVENT 0
wschon 1:2129bb91c172 25
wschon 1:2129bb91c172 26 #if (DEBUG)
wschon 1:2129bb91c172 27 #define USB_DBG(x, ...) std::printf("[USB_DBG: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 28 #else
wschon 1:2129bb91c172 29 #define USB_DBG(x, ...)
wschon 1:2129bb91c172 30 #endif
wschon 1:2129bb91c172 31
wschon 1:2129bb91c172 32 #if (DEBUG_TRANSFER)
wschon 1:2129bb91c172 33 #define USB_DBG_TRANSFER(x, ...) std::printf("[USB_TRANSFER: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 34 #else
wschon 1:2129bb91c172 35 #define USB_DBG_TRANSFER(x, ...)
wschon 1:2129bb91c172 36 #endif
wschon 1:2129bb91c172 37
wschon 1:2129bb91c172 38 #if (DEBUG_EVENT)
wschon 1:2129bb91c172 39 #define USB_DBG_EVENT(x, ...) std::printf("[USB_EVENT: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 40 #else
wschon 1:2129bb91c172 41 #define USB_DBG_EVENT(x, ...)
wschon 1:2129bb91c172 42 #endif
wschon 1:2129bb91c172 43
wschon 1:2129bb91c172 44 #define USB_INFO(x, ...) std::printf("[USB_INFO: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 45 #define USB_WARN(x, ...) std::printf("[USB_WARNING: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 46 #define USB_ERR(x, ...) std::printf("[USB_ERR: %s:%d]"x"\r\n", __FILE__, __LINE__, ##__VA_ARGS__);
wschon 1:2129bb91c172 47
wschon 1:2129bb91c172 48 #endif
wschon 1:2129bb91c172 49
wschon 1:2129bb91c172 50
wschon 1:2129bb91c172 51