list p=18f4550
#include P18f4550.INC
DelayD1 equ 0x00
DelayD2 equ 0x01
;--------------------------------------------------
org 0000h
goto Start
org 00020h
Start:
movlb B'00000010' ;FE0H,back select 02H
movlw B'01100010' ;FE8H,62H
movwf OSCCON
movlw B'00000000'
movwf TRISD ;F93H
clrf PORTD ;PORTB,F81H
movlw H'00'
movwf LATD
;------------------------------------------------------
Main:
movlw H'FF'
movwf PORTD
call Delay
movlw H'00'
movwf PORTD
call Delay
goto Main
;--------------------------------------------------------
Delay:
movlw H'FF'
movwf DelayD1
Del1:
movlw H'FF'
movwf DelayD2
Del2:
decfsz DelayD2,1
goto Del2
decfsz DelayD1,1
goto Del1
return
;-------------------------------------------------------
End
;------------------------------------------------------------------------------------------
1. First, the problem is my PIC no response at all.
2. output msg is BUILD SUCCEEDED.
3. this program is only to control LEDs blinking
4. I'm using MPLAP IDE, MPASM Assembler v5.44
5. I used MPLAB SIM to simulated this program
6. The OSCCON i want to set it as 01100010(62H),
but dunno y simulation result is always show that OSCCON is 01100000(60H)
7. This Fcuk-ing shit still doesn't WORK
8. Last, if u guys need any photo or anything else to better understand with my problem, pls feel free to ask, thanks =]