Code Monkey home page Code Monkey logo

Comments (11)

SekoiaTree avatar SekoiaTree commented on May 27, 2024 1

Understandable, thanks! I'll try and do the configurable speed

from prk_firmware.

hasumikin avatar hasumikin commented on May 27, 2024

@SekoiaTree
How about this?

kbd.define_mode_key :BACKTICKS, [ Proc.new { kbd.macro("```") }, nil, 200, nil]

from prk_firmware.

SekoiaTree avatar SekoiaTree commented on May 27, 2024

@hasumikin that... sort of works? First, it's a teensy bit slow (you can see the characters one by one), but second it's the wrong character. I think that has something to do with me being on a QWERTZ keyboard (this is for a macropad) instead of a QWERTY. I noticed that KC_Z outputs Y and inversely, for example.

from prk_firmware.

SekoiaTree avatar SekoiaTree commented on May 27, 2024

Also, for some reason it seems to press enter after? Like, I just tried kbd.define_mode_key :BACKTICKS, [ Proc.new { kbd.macro("test") }, nil, 200, nil]

and that outputs:

test

from prk_firmware.

SekoiaTree avatar SekoiaTree commented on May 27, 2024

So, I believe this line is the cause for the long time; maybe it should be configurable in the .macro call?

cycle_time = 40 # To avoid accidental skip

Second, I figured out the enter. If you add ,false in the options, it turns it off. All good on that!

(entirely unrelated, but noticed when browsing the code. Why does it sleep for half a second when booting?


It also does it in a few other places)

from prk_firmware.

hasumikin avatar hasumikin commented on May 27, 2024

Proc.new { kbd.macro("```") } works for me and is faster than I type.
Whether it’s a QWERTY or not and whether it’s a full-size keyboard or a macro pad don’t matter at all

from prk_firmware.

SekoiaTree avatar SekoiaTree commented on May 27, 2024

Yes, yes it does. Any z inside the code instead types y, and inversely. Same for most special keys. This is an issue that pops up in a lot of things that don't handle non-qwerty keyboards, I think it's because of scancodes. And yes, it's faster than one can type, but it could be faster, so imo it should be configurable.

from prk_firmware.

hasumikin avatar hasumikin commented on May 27, 2024

Regarding the speed, I myself won’t make it configurable but will merge if you send a reasonable PR.

QWERTZ, yeah I could get what is happening. Fixing the problem isn’t easy because of RAM consumption.
Furthermore, that problem can’t be a high priority because I don’t have any QWERTZ keyboard. If many people came here to request fixing it, I will do 🫡

from prk_firmware.

hasumikin avatar hasumikin commented on May 27, 2024

@SekoiaTree
I came up with an idea of switching QWERTY to QWERTZ with adequate RAM consumption.
I've learned there are QWERTY, QWERTZ and AZERTY. Is there any other major kind of keyboard?
And also, I'm not knowledgeable about letters like á and ü etc. Should a keyboard firmware consider them?

from prk_firmware.

SekoiaTree avatar SekoiaTree commented on May 27, 2024

Keyboard formats are really complex :/ there's like, one per language. A swiss qwertz keyboard isn't the same as a german qwertz keyboard for special keys, for example. Honestly, it might just be easier to have some custom config or utility that maps from what QWERTY has to whatever your keyboard is.

from prk_firmware.

hasumikin avatar hasumikin commented on May 27, 2024

I'm closing this because the original issue, which is Macro already been implemented.
Anyone can open another issue regarding suggesting QWERTZ

from prk_firmware.

Related Issues (20)

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.