Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Pic16f877a+uart+max232+rs232 work in simulation and dosnt work in real

Status
Not open for further replies.

Cry Heart

Newbie level 3
Joined
Aug 5, 2011
Messages
4
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,303
i have problem about connect PIC16F877A with pc
when connect microcontroller to pc using serial port and max23
received zero
and when i send any char received zero too
hex works in proteus (send and receive)
and microcontroller works
and max232 works too

This is the full code just to test
Code:
void main()
{
USART_init(9600);
trisb=00000000;
portb=00000000;
while  (1)
          {
          portb.f0=1;
           if (usart_data_ready()==1)
              {
 
                 if(usart_read()=='1')
                {
                     usart_write('A');
                  }
 
              }
        }
 
 }

**broken link removed**
In real mode
**broken link removed**

In simulation mode
**broken link removed**
Use JDM Programmer

**broken link removed**

**broken link removed**

Use MAX232
(MAXIM) MAX232EPE
 

Hi,

also face this problem, till now i didn't get any solution.....
 

I was afraid you were?

If the program performs as expected in Proteus, but not in the physical circuit, it is most likely an issue with configuration bit/fuse, clock frequency or some other settings.

What version of MicroC and PICFlash are you using?

---------- Post added at 18:48 ---------- Previous post was at 18:45 ----------

Looking back over the thread, I just notice your were using a JDM programmer. Does this require the use of a separate GUI programmer interface other than PICFlash?
 

Designed the program already in vb.net
 

How are you setting your configuration bits/fuses? When using MicroC this is usually accomplished by settings in the PICFlash Utility. I believe the clock speed is also designated at that point as well.

By the way, Proteus does not require most of the settings to successfully simulate the code. This may account for your application running in Proteus and not in physical hardware.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top