Loading...
Searching...
No Matches
cc1xxx_common.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2017 Freie Universität Berlin
3 * SPDX-FileCopyrightText: 2018 Otto-von-Guericke-Universität Magdeburg
4 * SPDX-License-Identifier: LGPL-2.1-only
5 */
6
7#pragma once
8
57
58#include "net/gnrc/netif.h"
59
60#ifdef __cplusplus
61extern "C" {
62#endif
63
67#ifdef MODULE_GNRC_SIXLOWPAN
68#define CC1XXX_DEFAULT_PROTOCOL (GNRC_NETTYPE_SIXLOWPAN)
69#else
70#define CC1XXX_DEFAULT_PROTOCOL (GNRC_NETTYPE_UNDEF)
71#endif
72
76#define CC1XXX_ADDR_SIZE (1)
77
81#define CC1XXX_BCAST_ADDR (0x00)
82
88typedef struct __attribute__((packed)) {
89 uint8_t dest_addr;
90 uint8_t src_addr;
92
102typedef struct {
104 uint8_t addr;
105} cc1xxx_t;
106
111
127int gnrc_netif_cc1xxx_create(gnrc_netif_t *netif, char *stack, int stacksize,
128 char priority, char *name, netdev_t *dev);
129
139void cc1xxx_eui_get(const netdev_t *dev, uint8_t *eui);
140
141#ifdef __cplusplus
142}
143#endif
144
Definition for GNRC's network interfaces.
struct netdev_radio_rx_info cc1xxx_rx_info_t
Statistics for one received frame.
int gnrc_netif_cc1xxx_create(gnrc_netif_t *netif, char *stack, int stacksize, char priority, char *name, netdev_t *dev)
Creates a CC110x/CC1200 network interface.
void cc1xxx_eui_get(const netdev_t *dev, uint8_t *eui)
Retrieve a unique layer-2 address for a cc1xxx instance.
struct netdev netdev_t
Forward declaration for netdev struct.
Definition netdev.h:285
Layer 2 header used in CC1xxx frames.
uint8_t dest_addr
Destination layer 2 address.
uint8_t src_addr
Source layer 2 address.
Users of the CC110x/CC1200 adaption layer have to overlap their device handle with this structure.
netdev_t netdev
RIOT's interface to this driver.
uint8_t addr
Layer 2 address of this device.
Representation of a network interface.
Definition netif.h:132
Received frame status information for most radios.
Definition netdev.h:277