Issue using DATA statement with 16F1933 in PBP2.60


Closed Thread
Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2003
    Location
    Sydney, Australia
    Posts
    126

    Default Issue using DATA statement with 16F1933 in PBP2.60

    Hi All,

    i have been using the 16F1933 with great success for a while now using PBP2.60 (unpatched), but today went to add the DATA command to load some values to eeprom and save space on doing a static LOOKUP and reduce memory usage.

    When compiling I get the error :
    Address Exceeds Maximum range for this processor

    There is one entry for every byte I am trying to store. The chip has 256 byte of eeprom, but I am only trying to store data in the first 16 positions.

    Code:
    data $00,$3C,$78,$2C,$58,$20,$70,$FF,$00,$00,$00,$01,$02,$03,$03,$03
    Could it be an issue with the P16F1933.BAS file? Looking insode it has
    Code:
    EEPROM  $F000, $F0FF
    But I wonder if it is causing an issue.

    I can manually write the data to the eeprom in the PicKit2 software, but its a pain to do, and I sometimes forget to deselect the EEPROM write flag and loose all the data...

    Anyone got any idea ?

    Bill.

  2. #2
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,614


    Did you find this post helpful? Yes | No

    Question

    Hi, BCD

    Just tried a 16F1933 program ( ADCIN10_1934X.pbp from the Melabs Samples - modified for 16F1933 ), adding your DATA line ...

    No problem, it compiles fine within MCS ide.

    @ First, try to apply the patch ... as there were some little errors about the 16F enhanced series parameters ( shhhht !!! do not repeat it !!! )

    Hope you hadn't made too many mods to your libs ...

    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  3. #3
    Join Date
    Feb 2003
    Location
    Sydney, Australia
    Posts
    126


    Did you find this post helpful? Yes | No

    Default

    Ha Alain,

    Tried the 2.60a patch, but it made no difference.

    Even a very simple program with the DATA statement shows the issue.

    I wonder if its a MPASM thing ? What version are you running ? I have 5.34, but other than the EEPROM address thing it runs fine !

    bill

  4. #4
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,614


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by bcd View Post
    Ha Alain,

    Tried the 2.60a patch, but it made no difference.

    Even a very simple program with the DATA statement shows the issue.

    I wonder if its a MPASM thing ? What version are you running ? I have 5.34, but other than the EEPROM address thing it runs fine !

    bill
    Hi, Bill

    Here, I Have the latest 8.53 MPLAB release , I think MPASM is v 5.36 .
    I try it into MPLAB ide, as it didn' produce any problem within MCS ...

    read you soon ...
    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  5. #5
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,614


    Did you find this post helpful? Yes | No

    Default

    Bad news for you ...

    Executing: "C:\Program Files\Microchip\MPLAB IDE\PBP\PBPMPLAB.BAT" -ampasmwin -k# -p16LF1933 "Datatest.bas"
    Executing: "C:\Program Files\Microchip\MPLAB IDE\PBP\PBPW.EXE" -ampasmwin -k# -p16LF1933 "Datatest.bas"
    PICBASIC PRO(TM) Compiler 2.60A, (c) 1998, 2010 microEngineering Labs, Inc.
    All Rights Reserved.
    Loaded C:\Program Files\Microchip\MPLAB IDE\Projets\Datatest.COF.
    BUILD SUCCEEDED: Sun Aug 08 14:07:27 2010
    so, I only can recommend some PBP re-installation, re-patching ... and MPLAB 8.53 Update ...

    I attach my test-project

    Alain
    Attached Files Attached Files
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  6. #6
    Join Date
    Feb 2003
    Location
    Sydney, Australia
    Posts
    126


    Did you find this post helpful? Yes | No

    Smile Fixed it !

    I did the upgrade to 2.60a and it made no difference.

    What got it working was to upgrade MPASM to 5.36 through an update to MPLAB.
    Looking through the release notes it mentions issues with memory assignments for the 16F1xxx series, although in typical Microchip fashion you need to read between the lines.

    Thank you for your testing and pointing me in the right direction !

    Bill.

Members who have read this thread : 1

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