MC9S08AW16 SCI Noise Flag

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MC9S08AW16 SCI Noise Flag

1,934 Views
v_dave
Contributor IV
Hello All,
 
OK I have already generated an SR # 1-393967504 yesterday afternoon but no response yet from Freescale.  This is more of an issue that others may have seen before so hopefuly posting here might generate a couple of response to help out.
 
I seem to be getting the Noise Error Flag set on specific Bytes of data sent. Here is some details:

Codewarrior 6.0
MC9S08W16 Micro
Using the AsyncroSerial bean
Settings: 9600, 8, N, 1
VCC = 5V
 
I am sending a simple string "CP01\n\r" to the serial port on the Micro. I have tried from both Hyperterminal & from my Master Microcontroller and I consistently get a Noise Flag on the 'P' or the '0'.

I have attached a screen shot of a 'P' being sent to the RXD pin on the AW16. This exact signal created a Noise Error but it looks clean to me.
I have also done some further investigation. Using Hyperterminal I sent 30 each, every letter in the alphabet (Upper & Lower) plus 0..9. I found ONLY the following characters caused the Noise flag to be set:
 
0 - 0x30
8 - 0x38
P - 0x50
X - 0x58
a - 0x61
p - 0x70
q - 0x71
x - 0x78
y - 0x79
 
Every other alpha character wes recieved without any errors.
 
Any ideas on what is causing the Noise Error Flag to be set?
Labels (1)
0 Kudos
2 Replies

300 Views
Alban
Senior Contributor II
Hello Dave,
 
First thanks for giving the SR# away, that will prevent double work from FSL Tech Supp guys/girls.
 
For me, noise on a clean signal must come from misalignment.
Each BIT is sampled THREE times. If these THREE samples are not identical, there is noise.
 
If the BIT is not properly aligned, one of the sample may take the level of the previous or the following BIT within the BYTE.
 
The clock of the SCI is 16 times the clock of the baudrate and re-synchro to every high to low edge.
Therefore, on a slightly shifted baudrate, noise could be flagged.
 
'P' is 0x50 you indicate. A SCI message is 10-bits with last one at high level.
Therefore your graph should show 9 bits between the falling edge (Start bit) and the last rising edge (last 0 of lower nibble).
9600 bps means 104.17us per bit.
For 9 bits duration = 937.5us but your graph shows 900us < duration < 950us but I cannot see more precisely.
 
Can you please check the actual baudrate of the MCU?
For this send 0x55 from the MCU SCI and check bit timing over several bits to observe the shift.
 
Cheers,
Alban.
0 Kudos

300 Views
v_dave
Contributor IV
Hello,
 
Thanks for the quick response.
 
You actually helped me solve the issue.  At least I think I figured it out.  I need to test a little more to see if that is the case.
 
Anyways, I used your suggestions to check out what Baud Rate I was actually TXing.  Send a 0x55 I measured anywhere from 100uS to 103us.  This means I was TXing at 10Kish baud rate.  This explains why Hyperterminal was also not RXing the data even thought I could see it on the scope.  The baudrate was such that all the data was garbage.
 
Now going the other direction that means I am reading the data incorrectly and why I am seeing the Noise Flag set. 
 
So I tweaked some of the clock settings in the CPU bean (Now 3.888MHz internal clock, originally 2MHz) and now the data is measuring 104uS per bit.  Also the Data is coming through clean both in Hyperterminal and on the CPU. 
 
Not quite sure i this is what actually fixed the problem or I clicked on somethng else on accident.  That is why I will do some more extensive testing.
 
Thanks again for the Tips.
0 Kudos