aboutsummaryrefslogtreecommitdiff
path: root/libraries/Bridge/examples/Datalogger/Datalogger.ino
diff options
context:
space:
mode:
authorFede85 <f.vanzati@gmail.com>2013-06-21 19:48:56 +0200
committerFede85 <f.vanzati@gmail.com>2013-06-21 19:48:56 +0200
commit46d2b1f6a466c2493b89325944a7136826c7bab2 (patch)
treec53f78bfd4e4ce724b0e2c99b360a5e58716d70b /libraries/Bridge/examples/Datalogger/Datalogger.ino
parentafa19e359fb4082e7d54e832effdfacb18bc503a (diff)
renamed SD to FileSystem in FileIO library
Diffstat (limited to 'libraries/Bridge/examples/Datalogger/Datalogger.ino')
-rw-r--r--libraries/Bridge/examples/Datalogger/Datalogger.ino18
1 files changed, 5 insertions, 13 deletions
diff --git a/libraries/Bridge/examples/Datalogger/Datalogger.ino b/libraries/Bridge/examples/Datalogger/Datalogger.ino
index 5412631..dfd269f 100644
--- a/libraries/Bridge/examples/Datalogger/Datalogger.ino
+++ b/libraries/Bridge/examples/Datalogger/Datalogger.ino
@@ -8,8 +8,8 @@
* analog sensors on analog ins 0, 1, and 2
* SD card attached to SD card slot of the Arduino Yun
- You are allowed to remove the SD card while the Linux and the
- sketch is running but becareful to don't remove it while
+ You can remove the SD card while the Linux and the
+ sketch are running but becareful to don't remove it while
the system is writing on it.
created 24 Nov 2010
@@ -29,19 +29,11 @@ void setup() {
// Initialize the Bridge and the Console
Bridge.begin();
Console.begin();
+ FileSystem.begin();
while(!Console){
; // wait for Console port to connect.
}
-
- // see if the card is present and can be initialized:
- if (!SD.begin()) {
- Console.println("SD card failed, or not present");
- // don't do anything more:
- return;
- }
- Console.println("SD card initialized.");
-
}
@@ -62,8 +54,8 @@ void loop () {
// open the file. note that only one file can be open at a time,
// so you have to close this one before opening another.
- // The SD card is mounted at the following "/mnt/sda1"
- File dataFile = SD.open("/mnt/sda1/datalog.txt", FILE_APPEND);
+ // The FileSystem card is mounted at the following "/mnt/FileSystema1"
+ File dataFile = FileSystem.open("/mnt/sda1/datalog.txt", FILE_APPEND);
// if the file is available, write to it:
if (dataFile) {