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 / Replies / im using these codes#include

im using these codes#include

|

Microcontroller › 8051 › serial communication between pc and AT89c52 › im using these codes#include

May 10, 2012 at 8:10 am #7704
bll
Participant

im using these codes

#include <regx52.h>
unsigned char a ;

void main(void)
{

TMOD=0x20;
TH1=0xFD;
SCON=0x50;
TR1=1;

IE=0X00;

while(1)
{
while(RI==0);
a=SBUF;
P1=a;
RI=0;
}

}

 

 

 

 

 

but there is a problem at receiving data, i send numbers from 0 to 15, i got them properly at 89c52, but after 15 it doesnt work properly?, i cant see what is the problem.

RSS Recent Posts

  • Looking for single photovoltaic cells for light gate December 6, 2025
  • My Advanced Realistic Humanoid Robots Project December 6, 2025
  • Basics of induction. December 5, 2025
  • I am ready to move from electrical and electronics field but confused where ? December 5, 2025
  • 1.1kV Cockroft-Walton 200J Capacitor Charger December 4, 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