1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-09-13 04:20:18 +03:00
ben-wpan/tools/include/misctxrx.h
Werner Almesberger 8934c062a9 tools/: moved function to set transmit power from atrf-txrx to libatrf
- atrf-txrx/atrf-txrx.c (tx_pwr_230, tx_pwr_231, set_power): moved to
  lib/misctxrx.c
- include/misctxrx.h, lib/misctxr.c (set_power_step, set_power_dBm):
  separated dBm to index conversion from the actual operation
- atrf-txrx/atrf-txrx.c (main): use new set_power_dBm instead of old
  set_power
2011-04-12 16:37:05 -03:00

28 lines
768 B
C

/*
* include/misctxrx.h - Miscellaenous transceiver helper functions
*
* Written 2010-2011 by Werner Almesberger
* Copyright 2010-2011 Werner Almesberger
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/
#ifndef MISCTXRX_H
#define MISCTXRX_H
#include <stdint.h>
#include "atrf.h"
uint8_t wait_for_interrupt(struct atrf_dsc *dsc, uint8_t wait_for,
uint8_t ignore, int sleep_us, int timeout);
void set_power_step(struct atrf_dsc *dsc, int power, int crc);
void set_power_dBm(struct atrf_dsc *dsc, double power, int crc);
#endif /* !MISCTXRX_H */