forked from eden-emu/eden
		
	input_common: Use calibration from joycon
This commit is contained in:
		
							parent
							
								
									d2f5eae036
								
							
						
					
					
						commit
						f7164f77d6
					
				
					 5 changed files with 231 additions and 0 deletions
				
			
		|  | @ -64,6 +64,7 @@ DriverResult JoyconDriver::InitializeDevice() { | |||
|     accelerometer_performance = Joycon::AccelerometerPerformance::HZ100; | ||||
| 
 | ||||
|     // Initialize HW Protocols
 | ||||
|     calibration_protocol = std::make_unique<CalibrationProtocol>(hidapi_handle); | ||||
|     generic_protocol = std::make_unique<GenericProtocol>(hidapi_handle); | ||||
| 
 | ||||
|     // Get fixed joycon info
 | ||||
|  | @ -79,6 +80,9 @@ DriverResult JoyconDriver::InitializeDevice() { | |||
|     supported_features = GetSupportedFeatures(); | ||||
| 
 | ||||
|     // Get Calibration data
 | ||||
|     calibration_protocol->GetLeftJoyStickCalibration(left_stick_calibration); | ||||
|     calibration_protocol->GetRightJoyStickCalibration(right_stick_calibration); | ||||
|     calibration_protocol->GetImuCalibration(motion_calibration); | ||||
| 
 | ||||
|     // Set led status
 | ||||
|     generic_protocol->SetLedBlinkPattern(static_cast<u8>(1 + port)); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Narr the Reg
						Narr the Reg