geekhack

geekhack Projects => Making Stuff Together! => Topic started by: KeyBoulE on Fri, 30 October 2020, 10:18:02

Title: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Fri, 30 October 2020, 10:18:02
Hi All,
I am interested in designing a wireless keyboard for my needs. From my initial reading, I think I want to do something with a 2.4GHz receiver (not BLE) and I see there are a lot of projects already out there that I could use as a jumping off point. Ideally I could start with one of these projects and tweak the layout and design for my use case.

Mitosis (https://github.com/reversebias/mitosis) looks like it would meet my needs. I see he has everything open source and at first glance the documentation looks pretty robust. His design doesn’t use a switch matrix so if I run out of GPIO I may need to change direction there but I imagine that would be more straightforward than trying to figure out all the wireless stuff if I started from a normal wired QMK project.

If the forum has other suggestions that might make more sense to start from than Mitosis I am all ears. Thanks all.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Fri, 30 October 2020, 11:13:20
how big of a board are you planning on making? will probably be the deciding factor of which direction you go...

there was also the trident (https://github.com/YCF/Trident) (wireless let's split based on the mitosis) https://github.com/YCF/Trident

if you end up goint the BT route, here's what i've found so far (been watching this stuff for a while) good documentation/harware support still seems very spotty though there are a couple good ones.
blue micro https://github.com/jpconstantineau/BlueMicro_BLE
     - https://github.com/SouthPawEngineer/BlueMicro_BLE
     - https://www.reddit.com/r/MechanicalKeyboards/comments/8h8jf4/introducing_the_bluemicro_a_dropin_bluetooth/
nice nano https://geekhack.org/index.php?topic=106680.0
zmk (bluetooth focused fork of qmk) https://github.com/zmkfirmware/zmk
     - https://zmkfirmware.dev/docs/
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Fri, 30 October 2020, 11:20:56
Great, thanks Nevin. That gives me some reading to do. Based on the links you posted I gather that you are more intersted in the bluetooth route as opposed to the non-bt w/ receiver. Is that the case?

As far as how big. My thoughts were to do something similar to the lily58 in terms of key count.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: Tactile on Fri, 30 October 2020, 11:38:22
Bluetooth is a lot easier because there's only one gizmo to buy, the radio for the keyboard. The rest is handled by the gadget already in the computer. The setup you are looking for is more complicated because you would need both the keyboard radio & the USB receiver - basically a kit. And they would have to be coded, or paired, to communicate.

I'm not aware of a setup like that available to hobbyists but you might have a look at what Adafruit has for sale (https://www.adafruit.com/category/112). If there's such a thing out there, they've played around with it.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Fri, 30 October 2020, 11:53:30
lily58... it should be close then.
... what did i read... up to 29? keys... ah, here... 23 switches and 31 GPIOs (for the mitosis)
lily58 is 29 per side so you may be able to do it with minimal adjustments to the firmware.

i was saying size being the determining factor, because the couple that i've seen of the mitosis variants are all 1 switch per i/o instead of matrix. if there was use of a normal matrix and easier programability i'm sure the mitosis hardware would have blown up a lot more than it has.

the bluemicros and similar are pretty much a drop in promicro replacement with BT. adding BT to a wide array of existing keyboards that currently support promicros.
- so like the lily58... just swap the promicros for the BT promicro replacements and you're pretty much done.

- also, don't buy just any bluefruit, feather, etc... most are not compatible for what you want to do. (mainly because of processor/architecture not supported or fully supported/documented in QMK/ZMK yet)

you also have the added connectivity of other BT devices (phone, tablet, etc...) instead of just your computer or something with a usb port for the receiver.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Sat, 31 October 2020, 08:21:56
Cool, thanks guys. I have a nrf52840DK board sitting around and I think I can make that work with the Bluemicro firmware. I'll give it a shot and see how it performs before going down the receiver based route.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Sat, 31 October 2020, 13:11:45
keep us posted with what you try, what works & what didn't. BT is still relatively new in the DIY realm.

feel free to ask questions if you get stuck
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Sat, 07 November 2020, 10:20:37
Well i got BlueMicro up and running this morning on the nordic dev board. It's got a lot of wires for a wireless keyboard, haha. All in all a pretty easy process after having spent some time in qmk previously. Everything seems pretty snappy so far and I'm looking forward to seeing what battery life is like.

One thing I haven't seen in the docs is if it is possible to pair to multiple devices (computer, iPad, phone, etc) and quickly switch between them via a special keystroke. Is that possible in blue micro and if so could you guys point me in the right direction?

[attach=1]
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Sat, 07 November 2020, 13:08:13
NICE!
i'm going to show this to @pabile as well, because he's looking to do something similar.. .(wireless)

multiple devices... would be nice, i'd have to look in the documentation to see if that's implemented yet. if not, try searching other area's if not officially supported yet.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: pabile on Sat, 07 November 2020, 18:58:44
this is awesome! please keep us updated :)


p.s. thanks, nevin. one more reason to stay off bluefruit  :))
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Sun, 08 November 2020, 03:24:13
p.s. thanks, nevin. one more reason to stay off bluefruit  :))

yeah, i never really liked blueberries... lol
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: Applet on Sun, 08 November 2020, 12:19:44
I'm playing with a DIY design using nRF52840. I've only tried ZMK so far, but it's running good. nRF52 seems really promising.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Sun, 08 November 2020, 13:00:16
nRF52840... yes, i believe that is the one that has been the most compatible.

@Applet, please post a link to your thread if you've posted anything about it yet.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: Applet on Mon, 09 November 2020, 02:39:56
@Applet, please post a link to your thread if you've posted anything about it yet.
I've not posted anything about it yet, but I'll do a thread eventually. :D In short, it's a "Standard multi layout 60%" PCB using the holyiot nrf52840-module with DIY in mind, so mostly JLC basic parts and all is possible to solder with just an iron. There is some more info on my github-page: link (https://github.com/4pplet/cyber60)
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Tue, 08 December 2020, 15:07:37
Wires are slowly disappearing from my wireless keyboard.  :)

I’ve moved over to ZMK from BlueMicro. The ZMK docs and discord are pretty good and having a dockerized build environment is really nice for getting started without messing with setup stuff forever. Performance seems to be pretty good so far. I’ve only been using it to tinker with, not as a family driver, so haven’t gotten a great idea on battery life yet.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Tue, 08 December 2020, 15:10:27
looking good! :thumb:

any tricky things you ran across setting this up in either firmware?
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: KeyBoulE on Tue, 08 December 2020, 20:05:17
Not really anything too tricky with either BlueMicro or ZMK. The setup for both of them is fairly straightforward following the docs. Maybe a little more cumbersome for BM but pretty easy if you are comfortable with arduino. It took me a bit of time to adapt to the different ways that QMK, BM and ZMK define their switch matrix to keymap relationships. They are all pretty much the same concept but a few subtleties/typos added some time.

I really like the way that ZMK is keeping the user-specific stuff (keymaps, shields, etc) separate from the core functionality in the main ZMK repo. It’s pretty slick how users can make their own keymaps/shields and compile firmware via github actions without having to set up much on their local machine. And if you do want to go deeper they have a pre-configured docker image that gets you going quickly.
Title: Re: Best Starting Point For DIY Wireless Design. Mitosis?
Post by: nevin on Tue, 08 December 2020, 20:30:23
thanks