SG 2025


 

 

 

PIC18F55Q43
||
PIC16F15385

 

 

 

XLP ±â¼úÀÌ Àû¿ëµÈ 28/40/44/48ÇÉ, ÀúÀü·Â, °í¼º´É ¸¶ÀÌÅ©·ÎÄÁÆ®·Ñ·¯

28/40/44/48-PIN, LOW-POWER, HIGH-PERFORMANCE MICROCONTROLLER WITH XLP TECHNOLOGY

PPS Àá±Ý ½ÃÄö½º(C ¾ð¾î)

INTCON0bits.GIE = 0 ;         //ÀÎÅÍ·´Æ® ÀϽÃÁß´Ü
PPSLOCK = 0x55 ;              //Çʼö ½ÃÄö½º
PPSLOCK = 0xAA ;              //Çʼö ½ÃÄö½º
PPSLOCKbits.PPSLOCKED =
1 ;   //PPSLOCKED ºñÆ® ¼³Á¤  (1: Àá±Ý, 0 : ºñÆ® Áö¿ì±â)
INTCON0bits.GIE = 1 ;         //ÀÎÅÍ·´Æ® º¹¿ø

PPS Lock Sequence (C language)

INTCON0bits.GIE = 0;         //Suspend interrupts
PPSLOCK = 0x55;              //Required sequence
PPSLOCK = 0xAA;              //Required sequence
PPSLOCKbits.PPSLOCKED = 1;   //Set PPSLOCKED bit
INTCON0bits.GIE = 1;         //Restore interrupts

PPS Unlock Sequence (C language)

INTCON0bits.GIE = 0;         //Suspend interrupts
PPSLOCK = 0x55;              //Required sequence
PPSLOCK = 0xAA;              //Required sequence
PPSLOCKbits.PPSLOCKED
= 0;   //Clear PPSLOCKED bit
INTCON0bits.GIE = 1;         //Restore interrupts

PPS Lock Sequence (assembly language)

 ; suspend interrupts
    BCF      INTCON0,GIE
    BANKSEL  PPSLOCK        

 ; required sequence, next 5 instructions
    MOVLW    0x55
    MOVWF    PPSLOCK
    MOVLW    0xAA
    MOVWF    PPSLOCK

 ; Set PPSLOCKED bit
    BSF      PPSLOCK,PPSLOCKED

 ; restore interrupts
    BSF      INTCON0,GIE

 

 

Åë½Å °ü·Ã ¼±Åà °¡´ÉÇÑ ÇÉ Grid

 

 

 

 



New Projet ¸¸µé±â

 

MPLAB X IDE¿¡¼­ È­¸éÀÇ ¿ÞÂÊ »ó´Ü¿¡ New Project¸¦ Ŭ¸¯ÇÑ´Ù.

Ctrl + Shift + N

³ë¶õ»ö ¾ÆÀÌÄÜÀ» Ŭ¸¯Çϰųª ¸Þ´º¿¡¼­ File - New Project¸¦ ¼±ÅÃÇÑ´Ù.

 

1. Choose Projet

 

2. Select Device & Tool

 

3. Select Compiler (XC8 ¼±ÅÃ)

Compiler XC8  v2.00 ¡æ V2.41 (Q43 µî ½ÅÇü Chip)

 

4. Select Project Name & Folder  (Project Folder°¡ xxx.X·Î ¸¸µé¾îÁü)

 

5. ±âÁ¸ Hi-Tech C ÆÄÀÏ ºÒ·¯¿À±â

 

 

6. Configration bit ¼³Á¤ ÇØ¾ß ÇÔ




¼³Á¤ ÈÄ, ¾Æ·¡ ¹öÆ°À» ´©¸¥ ÈÄ



Ç쫆 ̢¿¡ ¸¸µé¾îÁö¸é ¼Ò½º¿¡ ºÙ¿© ³Ö´Â´Ù.

 

 

7. ÄÄÆÄÀÏ ÇÑ´Ù.

 

 

8. ´Ù¿î·ÎµåÇÑ´Ù.

 

 

--- ³¡ ---

 

 


 

 

 

Build Project (Comfile)

 

 

 

 

Clean and Build with PRO Comparison (Comfile)

 

 

Program Device for Production (Down Load)

 

 

 

 


 

 

 

 

 

 


 

 



2 SPI, 2 UART, RUN LED

SPI  :  Host / Client