sw: ignore unused-function warnings

Since there's a couple of inline functions in some of the
header files, it's too hard to avoid those.
sw: move to_us from envelope to sublime

envelope doesn't know anything about midi values, sublime does
sw: include stdio.h to purge some warnings
sw/main: make an implicit cast to purge a warning
sw/midi: cleanup midi callbacks

keep the callbacks (events) in an array and make a generic
register function that takes the array index as an argument.
sw: add support for midi control change events