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

TronSens HTM-B71 humidity sensor (I2C)

No detailed description...

Example for airframe file

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

<module name="humid_htm_b71">
b'<configure name="HTM_I2C_DEV" value="i2cX" />\n '
</module>

Module configuration options

Configure Options

  • name: HTM_I2C_DEV value: i2cX
    Description: select i2c peripheral to use (default i2c0)

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.

Periodic Functions

These functions are called periodically at the specified frequency from the module periodic loop.

  • humid_htm_start()
    • Frequency in Hz: 4
    • Delay: 0.66
      Integer to impose a sequence (between 0 and main_freq/function_freq)
    • Autorun: LOCK
      Periodic function automatically starts after init and can't be stopped.
  • humid_htm_read()
    • Frequency in Hz: 4
    • Delay: 0.9
      Integer to impose a sequence (between 0 and main_freq/function_freq)
    • Autorun: LOCK
      Periodic function automatically starts after init and can't be stopped.

Files

Header Files

The following headers are automatically included in modules.h

Source Files

Raw humid_htm_b71.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="humid_htm_b71" dir="meteo">
<doc>
<description>TronSens HTM-B71 humidity sensor (I2C)</description>
<configure name="HTM_I2C_DEV" value="i2cX" description="select i2c peripheral to use (default i2c0)"/>
</doc>
<header>
<file name="humid_htm_b71.h"/>
</header>
<init fun="humid_htm_init()"/>
<periodic fun="humid_htm_start()" freq="4" delay="0.66"/>
<periodic fun="humid_htm_read()" freq="4" delay="0.9"/>
<event fun="humid_htm_event()"/>
<makefile target="ap">
<configure name="HTM_I2C_DEV" default="i2c0" case="upper|lower"/>
<define name="USE_$(HTM_I2C_DEV_UPPER)"/>
<define name="HTM_I2C_DEV" value="$(HTM_I2C_DEV_LOWER)"/>
<file name="humid_htm_b71.c"/>
</makefile>
</module>