1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-09-30 01:09:47 +03:00

Literature consistently calls the Link Quality Indication LQI, not LQ. So do

we now.

- atrf/fw/atspi/ep0.c: changed LQ to LQI in comments
- atrf/tools/atspi-txrx/atspi-txrx.c (receive): changed LQ to LQI in comment
  and in diagnostic output
This commit is contained in:
Werner Almesberger 2010-08-24 21:03:39 -03:00
parent 8f744bba63
commit bb7b049f00
2 changed files with 5 additions and 5 deletions

View File

@ -58,7 +58,7 @@ extern void reset_rf(void);
static const uint8_t id[] = { EP0ATSPI_MAJOR, EP0ATSPI_MINOR, HW_TYPE };
static __xdata uint8_t buf[MAX_PSDU+3]; /* command, PHDR, and LQ */
static __xdata uint8_t buf[MAX_PSDU+3]; /* command, PHDR, and LQI */
static uint8_t size;
@ -172,9 +172,9 @@ static __bit my_setup(struct setup_request *setup) __reentrant
return 1;
case ATSPI_FROM_DEV(ATSPI_BUF_READ):
debug("ATSPI_BUF_READ\n");
if (setup->wLength < 2) /* PHR+LQ */
if (setup->wLength < 2) /* PHR+LQI */
return 0;
if (setup->wLength > MAX_PSDU+2) /* PHR+PSDU+LQ */
if (setup->wLength > MAX_PSDU+2) /* PHR+PSDU+LQI */
return 0;
nSS = 0;
spi_send(AT86RF230_BUF_READ);

View File

@ -82,7 +82,7 @@ static void set_power(usb_dev_handle *dev, double power)
static void receive(usb_dev_handle *dev)
{
uint8_t irq;
uint8_t buf[MAX_PSDU+1]; /* PSDU+LQ */
uint8_t buf[MAX_PSDU+1]; /* PSDU+LQI */
int n, ok, i;
uint8_t lq;
@ -124,7 +124,7 @@ static void receive(usb_dev_handle *dev)
}
ok = !!(atspi_reg_read(dev, REG_PHY_RSSI) & RX_CRC_VALID);
lq = buf[n-1];
fprintf(stderr, "%d bytes payload, CRC %s, LQ %u\n",
fprintf(stderr, "%d bytes payload, CRC %s, LQI %u\n",
n-3, ok ? "OK" : "BAD", lq);
for (i = 0; i != n-3; i++)
putchar(buf[i] < ' ' || buf[i] > '~' ? '?' : buf[i]);