Classes
Gruppe nützlicher Makros und Inline-Funktionen

Nützliche Makros und Funktionen. More...

Classes

struct  long_to_byte_t
 

Kritische Sektionen (Interrupts sperren)

static uint8_t read_and_replace_atomar (volatile uint8_t *data, uint8_t new_data)
 atomare Operationen More...
 

weitere nuetzliche Makros

static uint8_t swap (uint8_t x)
 Dreht die beiden Nibble in einem Byte um. More...
 
static uint8_t bit_count8 (uint8_t n)
 Zählt die Anzahl der gesetzten Bits in einem Byte. More...
 
static uint8_t bit_count32 (uint32_t n)
 Zählt die Anzahl der gesetzten Bits in einem Byte. More...
 
#define DEBUG_PRINT(s, ...)
 
More...
 

Detailed Description

Nützliche Makros und Funktionen.

Version
Id
utils.h 8541 2010-03-15 22:01:12Z fabian

Macro Definition Documentation

◆ DEBUG_PRINT

#define DEBUG_PRINT (   s,
  ... 
)


Definition at line 309 of file utils.h.

Function Documentation

◆ bit_count32()

static uint8_t bit_count32 ( uint32_t  n)
inlinestatic

Zählt die Anzahl der gesetzten Bits in einem Byte.

Parameters
nWert der verarbeitet werden soll.
Returns
Anzahl der gesetzten Bits (0..32)

Definition at line 344 of file utils.h.

◆ bit_count8()

static uint8_t bit_count8 ( uint8_t  n)
inlinestatic

Zählt die Anzahl der gesetzten Bits in einem Byte.

Parameters
nByte das verarbeitet werden soll.
Returns
Anzahl der gesetzten Bits (0..8)
See also
http://infolab.stanford.edu/~manku/bitcount/bitcount.html

Definition at line 323 of file utils.h.

◆ read_and_replace_atomar()

static uint8_t read_and_replace_atomar ( volatile uint8_t *  data,
uint8_t  new_data 
)
inlinestatic

atomare Operationen

Definition at line 138 of file utils.h.

◆ swap()

static uint8_t swap ( uint8_t  x)
inlinestatic

Dreht die beiden Nibble in einem Byte um.

Parameters
xByte das verarbeitet werden soll.

Definition at line 289 of file utils.h.



uavcan_communicator
Author(s):
autogenerated on Fri Dec 13 2024 03:10:04