Hello,
I try to make a music player with Arduino R4 WiFi and a VS1053 board.
I can't compilate the sketch : #include "wiring_private.h" is the problem.
I search in Internet a solution and it seams that R4 is not compatible with the library Adafruit_VS1053.
Someone knows if it's right and if I have to change my R4 to an R3 ?
That is true about the R4, but Adafruit created the library.
You might want to contact Limor Fried, the head of Adafruit. I believe her email is limor@adafruit.com
I have had problems with developers who work with Adafruit in the past. I found Limor to be approachable and easy to work with. Unfortunately, some of the developers are arrogant and do not have Adafruit's best interests at heart.
Hello Sir,
I send you a message because I have a problem of compatibility between a vs1053 board and an Arduino R4 Wifi.
I try to find a solution in internet and forum and it seams that Uno R4 is not compatible with the Adafruit_VS1053.h library. The problem is signaled for a long time here (compatibility with Arduino UNO R4 Wifi board by motazEmad · Pull Request #95 · adafruit/Adafruit_VS1053_Library · GitHub) and nothing change.
As I develop a product, I want to know if the problem will be solved or not. If he don't, I have to search a solution without R4.
Thank you for your answer.
Hi @afigiboto. I'll provide instructions you can follow to install the beta test version of the library that has the proposed changes to add support for the UNO R4 WiFi (as mentioned by @MrY in post #2):
A. Uninstall Release Version of Library
Select Sketch > Include Library > Manage Libraries... from the Arduino IDE menus to open the "Library Manager" view in the left side panel.
Type Adafruit VS1053 Library in the "Filter your search..." field.
Scroll down through the list of libraries until you see the "Adafruit VS1053 Library" entry.
Hover the mouse pointer over the "Adafruit VS1053 Library" entry.
You will see a ●●● icon appear near the top right corner of the library entry. Click on that icon.
A context menu will open.
Select "Remove" from the menu.
An "Uninstall" dialog will open.
Click the "YES" button in the "Uninstall" dialog to confirm that you want to uninstall the library.
The dialog will close.
Wait for the uninstall process to finish, as indicated by a notification at the bottom right corner of the Arduino IDE window:
Select Download ZIP from the menu.
A download of the ZIP file of the library will start.
Wait for the download to finish.
Select Sketch > Include library > Add .ZIP Library from the Arduino IDE menus.
The "Select the zip file containing the library you'd like to add" dialog will open.
Select the downloaded file from the dialog.
Click the "Open" button.
The dialog will close.
Wait for the installation process to finish, as indicated by a notification at the bottom right corner of the Arduino IDE window:
Thanks' for the response.
I'm in linux and I can't uninstall as you tell. I don't have uninstall in the IDE, I have to detete the folder. I think it's all right, no ?
With the new paquage, the #include "wiring_private.h" error desappear. Cool !!!
But I have a problem with SdFat.h. It works with SD.h, but not with SdFat.
OK, this is because you are using an outdated version of Arduino IDE. You might have ended up with this version unintentionally if you installed Arduino IDE via a package manager (e.g., APT). The instructions I provided are for use with the modern Arduino IDE 2.x versions (e.g., 2.3.4). Unless you have a specific reason for using the old 1.x IDE, I recommend you update.
You can download Arduino IDE 2.x from the link on the "Software" page:
Yes, that is perfectly fine. I only chose to use the Library Manager feature in my instructions because that is easier for the average Arduino user (who often are not experienced in working directly with the filesystem).
Please provide a detailed description of what you mean by this in a reply on this forum thread, including:
What did you do?
What were the results you expected from doing that thing?
What were the results you observed that did not match your expectations?
Make sure to include the full and exact text of any error or warning messages you might have encountered.
I am certain it is, because the author of the library has tested it with the UNO R4 WiFi:
Note that, although that thread is about performance problems, the library was still functional when used with the UNO R4 WiFi. I believe the performance has also improved since that time.
I can acces to the files list in BLE on my app. I've to use SdFat because the names of files are some times long (more than 8 caracters).
I've a great collection of errors :
In file included from /home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:28:0,
from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:
/home/stef/.arduino15/libraries/SD/src/SD.h:62:7: error: 'Sd2Card' does not name a type; did you mean 'SdCard'?
Sd2Card card;
^~~~~~~
SdCard
/home/stef/.arduino15/libraries/SD/src/SD.h:63:7: error: 'SdVolume' does not name a type; did you mean 'FsVolume'?
SdVolume volume;
^~~~~~~~
FsVolume
/home/stef/.arduino15/libraries/SD/src/SD.h:71:34: error: 'SD_CHIP_SELECT_PIN' was not declared in this scope
bool begin(uint8_t csPin = SD_CHIP_SELECT_PIN);
^~~~~~~~~~~~~~~~~~
/home/stef/.arduino15/libraries/SD/src/SD.h:71:34: note: suggested alternative: 'SD_CHIP_SELECT_MODE'
bool begin(uint8_t csPin = SD_CHIP_SELECT_PIN);
^~~~~~~~~~~~~~~~~~
SD_CHIP_SELECT_MODE
In file included from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:0:
/home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:347:3: error: reference to 'File' is ambiguous
File currentTrack; //!< File that is currently playing
^~~~
In file included from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:3:0:
/home/stef/Arduino/libraries/SdFat_-_Adafruit_Fork/src/SdFat.h:458:16: note: candidates are: typedef class File32 File
typedef File32 File;
^~~~
In file included from /home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:28:0,
from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:
/home/stef/.arduino15/libraries/SD/src/SD.h:28:9: note: class SDLib::File
class File : public Stream {
^~~~
In file included from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:0:
/home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:365:31: error: reference to 'File' is ambiguous
unsigned long mp3_ID3Jumper(File mp3);
^~~~
In file included from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:3:0:
/home/stef/Arduino/libraries/SdFat_-_Adafruit_Fork/src/SdFat.h:458:16: note: candidates are: typedef class File32 File
typedef File32 File;
^~~~
In file included from /home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:28:0,
from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:
/home/stef/.arduino15/libraries/SD/src/SD.h:28:9: note: class SDLib::File
class File : public Stream {
^~~~
In file included from /home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:4:0:
/home/stef/Arduino/libraries/Adafruit_VS1053_Library-master/Adafruit_VS1053.h:365:31: error: 'File' has not been declared
unsigned long mp3_ID3Jumper(File mp3);
^~~~
/home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino: In function 'void playMidiFile(const char*)':
/home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:127:10: error: 'class Adafruit_VS1053' has no member named 'startPlayingFile'
player.startPlayingFile(fullPath);
^~~~~~~~~~~~~~~~
/home/stef/.var/app/cc.arduino.IDE2/cache/.arduinoIDE-unsaved202516-52-td1i1v.ma5oj/sketch_feb6a/sketch_feb6a.ino:128:17: error: 'class Adafruit_VS1053' has no member named 'playingMusic'
while (player.playingMusic()) {
^~~~~~~~~~~~
exit status 1
Compilation error: 'class Adafruit_VS1053' has no member named 'startPlayingFile'
Great work on troubleshooting the cause of the errors! Are you still experiencing a compilation error? If so, please post the updated compilation output, just as you did in post #9.
Yes I have some errors, it's certainly because I code with my feet
But there are less !!! So cool !
/home/stef/Arduino/sketch_feb6a/sketch_feb6a.ino: In function 'void playMIDI(const char*)':
/home/stef/Arduino/sketch_feb6a/sketch_feb6a.ino:144:10: error: 'class Adafruit_VS1053' has no member named 'startPlayingFile'
player.startPlayingFile(path);
^~~~~~~~~~~~~~~~
/home/stef/Arduino/sketch_feb6a/sketch_feb6a.ino:146:17: error: 'class Adafruit_VS1053' has no member named 'playingMusic'
while (player.playingMusic()) {
^~~~~~~~~~~~
exit status 1
Compilation error: 'class Adafruit_VS1053' has no member named 'startPlayingFile'