What am I doing wrong ?


Closed Thread
Results 1 to 21 of 21

Hybrid View

  1. #1
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e
    so it seems you didn't read the FAQ
    pay attention to post #5 of the link bellow
    http://www.picbasic.co.uk/forum/showthread.php?t=543
    Thanks for the link, and whist I did look at the FAQ's.. I must admit that I didn't scroll down much further than the original post - Sorry !

    However the good news is that the LED is now pulsing away on GPIO 0

    However I really want to learn from this and I'm a tad confused (easy to do). Whats the difference between having the line in the program code and the INC file. ?

    I found that if I removed the line
    Code:
    @ __CONFIG _INTRC_OSC_NOCLKOUT & _WDT_ON & _PWRTE_ON & _MCLRE_OFF & _BODEN_ON
    from the programing code and left the INC file intact the program compiled but the LED did nothing. - Reming out the line in the INC file and adding it to the code file, resulted in the code compiling without errors and the LED is pulsing away fine !

    Should (or is that could) I use the INC file and have some statement in the programming code to call this file (something like include 12F675.inc)

    Also, will I have to modify every INC file for every PIC that I use so i don't get this problem again ?

    Cheers

    Malc

  2. #2
    Join Date
    Feb 2003
    Location
    Salt Lake City, Utah USA
    Posts
    517


    Did you find this post helpful? Yes | No

    Red face oops!

    Although technically correct, after some sleep and a few cups of coffee I can see that my suggestions would not have helped you. (#5 in this thread)

    good luck,

    Paul

  3. #3
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Yeah it's pain dude, you'll have to modify all .INC for all PIC you have in stock. The MPAM 'errorlevel -' stuff can't work on that... it would be just too much convenient.

    I already think of doing an automatic application to comment out every .inc file... maybe i'll do it one day... maybe

    But i think that even if you get this Error message, your config fuse will be set as per your code. It will just be an error message like the one for Page Boundary, or Find directive in column x, or... ,.. wich can be ignored. It's just unplesant to see it in your face
    Last edited by mister_e; - 9th June 2006 at 23:53.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  4. #4
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    I guess its all part of the learning curve ! As I stick to just two or three PICs I can't really moan about having to rem out the config line... I had a look at the 16F628a inc file and that too was remed out.. just don't remember doing it (like a lot of things these days... must be getting old !)

    Thanks for all the pointers and help

    Malc

Similar Threads

  1. LCD Showes Some Wrong Letters
    By sbobowski in forum General
    Replies: 2
    Last Post: - 23rd September 2008, 20:15
  2. Anyone know whats wrong with this code
    By Bonxy in forum Serial
    Replies: 10
    Last Post: - 9th March 2007, 17:29
  3. ADCIN - AD settings are wrong
    By teverett in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 4th December 2006, 17:32
  4. What am I doing wrong?
    By mankan in forum General
    Replies: 1
    Last Post: - 23rd June 2006, 20:03
  5. HDD IDE ATA 2 interface problems. code wrong?
    By rastan in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 27th March 2005, 17:01

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts