Firmware
Macros
drv_blinkm.h File Reference

BlinkM driver API. More...

#include <px4_defines.h>
#include <stdint.h>
#include <sys/ioctl.h>

Go to the source code of this file.

Macros

#define BLINKM0_DEVICE_PATH   "/dev/blinkm0"
 
#define _BLINKMIOCBASE   (0x2900)
 
#define _BLINKMIOC(_n)   (_PX4_IOC(_BLINKMIOCBASE, _n))
 
#define BLINKM_PLAY_SCRIPT_NAMED   _BLINKMIOC(1)
 play the named script in *(char *)arg, repeating forever
 
#define BLINKM_PLAY_SCRIPT   _BLINKMIOC(2)
 play the numbered script in (arg), repeating forever
 
#define BLINKM_SET_USER_SCRIPT   _BLINKMIOC(3)
 Set the user script; (arg) is a pointer to an array of script lines, where each line is an array of four bytes giving <duration>, <command>, arg[0-2]. More...
 

Detailed Description

BlinkM driver API.

This could probably become a more generalised API for multi-colour LED driver systems, or be merged with the generic LED driver.

Macro Definition Documentation

§ BLINKM_SET_USER_SCRIPT

#define BLINKM_SET_USER_SCRIPT   _BLINKMIOC(3)

Set the user script; (arg) is a pointer to an array of script lines, where each line is an array of four bytes giving <duration>, <command>, arg[0-2].

The script is terminated by a zero command.