yuto kawamura
/
George_Slave_BOTHMOVE
right and left move at the same time
debug/debug.h@9:ac95473a5d86, 2019-05-08 (annotated)
- Committer:
- shimizuta
- Date:
- Wed May 08 02:56:21 2019 +0000
- Revision:
- 9:ac95473a5d86
get gerege
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
shimizuta | 9:ac95473a5d86 | 1 | /** @file |
shimizuta | 9:ac95473a5d86 | 2 | *@brief デバッグ(teraterm表示)用のファイルです.DEBUG(引数);と打つとデバッグされます. |
shimizuta | 9:ac95473a5d86 | 3 | *本ヘッダファイル内のDEBUG_ONをdefineしなければと全てのデバッグ機能をなくすことが出来ます. |
shimizuta | 9:ac95473a5d86 | 4 | */ |
shimizuta | 9:ac95473a5d86 | 5 | #ifndef TEMPLATE_COMMON_DEBUG_DEBUG_H |
shimizuta | 9:ac95473a5d86 | 6 | #define TEMPLATE_COMMON_DEBUG_DEBUG_H |
shimizuta | 9:ac95473a5d86 | 7 | #include "mbed.h" |
shimizuta | 9:ac95473a5d86 | 8 | //#define DEBUG_ON//デバッグ用。使わないときはコメントアウト |
shimizuta | 9:ac95473a5d86 | 9 | |
shimizuta | 9:ac95473a5d86 | 10 | #ifdef DEBUG_ON |
shimizuta | 9:ac95473a5d86 | 11 | extern Serial pc; |
shimizuta | 9:ac95473a5d86 | 12 | //printf(...)と同義 |
shimizuta | 9:ac95473a5d86 | 13 | #define DEBUG(...) pc.printf("" __VA_ARGS__); |
shimizuta | 9:ac95473a5d86 | 14 | #else |
shimizuta | 9:ac95473a5d86 | 15 | //DEBUGと言われても何もしない |
shimizuta | 9:ac95473a5d86 | 16 | #define DEBUG(...) |
shimizuta | 9:ac95473a5d86 | 17 | #endif |
shimizuta | 9:ac95473a5d86 | 18 | |
shimizuta | 9:ac95473a5d86 | 19 | |
shimizuta | 9:ac95473a5d86 | 20 | #endif |