C027_SupportTest_xively_locationで使用しているC027用ライブラリ
Fork of C027_Support by
下記のプログラムC027_SupportTest_xively_locationで使用しているC027用ライブラリです。
Import programC027_SupportTest_xively_location
インターフェース2014年10月号のu-blox C027で3G通信する記事で使用したプログラム。 CQ publishing Interface 2014.10 issue, C027 3G test program.
オリジナルのライブラリは下記を参照してください。
Import libraryC027_Support
support library for C027 helper functions for Buffer Pipes, Buffered Serial Port (rtos capable) and GPS parsing. It includes modem APIs for USSD, SMS and Sockets.
SerialPipe.h
- Committer:
- mazgch
- Date:
- 2013-11-19
- Revision:
- 13:e2446fcdc246
- Parent:
- 9:e7a5959ffae1
- Child:
- 14:69c3e57ef0f5
File content as of revision 13:e2446fcdc246:
#pragma once #include "mbed.h" #include "Pipe.h" class SerialPipe : public Serial { public: SerialPipe(PinName tx, PinName rx, int rxSize = 128, int txSize = 128, const char* name = NULL); virtual ~SerialPipe(void); // tx channel int writeable(void); int putc(int c); // blocking int put(const void* buffer, int length, bool blocking = false); // rx channel int readable(void); int getc(void); // blocking int get(void* buffer, int length, bool blocking = false); protected: virtual int _getc(); virtual int _putc(int c); void rxIrqBuf(void); void txIrqBuf(void); void txStart(void); Pipe<char> _pipeRx; Pipe<char> _pipeTx; }; // ----------------------------------------------------------------------- #define WAIT -1 #define NOT_FOUND 0 class SerialPipeEx : public SerialPipe { public: SerialPipeEx(PinName tx, PinName rx, int rxSize = 128, int txSize = 128, const char* name = NULL); int getLine(char* buffer, int length); };