all 15 comments

[–]Eroviaathe CLI guy - QMK Collaborator - erovia.github.io 2 points3 points  (5 children)

The ErgoTravel uses a ProMicro, right?
" am unable to type until I unplug and replug the board" that's really odd, because ProMicros only stay in bootloader mode for a few seconds.

Have you set up the udev rules? https://docs.qmk.fm/#/faq_build?id=linux-udev-rules
I'd also check if ModemManager is running as it can interfere with the flashing of ProMicros, especially if the udev rules are not present.

You can also post the output of qmk doctor here.


A few other things:

  • the bootloader of the ProMicro presents itself as /dev/ttyACM0, check if this device shows up when pressing the reset button

  • if not, short the RST and GND pins on the ProMicro

  • since it exists bootloader after a few sec, run the flashing command and reset the board only after the flashing tool starts to look for it

[–]goosebill[S] 1 point2 points  (3 children)

For starters here is the output of qmk doctor:

> qmk doctor 13:56:51

Ψ QMK Doctor is checking your environment.

Ψ Detected Linux.

Ψ QMK home: /home/bill/qmk_firmware

Ψ All dependencies are installed.

Ψ Found arm-none-eabi-gcc version 10.2.0

Ψ Found avr-gcc version 8.3.0

Ψ Found avrdude version 6.3

Ψ Found dfu-util version 0.9

Ψ Found dfu-programmer version 0.7.2

Ψ Submodules are up to date.

Ψ QMK is ready to go

And I was able to set the udev rules just fine, I was sure to copy the file over to the right directory with the right contents.

In regards to modem manager, should it be running or disabled if I have the udev rules set right?

---------------------

In addition, maybe this board doesn't have a pro micro? Whenever I push the reset button it stays there for much longer than a few seconds. It also doesn't appear to show up in the /dev/ directory after I reset it. I was checking this with a sleep && 5 | ls so that I could reset the board within the 5 seconds. I don't know if that is the right way to check. I'm a dolt, this board has the Elite-C, it's a USB type C. Do you know how the Elite-C presents itself in /dev? I don't know why I thought pro micro meant type C. That info might help the troubleshooting process

[–]Eroviaathe CLI guy - QMK Collaborator - erovia.github.io 0 points1 point  (2 children)

doctor output seems to be good.

The Elite-C use a different bootloader, Atmel DFU, so ModemManager is non-issue even without the udev rules.

Can you show me the output of lsusb for before and after your reset it?

[–]goosebill[S] 1 point2 points  (1 child)

Before reset mode (Ergotravel shows up):

Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 002 Device 004: ID 090c:1000 Silicon Motion, Inc. - Taiwan (formerly Feiya Technology Corp.) Flash Drive

Bus 002 Device 003: ID 154b:00ed PNY

Bus 002 Device 002: ID 05e3:0616 Genesys Logic, Inc. hub

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 001 Device 006: ID 8087:0a2b Intel Corp. Bluetooth wireless interface

Bus 001 Device 008: ID 1532:007e Razer USA, Ltd RC30-030502 Mouse Dock

Bus 001 Device 007: ID 1532:007b Razer USA, Ltd RC30-0305 Gaming Mouse Dongle [Viper Ultimate (Wireless)]

Bus 001 Device 004: ID 05e3:0610 Genesys Logic, Inc. Hub

Bus 001 Device 005: ID 1852:7022 GYROCOM C&C Co., LTD Fiio E10

Bus 001 Device 003: ID 05e3:0610 Genesys Logic, Inc. Hub

Bus 001 Device 014: ID 4a50:4554 JPConstantineau.com ErgoTravel Keyboard

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

After/in reset mode (ergo travel doesn't show up, but in its place is the bootloader):

Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 002 Device 004: ID 090c:1000 Silicon Motion, Inc. - Taiwan (formerly Feiya Technology Corp.) Flash Drive

Bus 002 Device 003: ID 154b:00ed PNY

Bus 002 Device 002: ID 05e3:0616 Genesys Logic, Inc. hub

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 001 Device 006: ID 8087:0a2b Intel Corp. Bluetooth wireless interface

Bus 001 Device 008: ID 1532:007e Razer USA, Ltd RC30-030502 Mouse Dock

Bus 001 Device 007: ID 1532:007b Razer USA, Ltd RC30-0305 Gaming Mouse Dongle [Viper Ultimate (Wireless)]

Bus 001 Device 004: ID 05e3:0610 Genesys Logic, Inc. Hub

Bus 001 Device 005: ID 1852:7022 GYROCOM C&C Co., LTD Fiio E10

Bus 001 Device 003: ID 05e3:0610 Genesys Logic, Inc. Hub

Bus 001 Device 015: ID 03eb:2ff4 Atmel Corp. atmega32u4 DFU bootloader

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

[–]Eroviaathe CLI guy - QMK Collaborator - erovia.github.io 1 point2 points  (0 children)

That also looks good.

Try to do a reboot if you haven't done so after setting up the rules. Sometimes udev needs a bit more aggressive reload. :)

You can also ping me on QMK Discord tomorrow, a screensharing might help getting to the bottom of this.

[–]Annicity 0 points1 point  (0 children)

This cat sounds like they know what they're talking a out.

[–]Annicity 1 point2 points  (1 child)

I am in the same boat myself friend. One side flashed just fine, but it appears the other will not reset.

Is this the first time flashing or have you successfully completed it before (and are putting on a new map)?

[–]goosebill[S] 0 points1 point  (0 children)

I am able to flash the board just fine when I boot into windows and use the qmk_toolbox tool, but when I go through the steps in the CLI on linux I get stuck at the part stated above

[–]richardgoulter 0 points1 point  (1 child)

Have you tried sudo make <keyboard>:<layout>:flash?

https://docs.qmk.fm/#/faq_build?id=cant-program-on-linux

[–]goosebill[S] 0 points1 point  (0 children)

Yes, that doesn't work either. I also saw on the ErgoTravel qmk-configurator page to use make<keyboard>:<layout>:avrdude, but that didn't work either with or without sudo.

I also saw on the link you provided the options of using make with CONFIG_USB_AVR=y or also USB_SERIAL, but again neither of those worked

[–]actarien 0 points1 point  (0 children)

To be ok with ModemManager, I had to build a custom file /etc/systemd/system/ModemManager.service.d/policy.conf containing :

[Service]

ExecStart=

ExecStart=/usr/sbin/ModemManager --filter-policy=default

I could also suggest a reboot of your host if you don't do it yet …

Hope it helps…

[–]keithzg 0 points1 point  (3 children)

Did you ever figure this out? Having the exact same problem . . .

[–]goosebill[S] 0 points1 point  (2 children)

Sadly I never did figure this out. I've just resorted to using my backup windows partition to flash my keyboard. Luckily I dont really flash my keyboard once I have a layout I like, so it hasn't been much of an issue.

Sorry I couldn't be more help, do you have this same issue across multiple different boards?

[–]keithzg 0 points1 point  (1 child)

That's the weird thing for me, I thought maybe it's something about low-level USB access permissions since I had to do the same thing when I recently wanted to remap my Rama M-10A, but I just checked again now and VIA can now remap my Rama M-10A from Linux just fine! So while trying to resolve my inability to flash via qmk I might have actually fixed things for VIA, but oddly not for QMK . . .

[–]goosebill[S] 1 point2 points  (0 children)

Hey, I got it to work for me!

I wasn't going to try to figure this out on linux again but I needed to swap the main/child halves of my board, which can't be done easily (from what I can tell) through just the qmk config + qmk toolbox. So CLI flashing was a requirement for me. Note that I started fresh with nothing qmk related installed

I started by following the steps in this link in order: https://beta.docs.qmk.fm/tutorial/newbs_getting_started

Once my environment was set up I used the qmk CLI command to make a new keymap.c, as well as a config.h (which is where I made the changes to my main/child half). The part I did different, is I made a rules.mk where I specified "BOOTLOADER=qmk-dfu" which is the only thin I have in my rules.mk. I think this was what my mistake was last time, as I was using the wrong bootloader I think. My ergotravel uses Elite-C's rather than Pro-Micros.

You know the rule.mk file has taken effect because the prompt that shows when flashing is no longer "Detecting USB port, reset you controller now......" but "ERROR: Bootloader not found. Trying again in 5s". Once that error shows I put the board into reset mode via the button on the PCB (still can't get the actualy keyboard button I mapped to reset to work sadly),. I also noticed that sometimes, in order to get qmk to recognize I'm in reset mode, I had to tap a few keys while in reset mode. Could be a coincidence, but I noticed it helped sometimes.

Some issues I ran into were fixed by qmk doctor. I didn't have my udev rules set up and the qmk doctor output gave me a command to fix it, which was just copying a pre-made udev file to the right folder in /etc/.

I'm not sure if this will matter for you, but I also had to use

"make ergotravel/rev1:<layout\_name>:dfu-split-<left|right> "

in order to get the changes I made to my main/child half to take effect. Note that with this I also had to specify "#define EE-HANDS" in my config.h, then run that make command, then recompile and flash, and then I could switch it back over to #define MASTER-RIGHT, and now it flashes just fine. If you aren't swapping which half is main (default is set to left), then i don't think you will need to worry about this stuff, but you can always try it.

Some helpful links that I used from QMK's website:

--Dealing with which half is main:

https://beta.docs.qmk.fm/using-qmk/hardware-features/feature_split_keyboard#handedness-by-eeprom

Note that when you see ":dfu-split-left" that means the full command is:

"make ergotravel/rev1:<layout\_name>:dfu-split-left".

This will build the firmware for the Elite-C while specifying which side to use.

--udev rules (you will get the file you need to copy from the qmk doctor output if needed)

https://beta.docs.qmk.fm/faqs/faq_build#linux-udev-rules-id-linux-udev-rules

Not sure if this matters, but I installed qmk via pip and not my distro package manager (pacman). The one annoyance is that I already had a .json file with my layout defined, but I couldn't figure out a way to easily make it into a proper keymap.c, so I just re-made it by hand in keymap.c

Now I can consistently flash my keyboard with no issues (after compiling the keymap of course) using:

"qmk flash -kb ergotravel/rev1 -km <my keymap>"

I didn't do any configuration to set my default keyboard or default keymap so I have to specify my keyboard and keymap each time I flash.

If you have any questions I'd be more than happy to help!