[sdiy] MIDI receiving flowchart.. WAS MIDI I/O c code..
Mathias
alfrede at opferindustries.de
Mon Mar 30 12:37:28 CEST 2020
I found that and would like to share it with you guys:
https://learn.sparkfun.com/tutorials/midi-tutorial/all
Best
Mathias
On 21.03.20 02:32, Jean-Pierre Desrochers wrote:
> Thanks René !
> Even though there is no Rx interrupt code
> I will have a carefull look at your code with joy !
>
> JP
>
> -----Message d'origine-----
> De : Synth-diy [mailto:synth-diy-bounces at synth-diy.org] De la part de René Schmitz
> Envoyé : 20 mars 2020 21:10
> À : synth-diy at synth-diy.org
> Objet : Re: [sdiy] MIDI receiving flowchart.. WAS MIDI I/O c code..
>
> Well if none of you handles system common messages, I don't feel so bad.
>
> Here is some code I wrote some years back, and cobbled something
> together to be run in a shell, so you can actually examine this without
> the hassle of a embedded environment or ISRs etc.
>
> https://github.com/schmitzbits/terse_midi_parser
>
> Best,
> René
>
> On 21.03.2020 01:10, John Speth via Synth-diy wrote:
>> Neil's flowchart looks right. Here's another way to look at it from a
>> state machine perspective. For me personally, coding from a flow chart
>> leads to spaghetti code but a state machine translates to code much easier.
>>
>> http://myplace.frontier.com/~jspeth/MIDI_FSM.pdf
>>
>> Advice: There is little value and it's probably even detrimental to
>> attempt a starting MIDI reception code body. You need to fully implement
>> the MIDI reception and decoding parts. You can opt to disregard the
>> actions that should be taken after an unambiguous MIDI message is
>> received but you need to handle each byte.
>>
>> JJS
>>
>> On 3/20/2020 12:26 PM, Neil Johnson wrote:
>>> You mean like this:
>>>
>>> https://github.com/nejohnson/miby
>>>
>>> Look in the /doc folder for a PDF.
>>>
>>> Neil
>>>
>>> On Fri, 20 Mar 2020 at 19:17, Tom Wiltshire <tom at electricdruid.net
>>> <mailto:tom at electricdruid.net>> wrote:
>>>
>>> I think a flowchart is a good idea, but I’d say that the voice
>>> assignment part is a separate thing from the MIDI. Voice handling
>>> is a whole area in its own right.
>>>
>>> Tom
>>>
>>> ==================
>>> Electric Druid
>>> Synth & Stompbox DIY
>>> ==================
>>>
>>>> On 20 Mar 2020, at 19:10, Jean-Pierre Desrochers
>>>> <jpdesroc at oricom.ca <mailto:jpdesroc at oricom.ca>> wrote:
>>>>
>>>> One idea came to my mind reading all your great comments:
>>>> Would it be usefull for anybody in this DIY forum including
>>>> newbies like me
>>>> that someone would publish a 'starting' MIDI receiving flowchart
>>>> of the basics from the incoming bytes to the actual final process
>>>> of each received notes ?
>>>> For example this helping flowchart would show the basic steps
>>>> of first: the interrupt function (USART Rx flag test, RxBuffer[]
>>>> updating, etc...)
>>>> Then the behaviour of the main loop processing each received byte
>>>> for let's say a polyphonic MIDI to CV 8 voices module ?
>>>> And only for one MIDI channel for simplicity to understanding ?
>>>> I did in the past a big flowchart for my MIDI to CV 6 voices module
>>>> That I could 'squeeze'to keep only what's stated above.
>>>> This could be a starting point for anybody who wants to 'correct'
>>>> things
>>>> and this way the DIY forum would have a 'list standardized' flowchart
>>>> For anybody to use in the future..
>>>> This would answer many design questions to come.
>>>> Again, a small flowchart of how to receive MIDI bytes for only
>>>> one MIDI channel
>>>> And process for polyphonic use (8 voices).
>>>> If this suggestion interests enough diyers I could put my cleaned out
>>>> Flowchart on the list as a start..
>>>> Or maybe I'll be the only guy to be interested in that
>>>> Since many of you gurus have already been through these codings..
>>>> JP
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> Synth-diy mailing list
>>>> Synth-diy at synth-diy.org <mailto:Synth-diy at synth-diy.org>
>>>> http://synth-diy.org/mailman/listinfo/synth-diy
>>> _______________________________________________
>>> Synth-diy mailing list
>>> Synth-diy at synth-diy.org <mailto:Synth-diy at synth-diy.org>
>>> http://synth-diy.org/mailman/listinfo/synth-diy
>>>
>>>
>>> _______________________________________________
>>> Synth-diy mailing list
>>> Synth-diy at synth-diy.org
>>> http://synth-diy.org/mailman/listinfo/synth-diy
>> _______________________________________________
>> Synth-diy mailing list
>> Synth-diy at synth-diy.org
>> http://synth-diy.org/mailman/listinfo/synth-diy
>>
>
More information about the Synth-diy
mailing list