1˵

    չʾΪӻʹI2Cжշݡ   

2ʹû

   
        IDEߣKEIL MDK-ARM 5.34.0.0
    
    Ӳ
        壺N32G003F5S7-STB V1.0


3ʹ˵
	
    1ʱӣ48MHz
    2I2C ã
            SCL   -->  PA4          
            SDA   -->  PA5         
            CLOCK:100KHz
            
    3UART1ã
            TX  -->  PA2   
            RX  -->  PA3           
            ʣ115200
        

    4Բ
        aI2C
        bش븴λ
        cӴڿӡϢ֤

4ע
    SCLSDA

1. Function description

     This example demonstrates the use of I2C interrupts to send and receive data as a slave.

2. Use environment

    Software development environment:
         IDE tool: KEIL MDK-ARM 5.34.0.0
    
     Hardware environment:
         Development board: N32G003F5S7-STB V1.0


3. Instructions for use

     1. Main clock: 48MHz
     2. I2C configuration:
             SCL --> PA4          
             SDA --> PA5          
             CLOCK: 100KHz
            
     3. UART1 configuration:
             TX --> PA2
             RX --> PA3
             Baud rate: 115200
        

     4. Test steps and phenomena
         a, the jumper wire connects the master I2C
         b, compile and download the code, reset and run
         c, view the print information from the serial port and verify the result

4. Matters needing attention
     SCL and SDA must be pulled up