• slider image 442
  • slider image 492
  • slider image 493
  • slider image 494
  • slider image 495
  • slider image 496
  • slider image 488
  • slider image 491
:::

論壇索引


Board index » All Posts (n454113)




新手笨問題
高級會員
高級會員


買了 PIC16F87X 快速上手 何信龍 李雪銀 這本書

按照裡面的簡單測試程式範例 打了上去

list p=16f877
#include <p16f877.inc>
cnt       equ   0x20
delaycnt0 equ   0x21
delaycnt1 equ   0x22
          org   0x00
          nop 
          
goto  start
start
:
          
call  pic_init
main_loop
:
          
movlw b'11111110'
          
movwf rc
          movlw 0x08
          movwf cnt
inner_loop
:
          
call  delay
          bsf   status
,c
          rlf   rc
,f
          
goto  inner_loop
          
goto  main_loop
pic_init
:
          
clrf  intcon
          bsf   status
,rp0
          movlw 
b'00000000' 
          
movwf trisc
          bcf   status
,rp0
          movlw 
b'11111110'
          
movwf rc
          
return
delay:
          
movlw 0xff
          movwf delaycnt0
          movwf delaycnt1
delay0
:
          
decfsz delaycnt0,f
          
goto delay0
          decfsz delaycnt1
,f
          
goto delay0
          
return
          
end


Build All時 卻發生一大堆錯誤

CleanDone.
Executing"C:Program FilesMPLAB IDEMCHIP_Toolsmpasmwin.exe" //p16F877 "ex1.asm" /l"ex1.lst" /e"ex1.err"
Warning[205D:PICEX1.ASM 1 Found directive in column 1. (list)
Error[113]   D:PICEX1.ASM 13 Symbol not previously defined (rc)
Error[113]   D:PICEX1.ASM 18 Symbol not previously defined (status)
Error[113]   D:PICEX1.ASM 18 Symbol not previously defined (c)
Error[113]   D:PICEX1.ASM 19 Symbol not previously defined (rc)
Error[113]   D:PICEX1.ASM 23 Symbol not previously defined (intcon)
Error[113]   D:PICEX1.ASM 24 Symbol not previously defined (status)
Error[113]   D:PICEX1.ASM 24 Symbol not previously defined (rp0)
Error[113]   D:PICEX1.ASM 26 Symbol not previously defined (trisc)
Error[113]   D:PICEX1.ASM 27 Symbol not previously defined (status)
Error[113]   D:PICEX1.ASM 27 Symbol not previously defined (rp0)
Error[113]   D:PICEX1.ASM 29 Symbol not previously defined (rc)
Halting build on first failure as requested.
BUILD FAILEDTue Oct 25 02:55:30 2005


書上的範例應該沒錯 而我也照書上的打 有沒有人可以幫我解惑一下

謝謝...

發表於: 2005/10/25 3:19
頂部



« 1 ... 11 12 13 (14)



:::

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... ]

教育訓練中心

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