mirror of
https://github.com/OpenActionAPI/rust-elgato-streamdeck.git
synced 2026-10-28 18:02:41 +00:00
Fix Ajazz AKP153R
This commit is contained in:
1 parent
88f9859d05
commit
11ae3df723
4 files changed
+5
-5
No files matched your search
@@ -76,6 +76,6 @@ As it stands, this library should support the following devices:
|
||||
- Stream Deck Neo (thanks to [@ejiektpobehuk](https://github.com/ejiektpobehuk), [@AkechiShiro](https://github.com/AkechiShiro) and [node-elgato-stream-deck](https://github.com/Julusian/node-elgato-stream-deck))
|
||||
- Ajazz AKP153 (thanks to [@ZCube](https://github.com/ZCube))
|
||||
- Ajazz AKP153E (thanks to [@teras](https://github.com/teras))
|
||||
- Ajazz AKP153R (thanks to [@teras](https://github.com/teras) and [@damnkrat](https://github.com/damnkrat))
|
||||
- Ajazz AKP153R (thanks to [@teras](https://github.com/teras), [@damnkrat](https://github.com/damnkrat) and [@4ndv](https://github.com/4ndv))
|
||||
- Ajazz AKP815 (thanks to [@teras](https://github.com/teras))
|
||||
- MiraBox HSV293S (thanks to [@czyz](https://github.com/czyz))
|
||||
+1
-1
@@ -222,7 +222,7 @@ impl AsyncDeviceStateReader {
|
||||
StreamDeckInput::ButtonStateChange(buttons) => {
|
||||
for (index, (their, mine)) in zip(buttons.iter(), my_states.buttons.iter()).enumerate() {
|
||||
match self.device.kind {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp153R | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
if *their {
|
||||
updates.push(DeviceStateUpdate::ButtonDown(index as u8));
|
||||
updates.push(DeviceStateUpdate::ButtonUp(index as u8));
|
||||
|
||||
+2
-2
@@ -160,7 +160,7 @@ impl StreamDeck {
|
||||
/// Returns serial number of the device
|
||||
pub fn serial_number(&self) -> Result<String, StreamDeckError> {
|
||||
match self.kind {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp153R | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
let serial = self.device.get_serial_number_string()?;
|
||||
match serial {
|
||||
Some(serial) => {
|
||||
@@ -200,7 +200,7 @@ impl StreamDeck {
|
||||
Ok(extract_str(&bytes[5..])?)
|
||||
}
|
||||
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp153R | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
let bytes = get_feature_report(&self.device, 0x01, 20)?;
|
||||
Ok(extract_str(&bytes[0..])?)
|
||||
}
|
||||
|
||||
+1
-1
@@ -119,7 +119,7 @@ pub fn read_button_states(kind: &Kind, states: &[u8]) -> Vec<bool> {
|
||||
}
|
||||
|
||||
match kind {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
Kind::Akp153 | Kind::Akp153E | Kind::Akp153R | Kind::Akp815 | Kind::MiraBoxHSV293S => {
|
||||
let mut bools = vec![];
|
||||
|
||||
for i in 0..kind.key_count() {
|
||||
|
||||
Reference in new issue
Block a user