Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
telemetry_w5100 module

Telemetry using PPRZ protocol over W5100 Wifi module

W5100 is connected with a SPI link to the autopilot

Example for airframe file

Add to your firmware section: This example contains all possible configuration options, not all of them are mandatory!

<module name="telemetry_w5100">
b'<define name="W5100_DRDY_GPIO" value="GPIOX" />\n '
b'<define name="W5100_DRDY_GPIO_PIN" value="GPIOY" />\n '
b'<configure name="W5100_SPI_DEV" value="SPI1" />\n '
b'<configure name="W5100_SLAVE_IDX" value="1" />\n '
b'<configure name="W5100_IP" value="192,168,25,47" />\n '
b'<configure name="W5100_SUBNET" value="255,255,255,0" />\n '
b'<configure name="W5100_MULTICAST_IP" value="224,1,1,11" />\n '
b'<configure name="W5100_MULTICAST_PORT" value="1234" />\n '
</module>

Module configuration options

Configure Options

  • name: W5100_SPI_DEV value: SPI1
    Description: SPI port used for communication
  • name: W5100_SLAVE_IDX value: 1
    Description: SPI slave number
  • name: W5100_IP value: 192,168,25,47
    Description: IP address
  • name: W5100_SUBNET value: 255,255,255,0
    Description: network mask
  • name: W5100_MULTICAST_IP value: 224,1,1,11
    Description: multicast IP address
  • name: W5100_MULTICAST_PORT value: 1234
    Description: multicast IP port

Define Options

  • name: W5100_DRDY_GPIO value: GPIOX
    Description: GPIO port used for data ready pin
  • name: W5100_DRDY_GPIO_PIN value: GPIOY
    Description: GPIO pin number used for data ready pin

Module functions

Init Functions

These initialization functions are called once on startup.

Event Functions

These event functions are called in each cycle of the module event loop.

Files

Header Files

The following headers are automatically included in modules.h

Source Files

Raw telemetry_w5100.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="telemetry_w5100" dir="datalink" task="datalink">
<doc>
<description>
Telemetry using PPRZ protocol over W5100 Wifi module
W5100 is connected with a SPI link to the autopilot
</description>
<configure name="W5100_SPI_DEV" value="SPI1" description="SPI port used for communication"/>
<configure name="W5100_SLAVE_IDX" value="1" description="SPI slave number"/>
<configure name="W5100_IP" value="192,168,25,47" description="IP address"/>
<configure name="W5100_SUBNET" value="255,255,255,0" description="network mask"/>
<configure name="W5100_MULTICAST_IP" value="224,1,1,11" description="multicast IP address"/>
<configure name="W5100_MULTICAST_PORT" value="1234" description="multicast IP port"/>
<define name="W5100_DRDY_GPIO" value="GPIOX" description="GPIO port used for data ready pin"/>
<define name="W5100_DRDY_GPIO_PIN" value="GPIOY" description="GPIO pin number used for data ready pin"/>
</doc>
<dep>
<depends>spi_master,datalink_common</depends>
<provides>datalink,telemetry</provides>
</dep>
<header>
<file name="w5100.h"/>
</header>
<init fun="w5100_init()"/>
<event fun="w5100_event()"/>
<makefile target="!sim">
<configure name="W5100_SPI_DEV" default="SPI1" case="upper|lower"/>
<configure name="W5100_SLAVE_IDX" default="1"/>
<configure name="W5100_IP" default="192,168,25,47"/>
<configure name="W5100_SUBNET" default="255,255,255,0"/>
<configure name="W5100_MULTICAST_IP" default="224,1,1,11"/>
<configure name="W5100_MULTICAST_PORT" default="1234"/>
<define name="USE_$(W5100_SPI_DEV_UPPER)"/>
<define name="USE_SPI_SLAVE$(W5100_SLAVE_IDX)"/>
<define name="W5100_IP" value="$(W5100_IP)"/>
<define name="W5100_SUBNET" value="$(W5100_SUBNET)"/>
<define name="W5100_MULTICAST_IP" value="$(W5100_MULTICAST_IP)"/>
<define name="W5100_MULTICAST_PORT" value="$(W5100_MULTICAST_PORT)"/>
<define name="DOWNLINK_DEVICE" value="chip0"/>
<define name="DOWNLINK_TRANSPORT" value="pprz_w5100_tp"/>
<define name="DATALINK" value="W5100"/>
<file name="pprz_transport.c" dir="pprzlink/src"/>
<file name="w5100.c"/>
</makefile>
</module>