Skip to content

Commit 3f551e2

Browse files
docstrings: Minor fix in documented define name. (#246)
The `CODAL_SERIAL_IN_USE` macro does not exist, the `codal-core` `Serial::redirect()` method returns `DEVICE_SERIAL_IN_USE` instead. https://github.com/lancaster-university/codal-core/blob/a45ede432a646a0af86fbd89d9dd692689fb6fbd/source/driver-models/Serial.cpp#L842 Fixes #238
1 parent 78d1269 commit 3f551e2

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

inc/compat/MicroBitSerial.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ class MicroBitSerial : public NRF52Serial
109109
*
110110
* @param rx the new reception pin.
111111
*
112-
* @return CODAL_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
112+
* @return DEVICE_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
113113
*/
114114
int redirect(PinName tx, PinName rx);
115115

@@ -121,7 +121,7 @@ class MicroBitSerial : public NRF52Serial
121121
*
122122
* @param rx the new reception pin.
123123
*
124-
* @return CODAL_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
124+
* @return DEVICE_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
125125
*/
126126
int redirect(PinNumber tx, PinNumber rx);
127127

source/compat/MicroBitSerial.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ MicroBitSerial::MicroBitSerial(PinNumber tx, PinNumber rx, uint8_t rxBufferSize,
109109
*
110110
* @param rx the new reception pin.
111111
*
112-
* @return CODAL_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
112+
* @return DEVICE_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
113113
*/
114114
int MicroBitSerial::redirect(PinName tx, PinName rx) {
115115
static Pin *oldRx = NULL;
@@ -134,7 +134,7 @@ int MicroBitSerial::redirect(PinName tx, PinName rx) {
134134
*
135135
* @param rx the new reception pin.
136136
*
137-
* @return CODAL_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
137+
* @return DEVICE_SERIAL_IN_USE if another fiber is currently transmitting or receiving, otherwise DEVICE_OK.
138138
*/
139139
int MicroBitSerial::redirect(PinNumber tx, PinNumber rx) {
140140
static Pin *oldRx = NULL;

0 commit comments

Comments
 (0)