1. 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.
    Dismiss Notice

Oshonsoft Basic and SD Cards

Discussion in 'Oshonsoft' started by ericgibbs, Jan 7, 2016.

  1. ericgibbs

    ericgibbs Well-Known Member Most Helpful Member

    Joined:
    Jan 4, 2007
    Messages:
    21,180
    Likes:
    644
    Location:
    Ex Yorks' Hants UK
    ONLINE
    hi,
    Has any other user of SD Card Oshonsoft Basic been successful in getting the following commands to work.?

    SDCardFAT32FileExists and SDCadFAT32Dir

    So far I have been able to Init, Create, Write, Append, Close and Delete files OK.

    I am using a 18F4520 PIC, 8Gb SD Cards and a USB SD Card Writer/Reader for checking the SD Card files, also to format the cards for FAT32 use.

    There also appears to be two other problems.

    I have been unable to construct a new file name that the Compiler will allow, it appears that the any file name has to be written as part of the main program.

    Also after a Card File Read operation the file-length is zeroed!, so its not possible to Write/Append any further data to the file.

    Eric

    I did raise a bug report to Vlaidir sometime ago regarding the File-exists and Dir, but got no useful reply.

    If others are experiencing the same problems I will re-contact Vlad and tell him its got to be fixed.
     
    Last edited: Jan 7, 2016
  2. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,151
    Likes:
    907
    Location:
    Rochdale UK
    ONLINE
    I cant get any of it to work as you know... The only thing I can get is SD card type.... That all!!
     
  3. ericgibbs

    ericgibbs Well-Known Member Most Helpful Member

    Joined:
    Jan 4, 2007
    Messages:
    21,180
    Likes:
    644
    Location:
    Ex Yorks' Hants UK
    ONLINE
    hi Ian,
    My project is working fine on all the FAT32 commands except the two commands that will not execute,, the file exists command locks up the program.

    For a temporary get around of the file-exists and the 'fixed' file names, I am using the PIC's internal eeprom to save a file incremented count value, then use that value in a Select Case routine.
    ie:
    case 0
    create or append file0.txt
    Write 10, 1
    case 1
    create or append file1.txt
    Write 10,2

    etc
    ............................

    It's a little crappy but it enables me to move forward with my project.

    Eric
    I have also posted my initial post/thread to Oshonsoft/Yahoo group.
     
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,151
    Likes:
    907
    Location:
    Rochdale UK
    ONLINE

    I tend not to use Oshonsoft anymore.... Things keep changing plus I have now transferred all of my code to XC8 so it suits me better!! I use the SD routines from Motty22's web pages... They are that petite fat... Works okay on a pic16f4620...
     

Share This Page