HiramSilvey / HS

GNU General Public License v3.0
9 stars 0 forks source link

Allow "digital" joystick behavior #16

Closed HiramSilvey closed 3 years ago

HiramSilvey commented 3 years ago

Allow the joystick to act as a digital joystick.

  1. Add fields to profile.proto to support a "digital" style joystick for a given profile -> joystick type: digital, analog -> digital threshold: 0-100% (0 = neutral position, 100 = full press)
  2. When those fields are set, utilize the threshold to determine whether the joystick is pressed in any given direction. If the joystick is not beyond that threshold in either direction on a particular axis, then output the neutral axis position. Otherwise, output the full press value.