GithubHelp home page GithubHelp logo

sago35 / tinygo-keyboard Goto Github PK

View Code? Open in Web Editor NEW
65.0 4.0 10.0 8.29 MB

USB HID keyboard firmware for tinygo

License: MIT License

Go 96.14% Makefile 3.43% HTML 0.43%
firmware go golang hid keeb keyboard tinygo usb usbhid vial

tinygo-keyboard's Introduction

USB HID Keyboard firmware for TinyGo

The API is not yet fixed.

TinyGo 0.29 or later is required to build tinygo-keyboard 0.2.0

The following are supported.

  • key input
    • squared matrix scan
    • matrix scan
    • duplex-matrix scan
    • rotary encoder
    • GPIO
    • UART
    • Shifter (tinygo.org/x/drivers/shifter)
  • layer feature by mod key
  • mouse click / mouse wheel
  • support TRRS (UART)
  • support Vial

Microcontrollers

The following microcontrollers are supported.

  • rp2040
  • nrf52840
  • samd51
  • samd21

Tutorial

sgkb-0.4.0

# sgkb-0.4.0
$ tinygo flash --target xiao-rp2040 --size short ./targets/sgkb/left/
$ tinygo flash --target xiao-rp2040 --size short ./targets/sgkb/right/

# sgkb-0.3.0 or before
$ tinygo flash --target xiao-rp2040 --size short ./targets/sgkb/left-0.3.0/
$ tinygo flash --target xiao-rp2040 --size short ./targets/sgkb/right/
name amount
Cherry MX / Kailh Choc V1 72
key cap (1u) 68
key cap (1.5u) 1
key cap (1.75u) 1
key cap (2u) 1
key cap (ISO-ENTER) 1
Stabilizer (2u) 2
diode 1N4148 72
xiao-rp2040 2
pin header 1x7 4
TRRS connector 2
TRRS cable 1

sg48key

tinygo flash --target xiao --size short ./targets/sg48key/

sgh60

tinygo flash --target waveshare-rp2040-zero --size short ./targets/sgh60/

wiokey-0.1.0

$ tinygo flash --target wioterminal --size short ./targets/wiokey/
name amount
Cherry MX / Kailh Choc V1 6
key cap 6
diode 1N4148 6
wioterminal 1
pin socket 2x20 2

sgkey-0.1.0

$ tinygo flash --target xiao-rp2040 --size short ./targets/sgkey/
name amount
Cherry MX / Kailh Choc V1 6
key cap 6
diode 1N4148 6
xiao-rp2040 1
i2c ssd1306 1
register 10k ohm 2

fric10key-0.1.0

$ tinygo flash --target xiao-rp2040 --size short ./targets/fric10key/
name amount
Cherry MX / Kailh Choc V1 27
key cap (1u) 26
key cap (2u) 1
Stabilizer (2u) 1
diode 1N4148 27
xiao-rp2040 1

xiao-kb01

$ tinygo flash --target xiao-rp2040 --size short ./targets/xiao-kb01/

Gopher Badge

$ tinygo flash --target gopher-badge --size short ./targets/gopher-badge/

GoBadge / PyBadge

$ tinygo flash --target gobadge --size short ./targets/gobadge

MacroPad RP2040

$ tinygo flash --target macropad-rp2040 --size short ./targets/macropad-rp2040/

Restore default keymap

Set the key with the key code of 0x7C03, and then press it.
Then a reset will restore the default keymap.
See #8.

Restore default keymap (tinygo flash)

Restore default keymap each time it is reset by specifying --tags reset_to_default.
Note that in this setting, any changes made from Vial or other sources will immediately revert to the original setting.

$ tinygo flash --target wioterminal --size short  --tags reset_to_default ./targets/wiokey

Note

LICENSE

MIT

tinygo-keyboard's People

Contributors

ehime-iyokan avatar sago35 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

tinygo-keyboard's Issues

Want to add BLE support

I would like to add an implementation of the nRF52840 with BLE HID.
However, I do not have much knowledge of BLE and do not know how to tackle this issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.