Sorry to necro this thread but I’m having the exact same problem with a Planet Computers Gemini, an Android-based PDA with a build-in physical keyboard. The RIGHT SHIFT “latches” in exactly the way the OP described, and the only way to “un-latch” it is to either tap it briefly or to temporarily use the LEFT SHIFT at which point it “un-latches” when you release the LEFT SHIFT.
I’m actually trying to run an old Psion 3a emulator on Magic DOSbox, and the emulator itself has quirks which have required the use of Swiftkey as a sort of interpreter, and various on-screen buttons to emulate the softkeys and custom buttons of the original Psion hardware. As you can imagine, with three apps all talking to each other it took ages to figure out exactly what was happening with certain shifted keys, especially the / key which would either not work at all, or produce the wrong character, or bounce between the two states.
When I figured it out and searched for “magic dosbox” “right shift” , this was only one of two pages that were returned. The other was someone on a Gemini forum having a similar issue using a different flavour of DOSbox, so there may be some commonality in the source.
I’m kinda hoping someone has figured a way around this. If not, maybe this post will attract any other hapless Gemini users who are trying to recreate 20 year old hardware on the latest gear. It won’t necessarily help them, but at lest they’ll know they’re not alone!
In the meantime thank you for demonstrating to me that I’m not the only one to have had this issue. And for Magic DOSbox itself which is an amazingly versatile program. The ability to do on-screen tappable buttons enabled me to recreate the whole panel of softkeys that were present on the original Psion hardware, without which I’d have been stuck using F-keys which would have had to have been remapped because the Gemini doesn’t have an F-key row.