Allow build for NRF5340 MCU

Errata code referred to NRF_USBD_BASE.
This definition is not present in NRF5340 but both NRF52 and NRF53
do have NRF_USBD which maps to NRF_USBD_BASE for NRF52 and
to NRF_USBD_S_BASE for NRF5340.
This just make build possible for NRF5340.
This commit is contained in:
Jerzy Kasenberg 2021-05-11 08:53:33 +02:00
parent 59affc90aa
commit e2f795067a
1 changed files with 2 additions and 2 deletions

View File

@ -924,8 +924,8 @@ void tusb_hal_nrf_power_event (uint32_t event)
if ( nrfx_usbd_errata_166() )
{
*((volatile uint32_t *) (NRF_USBD_BASE + 0x800)) = 0x7E3;
*((volatile uint32_t *) (NRF_USBD_BASE + 0x804)) = 0x40;
*((volatile uint32_t *) ((uint8_t *) (NRF_USBD) + 0x800)) = 0x7E3;
*((volatile uint32_t *) ((uint8_t *) (NRF_USBD) + 0x804)) = 0x40;
__ISB(); __DSB();
}