Loading...
Searching...
No Matches
w5100.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2016 Freie Universität Berlin
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6#pragma once
7
32
33#include <stdint.h>
34
35#include "periph/spi.h"
36#include "periph/gpio.h"
37#include "net/netdev.h"
38
39#ifdef __cplusplus
40extern "C" {
41#endif
42
46enum {
47 W5100_ERR_BUS = -1,
48};
49
53typedef struct {
54 spi_t spi;
56 gpio_t cs;
57 gpio_t evt;
59
63typedef struct {
66} w5100_t;
67
79void w5100_setup(w5100_t *dev, const w5100_params_t *params, uint8_t index);
80
81#ifdef __cplusplus
82}
83#endif
84
spi_clk_t
Definition periph_cpu.h:348
Definitions low-level network driver interface.
Low-level GPIO peripheral driver interface definitions.
struct netdev netdev_t
Forward declaration for netdev struct.
Definition netdev.h:285
void w5100_setup(w5100_t *dev, const w5100_params_t *params, uint8_t index)
So the initial device setup.
Low-level SPI peripheral driver interface definition.
W5100 device descriptor.
Definition w5100.h:53
spi_t spi
SPI bus used.
Definition w5100.h:54
gpio_t cs
pin connected to the chip select line
Definition w5100.h:56
spi_clk_t clk
clock speed used on the selected SPI bus
Definition w5100.h:55
gpio_t evt
pin connected to the INT line
Definition w5100.h:57
Device descriptor for W5100 devices.
Definition w5100.h:63
netdev_t nd
extends the netdev structure
Definition w5100.h:64
w5100_params_t p
device configuration parameters
Definition w5100.h:65