Shivanand Gowda / RS485

Dependents:   Multiple_7SegDisplays

Fork of RS485 by Stefan Mueller

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers RS485.cpp Source File

RS485.cpp

00001 #include "RS485.h"
00002 
00003 RS485::RS485(PinName tx, PinName rx, PinName mode, const char *name) : Serial( tx, rx, name), m_modePin(mode)
00004 {   
00005     m_modePin = 0;
00006 }
00007 
00008 int RS485::_getc() { 
00009     return _base_getc();
00010 }
00011 
00012 int RS485::_putc(int c) {
00013     m_modePin = 1;
00014     int ret = _base_putc(c);
00015     m_modePin = 0;
00016     return ret;
00017 }
00018