(bit too late, had to cook dinner between typing) Here is how to ask a good question:
- I am trying to do this (like you can say I'm building a midi box that can do..., don't say too specific, like I'm trying to make this code work so it outputs ...). Nobody can get into your head and scoop that out if you don't say it.
- I have the following (hardware/software or code). What's working is... (don't forget we are half a world apart so what you don't describe in word is never going to get across the oceans)
- What is not work is... and don't forget "I want it to do ... but find it doing ... instead". The expression "It's not working" is frowned upon.
Remember if you want to get your question answered, you must first ask a good question. Nobody here owes you technical support so be nice when asking is required although nice answers are not always what you get.
Like Arrch is asking, answer part 3).