File Directory Error Message

Hi everyone, working on a MIDI controller, and downloaded a sketch from a DJTechTools article, and tried uploading to my Arduino, and I got this error message -

Arduino: 1.6.10 (Mac OS X), Board: “Arduino/Genuino Uno”

/Users/my Mac OS X account/Downloads/DJTT_DIY_MIDI/DJTT_DIY_MIDI.ino:1:20: fatal error: Bounce.h: No such file or directory
#include <Bounce.h>
^
compilation terminated.
exit status 1
Error compiling for board Arduino/Genuino Uno.

Using an Arduino Uno R3, on a Macbook Pro, El Capitan.

Any ideas on how to fix this?

Thanks, Spike

Have you downloaded and installed the "Bounce" library?

There's actually a later version available now, "Bounce2", but it's not 100% compatible, so some code changes are required to use it.
More info here:- Bounce

OldSteve:
Have you downloaded and installed the "Bounce" library?

There's actually a later version available now, "Bounce2", but it's not 100% compatible, so some code changes are required to use it.
More info here:- Bounce

I did that, installed library, and updated sketch, and got same error message.

SpikeHunter:
I did that, installed library, and updated sketch, and got same error message.

If you downloaded and installed the "Bounce2" library, there will no longer be a "Bounce.h" file, it will be called "Bounce2.h".
If you don't have the earlier "Bounce" library, that's the problem. Then you'll still need to make those other changes for the old code to work. (I see you've done this.)

There are also examples included with the "Bounce2" library. They're in ">File >Examples >Bounce2"

Ok, did what you suggested, still not working. I updated the code (which I may have done incorrectly) but I keep on getting a different error message.

Arduino: 1.6.10 (Mac OS X), Board: "Arduino/Genuino Uno"

/Users/My Personal Account/Downloads/DJTT_DIY_MIDI/DJTT_DIY_MIDI.ino: In function 'void setup()':
DJTT_DIY_MIDI:37: error: 'BUTTON_PIN_1' was not declared in this scope
pinMode(BUTTON_PIN_1,INPUT_PULLUP);
^
DJTT_DIY_MIDI:39: error: 'debouncer1' was not declared in this scope
debouncer1.attach(BUTTON_PIN_1);
^
DJTT_DIY_MIDI:43: error: 'BUTTON_PIN_2' was not declared in this scope
pinMode(BUTTON_PIN_2,INPUT_PULLUP);
^
DJTT_DIY_MIDI:45: error: 'debouncer2' was not declared in this scope
debouncer2.attach(BUTTON_PIN_2);
^
DJTT_DIY_MIDI:49: error: 'LED_PIN' was not declared in this scope
pinMode(LED_PIN,OUTPUT);
^
/Users/spiker/Downloads/DJTT_DIY_MIDI/DJTT_DIY_MIDI.ino: In function 'void loop()':
DJTT_DIY_MIDI:70: error: 'debouncer1' was not declared in this scope
debouncer1.update();
^
DJTT_DIY_MIDI:71: error: 'debouncer2' was not declared in this scope
debouncer2.update();
^
DJTT_DIY_MIDI:79: error: 'LED_PIN' was not declared in this scope
digitalWrite(LED_PIN, HIGH );
^
DJTT_DIY_MIDI:82: error: 'LED_PIN' was not declared in this scope
digitalWrite(LED_PIN, LOW );
^
DJTT_DIY_MIDI:94: error: 'usbMIDI' was not declared in this scope
usbMIDI.sendControlChange(i, ccValue*, 3);*

  • ^*
    DJTT_DIY_MIDI:110: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc0, cc_on, 3);*
  • ^*
    DJTT_DIY_MIDI:114: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc1, cc_on, 3);*
  • ^*
    DJTT_DIY_MIDI:118: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc2, cc_on, 3);*
  • ^*
    DJTT_DIY_MIDI:122: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc3, cc_on, 3);*
  • ^*
    DJTT_DIY_MIDI:128: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc0, cc_off, 3);*
  • ^*
    DJTT_DIY_MIDI:132: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc1, cc_off, 3);*
  • ^*
    DJTT_DIY_MIDI:136: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc2, cc_off, 3);*
  • ^*
    DJTT_DIY_MIDI:140: error: 'usbMIDI' was not declared in this scope
  • usbMIDI.sendControlChange(cc3, cc_off, 3);*
  • ^*
    exit status 1
    'BUTTON_PIN_1' was not declared in this scope

SpikeHunter:
Ok, did what you suggested, still not working. I updated the code (which I may have done incorrectly) but I keep on getting a different error message.

You’ll need to post your code before we can help further.
It needs to be enclosed in [code]code tags[/code] too, not inline. You can paste the code into your post, then select it and press the </> button to add code tags, or type them manually as shown in the previous sentence.
It makes it easier to read or select and copy to an IDE for checking, and also prevents the forum software from corrupting it with italics, smilies etc.

In future, all error messages should also be placed between code tags as well.

I can already imagine why you’re getting some of the errors, if not all, but I’ll wait until you post the code and check it over. (Or someone else will.)

Well, I just tracked down the source of your project, found the code you're trying to compile and also had a quick read of the article "How To Make Your Own DIY MIDI Controller".

A "Teensy" board is required for this project. It's not suitable for an UNO.

The "Teensyduino" package installs support for the "Teensy" board, and adds stuff like "usbMIDI".

An excerpt from the article you're working from:-

STEP 1: Plug your Teensy board into the USB port on your computer. After plugged in an orange light on the Teensy should be flashing on and off every second. This is called the ‘blink’ sketch – The Teensy board comes pre-loaded with it.

STEP 2: In the menubar, select Tools->Board->Teensy 2.0.

STEP 3: Also in the menubar, Tools->USB Type->MIDI

You'll need a "Teensy" if you really want to continue with this project.

Edit:
I guess this is the article you're following:- How To Make Your Own DIY MIDI Controller/

And this is the "Teensyduino" page, with more info:- Teensyduino

hoangvudb:
If you downloaded and installed the "Bounce2" library, there will no longer be a "Bounce.h" file, it will be called "Bounce2.h".

Echo....

OldSteve:
If you downloaded and installed the "Bounce2" library, there will no longer be a "Bounce.h" file, it will be called "Bounce2.h".

Didn't you have anything better for your first post on these forums?

Thanks, for your help, I may have found a solution for the issue I’m having, I downloaded a USBMIDI library, which seems to have solved the issue of the huge wall of “USBMIDI/button0.rising” etc. error messages, and just now I’ve got only one issue, another “No Such File Or Directory” message.

/Users/spiker/Downloads/DJTT_DIY_MIDI/DJTT_DIY_MIDI.ino:3:28: fatal error: MIDIUSB_loop.ino: No such file or directory
 #include <MIDIUSB_loop.ino>
                            ^
compilation terminated.
exit status 1
Error compiling for board Arduino/Genuino Uno.

You're trying to include a sketch, not a library. The library is at a higher level at GitHub, and is called "MIDIUSB". The actual 'include' file is named "MIDIUSB.h".

And it isn't suitable for an UNO. You're missing a vital point. You need a board with native USB capabilities. A UNO does not have that.

Of course, even if it could, the code that you already have will be useless with a different library. It needs the "Teensyduino" package, as I said.

Ok, I've given up on trying to make the Arduino work, what would replace that? Would a Nano be equivalent, or what would be?

SpikeHunter:
Ok, I've given up on trying to make the Arduino work, what would replace that? Would a Nano be equivalent, or what would be?

If you're trying to make the project from the article you were looking at, you need a Teensy.

So, I'm pretty much giving up at this point in time (it was for Science Fair and I'm away for when's it's due) but I'll try and order a Teensy so I can use the project myself. Thanks for all your help, it's my first Arduino project, and again, thanks.