Why UART data is getting corrupted?

Go To Last Post
2 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

I'm getting a strange issue. We have a Atmega 128 controller board that keeps on polling 15 Atmega8 based ultrasonic sensors. They are connected in RS 422 model where all Tx pins of 15 sensors are connected together and in-turn connected to the Rx of the Atmega 128 controller and all Rx pins of 15 sensors are connected together and finally connected to the Atmega 128.. 

Am making sure that the communication protocol is implemented correctly.. I mean.. no data collision among the sensors.. enabling and disabling Tx/Rx links property while exchanging the messages....

 

The problem is.. when I saw the output through the UART on the Atmeg128 controller, the output looks fine.. it is keeping on polling and I saw the below polling message...

01P 02P ......15P

Meaning 01 sensor.. what is the status..., 02 sensor what's the status ..? etc.. and sensors are also properly responding..

 

But when I checked on the next day, either none of them are working or few of them got frozen.

 

When I checked the same UART data,.. I found some scrap message or sometimes no UART data at all... 

And sometimes though Atmega 128 is polling fine, Atmega 8 is not at all responding.. it is mute..

No loose contacts ... 

Why so?

There's watchdog timer running in all Atmega8 and atmega128 also..

What are the typical causes for this strange issue?

Power supply is a 12V dc , meanwhile brand... 

Is it because somewhere some power spikes are disturbing the controller?

Last Edited: Fri. May 3, 2019 - 07:00 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

And I will lock this one.

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

Topic locked