HAL: RTC2 for nrf52833 was missing

The definitions in the HAL for RTC2 for the nrf52833 had
been forgotten. Let's add them.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This commit is contained in:
Alberto Escolar Piedras 2024-03-08 14:44:39 +01:00
parent 12e66d154f
commit ffd0ddec02
3 changed files with 7 additions and 2 deletions

View File

@ -125,7 +125,7 @@ void *nhw_convert_periph_base_addr(void *hw_addr) {
// {(void *)NRF_SPI2_BASE , 0x40023000UL},
// {(void *)NRF_SPIM2_BASE , 0x40023000UL},
// {(void *)NRF_SPIS2_BASE , 0x40023000UL},
// {(void *)NRF_RTC2_BASE , 0x40024000UL},
{(void *)NRF_RTC2_BASE , 0x40024000UL},
// {(void *)NRF_I2S_BASE , 0x40025000UL},
// {(void *)NRF_FPU_BASE , 0x40026000UL},
// {(void *)NRF_USBD_BASE , 0x40027000UL},

View File

@ -79,7 +79,10 @@ IRQn_Type nrfx_get_irq_number(void const * p_reg){
return 30;
} else if (IS_PERIPHERAL_REG(p_reg, PPI,,)) {
return 0x1F;
/*32-39*/
/*32-35*/
} else if (IS_PERIPHERAL_REG(p_reg, RTC, 2,)) {
return RTC2_IRQn;
/*37-39*/
} else if (IS_PERIPHERAL_REG(p_reg, UARTE, 1,)) {
return UARTE1_IRQn;
/*40-47*/

View File

@ -38,6 +38,8 @@ extern NRF_RTC_Type NRF_RTC_regs[];
#define NRF_RTC0_BASE (&NRF_RTC_regs[0])
#undef NRF_RTC1_BASE
#define NRF_RTC1_BASE (&NRF_RTC_regs[1])
#undef NRF_RTC2_BASE
#define NRF_RTC2_BASE (&NRF_RTC_regs[2])
extern NRF_ECB_Type NRF_ECB_regs;
#undef NRF_ECB_BASE
#define NRF_ECB_BASE (&NRF_ECB_regs)