el_fela:
Hey, thank you Pieter and Mike !! Glad to hear from you. But anyway, I see a lot of errors when compiling many library examples.
This is the output I get when trying the Control_Surface example @PieterP just posted, using latest Arduino IDE and latest Control-surface-master library downloaded from Github:
es\Control-Surface-master\src/Def/MIDIAddress.hpp:276:16: warning: 'deprecated' attribute directive ignored [-Wattributes]
MIDIAddress;
^
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:276:16: warning: 'deprecated' attribute directive ignored [-Wattributes]
MIDIAddress;
^
In file included from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\MIDI_Interface.hpp:6:0,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\MIDI_Interface.cpp:1:
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:57:80: warning: 'deprecated' attribute directive ignored [-Wattributes]
using MIDICNChannel [[deprecated("Use MIDIChannelCN instead")]] = MIDIChannelCN;
^
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:276:16: warning: 'deprecated' attribute directive ignored [-Wattributes]
MIDIAddress;
^
In file included from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\MIDI_Interface.hpp:6:0,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\SerialMIDI_Interface.hpp:3,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\DebugMIDI_Interface.hpp:3,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Interfaces\DebugMIDI_Interface.cpp:1:
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:57:80: warning: 'deprecated' attribute directive ignored [-Wattributes]
using MIDICNChannel [[deprecated("Use MIDIChannelCN instead")]] = MIDIChannelCN;
^
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:276:16: warning: 'deprecated' attribute directive ignored [-Wattributes]
MIDIAddress;
^
In file included from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/MIDI_Interfaces/MIDI_Interface.hpp:6:0,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Control_Surface/Control_Surface_Class.hpp:10,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Senders\RelativeCCSender.hpp:3,
from C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src\MIDI_Senders\RelativeCCSender.cpp:1:
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:57:80: warning: 'deprecated' attribute directive ignored [-Wattributes]
using MIDICNChannel [[deprecated("Use MIDIChannelCN instead")]] = MIDIChannelCN;
^
C:\Users\felipe\Documents\Arduino\libraries\Control-Surface-master\src/Def/MIDIAddress.hpp:276:16: warning: 'deprecated' attribute directive ignored [-Wattributes]
MIDIAddress;
^
In file included from C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.cpp:17:0:
C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.cpp: In member function 'virtual int MIDI_::getInterface(uint8_t*)':
C:\Users\felipe\AppData\Local\Arduino15\packages\arduino\hardware\sam\1.6.12\cores\arduino/USB/USBCore.h:93:56: warning: narrowing conversion of '(int)((MIDI_*)this)->MIDI_::.PluggableUSBModule::pluggedEndpoint' from 'int' to 'uint8_t {aka unsigned char}' inside { } [-Wnarrowing]
#define USB_ENDPOINT_OUT(addr) ((addr) | 0x00)
^
C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.h:187:10: note: in definition of macro 'D_MIDI_JACK_EP'
{ 9, 5, _addr,_attr,_packetSize, 0, 0, 0}
^
C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.cpp:53:18: note: in expansion of macro 'USB_ENDPOINT_OUT'
D_MIDI_JACK_EP(USB_ENDPOINT_OUT(MIDI_ENDPOINT_OUT),USB_ENDPOINT_TYPE_BULK,MIDI_BUFFER_SIZE),
^
C:\Users\felipe\AppData\Local\Arduino15\packages\arduino\hardware\sam\1.6.12\cores\arduino/USB/USBCore.h:94:56: warning: narrowing conversion of '(int)((((MIDI_*)this)->MIDI_::.PluggableUSBModule::pluggedEndpoint + 1u) | 128u)' from 'int' to 'uint8_t {aka unsigned char}' inside { } [-Wnarrowing]
#define USB_ENDPOINT_IN(addr) ((addr) | 0x80)
^
C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.h:187:10: note: in definition of macro 'D_MIDI_JACK_EP'
{ 9, 5, _addr,_attr,_packetSize, 0, 0, 0}
^
C:\Users\felipe\Documents\Arduino\libraries\MIDIUSB\src\MIDIUSB.cpp:55:18: note: in expansion of macro 'USB_ENDPOINT_IN'
D_MIDI_JACK_EP(USB_ENDPOINT_IN(MIDI_ENDPOINT_IN),USB_ENDPOINT_TYPE_BULK,MIDI_BUFFER_SIZE),
^
I'm probably doing something wrong, but what? Thanks again for your help guys, I really appreciate it!
Those all look like warnings to me. The code I posted compiles fine for me for the Arduino SAM Core version 1.6.12 and Arduino IDE version 1.8.9.
The warning: 'deprecated' attribute directive ignored [-Wattributes]
warnings are caused by the ancient compiler that's used by the Due toolchain, it doesn't understand the "deprecated" attribute yet. It's not an error, the compiler simply ignores it.
The other warnings in the MIDIUSB library are narrowing conversions that shouldn't be there, but are pretty harmless nonetheless.
If the code fails to compile, you'll have to post the full output and code, because I can't find any errors in the part of the output you posted.