DmNosachev / kinbp

Drop-in replacement controller for Kinesis Contoured keyboards
Creative Commons Attribution Share Alike 4.0 International
6 stars 5 forks source link

Hooking up a speaker? #4

Open LeoMegaAir opened 7 months ago

LeoMegaAir commented 7 months ago

I know you invested quite an effort to make your keyboard silent so my question will sound weird but is there a way to add a speaker to your setup, and how?

The Kinesis Contoured built-in speaker helps avoid bottoming the switch out at key press, plus it can be good to know if you really got the button pressed because the PC does not react instantly (when hitting one of those rubber buttons, e.g. F5 while reloading a web page).

afonsoguerra commented 7 months ago

I'm not the dev here, but just came across this and just to point out the software that runs on the kintbp/kintwin/kint41 etc, is QMK, so you might get more luck getting help there. To get you started, here is their documentation for audio: https://github.com/qmk/qmk_firmware/blob/master/docs/feature_audio.md

From the hardware side, you just need to find a spare pin for it, it will mostly be software programming I think.

LeoMegaAir commented 7 months ago

I'm not the dev here, but just came across this and just to point out the software that runs on the kintbp/kintwin/kint41 etc, is QMK, so you might get more luck getting help there.

This (kinbp) project supports QMK firmware. Question is, how to alter the PCB files to get two holes for the speaker in it and how to change/add the firmware get the keyboard produce the sounds similar to what Kinesis makes with the sound on, i.e. clicks on button presses.

DmNosachev commented 7 months ago

HI. I'll be back from vacation next week and will be able to see the current state of audio support in QMK for STM32 MCUs. You will need to install KiCAD to modify the PCB.

anm commented 7 months ago

I would like to do this too. It looks like the only spare usable pin is PB2/BOOT1 which has no timer output. The LED pins have some timers though that might suit for sound, so might move an LED to PB2.

I don't have the firmware at all though. It looks like the keyboard files are not in the qmk distribution and I can't find them here.

anm commented 6 months ago

I have designed a board with a piezo using two drive pins (one for each side). A one pin driver seems to exist for the STM32F4s, but I'm not sure the ALT_PIN stuff is implemented for the other pin, so maybe only one usable unless that is improved. I'll let you know if it works.

anm commented 5 months ago

I have it working. I moved some stuff on the board though - should probably test v2 before publishing.

anm commented 2 months ago

Tested and working: https://github.com/anm/kinesis_controller

The software needs some work though. The hardware PWM driver doesn't work properly, so switched to software which is ok, but not got the clicky working well yet. Generally need to rearrage the config stuff too - it's mostly just in the F411 directory, not F401.