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


Browsing this Thread:   1 Anonymous Users




(1) 2 »


Re: 急件 拜託
#11
資深會員
資深會員


查看用戶資訊
其實上面的都說的蠻詳細了
如還不太能理解的話
個人建議

1. 上workshop 然後順便跟講師問仔細
2. 弄本PIC的書 相關章節用力K一下

以上

發表於: 2008/2/15 9:27
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#10
初級會員
初級會員


查看用戶資訊
__CONFIG是一個虛擬指令Configuration Bits
它的意思上面的前輩已經說過了,因為你用的是16F72所以你應該去C:槽的Program Files--Microchip--MPASM Suite--P16F72.INC的檔案打開到最後面就可以看到這些設定值,
或是執行MPLAB IDE上面有configure選項的Configuration Bits中也有這些設定選項在程式中設定好後debugger或是燒錄時就會按照程式__CONFIG指令後的項目作設定,
至於要設哪些項目要看所用的PIC做決定不是每顆都一樣的,
因為設定的名稱大都用英文簡寫所以同樣的設定有時簡寫也會不同,這就是為何要去看.INC檔的原因了,
每個設定會用&符號來連起來,問題來了如果你要問的是每個設定的原因為何實在是難回答,
這種事是急不來的還是買本書來好好研究一下旁邊中文參考書中有很多可參考的書,
看你所用的是組語可以到旁邊的教材及講義的RTC中下載(MPASM 及 MPLINK講義)來研究一下,
我也不是什麼高手,但當你看到硬體設定就一頭霧水時表示要從PIC基本架構學起,否則會有問不完的問題,也會讓別人不知要如何幫助你.加油!

發表於: 2008/2/14 17:38
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#9
初級會員
初級會員


查看用戶資訊
版主我還是不懂

你可以舉例說明一下嗎

我比較不會這個

發表於: 2008/2/14 14:31
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#8
版主
版主


查看用戶資訊
這個問題我至少回達過10遍以上。
--------------------    MPLAB C18   ----------------------------------------

;*******************************************************************************
;*
3.For MPLAB C18 V2.40 or higher, use #pragma config directive                       *
;*for example                                                                     *    
//******************************************************************************
    #include <p18f452.h>
//*******************************************************************************
//*Configuration settings may be specified with multiple #pragma config directives.          *
//*MPLAB C18 verifies that the configuration settings specified are valid for the processor*
//*for which it is compiling                                                                                *            
//*The labels following the directive "pragma config" are defined in the P18F452.h file.    *
//*******************************************************************************
    #pragma config    OSC=HS
    #pragma config     PWRT=ON
    #pragma config     BOR=OFF, BORV=42
    #pragma config     WDT=OFF
    #pragma config      CCP2MUX=ON
    #pragma config      STVR=OFF, LVP=OFF, DEBUG=OFF
    #pragma config      CPD=OFF
    
void main(void)
{
//your code
}
//********************************************************************************


c:\mcc18\doc\hlpPIC18ConfigSet.chm
裡有詳細的設定參數值。

發表於: 2008/1/24 15:49
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#7
資深會員
資深會員


查看用戶資訊
C語言請看對應的header files以得到正確參數名稱。一樣的東西。

發表於: 2008/1/24 15:37
不要問我哪裡來,我只是個流浪天涯的工程師
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#6
初級會員
初級會員


查看用戶資訊
請問一下 c語言要設嗎

發表於: 2008/1/24 15:26
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#5
資深會員
資深會員


查看用戶資訊
P16F72.INC檔案最後有Configuration bits設定。參數你需要對照Data Sheet Page.59 Configuration Bits 那一節作相關設定。也可以完全不寫,然後從MPLAB的Configure-->Configuration Bits中設定相關運作參數。


發表於: 2008/1/24 14:59
不要問我哪裡來,我只是個流浪天涯的工程師
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#4
高級會員
高級會員


查看用戶資訊
在mcu動作前有一些硬體設定是可以讓user去自訂的。
例如ocillator你可以採用外部crystal oscillator,也可以在成本考量下採用mcu built in的RC oscillator。這些都是manufacture無法幫你決定的,所以你必須在configure bits中設定。datasheet後面都有介紹,寫程式的人一定要先看過才行。

發表於: 2008/1/24 13:34
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#3
初級會員
初級會員


查看用戶資訊
版主你好
你叫我看他裡面的文件
可是我不懂
你可以好心一點跟我說詳細一點嗎
謝謝

發表於: 2008/1/24 12:04
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 急件 拜託
#2
版主
版主


查看用戶資訊
設定 IC 硬體工作方式 , 此項設定是非常重要,倘若設定錯誤將使程式發生不可預期的誤動作。詳細的說明要看 Data Sheet裡有關 Special Features of the CPU 內有關 Configuration Words 的說明,其定義的文字須看 p16f72.inc 最後面的說明。

發表於: 2008/1/23 16:36
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... ]

教育訓練中心

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