GitXplorerGitXplorer
m

qmk_rc

public
59 stars
0 forks
5 issues

Commits

List of commits on branch latest.
Unverified
b191a87398b7ef560f47637ffb5890be1e057cf6

Fix test compiler warnings

mmmalecki committed 4 years ago
Unverified
549ec3cd0be36f08dc0a3e2f0d106e03778bd046

Fix and test data lengths over 255 bytes

mmmalecki committed 4 years ago
Unverified
d51b187d1d7ef992851210ae24d6082804646661

Assert final callback count

mmmalecki committed 4 years ago
Unverified
7432fd04f532d15e5df7fdf256be3b533669d2c5

Run tests in GitHub Actions

mmmalecki committed 4 years ago
Unverified
37663f69373f67b776c125b2ad96f52c67c29de3

Fix the test build

mmmalecki committed 4 years ago
Unverified
b731f3cd3ad84c96198e1e6c291260a3d88edf87

Briefly document custom commands

mmmalecki committed 4 years ago

README

The README file for this repository.

QMK RC

QMK RC is a project that aims to bring the same convenience to controlling your QMK keyboard from your computer, as QMK did to programming keyboards.

Quick start

To get started with QMK RC, you need to set up the keyboard and the host. Let's start with the keyboard:

Keyboard firmware

First, fetch the QMK RC source either into your keymap, or user directory:

bash <(wget -qO- https://raw.githubusercontent.com/mmalecki/qmk_rc/latest/bin/qmkrc_fetch)

Next, add these files to the SRC list in your rules.mk and enable the necessary QMK feature:

SRC += qmk_rc.c
RAW_ENABLE = yes

And include the header in your keymap.c:

#include "qmk_rc.h"

From here on, you can start feeding the QMK RC raw HID data:

#ifdef RAW_ENABLE
#define QMK_RC_BUFFER_MAX 64
uint8_t qmk_rc_buffer[QMK_RC_BUFFER_MAX] = {};

void raw_hid_receive(uint8_t *data, uint8_t length) {
  qmk_rc_receive(qmk_rc_buffer, QMK_RC_BUFFER_MAX, data, length);
}
#endif

Flash your keyboard with the modified software, as you usually do.

Host software

The host application is distributed as an npm package. To get it installed, run:

npm -g install qmkrcd

Play time!

Now, to the fun part.

Launch qmkrcd by typing qmkrcd. It will scan the HID devices attached to the host, and attempt to find one that quacks like a QMK-supported keybaord.

Alternatively, you can have qmkrcd connect to a specified device by passing its name as an argument: qmkrcd 'foostan corne'.

If qmkrcd doesn't find your device, please open an issue on its repository.

From now on, you should be able to control your keyboard. For example, to write a string to an OLED attached to your keyboard:

curl 127.0.0.1:9916/command -XPOST \
  -H 'content-type: application/json' \
  -d '{"id":3,"data":"Hello, QMK RC!"}' -v

For a full list of built-in commands, see Commands. You can also implement your own, Custom commands.

Acknowledgments

  • The QMK team for authoring an amazing piece of software
  • libuv team for their test framework