Questions tagged [usart]

USART stands for Universal Synchronous/Asynchronous Receiver/Transmitter is a modern IC which comes with a [UART](https://stackoverflow.com/tags/uart/info) that can also communicate synchronously. A USART is usually an individual (or part of an) integrated circuit used for serial communications over a computer or peripheral device serial port. The tag usart can be used for programming related questions of any usart device.

A Universal Synchronous/Asynchronous Receiver/Transmitter, abbreviated USART, is a piece of computer hardware that translates data between parallel and serial forms. USARTs are commonly used in conjunction with communication standards such as EIA, RS-232, RS-422 or RS-485. The universal designation indicates that the data format and transmission speeds are configurable.

A USART is usually an individual (or part of an) integrated circuit used for serial communications over a computer or peripheral device serial port. USARTs are now commonly included in microcontrollers. A dual UART, or DUART, combines two UARTs into a single chip. Many modern ICs now come with a UART that can also communicate synchronously; these devices are called USARTs (Universal Synchronous/Asynchronous Receiver/Transmitter).

The tag can be used for questions related to programming of a usart device, please note that https://electronics.stackexchange.com/ is another stackexchange website from where you can get answers for electronics related problems. Questions on Stackoverflow should be programming related.

See also tag .

263 questions
7
votes
1 answer

Stm32L151RCxxx USART Hang issue, Interrupt Based TX/RX simultaneously

I am running USART3, on 921600 BaudRate, using RTS CTS, I am always facing system hang when I try to do RX and TX simultaneously. I have pasted the main and IRQ code. IRQ is designed to Transmit a char 'A' while dropping all received data. Hangs…
Ishmeet
  • 1,540
  • 4
  • 17
  • 34
5
votes
1 answer

STM32: Use USART with character match ISR and DMA buffer

I'm using a STM32L432 device with FreeRTOS and STM32CubeMX. I try to implement a M2M-Communication via USART based on an ASCII protocol. The protocol sequences can differ in length but have a maximum length and a defined end character ('\r' /…
PascalS
  • 975
  • 1
  • 16
  • 40
5
votes
3 answers

ADC single conversion on STM32

I'm studying ADC programming on STM32 F103x and starting with the simplest case - single conversion. The internal temperature sensor (connected to ADC1) value is measured and sending it to COM port by using USART. A target seems clear but when I…
lft
  • 113
  • 1
  • 1
  • 12
5
votes
1 answer

USART wrong data incoming

I am writing a communication between Atmega162 and PC. On my PCB I have interface RS485 (converted from RS422 by MAX485) and it goes through ADAM-4520 transceiver into COM port. I've been testing my program in terminal and it seems strange to me,…
pasiasty
  • 71
  • 8
4
votes
1 answer

Sending mutiple characters using USART1 on an atmega4809 results in 0xFF to be send

Solution: Turns out it did not have anything to do with the USART. The problem was in the Makefile. I reused a Makefile I have been using for atmega328p and atmega2560 for a long time. But this Makefile does not include the .rodata section when…
4
votes
3 answers

Embedded Linux device blocking RS485 bus during startup

I'm having trouble with an industrial Linux computer I'm working with to achieve communication over an RS485 bus with multiple connected devices. What I've encountered is that the IO pins used by the RS485 USART driver are set to different levels at…
Stenis
  • 118
  • 9
4
votes
1 answer

ISO 7816 (SIM CARD ) Protocol

I am trying to talk to a device that uses ISO 7816 protocol with T=1. My hardware setup is a micro-controller using USART configured in SIM card mode.I have read the relevant documents but am unclear on what happens after an ATR. As far as I…
shikarssj
  • 135
  • 2
  • 5
3
votes
3 answers

STM32 UART in DMA mode stops receiving after receiving from a host with wrong baud rate

The scenario: I have a STM32 MCU, which uses an UART in DMA Mode with Idle Interrupt for RS485 data transfer. The baud rate of the UART is set in CubeMX, in this case to 115200. My Code works fine, when the Host uses the correct baud rate, it is…
Chris_B
  • 359
  • 5
  • 13
3
votes
2 answers

Issue regarding TX line of Arduino while communicating with Vending machine via MDB Protocol over USART

I am trying to communicate with a Vending machine using MDB Protocol with the help of Arduino Mega and I am partially successful in doing so. The circuit that I am using is attached here While the circuit diagram is shown below The Arduino Mega is…
Nauman Shakir
  • 135
  • 1
  • 3
  • 15
3
votes
1 answer

Interrupt-driven USART using UDRE with ATmega328P

I am having a problem with programming the serial for Arduino in C. The application demands speed, so I need to do it in C. I am using Codeblocks for it as it is easy to compile. As I also want the serial feature not blocking the application and…
BigFilhao
  • 157
  • 6
  • 15
3
votes
1 answer

Entering Low Power Mode on STM32L0 to use USART1

I want to use as little power as possible reading USART1 at 300 baud approx. 40 bytes. There are numerous other peripherals but they don't need to run- all that needs to be running is the RTC in parallel. Peripherals need to be frozen, ram needs to…
Flying Swissman
  • 818
  • 2
  • 14
  • 39
3
votes
0 answers

Getting a speed-bottleneck in data-communication when using anonymous pipes

I have a program setup where a MCU sends me sensor data via USART to a C# windows forms application. That application upon receiving the data via the serialdatareceived event sends it to a managed c++ application using anonymous pipes. As soon as…
user46794
  • 51
  • 6
3
votes
1 answer

STM32F427's USART1 sometimes sets 8th data bit as if it would be parity bit

I'm working with STM32F427 UASRT1 via the following class: void DebugUartOperator::Init() { // for USART1 and USART6 ::RCC_APB2PeriphClockCmd(RCC_APB2Periph_USART1, ENABLE); // USART1 via PORTA …
Victor Che
  • 75
  • 7
3
votes
1 answer

How does this simple line of C code work?

I need 9 bit UART data on an Arduino Uno and so I have to do some manual setup of the Arduino UART. Basically, I don't understand this line of example code (from the datasheet), it is meant to enable a UART Tx and Rx pin on the Arduino, which done…
Nathan Darker
  • 141
  • 1
  • 9
3
votes
2 answers

Direct memory access RX for the STM32L1

I've been trying for a while now to transmit a block of data from my computer to an STM32L100C-DISCO over USART. For performance reasons, this is to be done using DMA. So far, however, I have not been able to get it to work. As I cannot seem to…
Joost
  • 4,094
  • 3
  • 27
  • 58
1
2 3
17 18