AP_HAL_ChibiOS: allow AP_SCRIPTING_ENABLED to come from hwdef files

This commit is contained in:
Peter Barker 2023-06-07 15:56:50 +10:00 committed by Peter Barker
parent caf35b71a6
commit 3aaeb0f29c
15 changed files with 28 additions and 7 deletions

View File

@ -138,3 +138,7 @@ ROMFS_WILDCARD libraries/AP_OSD/fonts/font*.bin
define STM32_PWM_USE_ADVANCED TRUE
define DEFAULT_NTF_LED_TYPES 257
// disable scripting - no SD card
define AP_SCRIPTING_ENABLED 0

View File

@ -51,8 +51,7 @@ define HAL_PERIPH_ENABLE_BATTERY
define CAN_APP_NODE_NAME "org.ardupilot.CubeBlack-periph"
env DISABLE_SCRIPTING 1
define AP_SCRIPTING_ENABLED 0
# use blue LED
define HAL_GPIO_PIN_LED HAL_GPIO_PIN_FMU_LED_AMBER

View File

@ -50,7 +50,7 @@ define HAL_BARO_ALLOW_INIT_NO_BARO
define CAN_APP_NODE_NAME "org.ardupilot.CubeOrange-periph"
env DISABLE_SCRIPTING 1
define AP_SCRIPTING_ENABLED 0
# use blue LED
define HAL_GPIO_PIN_LED HAL_GPIO_PIN_FMU_LED_AMBER

View File

@ -46,7 +46,7 @@ define HAL_BARO_ALLOW_INIT_NO_BARO
define CAN_APP_NODE_NAME "org.ardupilot.CubeOrange-periph"
env DISABLE_SCRIPTING 1
define AP_SCRIPTING_ENABLED 0
# use blue LED
define HAL_GPIO_PIN_LED HAL_GPIO_PIN_FMU_LED_AMBER

View File

@ -151,6 +151,7 @@ define DEFAULT_SERIAL2_PROTOCOL SerialProtocol_RCIN
define DEFAULT_SERIAL3_PROTOCOL SerialProtocol_Sbus1
define DEFAULT_SERIAL4_PROTOCOL SerialProtocol_RCIN
define AP_SCRIPTING_ENABLED 0
# only use pulse input for PPM, other protocols
# are on serial

View File

@ -172,3 +172,5 @@ define HAL_COMPASS_AUTO_ROT_DEFAULT 2
define HAL_DEFAULT_INS_FAST_SAMPLE 1
# Motor order implies Betaflight/X for standard ESCs
define HAL_FRAME_TYPE_DEFAULT 12
define AP_SCRIPTING_ENABLED 0

View File

@ -210,6 +210,7 @@ define HAL_DEFAULT_CPORT 1
define CONFIGURE_PPS_PIN TRUE
define AP_PERIPH_HAVE_LED TRUE
define AP_SCRIPTING_ENABLED 1
define SCRIPTING_HEAP_SIZE (64*1024)
define GPS_MOVING_BASELINE 1

View File

@ -160,3 +160,5 @@ ROMFS_WILDCARD libraries/AP_OSD/fonts/font*.bin
define STM32_PWM_USE_ADVANCED TRUE
define DEFAULT_NTF_LED_TYPES 257
define AP_SCRIPTING_ENABLED 0

View File

@ -70,3 +70,5 @@ define HAL_LOGGING_DATAFLASH_ENABLED 1
define HAL_LOGGING_DATAFLASH_DRIVER AP_Logger_W25N01GV
define DEFAULT_NTF_LED_TYPES 257
define AP_SCRIPTING_ENABLED 0

View File

@ -194,3 +194,5 @@ ROMFS_WILDCARD libraries/AP_OSD/fonts/font*.bin
define STM32_PWM_USE_ADVANCED TRUE
define DEFAULT_NTF_LED_TYPES 257
define AP_SCRIPTING_ENABLED 0

View File

@ -49,7 +49,7 @@ define HAL_USE_RTC FALSE
define HAL_NO_RCIN_THREAD
env DISABLE_SCRIPTING 1
define AP_SCRIPTING_ENABLED 0
MAIN_STACK 0x2000
PROCESS_STACK 0x6000

View File

@ -54,7 +54,7 @@ define HAL_DISABLE_ADC_DRIVER FALSE
define CAN_APP_NODE_NAME "org.ardupilot.Pixracer_periph"
env DISABLE_SCRIPTING 1
define AP_SCRIPTING_ENABLED 0
MAIN_STACK 0x2000
PROCESS_STACK 0x6000

View File

@ -196,3 +196,5 @@ ROMFS_WILDCARD libraries/AP_OSD/fonts/font*.bin
define STM32_PWM_USE_ADVANCED TRUE
define DEFAULT_NTF_LED_TYPES 257
define AP_SCRIPTING_ENABLED 0

View File

@ -919,7 +919,6 @@ class ChibiOSHWDef(object):
else:
f.write('#define HAL_USE_SDC FALSE\n')
self.build_flags.append('USE_FATFS=no')
self.env_vars['DISABLE_SCRIPTING'] = True
if 'OTG1' in self.bytype:
if self.get_mcu_config('STM32_OTG2_IS_OTG1', False) is not None:
f.write('#define STM32_USB_USE_OTG2 TRUE\n')
@ -3262,6 +3261,10 @@ INCLUDE common.ld
#define HAL_PROXIMITY_ENABLED 0
#endif
#ifndef AP_SCRIPTING_ENABLED
#define AP_SCRIPTING_ENABLED 0
#endif
// end AP_Periph defaults
''')

View File

@ -205,4 +205,7 @@ define AP_LTM_TELEM_ENABLED 0
// no buttons on SkyViper:
define HAL_BUTTON_ENABLED 0
// disable scripting on SkyViper (should we enable this?)
define AP_SCRIPTING_ENABLED 0
AUTOBUILD_TARGETS Copter