TROUBLESHOOTING SOLUTIONS: PIANO APPLICATION MAC

PROBLEMS COVERED IN THIS SECTION
damaged application error
Java runtime error
piano not attached
Arduino Serial Monitor open
piano program problem
communication configuration problem


DAMAGED APPLICATION ERROR

Damaged_app

symptoms

If you try to open the Piano Application but get a message like the one above, don’t be alarmed and don’t click “Move to Trash”. The application is fine, you will just need to edit some of your system preferences before your computer will open it.

Starting with Mac OS X Mountain Lion (10.8.x), Apple introduced a security feature called Gatekeeper. By default, Gatekeeper prevents applications that you did not download from the Mac App Store from opening.

solution

step 1
Open the System Preferences application. You can probably find the System Preferences application on your dock. Its icon looks like this:

system_prefs_icon

If System Preferences isn’t in your dock, search for “system preferences” in the search bar located in the top right-hand part of your screen to find it:

search_bar

Double click on the System Preferences icon to open it.

step 2
Once the System Preferences application is open, click on “Security & Privacy” within the Personal section at the top.

system_prefs

step 3
Make sure you’re in the General tab. (You should be in this tab by default. You know you are in the General tab if it is dark grey.)

Click on the lock in the lower left-hand corner of the window. This will allow you to change the preferences in this window. You will be prompted to enter your computer’s password. Enter it and click “OK”.

security_privacy_locked-copy

Select the “Anywhere” bubble. This will allow your computer to open applications, like the Piano Application, that you’ve downloaded from the Internet.

security_privacy_unlocked-copy

step 4
Quit the System Preferences application. Try to open the Piano Application again. If all goes well, you should see a screen like the one below pop up.

Piano_Arduino_SerialPort-01.

Once you have successfully opened the Piano Application, your computer will recognize it and open it without displaying errors from now on.

step 5
If you’d like you can now go back to your original Gatekeeper settings. To do so, follow steps 1-3 above. In step 3, select the “Mac App Store and identified developers” bubble to return your computer to its default settings.

security_privacy_relocked-01

 

JAVA RUNTIME ERROR

java_error2

symptoms

If you encounter a message like the one above, this means that your computer is missing a piece of software called Java that the Piano Application needs to run.

solution

Click on the “Install” button in the window that pops up when you try to open the Piano Application. This will install the necessary Java software. Note: The installation will only work if you are connected to the Internet. If you have a slow internet connection, this step will take some time.

Once the Java package has downloaded, follow the instructions that pop up on your screen to complete the installation. Once Java is installed, try to open the Piano Application. Note: If it doesn’t work the first time, try restarting your computer and trying to open the Piano Application again.

 

PIANO NOT ATTACHED

symptoms

If your piano is not attached to your computer (or if it is attached improperly), you will not see a serial port entry for your piano in the list that pops up in the first Piano Application window.

The correct port entry will be the same serial port you selected when you set up the Arduino software. You should see an entry that starts with: “/dev/tty.usbserial-” and is followed by a series of letters and numbers. Here is a window without a valid serial port entry:

Piano_Application_NoSerialPort-01

solution

Quit the Piano Application. Attach your piano to your computer. Make sure that your FTDI board is properly attached to your LilyPad. Restart the Piano Application. You should now see a window with a valid serial port entry.

Piano_Arduino_SerialPort2-01

 

ARDUINO SERIAL MONITOR OPEN

symptoms

If the Serial Monitor in the Arduino software is open when you run the Piano Application, the application will not be able to communicate with your piano. This is because your piano is already communicating with the Arduino software and it can only communicate with one application at a time.

If you have left the Serial Monitor open, the Piano Application will open and run, but when you attempt to connect to your piano, by clicking on the correct serial port entry in the first screen, you will get this error message:

CommunicationProblem

solution

Quit the Piano Application. Close the Serial Monitor in the Arduino software. Restart the Piano Application. You should now be able to connect to your piano. When you click on the correct serial port entry in the first screen, you should see a window like the one below appear.

Piano_Arduino_FlatLine-01
 

PIANO PROGRAM PROBLEM

symptoms

If the program you uploaded to your piano is not sending properly formatted data to the Piano Application, the application will not be able to communicate with your piano.

If your piano does not have the correct program, the Piano Application will open and run, but when you attempt to connect to your piano, by clicking on the correct serial port entry in the first screen, you will get this error message:

CommunicationProblem

solution

Quit the Piano Application. Open the Arduino software and make sure your piano has the right program. Your piano should be programmed with a program like the one at the bottom of this page.

Make sure that your piano has the right program by opening the Serial Monitor in the Arduino software. Your Serial Monitor windo should look something like the image below. Note: Your numbers may be different, but their formatting should be similar.

SerialMonitorTouching

Close the Arduino Serial Monitor. Reopen the Piano Application. You should now be able to connect to your piano. When you click on the correct serial port entry in the first screen, you should see a window like the one below appear.

Piano_Arduino_FlatLine-01


COMMUNICATION CONFIGURATION PROBLEM

symptoms

If the Piano Application opens and runs, but when you attempt to connect to your piano, by clicking on the correct serial port entry in the first screen, you get the error message below, AND you have made sure that the Serial Monitor is closed and that your piano has the right program, you may have a communication configuration problem.

CommunicationProblem

Try the solution below when you have tried all of the other solutions outlined on this page and you are still seeing the error above when you try to open your serial port.

solution

step 1
Open up the Terminal application. This application is located in your Applications–>Utilities folder:

TerminalApp

Double click on the Terminal icon to open it. The opening screen will look something like this:

Terminal

Type the following lines into the application. (After you type each line, hit enter.)


    cd /var
    sudo mkdir lock
    sudo chmod 777 lock

    Note: You will be prompted for your password after you type sudo mkdir lock.
    Enter your computer’s password and hit return.

Here is what your Terminal window should look like after typing the commands:

TerminalCommands

step 3
Reopen the Piano Application. You should now be able to connect to your piano. When you click on the correct serial port entry in the first screen, you should see a window like the one below appear.

Piano_Arduino_FlatLine-01