Wrong data aquired from AS1_RecvChar(&var);  Serial Communication

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Wrong data aquired from AS1_RecvChar(&var);  Serial Communication

ソリューションへジャンプ
1,972件の閲覧回数
ArturoJsx
Contributor I

The value in serial data receiver register SCI1D is not getting the right value for *Chr variable of AS1_RcvChar() function, created by Processor Expert. I´m receiving "!" 0xa1 while I´m expecting to receive a 'A' 0x41 . 

 

Whatever value I try it gives me another.  for example if i send from my pc 0x01   i´m getting 0x81 in  AS1_RecvChar(&var) or SCI1D directly.

 

I try both MCF51QE128 and MC9S08QE128. I set my internal clock to 36Khz & internal bus to 9.216 so i could get a exact 115200 Baudrate for my serial com

ラベル(1)
0 件の賞賛
返信
1 解決策
1,205件の閲覧回数
ProcessorExpert
Senior Contributor III

 

Hello,

I think that it is not issue related to Processor Expert tool, it is rather timing issue. Please note that if non-default internal clock is needed, it’s necessary to set it in P&E connection dialog. Could you please doublecheck that your internal clock source is properly trimmed to 36 kHz? For more details please find attached screen-shot.

best regards
Vojtech Filip
Processor Expert Support Team

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,206件の閲覧回数
ProcessorExpert
Senior Contributor III

 

Hello,

I think that it is not issue related to Processor Expert tool, it is rather timing issue. Please note that if non-default internal clock is needed, it’s necessary to set it in P&E connection dialog. Could you please doublecheck that your internal clock source is properly trimmed to 36 kHz? For more details please find attached screen-shot.

best regards
Vojtech Filip
Processor Expert Support Team

0 件の賞賛
返信
1,205件の閲覧回数
ArturoJsx
Contributor I

Hello again

 

It works, as you said I didn´t notice I had to set the trim value on PE Dialog so once i did it I start to receive the right values. Thank you for your assistance !!

0 件の賞賛
返信