Forum Rule: Always post complete source code & details to reproduce any issue!
Page 4 of 4 FirstFirst ... 2 3 4
Results 76 to 84 of 84

Thread: SPI Flash Allocation Table

  1. #76
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,554
    I think the play objects need to gain some lower latency features (mainly, keeping the file open and ready) on the next major round of audio library work.

  2. #77
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany NRW
    Posts
    5,679
    Paul,

    currently, i'm rewriting my sdfile-flashing-utility.
    Are there known issues with SerialFlash.eraseAll(); ?
    It does not work for me. I'm using it for the Audioshield, together with SD.h

    Code:
      SPI.setSCK(14);  // Audio shield has SCK on pin 14
      SPI.setMOSI(7);  // Audio shield has MOSI on pin 7
    ..
      SerialFlash.begin();    
    ..
      SerialFlash.eraseAll();
      while (!SerialFlash.ready()) {
      }
    Edit:
    - is eraseAll() the correct function to erase the whole chip ?
    Last edited by Frank B; 03-30-2015 at 07:02 PM.

  3. #78
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,554
    Quote Originally Posted by Frank B View Post
    - is eraseAll() the correct function to erase the whole chip ?
    Yes, that's correct.

  4. #79
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany NRW
    Posts
    5,679
    Quote Originally Posted by PaulStoffregen View Post
    Yes, that's correct.
    Can you please give a short example (a few line, not a complete sketch) how to create a file and write it ?
    Your example does only create, but writes no data

  5. #80
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,554
    Quote Originally Posted by Frank B View Post
    Can you please give a short example (a few line, not a complete sketch) how to create a file and write it ?
    Your example does only create, but writes no data
    Here's a new example that fully copies files from the SD code to flash chip.

    https://github.com/PaulStoffregen/Se...CopyFromSD.ino

  6. #81
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,554
    Since this very old thread, the SerialFlash library was written! It gives filesystem-like access to the flash, while preserving the low latency advantage (the reason you'd want to use NOR flash anyway).

    https://github.com/PaulStoffregen/SerialFlash

  7. #82
    Senior Member Pensive's Avatar
    Join Date
    Aug 2014
    Location
    Basingstoke, UK
    Posts
    562
    I'll try and implement it in the next couple of weeks! Thanks Paul.

  8. #83
    Junior Member
    Join Date
    Jun 2015
    Posts
    4
    Is there any way to copy data to SPI flash (via AVR) directly from computer? Like in Copy from SD example?

  9. #84
    Senior Member+ manitou's Avatar
    Join Date
    Jan 2013
    Posts
    2,191
    Not that one would want the overhead of FatFs on a SPI flash, but just for the record, I did get an Adafruit SdFat SPI flash library to work on T3.2 with prop shield SPI flash. Brief discussion here: https://forum.pjrc.com/threads/28505...l=1#post182121

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •