Add TwoWire::write(const char *) (#56)

This commit is contained in:
Drake Youngkun Min 2016-11-17 19:33:42 +09:00 committed by Me No Dev
parent 7abb15ca62
commit c0266615d5

View File

@ -71,6 +71,10 @@ public:
int peek(void); int peek(void);
void flush(void); void flush(void);
inline size_t write(const char * s)
{
return write((uint8_t*) s, strlen(s));
}
inline size_t write(unsigned long n) inline size_t write(unsigned long n)
{ {
return write((uint8_t)n); return write((uint8_t)n);
@ -92,4 +96,3 @@ public:
extern TwoWire Wire; extern TwoWire Wire;
#endif #endif