AP_HAL_Linux: Util_RPI: Add support to RPI5 identification

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
This commit is contained in:
Patrick José Pereira 2024-05-09 09:55:19 -03:00 committed by Willian Galvani
parent 3f88a5e749
commit 4af6142933
2 changed files with 6 additions and 0 deletions

View File

@ -62,6 +62,11 @@ void UtilRPI::_get_board_type_using_peripheral_base()
_linux_board_version = LINUX_BOARD_TYPE::UNKNOWN_BOARD;
printf("Cannot detect board-type \r\n");
break;
case 0x10:
_linux_board_version = LINUX_BOARD_TYPE::RPI_5;
printf("RPI 5 \r\n");
printf("Peripheral base address is %x\n", base);
break;
case 0x20000000:
_linux_board_version = LINUX_BOARD_TYPE::RPI_ZERO_1;
printf("RPI Zero / 1 \r\n");

View File

@ -8,6 +8,7 @@ enum class LINUX_BOARD_TYPE: int {
RPI_ZERO_1=0,
RPI_2_3_ZERO2=1,
RPI_4=2,
RPI_5=3,
ALLWINNWER_H616=100,
UNKNOWN_BOARD=999
};