2024-02-09 01:42 AM - last edited on 2024-02-11 10:59 AM by Imen.D
Hi,
Configured PC4 and PC5 for transmitting and receiving over USART1.
Enabled the interrupt, DMA is disabled.
Tried with different baud rates, same results.
The data seen on serial console application cutecom does not match data I am setting in my transmit buffer.
Tried same test on USART2 using putty, it shows data matching TX buffer.
Any suggestions ?
Thanks,
Mo
2024-02-09 02:20 AM
No schematic, no connections described, no code shown. How could anyone help you without any of these?
2024-02-09 02:29 AM
@mohitmg wrote:The data seen on serial console application cutecom does not match data I am setting in my transmit buffer.
Tried same test on USART2 using putty, it shows data matching TX buffer.
So you changed two things at once?
What does PuTTY show in the USART1 case?
What does this "cutecom" (not heard of that one before) show with the USART2 case?
Have you looked at the UART lines with a scope to see what's happening?
@mohitmg wrote:Enabled the interrupt, DMA is disabled.
Before adding those complications, can you do a simple, blocking Tx ?
As @gbm said, you're going to need to give a lot more details for anybody to be able to help debug this remotely.
2024-02-09 02:33 AM
@Andrew Neil wrote:
"cutecom" (not heard of that one before) .
This: https://cutecom.sourceforge.net/ ?
I note:
So are you sure that your code is sending in a proper format that CuteCom will recognise as a "line" ?
2024-02-09 01:43 PM
All I am doing is sending 2 byte data over UART TX and trying to sniff the data on TX line to make sure it matches what we are sending from the main function.
Note - We are running on ubuntu so cutecom is the tool I could find. Cutecom is able to see my device on tty/USB0 and attach.
Do you have any other tool I can use in similar fashion to see what exact data being sent out on UART TX line ?
Thanks,
Mohit
2024-02-10 01:28 AM - edited 2024-02-10 02:45 AM
@mohitmg wrote:All I am doing is sending 2 byte data over UART TX and trying to sniff the data
As I said, I don't know this "CuteCom" and, therefore, don't know exactly what it means by "line-based" - but I suspect it's not the right tool for doing that.
Especially as it also says it's not "character-oriented".
Again, have you tried with PuTTY and/or an oscilloscope?
You still haven't given any details of how you're connecting the board and the various USARTs to your host system.