Im going to order 2 of each package: SOIC, SSOP, QFN the PDIP isnt in stock at mouser so cant order it. But I can make a adapter for SOIC in like 15 min from plan to pcb so not a issue
SCRATCH THAT... ill order from digikey they also have the DIP so ill order 2 of : DIP, SOIC,QFN...
MPLINK 4.39, Linker
Device Database Version 1.1
Copyright (c) 1998-2011 Microchip Technology Inc.
Error - section '.udata_main.o' can not fit the section. Section '.udata_main.o' length=0x0000044e
Errors : 1
thanks ill try that out now. I hate linker files.. they should have never made them heh... PIC are the only MCU i know with linker files and i have tested a ton of MCUs heh
Oh yeah, i just ordered the parts.. but since its sunday wont ship til tomorrow
OK i want to get my COMMENT scheme going.. is this understandable ?
Code:
/*
READ: This command reads a file.
Parameters include:
READ SSSS C F...
SSSS = Seek Location, where to start when getting data (4 BYTES + SPACE)
C = Count of bytes to return, MAX 128 (1 BYTE + SPACE)
F... = FILE NAME (UP TO 120 BYTES + SPACE)
EXAMPLE: READ 0000 10 HELLO.TXT
The above example will return the first 10 bytes in the file HELLO.TXT
*/
The raw directory listing is good, but a search function would be valuable. The average user doesn't care what the entire contents of a directory are, just if a certain file is there or not. This can be coded by hand of course from the raw directory listing, but an inbuilt function to do this would make it FAR more useful to newbs.
LIST ALL FILES AND DIRECTORIES === DONE!
READ A FILE ================== DONE!
WRITE TO A FILE =============== NOT DONE!
APPEND TO A FILE ============== NOT DONE!
LIST FILES ONLY =============== DONE!
LIST DIR ONLY ================ DONE!
FIND A FILE ================== DONE!
FIND A DIR =================== DONE!
I personally wouldn't notate each individual function like that at the function location, that should probably be done at the begging of the file, basically as soon as you open it up you see all the instructions of use and then you just use simple comments at the function level to refer to the note in the comments section, that way your comment section and code section are separate. Notation of individual functions should be kept to a minim as most C code is pretty readable, if you're doing anything you think is a little 'tricky' to understand in the specific function toss a comment in on it.
I think the find function should be a little more sophisticated, but that's only if you're interested in adding additional functionality at the expensive of the time it'll take you to code it, I think you should get your write/append done before you do anything else. There should be two search modes, one that will search for a filename and will return the full directory path of each instance of that filename searching the entire FAT system, and one that works as you describe to simply return a yes/no if there is a file in a specific location.
Ah, i see I like the comments in line ... but people can remove or rearrange if they want. Since this is free for all im not going to kill myself heh.. but ill add that FIND FILE IN FAT [FFIF] function to search through it all..
Ill create the WRITE FILE and APPEND FILE first. I have been putting it off but dont know why ? i guess reading was more important to me at first
Writing is FAR more difficult and appending no easier. I've seen many file system implementations that have bugs or stopped at write functions because they look at it and went 'you need me to do WHAT?' Fat is easier than something like NTFS