Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Socket lwip-sys lwip
Fork of AbitUSBModem by
Diff: serial/io/IOSerialStream.h
- Revision:
- 100:dbd92e9515ef
- Parent:
- 96:b50f5f795684
--- a/serial/io/IOSerialStream.h Wed Feb 25 14:34:13 2015 +0000
+++ b/serial/io/IOSerialStream.h Mon May 11 14:07:07 2015 +0000
@@ -1,4 +1,7 @@
/* IOSerialStream.h */
+/* Modified by 2015 phsfan
+ * for ABIT SMA-01
+ */
/* Copyright (C) 2012 mbed.org, MIT License
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software
@@ -21,7 +24,7 @@
#include "core/fwk.h"
-#include "Serial.h"
+#include "RawSerial.h"
#include "rtos.h"
#include "MtxCircBuffer.h"
@@ -33,7 +36,7 @@
class IOSerialStream : public IOStream
{
public:
- IOSerialStream(mbed::Serial& serial);
+ IOSerialStream(mbed::RawSerial& serial);
/*virtual*/ ~IOSerialStream();
//0 for non-blocking (returns immediately), osWaitForever for infinite blocking
@@ -51,9 +54,15 @@
private:
- mbed::Serial& m_serial;
+ mbed::RawSerial& m_serial;
volatile bool m_serialTxFifoEmpty;
+#if defined(TARGET_LPC176X) || defined(TARGET_LPC408X) || defined(TARGET_LPC2368)
+ LPC_UART1_TypeDef *_uart;
+#elif defined(TARGET_LPC11UXX)
+ LPC_USART_Type *_uart;
+#endif
+
void setupReadableISR(bool en);
void readable(); //Callback from m_serial when new data is available
