Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: 'SD' was not declared in this scope #69

Open
Ramsonjehu opened this issue Feb 16, 2022 · 1 comment
Open

error: 'SD' was not declared in this scope #69

Ramsonjehu opened this issue Feb 16, 2022 · 1 comment

Comments

@Ramsonjehu
Copy link

Ramsonjehu commented Feb 16, 2022

I'm running person detection example from tensorflow_lite library. I have downloaded the jpeg decoder 1.8.0 from arduino library manager.

As in arduino_image_provide.cpp I have configured as mentioned below

/*
The sample requires the following third-party libraries to be installed and
configured:

Arducam

  1. Download https://github.com/ArduCAM/Arduino and copy its ArduCAM
    subdirectory into Arduino/libraries. Commit #e216049 has been tested
    with this code.
  2. Edit Arduino/libraries/ArduCAM/memorysaver.h and ensure that
    "#define OV2640_MINI_2MP_PLUS" is not commented out. Ensure all other
    defines in the same section are commented out.

JPEGDecoder

  1. Install "JPEGDecoder" 1.8.0 from the Arduino library manager.
  2. Edit "Arduino/Libraries/JPEGDecoder/src/User_Config.h" and comment out
    "#define LOAD_SD_LIBRARY" and "#define LOAD_SDFAT_LIBRARY".

By doing so im facing the following error.

C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp: In member function 'int JPEGDecoder::decodeSdFile(const char*)':
C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp:353:17: error: 'SD' was not declared in this scope
File pInFile = SD.open( pFilename, FILE_READ);
^~
C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp:353:17: note: suggested alternative: 'SS'
File pInFile = SD.open( pFilename, FILE_READ);
^~
SS
C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp: In member function 'int JPEGDecoder::decodeSdFile(const arduino::String&)':
C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp:361:17: error: 'SD' was not declared in this scope
File pInFile = SD.open( pFilename, FILE_READ);
^~
C:\Users\ML TEAM\Documents\Arduino\libraries\JPEGDecoder\src\JPEGDecoder.cpp:361:17: note: suggested alternative: 'SS'
File pInFile = SD.open( pFilename, FILE_READ);
^~
SS
exit status 1
Error compiling for board Arduino Nano 33 BLE.

@Bodmer
Copy link
Owner

Bodmer commented Feb 16, 2022

The istructions appear to be wrong, in particular:

Edit "Arduino/Libraries/JPEGDecoder/src/User_Config.h" and comment out
"#define LOAD_SD_LIBRARY" and "#define LOAD_SDFAT_LIBRARY".

You should NOT comment out #define LOAD_SD_LIBRARY

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants