Direct Hardware Register Access in Zephyre

Hello.. I want to access the nRF5340 registers to maniulate there values, for example : If, I want to acess the PSEL.RTS register or CONFIG of UART0  to initialize these. How may I have access of these to write any instruction like PSEL.RTS = 0x........; CONFIG = 0x.......;  Similarly how DIR , OUT or IN registers of PORT0 and PORT1 can be directly accessed in Zyphyre ?

Thanks

Parents Reply Children
  • Hi Gulzar Singh,

    mexco said:
    For example: let I want led on Pin 12 of P0

    #define led_pin 12 
    #define button_pin (30 + 31)   // Since on port1.

    Note that nRF53 does only have 48 general purpose I/= pins so 30 on P1 is not a valid pin.

    mexco said:
    2. I am using nRF5340DK kit. Does , the default internal Clock Nordic SOC starts automatically jut after power on or need some configuration ?

    The clock sources can be configured and you can set them to be automatically started. there is a lot of info regarding that in devzone like here. Please search for those threads and see if you find them useful.

Related