nrf52 uarte receive timeout


I have a question regarding the nrf52 UARTE driver. I have the basics setup and working, I can send and receive data using the UARTE. What I need to do now, is find a way to receive incoming data BEFORE the rx buffer is full (if incoming data stops coming)

Example: I start a dma reception with a rx buffer of size 10. Then I receive 5 bytes on the uart, and nothing more. I don't want to wait (forever?) for another 5 bytes to fill up the buffer, but rather (after a certain timeout) receive the 5 bytes.

On other platforms this can be done for example by configuring a rx timeout in the driver/hw, or by letting a hw timer monitor the rx buffer and stop the reception after a certain time if no new data has arrived.

Any hints on how I can do this on the nRF52 platform?