Another 2.60 worry


Closed Thread
Results 1 to 19 of 19

Hybrid View

  1. #1
    Join Date
    Aug 2010
    Location
    Maryland, USA
    Posts
    869


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    I assume they are not commented in the include file? I usually give the file a PBP extension, but I doubt that is it.Can you attach the .lst file created when you use the include?
    -Bert

    The glass is not half full or half empty, Its twice as big as needed for the job!

    http://foamcasualty.com/ - Warbird R/C scratch building with foam!

  2. #2
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    Just my thoughts . . . change the file extension to .bas and make it the first line of code . . .
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  3. #3
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    I just override settings at the top of my programs.

    Code:
    ' PicBasic Pro program
    ' Michelle Science Project
    ' Game Show Buttons, version 1, April 2011
    
    ASM
    @ DEVICE PIC16F877, HS_OSC, WDT_OFF, PWRT_ON, BOD_ON, LVP_OFF, CPD_OFF, WRT_OFF, DEBUG_OFF, PROTECT_OFF
    ENDASM
    
    DEFINE OSC 20       ' 15-33pF (22pF used)
    
    yada yada yada
    I could be using the default values; I never bothered to check.

    But as someone said, I don't loose settings with future upgrades. Or worse, have the default settings changed and pull what little hair I have left trying to find what is wrong in my code.
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  4. #4
    Join Date
    Mar 2009
    Location
    Colorado
    Posts
    378


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    Quote Originally Posted by cncmachineguy View Post
    I assume they are not commented in the include file? I usually give the file a PBP extension, but I doubt that is it.Can you attach the .lst file created when you use the include?
    I found what apparently was causing the problem, but don't quite understand why. I changed the file extension to .pbp and had it in a 2nd level folder below my PBP folder while my application code resides in a 3rd level folder. IT was my understanding that as long as an include file was in a folder at a higher level than the code that was using it, that the INCLUDE statement would find it. However, unless I placed the include file in the same folder as my application code or moved the file to the PBP folder my application code wouldn't work. As long as it was in the 2nd level folder my application code wouldn't work.

    Can anyone tell me how this works?

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


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    Just specify the path in your include line then. I do it all the time.

    I have a root folder named PBP_PROG and some subfolders. One subfolder by application and a couple of other for various include type (DevBoards headers, LCD/GLCD drivers/wrapper, etc etc etc)
    C:\PBP_Prog
    C:\PBP_Prog\DemoXyz
    C:\PBP_Prog\Nokia3310

    Assuming I'm working on a prgram located in DemoXyz folder, If I want to use the Nokia3310 related include I just need to use the following line
    INCLUDE "..\Nokia3310\GLCD_NOKIA.PBP"

    the file extension do not make any difference, it could be .inc, pbp, bas, bak.. whatever.

    For Win7/Vista, you may have a error message if the path+filename exceed 32 characters (or so)

    All config fuses are in my code, never elsewhere/ I comment out the one in the PBP folder all the tie. Fortunately now with PBP3 we no longer need to do so. This reminds me I need to upgrade today... where<s my proof of purchase now... arg... I know I have it somewhere. Back in 1999/2000
    Last edited by mister_e; - 8th August 2011 at 20:29.
    Steve

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

  6. #6
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    Quote Originally Posted by mister_e View Post

    the file extension do not make any difference, it could be .inc, pbp, bas, bak.. whatever.
    :
    As I continue to learn . . .
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

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


    Did you find this post helpful? Yes | No

    Default Re: Another 2.60 worry

    figure an include to be nothing more than a text substitution... on a single line.
    Steve

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

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