Welcome to Hackster!
Hackster is a community dedicated to learning hardware, from beginner to pro. Join us, it's free!
karlee theodore
Published © GPL3+

Shotty Controller

Ever want to play a game while putting your laptop at risk? When with the Shotty Controller you can do just that and more.

BeginnerShowcase (no instructions)1 hour344
Shotty Controller

Things used in this project

Hardware components

Circuit Playground Express
Adafruit Circuit Playground Express
×1
Tinned Copper Wire, Solid
Tinned Copper Wire, Solid
×1
USB-A to Micro-USB Cable
USB-A to Micro-USB Cable
×1

Story

Read more

Schematics

Shotty Controller

Touch shot glasses filled with salt water to play a game on your laptop.

Code

Shotty Controller

JavaScript
Touch conductive items attached to CPX to play game.
input.touchA7.onEvent(ButtonEvent.Click, function () {
    keyboard.key("w", KeyboardKeyEvent.Press)
})
input.touchA5.onEvent(ButtonEvent.Click, function () {
    keyboard.type("kk")
})
input.touchA1.onEvent(ButtonEvent.Click, function () {
    keyboard.key("a", KeyboardKeyEvent.Press)
})
input.touchA6.onEvent(ButtonEvent.Click, function () {
    keyboard.key("d", KeyboardKeyEvent.Press)
})
input.touchA4.onEvent(ButtonEvent.Click, function () {
    keyboard.key("b", KeyboardKeyEvent.Press)
})
input.touchA3.onEvent(ButtonEvent.Click, function () {
    keyboard.key("s", KeyboardKeyEvent.Press)
})
light.setBrightness(10)
light.showRing(
`black blue black green black black green black yellow black`
)

Credits

karlee theodore
5 projects • 0 followers
Contact

Comments

Please log in or sign up to comment.