STM32 · Embedded · 06
Streaming Waveforms over USART2 to SerialChart
Using the ADC/UART note, I retraced HAL_ADC_Start, PollForConversion, GetValue, and USART2 transmission. The saved SerialChart configuration uses COM6, 115200 baud, and fields spanning 0-3.3 V and 0-4096 ADC counts.

What I checked first
Using the ADC/UART note, I retraced HAL_ADC_Start, PollForConversion, GetValue, and USART2 transmission. The saved SerialChart configuration uses COM6, 115200 baud, and fields spanning 0-3.3 V and 0-4096 ADC counts.
Source view
- The line format separates sample index, timestamp, raw ADC, moving average, and filtered voltage.
- Each sample ends with CRLF so SerialChart can keep reading consistent fields.
- The illuminated LED confirms power/status only; it is not proof of waveform quality.
Code path
sprintf((char *)TxData,
"%lu,%lu,%lu,%lu,%.6f\r\n",
sample_index, timestamp_us,
ADCValue, Smooth_ECG, ECG_Filtered);
HAL_UART_Transmit(&huart2, TxData, strlen((char *)TxData), 10);
Key terms
- USART2
- 115200 baud
- CSV framing
- SerialChart
Review sequence
- USART2
- 115200 baud → CSV framing
- SerialChart
Official references
- STM32CubeF4 Getting Started (UM1730)
- STM32 DSP with CMSIS (AN4841)
- Arm CMSIS-DSP
- STM32CubeF4 repository
The reviewed sources contain 22 prototype photos, a 40-slide STM setup deck, a three-page KiCad schematic, an ADC/UART note, an HRV module, two PPG code records, twelve top-level ECG C variants, and a complete CubeIDE project archive. I do not count byte-identical variants or ST/Arm vendor files as separate results, and I make no new performance claim without saved measurements.