well, I'm not too sure about your codes, but that Serial (including USB serial and HardwareSerial) uses a ringbuffer.
If the receiving end did not read the buffer, it is possible that it gets filled.
I reviewed the codes and found that there is
Serial.availableForWrite()
virtual int ...
Search found 2942 matches: serial*
Searched query: serial*
- Tue Sep 02, 2025 1:54 pm
- Forum: Libraries & Hardware
- Topic: USB Buffer Over run STM32L432
- Replies: 5
- Views: 95
- Tue Sep 02, 2025 4:07 am
- Forum: Libraries & Hardware
- Topic: USB Buffer Over run STM32L432
- Replies: 5
- Views: 95
Re: USB Buffer Over run STM32L432
well, format your post, comment so that it is more readable, e.g.
for (uint16_t A = 0; A < 15; A++) {
Serial.println(A);
filterxo[A] = getdouble();
Serial.println(filterxo[A], 3);
Serial.read(); // get rid of spacer/term char x
}
did you declare your filterxo array properly? e.g.
#include ...
for (uint16_t A = 0; A < 15; A++) {
Serial.println(A);
filterxo[A] = getdouble();
Serial.println(filterxo[A], 3);
Serial.read(); // get rid of spacer/term char x
}
did you declare your filterxo array properly? e.g.
#include ...
- Mon Sep 01, 2025 6:06 pm
- Forum: Libraries & Hardware
- Topic: USB Buffer Over run STM32L432
- Replies: 5
- Views: 95
Re: USB Buffer Over run STM32L432
As a bit different test, this shows a USB buffer size of 64 bytes max, but prints about 128 before losing it. The string variable teststr can go long if hardcoded:
else if (cmmd == 'c') {
while (Serial.available() == 0) {}
Serial.print("string started ");
Serial.println(Serial.available ...
else if (cmmd == 'c') {
while (Serial.available() == 0) {}
Serial.print("string started ");
Serial.println(Serial.available ...
- Mon Sep 01, 2025 5:10 pm
- Forum: Libraries & Hardware
- Topic: USB Buffer Over run STM32L432
- Replies: 5
- Views: 95
USB Buffer Over run STM32L432
I started (as a non programmer) with Thomas Roell and the Ladybug board. I used his board files and library forever.
Now Im porting to the STM32duino Core. Got through most porting issues with Generic L432KCUx series setting. But I used to write from a PC to my board through USB a large chunk of ...
Now Im porting to the STM32duino Core. Got through most porting issues with Generic L432KCUx series setting. But I used to write from a PC to my board through USB a large chunk of ...
- Thu Aug 28, 2025 12:46 pm
- Forum: General discussion
- Topic: STM32F411 based custom PCB I2C debugging
- Replies: 2
- Views: 743
STM32F411 based custom PCB I2C debugging
Hi everyone: i received in these days a custom PCB i designed based on the STM32F411 microcontroller:
I wanted to experiment with such MCUs and make a custom board with them for the first time; i was also interested in making it compatible with the arduino framework through PlatformIO as i already ...
I wanted to experiment with such MCUs and make a custom board with them for the first time; i was also interested in making it compatible with the arduino framework through PlatformIO as i already ...
- Mon Aug 04, 2025 10:02 pm
- Forum: STM32F2 based boards
- Topic: Getting the Netduino 2 (STM32F205) working via STM32duino
- Replies: 0
- Views: 27534
Getting the Netduino 2 (STM32F205) working via STM32duino
First a big ' Thank You! ' to the maintainers of this toolset and forum. I was able to rediscover and find new uses for my outdated and unsupported Netduino 2 board. A board I thought was obsolete. I'm still exploring how I can use STM32duino with this board but getting it programmed via the Arduino ...
- Sun Aug 03, 2025 5:04 am
- Forum: General discussion
- Topic: Trouble using 3 UARTs simultaneous on STM32F405
- Replies: 7
- Views: 2034
Re: Trouble using 3 UARTs simultaneous on STM32F405
I reviewed the codes, and it is quite 'convoluted'
when HardwareSerial initializes
https://github.com/stm32duino/Arduino_Core_STM32/blob/main/cores/arduino/HardwareSerial.cpp#L133
it configures the pins according to PeripheralPins.c
https://github.com/stm32duino/Arduino_Core_STM32/blob/main ...
when HardwareSerial initializes
https://github.com/stm32duino/Arduino_Core_STM32/blob/main/cores/arduino/HardwareSerial.cpp#L133
it configures the pins according to PeripheralPins.c
https://github.com/stm32duino/Arduino_Core_STM32/blob/main ...
- Sat Aug 02, 2025 11:37 pm
- Forum: General discussion
- Topic: Trouble using 3 UARTs simultaneous on STM32F405
- Replies: 7
- Views: 2034
Re: Trouble using 3 UARTs simultaneous on STM32F405
I understand now, thank you! Yes, I have CDC supersede. I looked in WSerial.h to understand a bit more and it looks like that's done by this block
#if defined (USBCON) && defined(USBD_USE_CDC)
#ifndef DISABLE_GENERIC_SERIALUSB
#define ENABLE_SERIALUSB
#if !defined(Serial)
#define Serial ...
#if defined (USBCON) && defined(USBD_USE_CDC)
#ifndef DISABLE_GENERIC_SERIALUSB
#define ENABLE_SERIALUSB
#if !defined(Serial)
#define Serial ...
- Sat Aug 02, 2025 1:44 pm
- Forum: General discussion
- Topic: Trouble using 3 UARTs simultaneous on STM32F405
- Replies: 7
- Views: 2034
Re: Trouble using 3 UARTs simultaneous on STM32F405
from the arduino menu, if you select "USB Support - CDC (generic 'Serial' supersede U(S)ART"
USB-Serial become the definiition of Serial
hence when you issue
void setup() {
Serial.begin();
}
that goes to USB-Serial. Serial1 .. Serial4 are still there but those are HardwareSerial which goes to ...
USB-Serial become the definiition of Serial
hence when you issue
void setup() {
Serial.begin();
}
that goes to USB-Serial. Serial1 .. Serial4 are still there but those are HardwareSerial which goes to ...
- Sat Aug 02, 2025 12:54 pm
- Forum: General discussion
- Topic: Trouble using 3 UARTs simultaneous on STM32F405
- Replies: 7
- Views: 2034
Re: Trouble using 3 UARTs simultaneous on STM32F405
Thanks for the replies. Could you please explain more what you mean by override with USB serial? Serial over USB is working fine but do you think it could be causing my issue?
Here's what I have for my clock configuration. I took this from the firmware that comes with the board.
void SystemClock ...
Here's what I have for my clock configuration. I took this from the firmware that comes with the board.
void SystemClock ...