Skip to content

Commit 42cb8b5

Browse files
committed
small change
- revert local variable to uint8 in Serial.read
1 parent 0ec7e72 commit 42cb8b5

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

STM32F1/cores/maple/usb_serial.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,13 +158,13 @@ uint32 USBSerial::read(uint8 * buf, uint32 len) {
158158

159159
/* Blocks forever until 1 byte is received */
160160
int USBSerial::read(void) {
161-
int8 b;
161+
uint8 b;
162162
/*
163163
this->read(&b, 1);
164164
return b;
165165
*/
166166

167-
if (usb_cdcacm_rx((uint8*)&b, 1)==0)
167+
if (usb_cdcacm_rx(&b, 1)==0)
168168
{
169169
return -1;
170170
}

0 commit comments

Comments
 (0)