• slider image 442
  • slider image 483
  • slider image 484
  • slider image 485
  • slider image 486
  • slider image 487
:::


Browsing this Thread:   1 Anonymous Users






Re: UART自己會亂傳?!
#3
初級會員
初級會員


查看用戶資訊
@o@" 竟然有人回覆我,真是受寵若驚. 多謝tonys兄
老實說我覺得這不大像是個問題,只是io初始化時的"現象"吧
n個貓當初鑽牛角尖太久就把它誤解成Errata裡的情況,不過目前還在try 不知道是否會影響到功能的完整性.
ps. 我還以為是版主先跳出來講解說XD

n個貓

發表於: 2009/11/27 9:46
God grant me the serenity To accept the things I cannot change; Courage to change the things I can; And wisdom to know the difference.
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: UART自己會亂傳?!
#2
資深會員
資深會員


查看用戶資訊
不是你的問題,請放心。

就改照著 errata 中所述的 workaround 方法來作就是。方法有很多種,任選一種合用或你喜歡的就好。

翻了一下 workaround 講的很白話,看不出有什麼疑難,照作就是。 errta 與 datasheet 有矛盾的地方,以 errta 為準。

如還有問題可再問。

發表於: 2009/11/27 7:04
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


UART自己會亂傳?!
#1
初級會員
初級會員


查看用戶資訊
小弟在這邊有點問題想請教一下
我在使用UART時傳送接受數據都正常,但是一開始前一兩個bit自己會無中生有跑出"0x00"或是"0xFF"

mcu:pic18f4525, 震盪器:12Mhz
mode:Asynchronous.
BRGH:High speed.
Asynchronous mode:Enables receiver.

//-------------code------------------
TXSTA=0b00100100;
RCSTA=0b10010000;
SPBRG=12; //baud rate 57600
//-------------end-------------------

ex:0xFF 0xFF 0x30 x031 0x32 但實際上接受的數據只有0x30,0x31,0x32前面兩筆自己跑出來的 @O@"

小弟有看了18F4525的Errata第34項Module: EUSART感覺這問題好像就是我發生的問題

Errata內文:In rare situations, one or more extra zero bytes
have been observed in a packet transmitted by the
module operating in asynchronous mode. The
actual data is not lost or corrupted; only unwanted
(extra) zero bytes are observed in the packet.

但是小弟有點不懂它work around的方式.
有請各位先進指點迷津...是哪個環節出了問題?

發表於: 2009/11/24 10:46
God grant me the serenity To accept the things I cannot change; Courage to change the things I can; And wisdom to know the difference.
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部







You can view topic.
不可以 發起新主題
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create PDF files.
You cannot get print page.

[進階搜尋]


:::

Microchip連結

https://www.facebook.com/microchiptechnologytaiwan/
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=13
https://mu.microchip.com/page/tmu
http://elearning.microchip.com.tw/modules/tad_link/index.php?cate_sn=1
https://page.microchip.com/APAC-PrefCenters-TW.html
http://www.microchip.com/
http://www.microchip.com/treelink
http://www.microchipdirect.com/
http://www.microchip.com.cn/newcommunity/index.php?m=Video&a=index&id=103
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=2
http://www.microchip.com.tw/Data_CD/eLearning/index.html
http://www.microchip.com.tw/RTC/RTC_DVD/
https://www.microchip.com/development-tools/
https://www.youtube.com/user/MicrochipTechnology
[ more... ]

教育訓練中心

!開發工具購買
辦法說明 [業界客戶] [教育單位]
----------------------------------
!校園樣品申請
辦法說明 [教師資格] [學生資格]
----------------------------------