mmc fat16 write problem

Discussion in 'Embedded Systems and Microcontrollers' started by wael_73, Feb 26, 2011.

  1. wael_73

    Thread Starter New Member

    Nov 13, 2008
    hi , i want to make txt file on mmc (fat16) , I want to send special key to txt file such as ( enter key to make newline) and (tabe key to separate bt words) , i make the file and send characters to it but i cannot make newline or separate tab bt words . can you help me plz.
  2. beenthere

    Retired Moderator

    Apr 20, 2004
    Is this text you are typing in or are you formatting an existing text file?

    In any case, the newline indicator is usually a carriage return and a line feed. The control codes are in both ASCII and Unicode. The tab code is there, too.

    Are you sure you can't insert these control codes, or is the app reading the file unable to handle them?
  3. haridas

    New Member

    Dec 5, 2012
    how can I send command tor card from the controller. I want to know how could I load the command register. is it simply loading the command number like for CMD0 simply load the cmd register with 0 and for cmd17 with 17 ih hexa
  4. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    You owuld need some sort of file system code. Elm softwares has a generic fat file system, you may find an example for your controller.

    Microchip has libraries and example programs for several PICs, but it is NOT a small bit of code. The last time I used it on a PIC18 device I believe it took near 30K instructions.