Developer World
Spresense Arduino Library v3.3.0-b2e6327
eMMC.h
Go to the documentation of this file.
1/*
2 * eMMC.h - Spresense Arduino eMMC library
3 * Copyright 2019 Sony Semiconductor Solutions Corporation
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19
20#ifndef __eMMC_H__
21#define __eMMC_H__
22
23#ifdef SUBCORE
24#error "eMMC library is NOT supported by SubCore."
25#endif
26
43#include <sdk/config.h>
44
45#include <Arduino.h>
46#include <Storage.h>
47
54class eMMCClass : public StorageClass {
55
56public:
57 eMMCClass();
58
67 boolean begin();
68
78 boolean begin(uint8_t);
79
86 boolean end();
87
92
96 int endUsbMsc();
97
105 int format(uint8_t fattype = 32);
106
107private:
108 void *mshandle;
109 uint8_t power_pin;
110};
111
112extern eMMCClass eMMC;
113
116#endif
Spresense Arduino Storage library.
The Storage class provides functions for accessing the storage manipulating its files and directories...
Definition: Storage.h:53
The eMMC class provides functions for accessing the eMMC and manipulating its files and directories....
Definition: eMMC.h:54
int format(uint8_t fattype=32)
Format the eMMC device.
int beginUsbMsc()
Start USB Mass Storage Class.
boolean begin()
Initialize the eMMC library.
boolean end()
Finalize the eMMC library.
boolean begin(uint8_t)
Initialize the eMMC library with Power on PIN.
int endUsbMsc()
Stop USB Mass Storage Class.