1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-07-27 18:02:17 +03:00

examples: format all .ino files

This formats all the example source files using Arduino style rules.
This commit is contained in:
Ivan Grokhotkov
2018-02-19 18:30:59 +03:00
committed by Ivan Grokhotkov
parent e226251b27
commit 61cd8d8385
88 changed files with 2730 additions and 2801 deletions

View File

@ -1,32 +1,31 @@
/*
SD card datalogger
This example shows how to log data from three analog sensors
to an SD card using the SD library.
This example shows how to log data from three analog sensors
to an SD card using the SD library.
The circuit:
* analog sensors on analog ins 0, 1, and 2
* SD card attached to SPI bus as follows:
The circuit:
analog sensors on analog ins 0, 1, and 2
SD card attached to SPI bus as follows:
** MOSI - pin 11
** MISO - pin 12
** CLK - pin 13
** CS - pin 4
created 24 Nov 2010
modified 9 Apr 2012
by Tom Igoe
created 24 Nov 2010
modified 9 Apr 2012
by Tom Igoe
This example code is in the public domain.
This example code is in the public domain.
*/
*/
#include <SPI.h>
#include <SD.h>
const int chipSelect = 4;
void setup()
{
void setup() {
// Open serial communications and wait for port to open:
Serial.begin(9600);
while (!Serial) {
@ -45,8 +44,7 @@ void setup()
Serial.println("card initialized.");
}
void loop()
{
void loop() {
// make a string for assembling the data to log:
String dataString = "";