1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-11-05 09:56:17 +02:00
Commit Graph

14 Commits

Author SHA1 Message Date
Werner Almesberger
b0c15b7e7c tools: give the driver control over CLKM (for ATmega32U2 boards)
- include/atrf.h (atrf_set_clkm), lib/atrf.c (atrf_set_clkm): set or
  disable CLKM
- lib/driver.h (atrf_set_clkm_generic), lib/atrf.c (atrf_set_clkm_generic):
  generic function to set CLKM without restrictions
- lib/driver.h (struct atrf_driver): added driver operation "set_clkm"
  to set CLKM
- lib/atusb.c (atusb_set_clkm, atusb_driver): restrict CLKM on ATmega32U2
  boards
- atrf-txrx/atrf-txrx.c (init_txrx): use atrf_set_clkm to set CLKM
- atrf-txrx/atrf-txrx.c (init_txrx, main): pass CLKM frequency in MHz
  instead of code point
2011-02-10 23:11:34 -03:00
Werner Almesberger
a9321cea7c libatrf: new function atrf_identify to identify the chip
- tools/lib/atrf.h, tools/lib/atrf.c (atrf_identify): added chip
  identification function to library
- tools/atrf-id/atrf-id.c (show_info): print information returned by
  atrf_identify
- tools/atrf-id/atrf-id.c (show_info): decode JEDEC manufacturer ID
2011-01-07 12:35:51 -03:00
Werner Almesberger
a8a898e202 The Great ATSPI Renaming, part 9: update comments as well
- Makefile.common, lib/atrf.c, lib/atusd.c: change ATSPI to ATRF in title
  comment
- include/atrf.h: comment still referred to atrf-id as "atspi-id"
2010-11-11 10:30:37 -03:00
Werner Almesberger
bcd3691c8a The Great ATSPI Renaming, part 6: change atrf API from atspi_* to atrf_*
- include/atrf.h, lib/atrf.c (struct atspi_dsc): renamed to "struct
  atrf_dsc"
- include/atrf.h, lib/atrf.c (atspi_*): renamed all functions to atrf_*
- include/misctxrx.h, lib/misctxrx.c (wait_for_interrupt): updated for API
  name change
- atspi-id/atspi-id.c (show_usb_info, show_info, main),
  atspi-reset/atspi-reset.c (main), atspi-rssi/atspi-rssi.c (sweep, main),
  atspi-rssi/gui.h (gui), atspi-rssi/gui.c (sweep, gui),
  atspi-trim/atspi-trim.c (main), atspi-txrx/atspi-txrx.c (init_txrx,
  set_channel, set_power, receive, transmit, test_mode, main):
  updated for API name change
2010-11-11 10:10:13 -03:00
Werner Almesberger
cf23ac6128 The Great ATSPI Renaming, part 4: rename include/atspi.h to include/atrf.h
- include/atspi.h: renamed to include/atrf.h
- include/misctxrx.h, lib/atrf.c, lib/misctxrx.c, atspi-id/atspi-id.c,
  atspi-reset/atspi-reset.c, atspi-rssi/atspi-rssi.c, atspi-rssi/gui.c,
  atspi-rssi/gui.h, atspi-trim/atspi-trim.c, atspi-txrx/atspi-txrx.c:
  change  #include "atspi.h"  to  #include "atrf.h"
2010-11-11 08:58:47 -03:00
Werner Almesberger
5d63a009c8 libatspi: new function atspi_test_mode to enter test mode
- include/atspi.h, lib/atspi.c: new function atspi_test_mode to enter test
  mode
- lib/driver.h (struct atspi_driver): add backend function test_mode
- lib/atusb.c (atusb_test_mode), lib/atusb.c (atusb_driver): enter test
  mode
- lib/atusd.c (atusd_driver): test mode is not supported
2010-11-11 02:29:07 -03:00
Werner Almesberger
2a245e1ee3 Make wait_for_interrupt available to all atspi tools.
- tools/atspi-txrx/atspi-txrx.c: cleaned up includes - we need stdint.h but
  we don't need atspi/ep0.h
- tools/atspi-txrx/atspi-txrx.c (wait_for_interrupt),
  tools/include/misctxrx.h (wait_for_interrupt), tools/lib/Makefile (OBJS),
  tools/lib/misctxrx.c (wait_for_interrupt): moved wait_for_interrupt from
  atspi-txrx to the atspi library, so that we can share it
2010-09-09 17:42:47 -03:00
Werner Almesberger
18eec557d0 Updated atusd driver for new hardware. Make use of the interrupt line.
- tools/lib/atusd.c (spi_send_partial, spi_send): removed the old spi_send
  and renamed spi_send_partial to spi_send
- tools/lib/atusd.c (atusd_cycle, spi_send, spi_recv, atusd_open): updated
  for removal of SLP_TR and split of MxSx into MOSI and MISO
- tools/lib/atusd.c (atusd_reset_rf, atusd_open): added delays to precharge
  the capacitors
- tools/lib/atusd.c (atusd_reset, spi_data_in, spi_data_out, spi_finish):
  removed functions for obsolete hardware features
- tools/lib/atusd.c (atusd_reg_read): removed calls to removed functions
- tools/lib/atusd.c (atusd_buf_write, atusd_buf_read, atusd_driver): new
  buffer read/write functions
- tools/atspi-txrx/atspi-txrx.c (init_txrx): set the internal osciallator
  trim only in the USB version. Switch to the external oscillator in the
  uSD version.
- tools/atspi-rssi/atspi-rssi.c (sweep), tools/atspi-txrx/atspi-txrx.c
  (set_channel): wait for the PLL to settle after setting the channel
- tools/include/atspi.h, tools/lib/atspi.c (atspi_interrupt),
  tools/lib/driver.h (struct atspi_driver), tools/lib/atusd.c
  (atusd_interrupt): new function to poll the interrupt line
- tools/atspi-txrx/atspi-txrx.c (receive): only read REG_IRQ_STATUS if
  there is a pending interrupt
- tools/atspi-id/atspi-id.c (usage): print "usage:" as well
- tools/Makefile (upload): upload the atspi tools to the Ben
2010-09-09 09:19:06 -03:00
Werner Almesberger
f20d685f8e Merged uSD driver into unified tool build, completed conversion of tools.
- atusd/tools/lib/atusd.c: moved to tools/lib/
- atusd/tools/lib/atusd.h: removed, we can now use tools/include/atspi.h
- tools/lib/atusd.c: added copyright header
- tools/lib/atusd.c: updated for driver API
- tools/lib/Makefile: added atusd.o
- tools/Makefile.common: moved common elements from all other makefiles in
  tools/*/ here
- tools/Makefile.common: added target-specific compiler and flags
- tools/atspi-id/Makefile, tools/atspi-reset/Makefile,
  tools/atspi-rssi/Makefile, tools/atspi-trim/Makefile,
  tools/atspi-txrx/Makefile, tools/lib/Makefile: used Makefile.common
- tools/lib/Makefile: differentiate USB and uSD build
- tools/atspi-id/atspi-id.c, tools/atspi-reset/atspi-reset.c,
  tools/atspi-rssi/atspi-rssi.c, tools/atspi-trim/atspi-trim.c,
  tools/atspi-txr/atspi-txr.c: updated for driver-agnostic API
- tools/atspi-id/atspi-id.c, tools/atspi-reset/atspi-reset.c,
  tools/atspi-rssi/atspi-rssi.c, tools/atspi-trim/atspi-trim.c,
  tools/atspi-txr/atspi-txr.c: corrected AF86RF230 typo in title
- tools/include/atspi.h, tools/lib/atspi.c, tools/lib/driver.c,
  tools/lib/atusb.c: brought back support for atspi_error and
  atspi_clear_error
- tools/atspi-id/atspi-id.c (atspi_get_protocol): renamed to get_protocol,
  to make it clear that it's not from libatspi
- tools/atspi-id/atspi-id.c (atspi_get_build): renamed to get_build, to
  make it clear that it's not from libatspi
- tools/include/atspi.h, tools/lib/atspi.c (atspi_usb_handle): new function
  to obtain a driver's USB device handle (or NULL if the driver doesn't use
  USB)
2010-09-05 20:32:58 -03:00
Werner Almesberger
e2b2df2e31 Made the libatspi API driver-agnostic.
- tools/include/atspi.h: API is now driver-independent
- tools/lib/driver.h: API between driver and frontend
- tools/lib/atspi.c: renamed to atusb.c and updated for driver API
- tools/lib/atspi.c: frontend functions for the driver API
- tools/lib/Makefile: added atusb.o
2010-09-05 19:06:48 -03:00
Werner Almesberger
36e73c4abb Moved tools/ out of atrf, in preparation of merge with atusd.
- atrf/tools/: moved to tools/
- tools/Makefile: updated path to Makefile.recurse
- tools/atspi-id/Makefile, tools/atspi-reset/Makefile,
  tools/atspi-rssi/Makefile, tools/atspi-trim/Makefile,
  tools/atspi-txrx/Makefile, tools/lib/Makefile: updated paths to f32xbase
  and to atrf/fw/include
2010-09-05 17:37:35 -03:00
Werner Almesberger
c2dd23840c Moved fw/ and tools/ into atrf/ as well.
- fw/: moved to atrf/fw/
- tools/: moved to atrf/tools/
- atrf/fw/atspi/Makefile, atrf/fw/boot/Makefile: updated relative path to
  f32xbase
- atrf/tools/Makefile: updated relative path to Makefile.recurse
- atrf/tools/atspi-id/Makefile, atrf/tools/atspi-reset/Makefile,
  atrf/tools/atspi-rssi/Makefile, atrf/tools/lib/Makefile: updated relative
  path to f32xbase
- atrf/fw/include/at86rf230.h: corrected path in title
- atrf/tools/include/atspi.h: added title and copyright header
2010-08-23 13:39:07 -03:00
Werner Almesberger
419b596c5d atspi-reset: utility to reset transceiver or entire board.
- tools/include/atspi.h, tools/lib/atspi.c (atspi_reset): new function to
  send the ATSPI_RESET command (MCU reset)
- tools/include/atspi.h, tools/lib/atspi.c (atspi_reset_rf): new function
  to send the ATSPI_RESET_RF command (transceiver reset)
- tools/atspi-reset/Makefile, tools/atspi-reset/atspi-reset.c: reset utility
2010-08-22 06:24:52 -03:00
Werner Almesberger
ac349b0bc0 Introduce library with ATSPI access functions (largely untested)
- tools/include/atspi.h, tools/lib/Makefile, tools/lib/atspi.c: library
  with ATSPI access functions
- tools/atspi-id/Makefile: use libatspi
- tools/atspi-id/atspi-id.c (main) use atspi_open instead of open_usb
- fw/atspi/at86rf230.h: moved to fw/include/
- fw/include/at86rf230.h: added ID registers
- fw/atspi/ep0.c: removed stray #endif
2010-08-20 16:27:24 -03:00