-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Program/TG Select buttons and choice for Program Change to act on Voices or Performances #500
Conversation
…selection and short cuts as buttons and MIDI buttons.
… TG or Performances.
…dating if on Performance/Load display. Swapped TG1 and TG3 in Performance 000008 so that TG1 is set to MIDI CH 1 in all Performances.
Hi Kevin, thank you very much for this PR. What would prevent us from using LSB and MSB to allow for more than 128 performances? |
Build for testing: @Stooovie please try it out and let us know whether this works for you. Thanks! |
Yes, we'd have to introduce the concept of "banks" for performances too, but that might need a little thinking about as the concept doesn't exist at the moment. Program Change only has a single byte, hence the 128 limitation. Kevin |
Hi, thanks! I set MIDIButtonPgmUp and MIDIButtonPgmDown and it DOES change the patches BUT it sort of adds patches to the original default sound - that is always there. I apologize, I'm not a great candidate for testing as my knowledge of DX7 is almost nonexistent, I was always just playing with presets. Is this something to do with performances vs programs? Again, sorry, I'll have to read up on these. Thanks for your effort so far, it probably does what I want when set up correctly :) |
I've afraid you've fallen foul of this one (not your fault - I still think this is a fault with the default "as shipped" configuration): #384 Kevin |
Hi @Stooovie , maybe the following will solve your problem: Peter |
Please clarify what you mean by "patches": Voices or performances? I thought you wanted to change the performances (=all voices running on all tone generators). For that, you need to use the "build for testing" and set @diyelectromusic will doing so also allow MIDIButtonPgmUp and MIDIButtonPgmDown to change performances? (Just double checking.)
By default we are shipping a performance that contains multiple voices (more than one tone generator is used). But when changing the performance, then of course all tone generators should be configured according to the new performance loaded. So I would be suprised that if changing performances, some voices from the original performance would be "left over". I'd consider that a bug... or am I not understanding the issue? Thinking a bit more about it: Instead of having |
Yes, that's the idea (hopefully).
But that is the key issue. By default, as "shipped" things like Program Change work on voices not performances, hence the (continuing) confusion. I hope this change might help with the issue a little, but we are going to have to update the default configuration at some point, either to force Performance mode (least preferred for me - I don't think the DX7II defaults to performance mode does it? Doesn't it start in normal mode?) or to "fix" the default performance (still my preferred option for all the reasons I've stated several times before).
I did wonder about that, but instead went for MIDI channel on TG1 for "performance" mode, figuring it was perhaps least likely to cause confusion. It was also easier to implement for this first try. We could try for a dedicated "performance channel", but I certainly don't think we should then further limit TG channels if we do. Either way, as MIDI channels are part of the performance configuration I think neither is ideal and each will have different limitations. Maybe give this a bit of time to settle and see how people find it? Kevin |
I've just updated this one again. @probonopd I was wondering if it was possible to merge it in so it doesn't keep getting out of date (assuming you're happy with it of course)? Kevin |
Hi @diyelectromusic, can you please suggest the documentation for https://github.com/probonopd/MiniDexed/wiki/Files for this? I don't know whether the solution here is exactly what we were looking for; I was assuming we basically wanted a way to have a sysex that switches |
Well the discussion meandered quite a lot, but the original ask from #496 I left the SysEx part as "Well if someone can verify that we can enable performance mode from MIDI using the sequence I posted below, then I'll have a look at allowing program change to be either performance or voices" - not having any original instruments, there is nothing I can do to test any of it to know what it does. "In fact, I can look at it regardless and make it a UI/config setting, but I'd still like to know if it was possible over MIDI! :)" - So I did the latter and it has been ready to integrate for a while now. In terms of documentation, it will expand the comments in the minidexed.ini file:
and the settings for configuring buttons themselves:
(and the corresponding MIDI buttons too) If accepted I'll update the Wiki (it doesn't seem appropriate to update the documentation before the feature has even been agreed... let alone integrated?). Kevin |
Hi Kevin @diyelectromusic , ExpandPCAcrossBanks=1 works as expected. Voice changes are immediately reflected in the UI. My thoughts: X= 1-16: On MIDI channel x, program change commands change the performance. Voices are changed on all other channels. PerformanceProgramChange=0 (off): ProgramChange commands only affect the Voices, Performances are not changed. This gives you the opportunity, for example from a DAW, to change the Performances and the Voices. If I understand correctly, the Yamaha TX-802 behaves the same way. |
I think this was because of how the performance menus are structured. The voice menus work on a "if it is visible it is selected" basis but the performance is on a "you have to choose it to load it" basis, so the visible one isn't the selected one until it is actually selected. So atm the performance menu /is/ updated (the [L] symbol moves) but the name doesn't auto-scroll to the active one. I'm not sure if that is actually possible tbh with how it is structured, but I'll take another look...
I did wonder about this too. I shied away from it as I thought we wanted a menu option to mimic the "performance" button on the real synth UI, so it was either on or off. Maybe I should add PerformanceProgramChangeChannel (yes I know... yet another config option...), but maybe the simpler is to update the menu to select between OFF then 1-16... I'll have another look. Although again, I can't guarantee this will be easy to slot into the MIDI handling, as ProgramChange is definitely a Voice channel message in the handling, but I'll see what I can do - I did need to introduce "system level channel handling" for MIDI control buttons, so it might already have the necessary glue in place...
So you want to be able to select a performance using the PerformanceChange MIDI channel, but then override the individual selections for TGs based on their own channels and receiving ProgramChange messages for voices? I think we could do that, but are you sure that is what the TXX-802 does - that sounds like a recipe for getting things really out of sync in terms of DAW vs MiniDexed UI vs Performance Settings vs what is actually playing! :) I guess part of the problem is that as MIDI channel is stored within a Performance (is that the same on a TX-802?), selecting a different performance will be changing MIDI channels "under the hood" for individual TGs so sending a Program Change might mean different things for different performances - but maybe that doesn't matter. I've no idea how we describe that in the documentation mind :) ... but if that is the consensus of what we think it ought to be, I think that is possible. It just sounds very complicated and ripe for all sorts of confusion! :) Kevin |
Hi Kevin, thanks for having a look. If you find a way to make it consistent, I'd be all for it. Personally I don't like that voices and performances behave differently in this regard. Let's try to be as consistent as possible.
In the manual there is a MIDI implementation chart which shows: I can't make any sense of it yet. There is also this: Note that the TX-802 only has memory for 64 performances. With @Banana71's productivity, this is nowhere nearly enough for us. Maybe we can find a TX-802 owner who can explain how selecting performances vs. voices via MIDI works there. |
We also need to be careful not to just focus on the TX-802 (which I think was the rack version of the DX7-II?), as we have the TX-7, TX-816/216 too and MiniDexed is become a weird mix of them all :) It's nice to support as much as we can, but it is starting to get real messy! I'll have a proper read and see what I can decipher too! Kevin |
Ok, so isn't that flow chart basically saying: So the idea that it will select performances if on the selected channel and voices on any other channel doesn't seem right? Or is it... actually, I've no idea what that flow chart is saying! Anyone want to buy me a TX-802? :) |
My mistake. The Yamaha TX-802 actually behaves differently. |
We need a MIDI (sysex?) command to toggle PerformanceProgramChange on/off, no? |
I'm also still looking for original DX7 equipment. My favorite is the DX7IID or DX7IIFD. |
The best thing would be a utility page in the UI where you can make some settings and also have the option to save them. It sounds like a lot of work though. |
This is from the "MIDI Technical Data and Charts" from the DX7II: Which seems to confirm the either/or nature of the setting. The SysEx stuff was in the previous discussion and taken from my reading of the same charts, but I really need someone to confirm it. But I don't think we really need to change this over MIDI. The main ask is a config setting to allow the user of MiniDexed to decide if it is voices or performances, coupled with a UI setting to change "live" that goes quite a long way I'd say? It certainly doesn't make a lot of sense to me to be switching live - if performances are being selected but you then want to select individual voices on specific TGs then you really have to re-initialise the MiniDexed into 8 TGs of known configuration before anything you send makes much sense. As I say, the performances could have completely messed with the MIDI channels for TGs and so on, not to mention the fact that the voices are not linked to ROMs when loaded from performances... No, I think it is pretty good to have people initialise the unit in either voice or performance mode - otherwise there is room for huge amounts of confusion! Kevin |
OK; I see. So do you think this should be merged as-is? |
I think part of the reason we're struggling is that the actual performance data for the DX7II doesn't include the MIDI channel (see table "5-3 Performance Parameters" in the "MIDI Technical Data and Charts" manual. This means that fiddling with performances (if I'm understanding it correct) won't mess with the MIDI configuration. In our case that isn't true as the MIDI channels for each TG is part of the performance configuration. We also store bank/voice numbers even though they aren't used (which is also a bit confusing - more on that here #454 (reply in thread))... but there is only so much messing around I'm prepared to do as part of this one change :) Kevin |
I'll do a few updates - at the very least to see if I can make the Performance MIDI channel a little more obvious. I'm trying to remind myself what I did now :) It might also be worth changing the config setting to use the words used in the original manuals too - I'll see if I can match or not! Kevin |
Haha! Just fell foul of some of that confusion I was talking about myself... When testing the PC changing, my initial config file performance.ini has TG1-8 mapped to MIDI channels 1-8 and all seems fine. Then I switch to select performances and all seems ok. Then I switch back to voices and weirdly I see six sets of Program Change messages going to MIDI channel 1... and I can't work out why... ... and then I realise that when testing the performance selection I've selected a voice that has six TGs all configured for MIDI channel 1 :/ I'm really starting to think we should not be having MIDI channel (or voice or bank) in the saved performance files... Looking at the TX802 I see the parameter dumps are in several parts: the performance file has the effects/etc in it; but there is also a "system parameters" dump which is defined as follows: That would be quite a big change, but it is also probably the way this kind of thing ought to be handled.... but I'm not going to even attempt to think about that as part of this change. Kevin |
…ormance Select Channel. Also now accepts 1-16 or Omni as values.
… or Performances.
Ok, so this is where we are with this one. There are now GPIO and MIDI button options for a PGM Up/Down and TG Up/Down selection UI elements. PGM Up/Down can be configured to act on either Voices within a TG or on Performances. This is determined by the PerformanceSelectChannel setting in minidexed.ini or the UI setting under "Performances -> MIDI PC" which determines if Program Change messages act on voices or Performances. PerformanceSelectChannel is set as follows:
This interacts with other config settings as follows: Note that only the first 128 performances can be selected over MIDI as we have no concept of LSB/MSB or banks for performances. Limitations:
I think this is about the shape of it. Anyone fancy giving it a go!!? :) When this gets to the point where we're happy with it and it is merged in then I'll attempt to update the wiki along the above lines! Kevin |
Thanks @diyelectromusic. From the description it reads like it's a really complex feature.
This part I don't understand. Why can't we just use the same MSB and LSB Program Change (PC) for voices and performances, depending on whether we are in "voice switching mode" or "performance switching mode"?
Maybe we should make it switch performances rather than voices by default now? |
Because we'd have to implement performance "banks" first which is something we don't have at all in the system. If you think we need that then that is something for a different PR as it will be quite an extensive set of changes.
I still think that only plays to how some people will be using MiniDexed and takes it away from being a DX7(II) in a box as the default DX7II mode is to switch voices not performances. The DX7s are a multi-timbral synth first and foremost, whereas treating performances as the "native voice" is more like treating it as a 8x6-operator massively polyphonic single FM synth. As I understand things, most of the performances that are shipped with MiniDexed are effectively single combined voices. But you can set the default in minidexed.ini however you wish. There will still be some confusion I feel just from the terminology if nothing else - people will almost certainly (as a default) expect Program Change to change the FM voices used on the MIDI channel they use to send notes to a TG. But if we default to performances that only makes sense if all TGs have the same MIDI channel which kind of becomes "the MIDI channel of the synth" (but it has to be configured in 9 different places - 8 TGs and the performance select channel). It is perhaps more in keeping with what MiniDexed is now to treat performances this way, but at this point it is diverging from the nature of the original synths.... It might be good for an audience not knowing anything about a DX7 and wanting a "cool FM synth on a Pi" but all the reputation of MiniDexed was based on being "DX7s in a box" so I'd advise caution about diverging too far away from what the DX7s actually were... Kevin |
Yes, MiniDexed started out as a "DX7 or TX812 in a box" but the more I learn, the more I think we actually want a "DX7IId or TX802 in a box". But hey, all of this is new to me since I never had the original hardware back in the day to begin with. Yes, I think we need performance "banks" because @Banana71 alone is easily providing more than 127 of them. But I agree that's for another PR then. I will open an issue so that it won't be forgotten. @diyelectromusic kindly let me know once you think this PR is ready for being merged. |
I think I'm done with it now, but it would be useful for someone to give it a spin too! :) |
Build for testing: MiniDexed_2023-08-12-c598e2e @Banana71 it'd be very helpful if you could test the heck out of this, as you know what to expect ;-) |
My RPi 4 does not start with the MiniDexed_2023-08-12-c598e2e version. (I can't easily connect a monitor to HDMI). With the ExpandPCAcrossBanks=1 function, the Voices Bank are loaded across the board, but the bank is not updated in the UI. This means that if I load a Voice greater than 32 from Bank A, the display stays on Bank A instead of switching to Bank B, C or D. I have to get used to it first. However, it is clear to me that you cannot update the bank because otherwise there would be no meaningful scrolling up.
I don't understand you there @diyelectromusic I think a combined program change function is still the most sensible. Here is an example:
Performance:
For the next bridge in the song, the possibility to change only the sound of TG7 would be desirable. |
Yes, I think this is one case where people will largely be doing one or the other - i.e. either running it as a "MIDI voice bank of 128 voices" or treating it as banks/voices in their own right (either via DAW or UI). (BTW - the expand function is already in there, that isn't part of this PR, just the bit about performances).
I was attempting to show how the terminology is going to confuse. In this mode it is largely acting as a single synth - changing performances changes all TGs etc, but the MIDI configuration could still be split causing confusion as bits might be acting on their own...
I like the idea, but I really don't think we can do this whilst MIDI channels (and voice/banks for that matter, although they are ignored) are part of the performance configuration. You might think you have TGs responding on MIDI channels 3,4,5 but if you load a performance with a different MIDI config you're a bit stuffed :) I think you have to mentally model the device either as a multi-timbral 8 TGs device, giving each TG its own setting; or a single 8x6 operator device where you assume the performance will be the entirety of what you need to load to make it do its thing. As I say, if we somehow separate out the "system configuration" from the "performance configuration" then what you are suggesting probably makes more sense (to me at least), but right now they are combined and I think the only safe thing is to force the user to look at the device one way or the other... a hybrid just leaves too many avenues for getting the UI/DAW/sound/MIDI config out of sync in my view and leaving them wondering why nothing is responding anymore - I already had that problem myself during testing and I'd like to think I know how it is supposed to be working! :) Kevin |
Ah, failing an assert in MiniDexed SetParameter... probably a timing thing on a Pi4, I'll take a look (all my testing tends to be on a Pi 3 as its easier to plug into screens!) Update: Yes the timing of my call to SetParameter to set the PerformanceSelectChannel - apparently one can't use SetParameter until the reverb has been initialised (which is a bit of a pointless dependency, but I can see why it's there). What is really odd is why the assert doesn't trigger on a Pi 3...? Anyway, just moving the line of code to after the reverb is set up... Kevin |
…set problem on a Pi 4 and updated menu text to fit nicely on a HD44780 display.
Right an update is now building. I've also had to change the text for the Performance menu from "MIDI PC" to "PCCH" to make it shorter so it doesn't wrap on a HD44780 display - again my Pi 3 has a SSD1306 display which is two characters longer! My Pi 4 setup is using the HD44780, so note to self: don't be lazy and test on the PI 4 too :) Kevin |
Build for testing: MiniDexed_2023-08-13-f6a53c2 |
RPi 3, seems to work. |
It would be nice, but I refer you to my previous comments:
And after taking another look concluded:
I think it is a different issue and not for this change to fix the inconsistency in voices vs performances in the menus. Might be worth going back to the original author of the performance menus and asking why they were different to make sure we're not missing something? (this change does seem to be prompting a lot of discussion about things that weren't actually in scope in the first place!) Kevin |
Wiki now updated in hardware and files sections. Probably should expand on the MIDI implementation section at some point too, but I need to think about how best to describe it there, so haven't done that yet. Kevin |
Thank you very much @diyelectromusic |
Looks like there was no universal standard how to do this. Found this in the Yamaha manual for the PF2000, one of their lesser known FM instruments from the 80s: If you ask me, this is a really awkward way of doing it. Especially since the numbering on the cartridge is not a 1:1 match to the numbering of the MIDI messages. |
All part of the reasons for inventing General MIDI... :) |
Includes updates to do the following:
Update inspired by discussion on "headless MIDI" patch changing here: #496
Kevin