Skip to content

Instantly share code, notes, and snippets.

@Lewiscowles1986
Last active November 18, 2023 19:08
Show Gist options
  • Save Lewiscowles1986/eef220dac6f0549e4702393a7b9351f6 to your computer and use it in GitHub Desktop.
Save Lewiscowles1986/eef220dac6f0549e4702393a7b9351f6 to your computer and use it in GitHub Desktop.
Playstation 2 EU USB "The Buzz" controller

"The Buzz" Playstation 2 EU USB controller

Using tool "Simple HID Write"

  • W: Write
  • R: Read
W 00 {FF} 00 00 00 // controller 1 red light activate
W 00 {00} 00 00 00 // controller 1 red light deactivate
W 00 00 {FF} 00 00 // controller 2 red light activate
W 00 00 {00} 00 00 // controller 2 red light deactivate
W 00 00 00 {FF} 00 // controller 3 red light activate
W 00 00 00 {00} 00 // controller 3 red light deactivate
W 00 00 00 00 {FF} // controller 4 red light activate
W 00 00 00 00 {00} // controller 4 red light deactivate

R 7F 7F {00 00 F0} // any controller button release (reports currently pressed buttons)

R 7F 7F {01} 00 F0 // controller 1 red button press
R 7F 7F {10} 00 F0 // controller 1 blue button press
R 7F 7F {08} 00 F0 // controller 1 orange button press
R 7F 7F {04} 00 F0 // controller 1 green button press
R 7F 7F {02} 00 F0 // controller 1 yellow button press

R 7F 7F {20} 00 F0 // controller 2 red button press
R 7F 7F 00 {02} F0 // controller 2 blue button press
R 7F 7F 00 {01} F0 // controller 2 orange button press
R 7F 7F {80} 00 F0 // controller 2 green button press
R 7F 7F {40} 00 F0 // controller 2 yellow button press

R 7F 7F 00 {04} F0 // controller 3 red button press
R 7F 7F 00 {40} F0 // controller 3 blue button press
R 7F 7F 00 {20} F0 // controller 3 orange button press
R 7F 7F 00 {10} F0 // controller 3 green button press
R 7F 7F 00 {08} F0 // controller 3 yellow button press

R 7F 7F 00 80 {F0} // controller 4 red button press
R 7F 7F 00 00 {F8} // controller 4 blue button press
R 7F 7F 00 00 {F4} // controller 4 orange button press
R 7F 7F 00 00 {F2} // controller 4 green button press
R 7F 7F 00 00 {F1} // controller 4 yellow button press

NOTE: All results seem to be flag-sets for buttons so for example combining is a binary OR operation

R 7F 7F {20 80} F0 // controller 2 & controller 4 red button press

R 7F 7F 00 {03} F0 // controller 2 blue & orange button press

R 7F 7F 00 00 {FC} // controller 4 blue & orange button press

R 7F 7F 00 {03 FC} // controller 2 & 4 blue & orange button press

W 00 {FF FF FF FF} // Turn on all red lights for controllers

Also:

  • When multiple buttons are pressed, multiple button release receives are generated (seems to be one-per button)
  • When multiple buttons are pressed, even if simultaneous the hw controller generates one event per button resolving timing issues
  • When multiple reads are detected from multi-press, it's probably a good idea to debounce until presses stop, or register the first and ignore the rest
  • As the controller sends complete state per button press, no need to store state

Device Info

  • VID 054C (hex) 1356 (dec) 2514 (oct)
  • PID 0002 (hex) 0002 (dec) 0002 (oct)
  • REV 1101 (hex) 4353 (dec) 10401 (oct)
  • Vendor name "Logitech"
  • Product name "Logitech Buzz(tm) Controller V1"
  • Serial No ""

Report Size

  • Input 6-Bytes
  • Output 8-Bytes
  • Feature 0-Byte
@Lewiscowles1986
Copy link
Author

from time import sleep
import hid

activeDevice = None
all_hids = hid.enumerate()
activeDevice = hid.Device(1356, 2)

if activeDevice:
    try:
        # activeDevice.open()
        activeDevice.write(b'\x00\x00\xff\xff\xff\xff\x00\x00')
        for i in range(20):
            activeDevice.write(b'\x00\x00\xff\00\00\00\x00\x00')
            sleep(0.15)
            activeDevice.write(b'\x00\x00\00\xff\00\00\x00\x00')
            sleep(0.15)
            activeDevice.write(b'\x00\x00\0\00\xff\00\x00\x00')
            sleep(0.15)
            activeDevice.write(b'\x00\x00\00\00\00\xff\x00\x00')
            sleep(0.15)
        activeDevice.write(b'\x00\x00\xff\xff\xff\xff\x00\x00')
        sleep(10)
    finally:
        activeDevice.close()

@Anukatak
Copy link

Hello! Realy happy with your script! Is there a way to keep the lights on?

@Lewiscowles1986
Copy link
Author

@Anukatak well you'll see there are turn off and turn on, so if you turn on without turning off, they would stay on, wouldn't they 😉

@Anukatak
Copy link

Sorry for the dumb question ahaha a few minutes after asking I understood just that! Thanks for the script!

@Lewiscowles1986
Copy link
Author

It was not my intent to make you feel dumb or like your question was unfounded. Sorry for that. Text medium was not conveying me being a bit smirky in explanation. Thanks for feedback and glad you like.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment