Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
版主
|
時間快慢是由 32768Hz 石英晶體所決定的,再說 PIC24 是3.3V 的工作電壓,且電壓的變化對 Crystal 的影響很輕微。建議你先監測一下 32768Hz 的頻率誤差後再作時間變快、慢的 bug.
發表於: 2010/2/11 10:34
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
中級會員
|
QQ ,不好意思,請問一下。
昨天測試RTCC這個,在電腦接上USB之後,它的秒數是每8.7秒跳一次,且不會到達10就歸回原值。 但測試了ㄧ種直接由110V轉USB的變壓器供電,卻正常顯示 含每到59就進位,可是速度稍快。 約正常時間47秒,它就跑完一分鐘了。 且用示波器量測,電壓值是ㄧ樣的。 卻有兩種結果!! ,
發表於: 2010/2/11 9:11
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
中級會員
|
不好意思,請問一下。
RTCC是使用兩個震盪器輸入源,上次程式裡面是是使用 8Mhz,請問要如何開始第二震盪器輸入32MHZ, ?
發表於: 2010/2/9 16:57
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
版主
|
依據 256GB110 Data Sheet 裡的 Config1 的設定暫存器裡:
CONFIG1 =
COE 應是工廠測試使用的位元,他並不存在於 Data Sheet,但在256GB110 的 h 檔裡卻有此宣告 Clip-on Emulation mode , 實際在 MPLAB IDE 下裡的 CONFIG 選項下也看不到此位元。所以還是建議使用 COE_OFF 的設定。
發表於: 2010/2/8 14:12
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
中級會員
|
_CONFIG1( JTAGEN_OFF & GCP_OFF & GWRP_OFF & COE_OFF & FWDTEN_OFF & ICS_PGx2)
_CONFIG2( FCKSM_CSDCMD & OSCIOFNC_ON & POSCMOD_HS & FNOSC_PRI ) 請問COE 是指第二個震盪輸入,關閉嗎?
發表於: 2010/2/8 10:37
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
中級會員
|
謝謝 ,我會仔細看的。
發表於: 2010/2/5 15:10
|
|||
|
Re: 不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
版主
|
前帳未清又開了新的主題。
有關你所說的 RTCC 的 function source code 是對的,一般是不會直接拿SRC 目錄下的程式加到 Project 裡的,除非你要修改Microchip所提供的函數功能。 因為使用 RTCC 有佔存器鎖定的問題所以使用起來很如意出錯的,針對使用 RTCC Libraries Function 可以看一下底下的 COde Example 它是使用PIC24FJ256GB110 使用中斷模式所寫的時鐘。 Attach file: Link only for registered users
發表於: 2010/2/5 10:13
|
|||
|
不好意思~關於RTCC的設定
|
||||
---|---|---|---|---|
中級會員
|
RTCC的設定是否用peripheral_24F-->SRC-->PMC-->RTCC
裡面的C檔,來設定呢? 如果是,我的想法是 RTCCInitClock.c ----開啟第二震盪 RtccWrOn.c----開啟寫入RTCCRCFGROL RtccWriteTimeDate.c----開啟寫入RCFGCAL的值 RtccWriteAlrmTimeDate.c----開啟ALCFGPT的值 RtccSetChimeEnbl.c----開啟鬧鐘 RtccReadAlrmTimeDate.c---讀取鬧鐘時間 RtccReadTimeDate.c---讀取RTCC時間 ~我使用的是APP026-3這塊板子
發表於: 2010/2/5 8:36
|
|||
|