Contiki-NG
Loading...
Searching...
No Matches
The nRF52840 System-on-Chip

This group documents the Nordic Semiconductor nRF52840 CPU. More...

Topics

 Device drivers
 

Files

file  arch/cpu/nrf52840/dbg.c
 Hardware specific implementation of putchar() and puts() functions.
file  arch/cpu/nrf52840/rtimer-arch.c
 Architecture dependent rtimer implementation header file.
file  arch/cpu/nrf52840/rtimer-arch.h
 Architecture dependent rtimer implementation header file.

Functions

int dbg_putchar (int c)
 Print a character to debug output.
unsigned int dbg_send_bytes (const unsigned char *s, unsigned int len)
 Print a stream of bytes.
void rtimer_arch_init (void)
 Initialized the architecture-dependent part of rtimer.
void rtimer_arch_schedule (rtimer_clock_t t)
 This function schedules a one-shot event with the nRF RTC.
rtimer_clock_t rtimer_arch_now ()
 Returns the current real-time clock time.

Detailed Description

This group documents the Nordic Semiconductor nRF52840 CPU.

Function Documentation

◆ dbg_putchar()

int dbg_putchar ( int c)

Print a character to debug output.

Parameters
cCharacter to print
Returns
Printed character

Definition at line 59 of file dbg.c.

◆ dbg_send_bytes()

unsigned int dbg_send_bytes ( const unsigned char * seq,
unsigned int len )

Print a stream of bytes.

Parameters
seqA pointer to the stream
lenThe number of bytes to print
Returns
The number of printed bytes

Definition at line 71 of file dbg.c.

References dbg_putchar().

◆ rtimer_arch_init()

void rtimer_arch_init ( void )

Initialized the architecture-dependent part of rtimer.

We don't need to explicitly initialise anything but this routine is required by the API.

Initialized the architecture-dependent part of rtimer.

The Sleep Timer starts ticking automatically as soon as the device turns on. We don't need to turn on interrupts before the first call to rtimer_arch_schedule()

Definition at line 52 of file rtimer-arch.c.

◆ rtimer_arch_now()

rtimer_clock_t rtimer_arch_now ( void )

Returns the current real-time clock time.

Returns
The current rtimer time in ticks
See also
RTIMER_NOW()

< ST count/compare value 0

< ST count/compare value 1

< ST count/compare value 2

< ST count/compare value 3

Definition at line 76 of file rtimer-arch.c.

◆ rtimer_arch_schedule()

void rtimer_arch_schedule ( rtimer_clock_t t)

This function schedules a one-shot event with the nRF RTC.

Schedules an rtimer task to be triggered at time t.

Parameters
tThe time when the task will need executed.

t is an absolute time, in other words the task will be executed AT time t, not IN t rtimer ticks.

< Compare value load status

< STx upload status signal

< ST count/compare value 3

< ST count/compare value 2

< ST count/compare value 1

< ST count/compare value 0

Definition at line 70 of file rtimer-arch.c.