that, plus some hardware and soldering stuff,@crumoetz: I also don't think that's impossible but it is a task that's not accomplished in a few days of work yet alone as a one person project. In the current state you would have to do this:
Find an user land exploit in the Pokemon game.
Then Loading arbitrary code while maintaining the core of the bt functions.
Gaining kernel level access to the arm9 processor.
Exploiting arm11 from the arm9 process and break out of the NDS firm.
Hack somehow the functionality of the 3ds firmware to make use of the bt keyboard.
Man you have to be a monster to do this.