rgerganov / footswitch

Command-line utility for PCsensor and Scythe foot switches
MIT License
411 stars 60 forks source link

Support for new pedal 5131:2019 Pedal? #58

Open stefmat10 opened 4 years ago

stefmat10 commented 4 years ago

I just got a new pedal from AliExpress and the VID:PID is 5131:2019 so it does not find it!

I have tried adding it to the list of VIDS in the source code but it still does not work so any suggestions?

scizzorz commented 4 years ago

I'm experiencing the same issue - I just got a new pedal from Amazon that's branded the FS1-P with the same VID:PID. I wasn't able to get it to work with PCSensor on Windows, and the software download link provided by the pack-in manual doesn't have a lot of flexibility; eg: you can only configure it for a single key / button, which triggers both the press/release events when the switch is pressed.

rgerganov commented 4 years ago

Can you post the Amazon link and the software download link?

scizzorz commented 4 years ago

Amazon and software. The software seems... sketchy...

scizzorz commented 4 years ago

Relevant line of lsusb:

Bus 001 Device 029: ID 5131:2019 GZIOT USBSW
elfifae commented 3 years ago

Just got one of these footpedals myself and encountered this project and issue while looking into a way to reprogram it from Linux. Like scizzorz, I'm not about to blindly trust the CD-R they sent me with the drivers. A quick disassembly showed it's rather basic, with mine just being a basic microswitch foot pedal while the USB connector has all of the electronics (if you could call a CH551G and a couple of capacitors that...).

I found a project on hackaday that had an English datasheet for the CH551 and its sister chip, the CH552, that might lend some insight on how to reprogram it. I'll look into it in more detail myself to see if I can add the functionality to this software. Until then, here it is for your perusal. https://hackaday.io/project/169671-ch552-dragon

jasonm23 commented 2 years ago

A couple more vendor/prod id pairs:

USB Device Name Vendor ID Product ID
Footswitch1F1 (RDing) 0x0C45 0x7403
USBSW (GZIOT) 0x5131 0x2019

Footswitch1F1 (RDing)

Registers key down/up on press/release as it should. I got this one a long time ago and programmed it. Probably using the bundled software on a Windows VM running on VirtualBox.

Device Found
  type: 0c45 7403
  path: DevSrvsID:4295022991
  serial_number:
  Manufacturer: RDing
  Product:      FootSwitch1F1.
  Release:      1
  Interface:    1
  Usage (page): 0x1 (0xff00)

USBSW (GZIOT)

Is just out the box and is set to Return/Enter. It sends down/up for each press down, nicer build quality though. I guess I need to pry this one open and see what's up.

Device Found
  type: 5131 2019
  path: DevSrvsID:4295024190
  serial_number: SW
  Manufacturer: GZIOT
  Product:      USBSW
  Release:      0
  Interface:    0
  Usage (page): 0x6 (0x1)
jasonm23 commented 2 years ago

potentially interesting : https://www.codrey.com/learn/cheap-ch551g-mcu-with-usb-controller-part-1/

jasonm23 commented 2 years ago

FYI mine appears to have a CH552G

jasonm23 commented 2 years ago

https://github.com/MarsTechHAN/ch552tool

Izzard-UK commented 1 year ago

Hello. I've just bought one of these pedals. I bought the cheapest option and I've run into the same issue. It's a USBSW (GZIOT) | 0x5131 | 0x2019 … and I want to send different keypresses for DOWN and UP events, but unfortunately this only sends a key on DOWN.

I've been able to change the key that it sends from Enter to something else, using usbsw_config_en.exe - but it otherwise isn't compatible with PCSensor's configuration software for reasons which are now painfully obvious.

So.. has anyone figured out a way to make the GZIOT USBSW device function like the RDing device? That would be awesome.

jasonm23 commented 1 year ago

@Izzard-UK - beyond building a new firmware, for now we're stuck.

The GZIOT firmware was programmed to send down/up from one hardware switch close. As you've seen using the Win32 "official" software it's only possible to change which key it sends.

I set that to Esc, which can be used by Karabiner as a way to trigger sticky modifiers or macros.

Izzard-UK commented 1 year ago

That’s a shame. They’re not a bad little device for the money, and I can see use-cases for both types as described above. The main issue is that marketplaces like Amazon, eBay and AliExpress are flooded with lots of rebrands / iterations of these pedals but the descriptions never make it clear which type you’re getting.

jasonm23 commented 1 year ago

I got hold of one for about $2.

Unfortunately when I opened it up there was no MCU in there, even the switch hadn't been soldered to the cable.

There are some cheap 3 pedal pcsensor units available on AliExpress and they are pretty good though and $20ish

Izzard-UK commented 1 year ago

Can the better version actually be used to press two different keys? In other words, send one key code on down and a different one on up?

jasonm23 commented 1 year ago

Yeah, that works, key down/up is registered. The software is better and works on mac,windows,linux too. (PCSensor)

Mind you, I wanted to use them as modifiers, but pressing keys on another device switched off the modifiers, which is odd, because I can use the RDing pedal like that.

All would be well with a different firmware, I think.

Izzard-UK commented 1 year ago

Yeah, that works, key down/up is registered.

I have seen some screenshots of the software so I know that they can be set as a single key press or as a continuous press. What I haven’t seen, yet, is how to set a different keystroke for lifting off the pedal. Hopefully I can use USB Overdrive if the configuration app doesn’t allow it.