Buttplug sex toy control library

feat: Add support for Hismith Piupiu

authored by

blackspherefollower and committed by qdot.tngl.sh ce360cff c6fcae59

+55 -3
+17
crates/buttplug_server/src/device/protocol_impl/hismith_mini.rs
··· 184 feature_id: Uuid, 185 speed: i32, 186 ) -> Result<Vec<HardwareCommand>, ButtplugDeviceError> { 187 Ok(vec![ 188 HardwareWriteCmd::new( 189 &[feature_id],
··· 184 feature_id: Uuid, 185 speed: i32, 186 ) -> Result<Vec<HardwareCommand>, ButtplugDeviceError> { 187 + Ok(vec![ 188 + HardwareWriteCmd::new( 189 + &[feature_id], 190 + Endpoint::Tx, 191 + vec![0xCC, 0x03, speed as u8, speed as u8 + 3], 192 + false, 193 + ).into(), 194 + HardwareWriteCmd::new( 195 + &vec![HISMITH_MINI_ROTATE_DIRECTIOM_UUID], 196 + Endpoint::Tx, 197 + vec![0xCC, 0x01, if clockwise { 0xc0 } else {0xc1}, if clockwise { 0xc1 } else {0xc2}], 198 + false, 199 + ).into(), 200 + ]) 201 + } 202 + 203 + fn handle_output_spray_cmd(&self, _feature_index: u32, feature_id: Uuid, _level: u32) -> Result<Vec<HardwareCommand>, ButtplugDeviceError> { 204 Ok(vec![ 205 HardwareWriteCmd::new( 206 &[feature_id],
+24 -2
crates/buttplug_server_device_config/build-config/buttplug-device-config-v4.json
··· 1 { 2 "version": { 3 "major": 4, 4 - "minor": 78 5 }, 6 "protocols": { 7 "activejoy": { ··· 4111 "HISMITH S3", 4112 "Sinloli Cosima", 4113 "Sinloli-Ethel", 4114 - "Sinloli Aston" 4115 ], 4116 "services": { 4117 "0000ff90-0000-1000-8000-00805f9b34fb": { ··· 4386 "2205" 4387 ], 4388 "name": "Sinloli Aston" 4389 } 4390 ], 4391 "defaults": {
··· 1 { 2 "version": { 3 "major": 4, 4 + "minor": 80 5 }, 6 "protocols": { 7 "activejoy": { ··· 4111 "HISMITH S3", 4112 "Sinloli Cosima", 4113 "Sinloli-Ethel", 4114 + "Sinloli Aston", 4115 + "Hismith Piupiu" 4116 ], 4117 "services": { 4118 "0000ff90-0000-1000-8000-00805f9b34fb": { ··· 4387 "2205" 4388 ], 4389 "name": "Sinloli Aston" 4390 + }, 4391 + { 4392 + "features": [ 4393 + { 4394 + "feature-type": "Spray", 4395 + "id": "c24a6b8c-6665-4cf6-95f8-51140f9788b4", 4396 + "output": { 4397 + "Spray": { 4398 + "step-range": [ 4399 + 0, 4400 + 1 4401 + ] 4402 + } 4403 + } 4404 + } 4405 + ], 4406 + "id": "ae9c755d-a11f-43c3-9cce-1c3797788434", 4407 + "identifier": [ 4408 + "4002" 4409 + ], 4410 + "name": "Sinloli Piupiu" 4411 } 4412 ], 4413 "defaults": {
+13
crates/buttplug_server_device_config/device-config-v4/protocols/hismith-mini.yml
··· 161 - -100 162 - 100 163 id: d9ced3ed-cc74-4731-baeb-7bbf7fda288e 164 communication: 165 - btle: 166 names: ··· 174 - Sinloli Cosima 175 - Sinloli-Ethel 176 - Sinloli Aston 177 services: 178 0000ffe5-0000-1000-8000-00805f9b34fb: 179 tx: 0000ffe9-0000-1000-8000-00805f9b34fb
··· 161 - -100 162 - 100 163 id: d9ced3ed-cc74-4731-baeb-7bbf7fda288e 164 + - identifier: 165 + - '4002' 166 + name: Sinloli Piupiu 167 + features: 168 + - feature-type: Spray 169 + id: c24a6b8c-6665-4cf6-95f8-51140f9788b4 170 + output: 171 + Spray: 172 + step-range: 173 + - 0 174 + - 1 175 + id: ae9c755d-a11f-43c3-9cce-1c3797788434 176 communication: 177 - btle: 178 names: ··· 186 - Sinloli Cosima 187 - Sinloli-Ethel 188 - Sinloli Aston 189 + - Hismith Piupiu 190 services: 191 0000ffe5-0000-1000-8000-00805f9b34fb: 192 tx: 0000ffe9-0000-1000-8000-00805f9b34fb
+1 -1
crates/buttplug_server_device_config/device-config-v4/version.yaml
··· 1 version: 2 major: 4 3 - minor: 78
··· 1 version: 2 major: 4 3 + minor: 80