Menu

12F1xxx file save bug: temp solution...

Anonymous
2019-02-22
2019-02-22
  • Anonymous

    Anonymous - 2019-02-22

    To solve the little 12F1xxx save file bug I am doing the following:

    Command Line for the 12F1822:
    WRITING
    op -d 12F1822 -w blabla.hex

    READING
    op -d 16F1823 -s readedBlabla.hex

    12F1822 and 16F1823 flash sizes are the same, 2k.


    Command Line for the 12F1501:
    WRITING
    op -d 12F1501 -w blabla.hex

    READING
    op -d 16F1503 -s readedBlabla.hex

    "Tricking" op the source code:
    Changed "deviceRW.c" 16F1503 from 2k flash to 1k flash, same of 12F1501...

        PIC16,8.5,1,Read16F1xxx,{0x800,0,11,0},0x200,.....
    change to
        PIC16,8.5,1,Read16F1xxx,{0x400,0,11,0},0x200,.....
    

    Both cases seems to work OK, for while I think it is enough for what I need...

    Valter

     
  • Alberto Maccioni

    The actual fix is even easier:
    in fileio.c modify line 51 and comment line 52
    int x=0x3fff,addr;
    //if(!strncmp(dev,"16",2)||!strncmp(dev,"12F6",4)) x=0x3fff;

     
    • Anonymous

      Anonymous - 2019-02-22

      Wow, that's all?
      Yesterday I start to look at the CLI code, trying to see where the problem was...
      Had some difficult at first, but then, instead, just occurs to me to trick the code as a temp solution... lol...

      Thanks, I will change the code as suggested...
      The reason for the CLI write and read is that I am trying to create a STANDARD procedure to help users test new/untested devices, generated infos/log and then post the result so that you can use to update the website...
      For the procedure, I think that CLI commands will offer flexibility to make tests as "standard" as possible, thus keep a pattern in terms of procedures...

      Valter

       

Anonymous
Anonymous

Add attachments
Cancel





Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.