Struggling to flash HS60 v2 with ARM STM32F303CC


#1

Hi there,

I have been trying to flash this new HS60 v2 for a bit now and maybe someone out there can help me…
The micro is an ARM STM32F303CC which I haven’t flashed before.
First I made a “.bin” file with the QMK Configurator, that part was easy.

However I cannot flash that file into the PCB no matter what, I have tried Linux, Mac and Windows.

QMK Tools detects an “ARM STM32” in the console when I press the flash button on the back, but it doesn’t appear in the dropbox to select to actually flash it. In addition no ARM STM32 option appears in the Microcontroller dropbox either, onle the atmega ones.

dfu-util gives me different errors depending on the operating system but linux and windows tell me "More than one DFU capable USB device found! Try --list and specify the serial number"
Then when I do so I get two “devices” that are really only the one keyboard so everything is the same, aside from “alt”, “name” and what looks like a memory address?

I dont’ know, if someone with more experience can have a look at the screenshoots it would be great.

Thanks!


#2

You can type in the controller name into that Dropbox. Don’t know that it will help, but I had to do that for my LFKeyboard pcb.


#3

It’s necessary to pass additional arguments to dfu-util.

They can be found on GitHub, but I’m not allowed to post links.

So either add them to the command:

dfu-util -D file.bin -R -d 0483:df11 -a 0 -s 0x08000000:leave

Or use the command to build and flash qmk in one step. E.g.:

make hs60/v2:default:dfu-util

If you have trouble afterwards, keep in mind you have to reset the EEPROM:

Unplug -> Hold escape -> Plug in -> Unplug -> Release escape -> Plug in


#4

One more gotcha: if you use the ‘make’ command to build and flash QMK in one step, be sure to use the command that matches your layout. I have the ANSI HS60, and didn’t realize that default mapped to ISO until I launched VIA, which got into a weird state pretty quickly…

ISO:
make hs60/v2:default:dfu-util

ANSI:
make hs60/v2:ansi:dfu-util

HHKB:
make hs60/v2:hhkb:dfu-util


#5

Does the HS60 work with VIA?


#6

yes, it does, but I use some stuff that is not in VIA
and VIA doesn’t want to work in my Linux anyway…


#7

Also, while I’m thinking of it - if you’re rolling your own keymaps, you may want to grab the definitions from the appropriate instance of keyboards/hs60/v2/keymaps/*/config.h, again depending on whether you’re using ISO, ANSI, or HHKB.

I’m not sure if they are needed if you never use VIA, but since they seem to be specific to which HS60 layout you’re using, it seemed safest to include them - and I can confirm that you need them for VIA to work.

If you’re using VIA exclusively to do your HS60 layout and lighting, ignore this entire message.


#8

Thanks so much! This worked for me! :+1:


#9

DFU args are stored in keyboards/hs60/v2/rules.mk line 47.


#10

is there something you have to do to get it to work in VIA? Mine just shows the xs and os when I connect


#11

nevermind. just needed to update via


#12

So I found out that I needed to load the newest hs60 v2 build on my PCB to keep it from losing the Esc key when you change RGB modes (weird, right) So, I had to address all of this dfu bullshit.

At this point my PCB is unusable :frowning:

Keep in mind, the HS60v2 stuff doesn’t work in qmk toolbox. The board is listed, but the compiled defaults are not on the repo, so you can’t use it. Also, the .bin files listed on mechboards do not work on these PCBs.

I set up an environment to compile it myself on windows. As discussed previously, you have to pass additional arguments for dfu, or do the build and flash in one step.

I tried the build and flash, passing make hs60/v2:ansi:dfu-util

Build seem to go, .hex was created but an error (probably because I don’t think I had it it flashing mode) and qmk toolbox said “invalid dfu suffix signature”

Flashed the .build/hs60_v2_ansi.hex onto the PCB, which apparently was a bad decision.

Now I can’t use it at all. Mac doesn’t see it. Windows says USB malfunction.

I tried to reset but (hold esc, plug, unplug, release esc) but windows just sees it as a malfunctioning USB device. Idears?


#13

Shit, that sucks…
Have you tried dfu-util --list in both Mac and Windows?
What do you get?

The invalid suffix signature is ok, I always get that when I flash this board.
However I used the online QMK Configurator to get the firmware and it came out as a .bin not a .hex


#14

Btw you need get the PCB in flashing mode before running the dfu-util --list


#15

Well, at least I have one that works. Not sure about how to get the first one back in working order, or if I should request a replacement from Novelkeys, which is where I got it from.


#16

Yeah, the problem is I can’t get it in flashing mode. Windows will only see it as a malfunctioning USB device and basically won’t power it


#17

have you tried to push the button in the back while connected to the Mac?


#18

HOLY CRAP. I didn’t even see it had a hard reset! I got it working. LOL

Can I give you more than one heart? :heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart::heart:


#19

LOL


#20

BTW you could try to change the ESC key to ESC/~
These HS60s do very weird stuff
I had to change KC_LGUI to LGUI(KC_NO) in the HS60 v1…