The Key Control from Artificial Noise is a midi mapper that takes a standard Keyboard Midi Controller and maps the C scale (the white keys) to any key and any scale mode, and then the black keys are mapped to chords in that key and scale mode. It’s got plenty of short comings, in my opinion (like the Key dial should have been in cycle of fifths), but for what it is it seems pretty reasonable.
A second also for William WILD’s suggest of the Irijule Theoryboard, which is not released yet, and only available from pre-order like on Kickstarter. I got one on order.
ADDED December 1, 2020: They changed its operation so you can now use it to change key and scale from sequencers and arpeggjator outputs, and changed a few of the lesser used scales to more common ones. They also lowered the price quite a lot too. Looks like a much nicer product now.