Shop OBEX P1 Docs P2 Docs Learn Events
FSRW or Kye DOS in GCC? — Parallax Forums

FSRW or Kye DOS in GCC?

RaymanRayman Posts: 14,671
edited 2012-08-18 15:25 in Propeller 1
Are there any example projects out there yet that can open, read and write to SD card files?

Comments

  • Dave HeinDave Hein Posts: 6,347
    edited 2012-08-18 12:41
    There is a demo program in demos/c3files. PropGCC uses it's own file routines. Look at filetest.c in the src directory for an example of how to do file I/O in GCC.
  • RaymanRayman Posts: 14,671
    edited 2012-08-18 12:44
    Thanks Dave.

    BTW: How does the file read speed compare with FSRW under Spin?


    Actually, I can't find "demos/c3files" anywhere... Is it installed with SimpleIDE?
  • jazzedjazzed Posts: 11,803
    edited 2012-08-18 13:09
    Rayman wrote: »
    Actually, I can't find "demos/c3files" anywhere... Is it installed with SimpleIDE?

    It's part of the propgcc/demos package. Attached is a version I use with SimpleIDE on C3. The board type should choose the Sd Card configuration.
  • RaymanRayman Posts: 14,671
    edited 2012-08-18 13:42
    Ok, thanks, I'll see if I can find that.

    Does anybody know how this SD card read speed compares with FSRW in Spin?
  • jazzedjazzed Posts: 11,803
    edited 2012-08-18 13:49
    Rayman wrote: »
    Ok, thanks, I'll see if I can find that.

    Does anybody know how this SD card read speed compares with FSRW in Spin?

    I've never done any speed testing with it. Dave Hein developed most of the SD card library and test code.
    I believe the actual hardware interface is done in PASM, so the library should at least match or beat FSRW speed.

    I'll be away from home the rest of the day today.
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-08-18 14:16
    I haven't done any speed testing either. I suspect it may be slower than FSRW because the LMM version uses a buffer that is smaller than 512 bytes for each open file. This causes the same block to be re-read a few times as small chunks are read from the file. The FSRW and PropGCC speeds might be comparable when reading large chunks at a time. It would be good to run some tests to compare performance.
  • RaymanRayman Posts: 14,671
    edited 2012-08-18 15:25
    Ok, 80% of FSRW would be OK. But, at a minimum, being able to play 48ksps 16-bit stereo wave files would be good.
Sign In or Register to comment.