Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

line means?

Status
Not open for further replies.

tuls

New Member
hello Nigel, Can you please explain me what does the below line means, in detail.

LIST p=16F877A, W=2, X=ON, R=DEC

I'm Very new to PIC micro-controllers. I've referreed to your tutorials. Actually i'm using 16f877A and i've changed your sample program. i have connected MCLR pin with +5v line. Whenever i start the system i get blank screen (LCD) i disconnect the MCLR from +5v line and then reconnect and then the data is displayed on LCD? what can be the
reason?
 
tuls said:
hello Nigel, Can you please explain me what does the below line means, in detail.

LIST p=16F877A, W=2, X=ON, R=DEC

I'm Very new to PIC micro-controllers. I've referreed to your tutorials. Actually i'm using 16f877A and i've changed your sample program. i have connected MCLR pin with +5v line. Whenever i start the system i get blank screen (LCD) i disconnect the MCLR from +5v line and then reconnect and then the data is displayed on LCD? what can be the
reason?

That line just sends instructions to the assembler, it's explained in the MPASM helpfile.

p - sets the processor type
w - sets the message level
x - sets macro expansion ON or OFF
R - sets the default radix (number system), in this case to decimal.

How have you set the config fuses for the 16F877?.
 
thanks for replying here is config for pic16f877a

LIST p=16F877A, W=2, X=ON, R=DEC ;tell assembler what chip we are using
include "P16F877A.inc" ;include the defaults for the chip
ERRORLEVEL 0, -302 ;suppress bank selection messages
__CONFIG 0x393A ;sets the configuration settings (oscillator type etc.)
 
tuls said:
thanks for replying here is config for pic16f877a

LIST p=16F877A, W=2, X=ON, R=DEC ;tell assembler what chip we are using
include "P16F877A.inc" ;include the defaults for the chip
ERRORLEVEL 0, -302 ;suppress bank selection messages
__CONFIG 0x393A ;sets the configuration settings (oscillator type etc.)

Thats for a 16F877, NOT a 16F877A (which has different fuse settings).

Try __CONFIG 0x290A or __CONFIG 0x2902
 
i tried those but my programmer shows fuse error
 

Attachments

  • fuse.jpg
    fuse.jpg
    80.6 KB · Views: 366
tuls said:
i tried those but my programmer shows fuse error

Read the chip back to make sure it's actually programmed the fuses, which it probably has.

The values I gave only set the bits which are used, WinPicProg masks off any unused bits when it verifies, some programmers expect them to be '1'. But as it's just a verify error, the chip should be programmed OK.

Try it, and see if it works any better?.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top