aboutsummaryrefslogtreecommitdiffstats
path: root/core/comm
diff options
context:
space:
mode:
Diffstat (limited to 'core/comm')
-rw-r--r--core/comm/HardwareSerial.cpp6
-rw-r--r--core/comm/HardwareSerial.h6
-rw-r--r--core/comm/HardwareUsb.cpp8
-rw-r--r--core/comm/HardwareUsb.h8
4 files changed, 14 insertions, 14 deletions
diff --git a/core/comm/HardwareSerial.cpp b/core/comm/HardwareSerial.cpp
index 04d8d18..7a8fed9 100644
--- a/core/comm/HardwareSerial.cpp
+++ b/core/comm/HardwareSerial.cpp
@@ -44,14 +44,14 @@
#define USART3_RX_PORT GPIOB_BASE
#define USART3_RX_PIN 11
-HardwareSerial::HardwareSerial(uint8_t usartNum) {
+HardwareSerial::HardwareSerial(uint8 usartNum) {
ASSERT(usartNum == 1 ||
usartNum == 2 ||
usartNum == 3);
this->usartNum = usartNum;
}
-uint8_t HardwareSerial::read(void) {
+uint8 HardwareSerial::read(void) {
return usart_getc(usartNum);
}
@@ -64,7 +64,7 @@ void HardwareSerial::write(unsigned char ch) {
usart_putc(usartNum, ch);
}
-void HardwareSerial::begin(uint32_t baud) {
+void HardwareSerial::begin(uint32 baud) {
ASSERT(!(baud > USART_MAX_BAUD));
/* Set appropriate pin modes */
diff --git a/core/comm/HardwareSerial.h b/core/comm/HardwareSerial.h
index a3913f9..2c9c6b8 100644
--- a/core/comm/HardwareSerial.h
+++ b/core/comm/HardwareSerial.h
@@ -32,10 +32,10 @@ class HardwareSerial : public Print {
private:
uint8 usartNum;
public:
- HardwareSerial(uint8_t);
- void begin(uint32_t);
+ HardwareSerial(uint8);
+ void begin(uint32);
uint32 available(void);
- uint8_t read(void);
+ uint8 read(void);
void flush(void);
virtual void write(unsigned char);
using Print::write;
diff --git a/core/comm/HardwareUsb.cpp b/core/comm/HardwareUsb.cpp
index 269a68f..43438f1 100644
--- a/core/comm/HardwareUsb.cpp
+++ b/core/comm/HardwareUsb.cpp
@@ -34,8 +34,8 @@ HardwareUsb::HardwareUsb(void) {
rx_buffer_offset_out = 0;
}
-uint8_t HardwareUsb::read(void) {
- uint8_t outVal = rx_buffer[rx_buffer_offset_out++];
+uint8 HardwareUsb::read(void) {
+ uint8 outVal = rx_buffer[rx_buffer_offset_out++];
#if 1
if (rx_buffer_offset_out == rx_buffer_offset_in) {
@@ -46,7 +46,7 @@ uint8_t HardwareUsb::read(void) {
return outVal;
}
-uint8_t HardwareUsb::available(void) {
+uint8 HardwareUsb::available(void) {
ASSERT(rx_buffer_offset_out >= 0);
// return rx_buffer_offset+1;
// return usb_serialGetRecvLen();
@@ -70,7 +70,7 @@ void HardwareUsb::usb_rx_cb(void) {
BootVectTable *vectTable = (BootVectTable*)(BOOTLOADER_VECT_TABLE);
HardwareUsb *thisPtr = (HardwareUsb*) vectTable->usb_local_obj_ptr;
- uint8_t numBytes = usb_serialGetRecvLen();
+ uint8 numBytes = usb_serialGetRecvLen();
#if 0
/* ONE-SHOT-TO-READ Version (buffer cleared on next recv interrupt */
diff --git a/core/comm/HardwareUsb.h b/core/comm/HardwareUsb.h
index b8733c1..a5ff191 100644
--- a/core/comm/HardwareUsb.h
+++ b/core/comm/HardwareUsb.h
@@ -33,13 +33,13 @@ class HardwareUsb : public Print {
static void usb_rx_cb(void);
static void usb_tx_cb(void);
unsigned char rx_buffer[USB_SERIAL_BUF_SIZE];
- int8_t rx_buffer_offset_out;
- int8_t rx_buffer_offset_in;
+ int8 rx_buffer_offset_out;
+ int8 rx_buffer_offset_in;
public:
HardwareUsb(void);
void begin();
- uint8_t available(void);
- uint8_t read(void);
+ uint8 available(void);
+ uint8 read(void);
void flush(void);
virtual void write(unsigned char);
using Print::write;