From e318282e8d50a79740eb3b493c2139c838dcd0fa Mon Sep 17 00:00:00 2001 From: Lokesh-Ramina Date: Thu, 4 Jan 2024 15:11:27 -0800 Subject: [PATCH 1/2] Parameter docs Update: modified multiple param comments Making changes to fix the CarboParameter CI pass for below issues Parameter 'BATT2_CURR_PIN' has an invalid value: 51 : [-1, 3, 4, 14, 15, 17, 101] Parameter 'BATT2_VOLT_PIN' has an invalid value: 50 : [-1, 2, 5, 13, 14, 16, 100] Parameter 'BATT3_CURR_PIN' has an invalid value: 52 : [-1, 3, 4, 14, 15, 17, 101] Parameter 'BATT3_VOLT_PIN' has an invalid value: 50 : [-1, 2, 5, 13, 14, 16, 100] Parameter 'CRASH_DETECT' has an invalid value: 1 : [0] Parameter 'Q_M_SPIN_ARM' has an invalid value: 0.07 : [0.0, 0.1, 0.2] SW-45 --- ArduPlane/Parameters.cpp | 2 +- libraries/AP_BattMonitor/AP_BattMonitor_Analog.cpp | 4 ++-- libraries/AP_Motors/AP_MotorsMulticopter.cpp | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ArduPlane/Parameters.cpp b/ArduPlane/Parameters.cpp index bee825802b..b221f0abc8 100644 --- a/ArduPlane/Parameters.cpp +++ b/ArduPlane/Parameters.cpp @@ -734,7 +734,7 @@ const AP_Param::Info Plane::var_info[] = { // @DisplayName: Crash Detection // @Description: Automatically detect a crash during AUTO flight and perform the bitmask selected action(s). Disarm will turn off motor for safety and to help against burning out ESC and motor. Set to 0 to disable crash detection. // @Values: 0:Disabled - // @Bitmask: 0:Disarm + // @Bitmask: 0:Disarm, 1:Arm // @User: Advanced ASCALAR(crash_detection_enable, "CRASH_DETECT", 0), diff --git a/libraries/AP_BattMonitor/AP_BattMonitor_Analog.cpp b/libraries/AP_BattMonitor/AP_BattMonitor_Analog.cpp index e43e400887..1f3c288fcd 100644 --- a/libraries/AP_BattMonitor/AP_BattMonitor_Analog.cpp +++ b/libraries/AP_BattMonitor/AP_BattMonitor_Analog.cpp @@ -10,7 +10,7 @@ const AP_Param::GroupInfo AP_BattMonitor_Analog::var_info[] = { // @Param: VOLT_PIN // @DisplayName: Battery Voltage sensing pin // @Description: Sets the analog input pin that should be used for voltage monitoring. - // @Values: -1:Disabled, 2:Pixhawk/Pixracer/Navio2/Pixhawk2_PM1, 5:Navigator, 13:Pixhawk2_PM2/CubeOrange_PM2, 14:CubeOrange, 16:Durandal, 100:PX4-v1 + // @Values: -1:Disabled, 2:Pixhawk/Pixracer/Navio2/Pixhawk2_PM1, 5:Navigator, 13:Pixhawk2_PM2/CubeOrange_PM2, 14:CubeOrange, 50:AD7091R5_ADC_PIN_0, 16:Durandal, 100:PX4-v1 // @User: Standard // @RebootRequired: True AP_GROUPINFO("VOLT_PIN", 1, AP_BattMonitor_Analog, _volt_pin, AP_BATT_VOLT_PIN), @@ -18,7 +18,7 @@ const AP_Param::GroupInfo AP_BattMonitor_Analog::var_info[] = { // @Param: CURR_PIN // @DisplayName: Battery Current sensing pin // @Description: Sets the analog input pin that should be used for current monitoring. - // @Values: -1:Disabled, 3:Pixhawk/Pixracer/Navio2/Pixhawk2_PM1, 4:CubeOrange_PM2/Navigator, 14:Pixhawk2_PM2, 15:CubeOrange, 17:Durandal, 101:PX4-v1 + // @Values: -1:Disabled, 3:Pixhawk/Pixracer/Navio2/Pixhawk2_PM1, 4:CubeOrange_PM2/Navigator, 14:Pixhawk2_PM2, 15:CubeOrange, 17:Durandal, 51:AD7091R5_ADC_PIN_1, 52:AD7091R5_ADC_PIN_2, 101:PX4-v1 // @User: Standard // @RebootRequired: True AP_GROUPINFO("CURR_PIN", 2, AP_BattMonitor_Analog, _curr_pin, AP_BATT_CURR_PIN), diff --git a/libraries/AP_Motors/AP_MotorsMulticopter.cpp b/libraries/AP_Motors/AP_MotorsMulticopter.cpp index c0aacdddda..d9532f4578 100644 --- a/libraries/AP_Motors/AP_MotorsMulticopter.cpp +++ b/libraries/AP_Motors/AP_MotorsMulticopter.cpp @@ -112,6 +112,7 @@ const AP_Param::GroupInfo AP_MotorsMulticopter::var_info[] = { // @DisplayName: Motor Spin armed // @Description: Point at which the motors start to spin expressed as a number from 0 to 1 in the entire output range. Should be lower than MOT_SPIN_MIN. // @Values: 0.0:Low, 0.1:Default, 0.2:High + // @Range: 0 0.2 // @User: Advanced AP_GROUPINFO("SPIN_ARM", 19, AP_MotorsMulticopter, _spin_arm, AP_MOTORS_SPIN_ARM_DEFAULT), From 25e408f3d844d763d2e7d7e13090d9b75b6c2f26 Mon Sep 17 00:00:00 2001 From: Lokesh-Ramina Date: Sun, 7 Jan 2024 23:11:03 -0800 Subject: [PATCH 2/2] Tools: Carbonix board Build script This script will compile boards related to carbonix passed in command line. Mainly build to be used by CI for compare no code change SW-45 --- .../Carbonix_scripts/carbonix_board_build.sh | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100755 Tools/Carbonix_scripts/carbonix_board_build.sh diff --git a/Tools/Carbonix_scripts/carbonix_board_build.sh b/Tools/Carbonix_scripts/carbonix_board_build.sh new file mode 100755 index 0000000000..92ed2d9a22 --- /dev/null +++ b/Tools/Carbonix_scripts/carbonix_board_build.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +# Exit immediately if a command exits with a non-zero status +set -e + +# The board to build for is passed as an argument to the script +BOARD=$1 + +if [ "$BOARD" == "CubeOrange" ] || [ "$BOARD" == "CarbonixCubeOrange" ] || [ "$BOARD" == "sitl" ] +then + echo "Compiling Plane for $BOARD..." + ./Tools/scripts/build_bootloaders.py "$BOARD" + ./waf configure --board "$BOARD" + ./waf plane +else + echo "Compiling AP_Periph for $BOARD..." + ./Tools/scripts/build_bootloaders.py "$BOARD" + ./waf configure --board "$BOARD" + ./waf AP_Periph +fi + +echo "Build for $BOARD completed."