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


Browsing this Thread:   1 Anonymous Users




« 1 (2)


Re: 舊版本C30可編譯,新版本的C30編譯不會過問題求教?
#4
版主
版主


查看用戶資訊
maru2000 大大,真有你的這樣都讓你找的到。謝謝。

剛檢查了一下 C30 V3.12 的版本(我目前在用的),其實他又改了回來了,很抱歉這個定義又改到其它的檔案了:
C:\Program Files\Microchip\MPLAB C30\src\peripheral_24F\include\PIC24F_periph_features.h
的檔案了,而且將 " /* #define USE_AND_OR */" 加上註解了,所以Timers.h 將會使用 & 的方式來運算這些常數值。
所以如果你使用 v3.12 (含) 以後的版本就可以跟以前相容了。

PIC24F_periph_features.h 檔裡的說明:
#include <p24Fxxxx.h>

/* By default, configuration constants are assembled from macros */
/* using the bit-wise AND operator (&). An alternate mode is */
/* available in which constants are assembled using the bit-wise */
/* OR operator (|) to set values and bit-wise AND (&) masks to */
/* clear values. To enable the alternate mode, define the */
/* USE_AND_OR symbol. */
/* */
/* To define this macro as a compiler option: */
/* -DUSE_AND_OR */
/* To define this macro in source code: */
/* #define USE_AND_OR */

發表於: 2010/1/8 13:46
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 舊版本C30可編譯,新版本的C30編譯不會過問題求教?
#3
資深會員
資深會員


查看用戶資訊

發表於: 2010/1/8 13:26
==== ^^ ^^ ====
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: 舊版本C30可編譯,新版本的C30編譯不會過問題求教?
#2
資深會員
資深會員


查看用戶資訊
剛剛個人選同系列的另一顆dsPIC30f6010a編譯,居然通過編譯,真是奇怪,只是本人無dsPIC30f6010a晶片可供燒錄驗證,手上只有dsPIC30f4011而己,之前舊版本確定可編譯及燒錄.

發表於: 2010/1/7 22:21
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


舊版本C30可編譯,新版本的C30編譯不會過問題求教?
#1
資深會員
資深會員


查看用戶資訊
個人本來一直使用C30的V3.02版本,而程式編譯及燒錄及執行都正常,最近更新至V3.20B版本,結果原程式就不能通過編譯,出問題在呼叫UART的週邊函式:

#include<p30f4011.h>
#include<uart.h>
........
int main(void)
{

.......................

baudvalue = 5;
U1MODEvalue = UART_EN & UART_IDLE_CON &
UART_DIS_WAKE & UART_EN_LOOPBACK &
UART_EN_ABAUD & UART_NO_PAR_8BIT &
UART_1STOPBIT;
U1STAvalue = UART_INT_TX_BUF_EMPTY &
UART_TX_PIN_NORMAL &
UART_TX_ENABLE & UART_INT_RX_3_4_FUL &
UART_ADR_DETECT_DIS &
UART_RX_OVERRUN_CLEAR;
OpenUART1(U1MODEvalue, U1STAvalue, baudvalue);
..............
}

編譯錯誤訊息為
error: 'UART_TX_PIN_NORMAL' undeclared (first use in this function)
個人覺得很訝異,在舊版本並沒有此問題,怎麼新版本會error?

發表於: 2010/1/7 22:07
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... ]

教育訓練中心

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