+ Post New Thread
Results 1 to 4 of 4
  1. #1
    Junior Member level 2
    Points: 159, Level: 2

    Join Date
    Jan 2014
    Posts
    23
    Helped
    1 / 1
    Points
    159
    Level
    2

    Communication Between Two at89s52 microcontroller using i2c

    Hi,
    Every one First of all i wanna thank this forum it is much helpfull for begainers

    Sir
    I want to communicate two microcontroller (at89s52) through i2c i m totally new in this feild i hav knowlegde about i2c ..

    But sir i want help frm u guys how can i communicate them plz help me with a short example.........

    •   Alt28th January 2014, 08:27

      advertising

        
       

  2. #2
    Advanced Member level 2
    Points: 4,494, Level: 15
    Genovator's Avatar
    Join Date
    Dec 2011
    Location
    India
    Posts
    499
    Helped
    76 / 76
    Points
    4,494
    Level
    15
    Blog Entries
    1

    Re: Communication Between Two at89s52 microcontroller using i2c

    There's already on-chip UART in 89s52. You can use it for simplicity. Is there any specific reason for choosing I2C???

    The best common technique for implementing SPI or I2C on 8051's is bit banging by using "RLC" in assembly. Refer to this:
    http://www.8051projects.net/i2c-twi-...ementation.php
    Wading all day.....


    1 members found this post helpful.

    •   Alt28th January 2014, 09:17

      advertising

        
       

  3. #3
    Junior Member level 2
    Points: 159, Level: 2

    Join Date
    Jan 2014
    Posts
    23
    Helped
    1 / 1
    Points
    159
    Level
    2

    Re: Communication Between Two at89s52 microcontroller using i2c

    Quote Originally Posted by Genovator View Post
    There's already on-chip UART in 89s52. You can use it for simplicity. Is there any specific reason for choosing I2C???

    The best common technique for implementing SPI or I2C on 8051's is bit banging by using "RLC" in assembly. Refer to this:
    http://www.8051projects.net/i2c-twi-...ementation.php
    no there is no any specific reason but sir i working on a fire alarm project where i hav to communicate them can u plz tell me abt uart pins

    can u plz tell me about UART pins in at89s52



    •   Alt28th January 2014, 10:12

      advertising

        
       

  4. #4
    Advanced Member level 2
    Points: 4,494, Level: 15
    Genovator's Avatar
    Join Date
    Dec 2011
    Location
    India
    Posts
    499
    Helped
    76 / 76
    Points
    4,494
    Level
    15
    Blog Entries
    1

    Re: Communication Between Two at89s52 microcontroller using i2c

    Refer to 89s52 datasheet, Pin 3.0 & 3.1 are dedicated UART pins RXD & TXD. RXD receives serial data while TXD transmits. But there are lots of modes for that. You have to configure UART by generating specific baud rate by T2CON register, setting SCON register, reading or writing the transmitting data in SBUF register. Its easy to configure unlike I2C.
    There are lot of things to know. Refer to the following.

    http://www.atmel.com/Images/doc4316.pdf
    http://www.8052.com/tutser.phtml
    http://www.atmel.in/Images/doc4346.pdf
    http://www.atmel.in/tools/CODEEXAMPLESFOR8051UART.aspx

    Do some google search first...
    Wading all day.....



+ Post New Thread
Please login