To me, it all seems okay, but when the firmware is flashed, the arduino should show up as a MIDI device in the System Information, but it just shows up as a "Communication Device".
Can anyone help me why that is? Is the firmware not flashed correctly?
I have done something, because I am not longer able to upload sketches via the Arduino IDE, which I shouldn't be able to whith a different firmware.
Am I missing something important?
I hope someone can help me, because I am completely stuck with my project
Hansibassi:
I have an Arduino Uno rev3, which I want to turn into a MIDI device. ...
I don't have an external ISP, so I have tried to use another Arduino as an AVR ISP
With a little searching, and in the tutorial #simplex linked to I've found, that I maybe need a crystal in my circuit, because the invalid device signature error could be caused by different clock frequencies. Or that's how I understood it.
Does that make sense?
And if I need a crystal, how do I connect it, when I'm using the ISP-header? I can't connect the crystal as in the tutorial you linked to#simplex, since I'm connecting to the ISP header
The USB AVR you want to flash has already a crystal connected to it.
If the lines (SS, MOSI, MISO, SCK) of the Aruino Uno configured as ISP Programmer are connected to the ICSP header pins (Reset, MOSI, MISO, SCK) corresponding to the USB AVR on the second Arduino Uno, you should be able to program the USB AVR with avrdude.
Likely you have wrong ISP connections between the Arduino Uno as Programmer and the ICSP header of the USB AVR on the second Arduino Uno board.
The SS signal of Arduino Uno Programmer is available just on pin 10 not on the ICSP. You have to take this into account when you make the wiring.
Also, do not try to write anything in the 16u2 as long as this command:
#simplex, you were right about the fact, that the error was caused by wrong ISP connections.
Thank you for the help!
The final solution was as follows:
Load the MegaISP sketch to the first Arduino Uno used as the ISP programmer. The sketch is also included as an example in the Arduino IDE, under the name "ArduinoISP".
Connect this Arduino to the Arduino you want to program. The connections are as follows:
Connect programmer pin 10 to the targets ICSP Reset header
Connect pin 11 to MOSI
Connect pin 12 to MISO
Connect pin 13 to SCK
The ICSP header connectors is shown below:
The VTG and GND pins on the ICSP header is not used.
When using the Arduino Uno an 10uF capacitor has to be connected between RESET and GND, as described in the ArduinoISP tutorial
The final schematic should be as shown below:
Connect the programmer-Arduino to the computer, open Terminal/the commando promt and type the following command: avrdude -p m16u2 -F -P /dev/cu.usbmodem621 -c avrisp -U flash:w:HIDUINO_MIDI.hex -U lfuse:w:0xFF:m -U hfuse:w:0xD9:m -U efuse:w:0xF4:m -U lock:w:0x0F:m -b 19200
'/dev/cu.usbmodem621' should be replaced by the port, your Arduino is connected to. [/li]
I want to do the same thing, but I have Windows, instead of the command, what should I do? Sorry if it's a noob question, I'm have no idea about command lines.