From 7574e88aed658febaedf8921615cbf6419c11526 Mon Sep 17 00:00:00 2001 From: WT-MM Date: Wed, 11 Dec 2024 03:08:56 +0000 Subject: [PATCH 1/2] deg limits --- platforms/kbot/src/lib.rs | 92 +++++++++++++-------------- platforms/kbot/src/process_manager.rs | 6 +- 2 files changed, 49 insertions(+), 49 deletions(-) diff --git a/platforms/kbot/src/lib.rs b/platforms/kbot/src/lib.rs index cb988ea..e648820 100644 --- a/platforms/kbot/src/lib.rs +++ b/platforms/kbot/src/lib.rs @@ -86,48 +86,48 @@ impl Platform for KbotPlatform { 11, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 12, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 13, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 14, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 15, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 16, ActuatorConfiguration { actuator_type: ActuatorType::RobStride00, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), // Right Arm @@ -135,48 +135,48 @@ impl Platform for KbotPlatform { 21, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 22, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 23, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 24, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 25, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 26, ActuatorConfiguration { actuator_type: ActuatorType::RobStride00, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), // Left Leg @@ -184,40 +184,40 @@ impl Platform for KbotPlatform { 31, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 32, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 33, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 34, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 35, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), // Right Leg @@ -225,40 +225,40 @@ impl Platform for KbotPlatform { 41, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 42, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 43, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 44, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ( 45, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(4.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(15.0f32), + max_velocity: Some(10.0f32), }, ), ], @@ -284,8 +284,8 @@ impl Platform for KbotPlatform { 1, robstridev2::ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(2.0f32.to_radians()), - max_velocity: Some(10.0f32.to_radians()), + max_angle_change: Some(2.0f32), + max_velocity: Some(10.0f32), }, )], ) diff --git a/platforms/kbot/src/process_manager.rs b/platforms/kbot/src/process_manager.rs index 15751ef..4111e4c 100644 --- a/platforms/kbot/src/process_manager.rs +++ b/platforms/kbot/src/process_manager.rs @@ -245,10 +245,10 @@ impl ProcessManager for KBotProcessManager { *kclip_uuid = Some(new_uuid.clone()); drop(kclip_uuid); - let (pipeline, _sink) = Self::create_pipeline(&video_path)?; + // let (pipeline, _sink) = Self::create_pipeline(&video_path)?; // Start the pipeline - pipeline.set_state(gst::State::Playing)?; + // pipeline.set_state(gst::State::Playing)?; // Start telemetry logger let logger = TelemetryLogger::new( @@ -265,7 +265,7 @@ impl ProcessManager for KBotProcessManager { drop(telemetry_logger); let mut pipeline_guard = self.pipeline.lock().await; - *pipeline_guard = Some(pipeline); + *pipeline_guard = None; Ok(KClipStartResponse { clip_uuid: Some(new_uuid), From aa998627d02e30c04e5fa07865abc6c4c582ba14 Mon Sep 17 00:00:00 2001 From: WT-MM Date: Wed, 11 Dec 2024 03:13:33 +0000 Subject: [PATCH 2/2] higher limits --- platforms/kbot/src/lib.rs | 88 +++++++++++++++++++-------------------- 1 file changed, 44 insertions(+), 44 deletions(-) diff --git a/platforms/kbot/src/lib.rs b/platforms/kbot/src/lib.rs index e648820..139e9d0 100644 --- a/platforms/kbot/src/lib.rs +++ b/platforms/kbot/src/lib.rs @@ -86,48 +86,48 @@ impl Platform for KbotPlatform { 11, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), // Percentage of max + max_velocity: Some(25.0f32), }, ), ( 12, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 13, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 14, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 15, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 16, ActuatorConfiguration { actuator_type: ActuatorType::RobStride00, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), // Right Arm @@ -135,48 +135,48 @@ impl Platform for KbotPlatform { 21, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 22, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 23, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 24, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 25, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 26, ActuatorConfiguration { actuator_type: ActuatorType::RobStride00, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), // Left Leg @@ -184,40 +184,40 @@ impl Platform for KbotPlatform { 31, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 32, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 33, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 34, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 35, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), // Right Leg @@ -225,40 +225,40 @@ impl Platform for KbotPlatform { 41, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 42, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 43, ActuatorConfiguration { actuator_type: ActuatorType::RobStride03, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 44, ActuatorConfiguration { actuator_type: ActuatorType::RobStride04, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ( 45, ActuatorConfiguration { actuator_type: ActuatorType::RobStride02, - max_angle_change: Some(15.0f32), - max_velocity: Some(10.0f32), + max_angle_change: Some(60.0f32), + max_velocity: Some(25.0f32), }, ), ],