# Missing or endless keypresses after poweron

**URL:** <https://community.keyboard.io/t/missing-or-endless-keypresses-after-poweron/5855>\
**Category:** Help and Getting Started\
**Created:** [October 26, 2022, 7:14pm UTC](https://community.keyboard.io/t/missing-or-endless-keypresses-after-poweron/5855 "2022-10-26T19:14:08Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![algernon](https://yyz1.discourse-cdn.com/flex031/user_avatar/community.keyboard.io/algernon/32/4404_2.png) [@algernon](https://community.keyboard.io/u/algernon)\
**Post date:** [October 27, 2022, 11:14am UTC](https://community.keyboard.io/t/missing-or-endless-keypresses-after-poweron/5855/5 "2022-10-27T11:14:30Z")

</div>

> [@hupfdule](#):
>
> Is this .ino file considered being part of the firmware? How is this .ino file related to the actual firmware?

Yes. The firmware is a combination of the sketch (the `.ino` file), and all of its dependencies: Kaleidoscope, the Arduino core used, KeyboardioHID, and any other library or third-party plugin you may pull in.

> [@hupfdule](#):
>
> That means, should I pull some changes of the “default” .ino file from time to time into my local copy I use for building the firmware?

That depends whether you want those changes or not. It’s perfectly fine to not have anything in common with the default firmware. (Mine for example, has no relation; there are common plugins, but that’s about it.)

> [@hupfdule](#):
>
> You write about version 0.91.0. That is the version I see in Chrysalis when looking for a firmware update. But the Kaleidoscope on github (and the above mentioned arduino directory) have a current version number of 1.99.7. Why this different version numbers? How are they related?

0.91.0 is the version of [Chrysalis-Firmware-Bundle](https://github.com/keyboardio/Chrysalis-Firmware-Bundle). The version is unrelated to Kaleidoscope. We version them independently so that they can be released and managed separately: we usually release the firmware bundle more often than Kaleidoscope. The firmware bundle also depends on the Arduino core ([ArduinoCore-GD32-Keyboardio](https://github.com/keyboardio/ArduinoCore-GD32-Keyboardio) in case of the Model100).

So, as I wrote above, the relation is that `Chrysalis-Firmware-Bundle` is at the top, that’s what we build the firmware from. It depends on Kaleidoscope (the main firmware _library_, think of it as a framework of sorts), which in turn depends on KeyboardioHID (the HID implementation we use), and the appropriate Arduino Core (the aforementioned `ArduinoCore-GD32-Keyboard` for the Model100, and [Kaleidoscope-Bundle-Keyboardio](https://github.com/keyboardio/Kaleidoscope-Bundle-Keyboardio) for previous, AVR-based keyboards).

The tooling for the official builds - as of 0.91.0 - pulls in a specific git commit for Kaleidoscope, and the latest git head for the Arduino Core, along with whatever version of KeyboardioHID the core itself pulls in.

Yes, it’s a bit complicated.

> [@hupfdule](#):
>
> When I am building my own firmware and install it (via Chrysalis) it ends up having a version number of 0.0.0. That means I have no indicator what actual firmware version I am using. What do I have to do to get the actual version number (preferably with a custom suffix indicating my changes to the .ino file).

The version is set via the [FirmwareVersion plugin](https://kaleidoscope.readthedocs.io/en/latest/plugins/Kaleidoscope-FirmwareVersion.html). If you define `KALEIDOSCOPE_FIRMWARE_VERSION` to a string _before_ including the plugin’s header in your sketch, then you can set a custom version.

If you derive your sketch from the official firmware, and intend to follow it, then I guess it makes sense to set that version to something like `0.91.0-hupfdule.1`, and bump it whenever you feel like it. If you’re using CLI tools to build the firmware, you may be able to set things up so that the version becomes a git sha or something.

If you want to see a standalone sketch, [here](https://git.madhouse-project.org/algernon/Model100-sketch) you can find mine. I build it using command line tools. `make setup` will set things up, and `make` compiles it. There are many ways to set things up, however.

> [@hupfdule](#):
>
> How can I build my firmware without using the Arduino IDE?

On Linux - and likely macOS -, the easiest is probably to start with the `Chrysalis-Firmware-Bundle` repository. `make setup` will do the necessary steps to install stuff, `make update` will update dependencies, and `make` will compile all firmware. `make Keyboardio/Model100` will only compile firmware for the Model100. It does require [`arduino-cli`](https://arduino.github.io/arduino-cli/latest/installation/) to be available, but does everything else apart from that.

> [@Moilleadoir](#):
>
> **Edit:** Looking at the Chrysalis repo just now it seems that things have changed recently. Before the Chrysalis version was updated first, but now it seems that the Kaleidoscope code is the canonical version, which I suppose means 1.99.7 is the latest.

No, the firmware bundle is still versioned independently. We just rearranged things so that rather than having two copies of the firmware (one in the bundle, one in Kaleidoscope to serve as an example in the Arduino IDE), we only have one: the one in Kaleidoscope. This rearrangement does not affect how things are versioned, it’s merely to eliminate the problem of the two copies growing out of sync.

---

_[View the full topic](https://community.keyboard.io/t/missing-or-endless-keypresses-after-poweron/5855)._
