diff --git a/boards/nullbitsco/README.md b/boards/nullbitsco/README.md index b4fe7de14..15d7077b7 100644 --- a/boards/nullbitsco/README.md +++ b/boards/nullbitsco/README.md @@ -1 +1,2 @@ -https://nullbits.co/ \ No newline at end of file +Mappings for [nullbits](https://nullbits.co/) keyboards, +often based on the [BIT-C pro micro MCU](https://nullbits.co/bit-c/). diff --git a/boards/nullbitsco/tidbit/README.md b/boards/nullbitsco/tidbit/README.md index f8ba9f969..62b6ab66f 100644 --- a/boards/nullbitsco/tidbit/README.md +++ b/boards/nullbitsco/tidbit/README.md @@ -1 +1,38 @@ -https://nullbits.co/tidbit/ \ No newline at end of file +Keyboard mapping for the [nullbits tidbit](https://nullbits.co/tidbit/). + +Copy `kb.py` and `main.py` to your top level circuitpython folder beside the kmk folder. +Edit the key mapping in `main.py` to match your build, +for example the number and location of encoders and double-size keys. + +The Keyboard constructor supports a couple of optional arguments (see `kb.py`). + +If you're setting your tidbit up in landscape mode, +with the USB connector at top right instead of top left, pass +`landscape_layout=True`. + +You can specify the active encoder positions by passing a list like +`active_encoders=[0, 2]` which corresponds to the 1st and 3rd positions shown +in [step 6](https://github.com/nullbitsco/docs/blob/main/tidbit/build_guide_en.md#6-optional-solder-rotary-encoder-led-matrix-andor-oled-display) of the build guide. +The default is for a single encoder in either of the top two locations labeled 1 +in the build diagram, i.e. `active_encoders=[0]`. Pass an empty list if you skipped +adding any encoders. + +You can control the RGB backlights with the [RGB extension](http://kmkfw.io/docs/rgb). +Here's an example: + +```python +from kb import KMKKeyboard +from kmk.extensions.rgb import RGB, AnimationModes + +keyboard = KMKKeyboard(active_encoders=[0], landscape_layout=True) + +rgb = RGB( + pixel_pin=keyboard.pixel_pin, + num_pixels=8, + animation_mode=AnimationModes.BREATHING, + animation_speed=3, + breathe_center=2, +) +keyboard.extensions.append(rgb) + +``` diff --git a/boards/nullbitsco/tidbit/kb.py b/boards/nullbitsco/tidbit/kb.py index dde96f0be..4d8399256 100755 --- a/boards/nullbitsco/tidbit/kb.py +++ b/boards/nullbitsco/tidbit/kb.py @@ -22,7 +22,6 @@ class KMKKeyboard(_KMKKeyboard): active_encoders=[0, 2] to list installed encoder positions (first=0) then declare keyboard.encoders.map = [(KC. , KC., None), (...)] - enable_rgb=False (default True) to add rgb module (requires neopixel.py) landscape_layout=True to orient USB port top right rather than left (default) """ # led = digitalio.DigitalInOut(board.D21) @@ -45,7 +44,7 @@ class KMKKeyboard(_KMKKeyboard): diode_orientation = DiodeOrientation.ROW2COL i2c = board.I2C #TODO ?? - def __init__(self, active_encoders=[], landscape_layout=False): + def __init__(self, active_encoders=[0], landscape_layout=False): super().__init__() if landscape_layout: