Component Test's Software to work with "Universal Controller Box" - Software is an interpreter or "compiler" for programs to be done with a .txt file and read off of the SD Card
Dependencies: BridgeDriver FrontPanelButtons MCP23017 SDFileSystem TextLCD mbed
Diff: TextFile.h
- Revision:
- 6:d1594fd2ec5a
- Parent:
- 5:e36e0538a903
- Child:
- 9:5a0c4c6e39c7
diff -r e36e0538a903 -r d1594fd2ec5a TextFile.h --- a/TextFile.h Tue Sep 23 18:24:19 2014 +0000 +++ b/TextFile.h Tue Sep 23 23:42:32 2014 +0000 @@ -32,10 +32,21 @@ // read file names into vector of strings vector<string> readFileNames(char *dir) { + lcd.setAddress(0,1); + lcd.printf("TEST1"); + vector<string> filenames; DIR *dp; struct dirent *dirp; + + lcd.setAddress(0,2); + lcd.printf("TEST2"); + dp = opendir(dir); + + lcd.setAddress(0,3); + lcd.printf("TEST3"); + //read all directory and file names in current directory into filename vector while((dirp = readdir(dp)) != NULL) { filenames.push_back(string(dirp->d_name)); @@ -119,9 +130,14 @@ - lcd.setAddress(0,1); + lcd.setAddress(0,2); lcd.printf("Current Line#: %d ", lineData.lineNumber); + lcd.setAddress(0,3); + lcd.printf(" "); // Clear the Line using Spaces (Emptyness) - Note one line is 20 Characters + lcd.setAddress(0,3); + lcd.printf("cmd/dvc: %s", lineData.word[0]); + /* lcd.cls(); //clear the display lcd.setAddress(0,0);