1
0
mirror of https://github.com/arduino/Arduino.git synced 2024-11-30 11:24:12 +01:00
Arduino/hardware/arduino/avr/libraries/Robot_Control/RobotSdCard.cpp
Cristian Maglie 3394f61276 Merged 1.0.5
2013-05-29 18:30:36 +02:00

22 lines
454 B
C++

#include <ArduinoRobot.h>
void RobotControl::beginSD(){
card.init();
file.init(&card);
melody.init(&card);
}
void RobotControl::_enableSD(){
DDRB = DDRB & 0xDF; //pinMode(CS_LCD,INPUT);
DDRB = DDRB | 0x10; //pinMode(CS_SD,OUTPUT);
}
/*
void RobotControl::sdTest(){
file.open("Infor.txt",O_READ);
uint8_t buf[7];
char n;
while ((n = file.read(buf, sizeof(buf))) > 0) {
for (uint8_t i = 0; i < n; i++) Serial.write(buf[i]);
}
}*/