Module: ProconBypassMan::DeviceConnection::OutputReportMarkerable
- Included in:
- OutputReportWatcher, SpoofingOutputReportWatcher
- Defined in:
- lib/procon_bypass_man/device_connection/output_report_markerable.rb
Constant Summary collapse
- OUTPUT_REPORT_FORMAT =
/^01/
- INPUT_REPORT_FORMAT =
/^21/
Instance Method Summary collapse
Instance Method Details
#mark_as_receive(raw_data) ⇒ void
This method returns an undefined value.
19 20 21 22 23 24 25 26 27 |
# File 'lib/procon_bypass_man/device_connection/output_report_markerable.rb', line 19 def mark_as_receive(raw_data) data = raw_data.unpack("H*").first case data when INPUT_REPORT_FORMAT sub_command = data[28..29] sub_command_arg = data[30..31] @hid_sub_command_request_table.mark_as_receive(sub_command: sub_command, sub_command_arg: sub_command_arg) end end |
#mark_as_send(raw_data) ⇒ void
This method returns an undefined value.
7 8 9 10 11 12 13 14 15 |
# File 'lib/procon_bypass_man/device_connection/output_report_markerable.rb', line 7 def mark_as_send(raw_data) data = raw_data.unpack("H*").first case data when OUTPUT_REPORT_FORMAT sub_command = data[20..21] sub_command_arg = data[22..23] @hid_sub_command_request_table.mask_as_send(sub_command: sub_command, sub_command_arg: sub_command_arg) end end |