Skip to content

HAL_ChibiOS: Added support for CORVON743V1 #29797

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

holydust
Copy link
Contributor

No description provided.

@Hwurzburg Hwurzburg requested review from andyp1per and Hwurzburg May 5, 2025 20:52
@Hwurzburg Hwurzburg added the WikiNeeded needs wiki update label May 5, 2025
Copy link
Collaborator

@andyp1per andyp1per left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

DEFAULTGPIO OUTPUT LOW PULLDOWN

# order of UARTs (and USB)
SERIAL_ORDER OTG1 USART1 USART2 USART3 UART4 USART6 UART7 UART8
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you wanted you could put "EMPTY" between 4 and 6 and then the serial numbers would match the uart numbers

PB0 TIM3_CH3 TIM3 PWM(6) GPIO(55)
PD12 TIM4_CH1 TIM4 PWM(7) GPIO(56) BIDIR
PD13 TIM4_CH2 TIM4 PWM(8) GPIO(57)
PD14 TIM4_CH3 TIM4 PWM(9) GPIO(58)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's actually no downside to adding BIDIR to this output as well since it does not use an extra DMA channel and they are al on TIM4

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the tip

Copy link
Collaborator

@Hwurzburg Hwurzburg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you should add the SD card support in the bootloader so flashing from SD is possible...also you would need to add this in the bootloader hwdeef:
define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1
and this in the hwdef:
env BUILD_ABIN True


## RC Input

The default RC input is configured on the UART6. The SBUS pin is inverted and connected to RX6. Non SBUS, single wire serial inputs can be directly tied to RX6 if SBUS pin is left unconnected. RC could be applied instead at a different UART port such as UART1, UART4 or UART8, and set the protocol to receive RC data: `SERIALn_PROTOCOL=23` and change SERIAL5 _Protocol to something other than '23'.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The default RC input is configured on the UART6. The SBUS pin is inverted and connected to RX6. Non SBUS, single wire serial inputs can be directly tied to RX6 if SBUS pin is left unconnected. RC could be applied instead at a different UART port such as UART1, UART4 or UART8, and set the protocol to receive RC data: `SERIALn_PROTOCOL=23` and change SERIAL5 _Protocol to something other than '23'.
The default RC input is configured on the UART6 . The SBUS pin is inverted and connected to RX6. Non SBUS, single wire serial inputs can be directly tied to RX6 if SBUS pin is left unconnected. RC could be applied instead to a different UART port such as UART1, UART4 or UART8, and set the protocol to receive RC data ``SERIALn_PROTOCO`` =23 and change :ref:`SERIAL5 _PROTOCOL <SERIAL5 _PROTOCOL>` to something other than '23'. For rc protocols other than unidirectional, the TX6 pin will need to be used:
- :ref:`SERIAL5_PROTOCOL<SERIAL5_PROTOCOL>` should be set to "23".
- FPort would require :ref:`SERIAL5_OPTIONS<SERIAL5_OPTIONS>` be set to "15".
- CRSF would require :ref:`SERIAL5_OPTIONS<SERIAL5_OPTIONS>` be set to "0".
- SRXL2 would require :ref:`SERIAL5_OPTIONS<SERIAL5_OPTIONS>` be set to "4" and connects only the TX pin.


## VTX Support

The SH1.0-6P connector supports a DJI Air Unit / HD VTX connection. Protocol defaults to DisplayPort. Pin 1 of the connector is 9v so be careful not to connect this to a peripheral requiring 5v.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The SH1.0-6P connector supports a DJI Air Unit / HD VTX connection. Protocol defaults to DisplayPort. Pin 1 of the connector is 9v so be careful not to connect this to a peripheral requiring 5v.
The SH1.0-6P connector supports a DJI Air Unit / HD VTX connection. Protocol defaults to DisplayPort. Pin 1 of the connector is 9v so be careful not to connect this to a peripheral that can not tolerate this voltage.


## PWM Output

The CORVON743V1 supports up to 10 PWM outputs.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The CORVON743V1 supports up to 10 PWM outputs.
The CORVON743V1 supports up to 10 PWM outputs. All outputs support PWM, DShot, and Bi-Directional DShot.


The CORVON743V1 supports up to 10 PWM outputs.

All the channels support DShot.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove and blank lines


All the channels support DShot.

Channels 1-8 support bi-directional DShot.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove and blank lines


The default battery parameters are:

- BATT_MONITOR 4
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change all these to this format:

  • :ref:BATT_MONITOR<BATT_MONITOR> = 4
  • :ref:BATT_VOLT_PIN<BATT_VOLT_PIN__AP_BattMonitor_Analog> = 10
  • :ref:BATT_CURR_PIN<BATT_CURR_PIN__AP_BattMonitor_Analog> = 11 (CURR pin)
  • :ref:BATT_VOLT_MULT<BATT_VOLT_MULT__AP_BattMonitor_Analog> = 21.2
  • :ref:BATT_AMP_PERVLT<BATT_AMP_PERVLT__AP_BattMonitor_Analog> = 40.2

![CORVON743V1 Ports Connection](CORVON743V1_PortsConnection.jpg)

## Loading Firmware

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Firmware for these boards can be found `here <https://firmware.ardupilot.org>`__ in sub-folders labeled "CORVON743V_1".

@@ -0,0 +1,11 @@
#BATTERY MONITOR ON
BATT_MONITOR 4
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to hwdef

OSD_TYPE2 = 5

#Serial Port defaults
SERIAL2_PROTOCOL 42
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move all these to hwdef

PB0 TIM3_CH3 TIM3 PWM(6) GPIO(55)
PD12 TIM4_CH1 TIM4 PWM(7) GPIO(56) BIDIR
PD13 TIM4_CH2 TIM4 PWM(8) GPIO(57)
PD14 TIM4_CH3 TIM4 PWM(9) GPIO(58)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
PD14 TIM4_CH3 TIM4 PWM(9) GPIO(58)
PD14 TIM4_CH3 TIM4 PWM(9) GPIO(58) BIDIR

Copy link
Collaborator

@Hwurzburg Hwurzburg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mistakenly checked comment instead of request changes on my review...this tags as such

and your board id has already been taken....I suggest a separate PR to reserve (they geet merged quickly) and you will need to redo the bootloader file (you will anyway iff you follow my suggestion re SD card flashing_

@holydust
Copy link
Contributor Author

I mistakenly checked comment instead of request changes on my review...this tags as such

and your board id has already been taken....I suggest a separate PR to reserve (they geet merged quickly) and you will need to redo the bootloader file (you will anyway iff you follow my suggestion re SD card flashing_

sure, this PR for reserving the borad ID, I'll correct the rest docs, thanks.

@holydust
Copy link
Contributor Author

you should add the SD card support in the bootloader so flashing from SD is possible...also you would need to add this in the bootloader hwdeef: define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1 and this in the hwdef: env BUILD_ABIN True

Hello, I have added define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1 into hwdef-bl, but have problem while building the new bootloader.

Build failed
-> task in 'bootloader/AP_Bootloader' failed (exit status 1):
{task 4452046816: cxx flash_from_sd.cpp -> flash_from_sd.cpp.7.o}

@Hwurzburg
Copy link
Collaborator

dont know if you added the SD interface, but I discovered that some other defines in the bootloader hwdef are required...I need to add them to the wiki...here is what is needed your file:
define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1
define FATFS_HAL_DEVICE SDCD1
define FATFS_HAL_DEVICE SDCD1

microSD support

PC12 SDMMC1_CK SDMMC1
PD2 SDMMC1_CMD SDMMC1
PC8 SDMMC1_D0 SDMMC1
PC9 SDMMC1_D1 SDMMC1
PC10 SDMMC1_D2 SDMMC1
PC11 SDMMC1_D3 SDMMC1

FATFS support:

define CH_CFG_USE_MEMCORE 1
define CH_CFG_USE_HEAP 1
define CH_CFG_USE_SEMAPHORES 0
define CH_CFG_USE_MUTEXES 1
define CH_CFG_USE_DYNAMIC 1
define CH_CFG_USE_WAITEXIT 1
define CH_CFG_USE_REGISTRY 1

it build for me now

@holydust
Copy link
Contributor Author

dont know if you added the SD interface, but I discovered that some other defines in the bootloader hwdef are required...I need to add them to the wiki...here is what is needed your file: define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1 define FATFS_HAL_DEVICE SDCD1 define FATFS_HAL_DEVICE SDCD1

microSD support

PC12 SDMMC1_CK SDMMC1 PD2 SDMMC1_CMD SDMMC1 PC8 SDMMC1_D0 SDMMC1 PC9 SDMMC1_D1 SDMMC1 PC10 SDMMC1_D2 SDMMC1 PC11 SDMMC1_D3 SDMMC1

FATFS support:

define CH_CFG_USE_MEMCORE 1 define CH_CFG_USE_HEAP 1 define CH_CFG_USE_SEMAPHORES 0 define CH_CFG_USE_MUTEXES 1 define CH_CFG_USE_DYNAMIC 1 define CH_CFG_USE_WAITEXIT 1 define CH_CFG_USE_REGISTRY 1

it build for me now

thanks, I'll try it out.

@holydust holydust requested a review from Hwurzburg May 13, 2025 03:24
@holydust
Copy link
Contributor Author

@Hwurzburg Hello, I have updated the files, please review them when you get a chance, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants