EngineersGarage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise
You are here: Home / Topics / 8051 based problem

8051 based problem

|

Microcontroller › 8051 › 8051 based problem

  • This topic has 23 replies, 8 voices, and was last updated 11 years, 5 months ago by balaji.
Viewing 15 posts - 1 through 15 (of 24 total)
1 2 →
  • Author
    Posts
  • December 13, 2013 at 12:15 pm #4839
    balaji
    Participant

    hi freiends

     

     

    please help me for these bug ,i using 8051 serial communication using printf function and chaeck simulation in proteues they give output differents i check other controllers output should be came 

      

    December 14, 2013 at 11:55 am #10734
    doraemon
    Participant

    Make sure baud rate set by program in 8051 and in virtual terminal of proteus is same.  To change baud rate,parity etc right click on virtual terminal and set it(baud rate same in virtual terminal and that of 8051 program). Hope this may fix problem.

    December 18, 2013 at 8:40 am #10745
    balaji
    Participant

    hi friend

    I put same baud rate only but output didn’t came if use for another controller for check the tx data is correct ,i got the correct data transmission result i just doubt compiler should wrong if u have proteus simulation please check it down 

    December 24, 2013 at 8:43 pm #10754
    Mayukh Sarkar
    Participant

    please provide the code.. I think there is some problem in your printf function or your proteus dll file to virtually create serial terminal, and yes it can be baud rate prob. so please provide the code 

    December 25, 2013 at 6:26 am #10757
    balaji
    Participant
    #include<reg51.h>
     
    sbit sw=P1^0;
    //unsigned char *call_cmd =”ATD9843927672;”;
     
    unsigned char b[]={‘A’,’T’,’D’,’8′,’8′,’4′,’3′,’9′,’2′,’7′,’6′,’7′,’2′,};
    unsigned char i;
    void delay(unsigned char z)
    {
     unsigned int i,j;
     for(i=0;i<z;i++)
     for(j=0;j<1275;j++);
     }
     void trans(unsigned val)
     {
      SBUF=val;
     
      while(TI==0);
      TI=0;
     
      }
     
     
     
     void main()
     {
    P1=0xff;
     
      SCON=0X52;
      TMOD=0X20;
      TH1=0XFD;
      TR1=1;
      TI=1;
      sw=0;
      while(1)
      {
       if(sw==0)
       {
         for(i=0;i<14;i++)
            {
           trans(b);
      delay(50);
       }
    }
      
       }
      }
    December 25, 2013 at 2:15 pm #10759
    Mayukh Sarkar
    Participant

    I don’t see any printf function. Anyway gimme some time & I will get it done 

    December 26, 2013 at 4:28 am #10760
    balaji
    Participant

    hi friend

    thanks for your response

    December 26, 2013 at 10:54 am #10761
    shiva vadla
    Participant

    Hello Balaji……
    pls set proties controller baud rate as 11.0592Mhz….
    double click on controller and set baud rate…….
    i am expectng this may cause problem.

    December 26, 2013 at 11:07 am #10762
    balaji
    Participant

    hello

    we should set the baudrate in virtual terminal only , how set baudrate in controller side

    December 28, 2013 at 11:27 am #10764
    VIJAYAKUMAR
    Participant

    hi balaji 

     

     

     i think so u have to convet the data before sending to serial port

     

    December 28, 2013 at 12:35 pm #10765
    sandeep
    Participant

     

    firstly connect the button  to vcc  from 5v, and while comparing the loop go for while not if, and check the debounce condition also. 

     

    December 28, 2013 at 12:53 pm #10766
    balaji
    Participant

    hi friends

    thanks for your response

     jeyakumar  told convert the data before sending it means i dont know clearly wts conversion here

    i just put a data in SBUF so its FRAMING and sending the data ,if u means use max232 there is no need in proteus simulation

     

     

    and one friend i didnt see the name

    he told the button connecting problem i check and tell me later friend

     

    December 28, 2013 at 1:12 pm #10767
    hiren
    Participant

    how to blow 12v lamp from 8051 microcontroller for 1min time.

    December 28, 2013 at 1:19 pm #10768
    balaji
    Participant

    HELLO HIREN

    if 12 volt bulb first but relay for this 

    and create software for this ,create time delay function for exact 50 ms and use for loop and repat running the delay to 10 times it should give  1sec and u further repat the delay for 60 times u will get a  1 min

    December 29, 2013 at 1:03 pm #10782
    kishore
    Participant

    hi Balaji, 

                 while creating HEX file what was the clock frequency and what is the clock frequency you set in µc. As default in proteus it is 12Mhz. while creating HEX file set xtal as 11.0592Mhz and the µc you used in proteus, double click to see the properties and set clock frequency as 11.0592 Mhz.

    and set virtual terminal as Echo typed character.

     

  • Author
    Posts
Viewing 15 posts - 1 through 15 (of 24 total)
1 2 →
  • You must be logged in to reply to this topic.
Log In

RSS Recent Posts

  • Siemens large industrial PLC parts June 15, 2025
  • Parts required for a personal project June 15, 2025
  • Cant log in to Easy PC forum June 15, 2025
  • Failure of polypropylene motor-run capacitors June 15, 2025
  • Wideband matching an electrically short bowtie antenna; 50 ohm, 434 MHz June 15, 2025

Stay Up To Date

Newsletter Signup
EngineersGarage

Copyright © 2025 WTWH Media LLC. All Rights Reserved. The material on this site may not be reproduced, distributed, transmitted, cached or otherwise used, except with the prior written permission of WTWH Media
Privacy Policy | Advertising | About Us

Search Engineers Garage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise