zip

PIC16F877 MCU Hardware IIC Programming Example

  • 2013-09-22
  • 5.04KB
  • Points it Requires : 2

BANKSEL I2C_Addr ; The \"BANKSEL\" may not necessary if I2C_Addr is @ the same bank with SSPBUF movf I2C_Addr,W ; The Address you wish to \"READ\" from BANKSEL SSPBUF movwf SSPBUF call WaitI2C call RstartI2C ; Restart Condition !! call WaitI2C ; Wait Until Restart OK !! BANKSEL SSPBUF movlw B\'10100001\' ; Write Read Command movwf SSPBUF call WaitI2C call RecI2C ; Enable I2C Receive call WaitI2C ; Wait Until Buffer Received BANKSEL SSPBUF movf SSPBUF,W ; Save to I2C_Data First !!

unfold

You Might Like

Uploader
jasionla
 

Recommended ContentMore

Popular Components

Just Take a LookMore

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
×