Stefan Schmidt
fc7551e532
atusb/fw: Use RX_AACK_ON instead of RX_ON in the firmware.
...
This allows to run the device in ARET networks as we handle the needed
automated ACK in hardware.
2015-05-20 15:02:19 +02:00
Werner Almesberger
bf067b3e73
atusb/fw/mac.c (RX_BUFS): increase buffer size from 2 to 3 frames
2013-07-30 20:38:13 -03:00
Werner Almesberger
7fd9044d94
atusb/fw/: add SPI block reception
...
This decreases the retrieval time for a frame of 102 bytes from
660 us to 384 us, corresponding to a speed change from about
1.26 Mbps to 2.17 Mbps (102 bytes plus 2 bytes overhead).
2013-07-30 19:52:54 -03:00
Werner Almesberger
998ac7e5c6
atusb/fw/mac.c (next_buf): dedicated function for incrementing buffer indices
2013-07-24 16:21:38 -03:00
Werner Almesberger
b73d5fc1af
atusb/fw/mac.c: remove queued_rx; buffer frames in the MCU instead
...
queued_rx held a frame in the transceiver's receive buffer until we could
transfer it. This may cause frame loss if a new reception begins.
We now retrieve frames from the transceiver immediately and buffer them
in the MCU.
2013-07-24 07:57:35 -03:00
Werner Almesberger
6416fa8d0b
atusb/fw/mac.c: add section titles
2013-07-23 12:50:42 -03:00
Werner Almesberger
367c1abb0e
atusb/fw/: echo back TX ACK sequence number; don't panic if driver times out TX
2013-04-01 22:04:05 -03:00
Werner Almesberger
65722d417a
atusb/fw/mac.c: queue frame reception if USB is busy
...
This way we we make sure we retrieve the frame and thus release dynamic
buffer protection (if enabled).
2013-04-01 15:17:37 -03:00
Werner Almesberger
d76bdf6a82
atusb/fw/mac.c (handle_irq): move frame reception to separate function
2013-04-01 14:29:57 -03:00
Werner Almesberger
60ee82ba93
atusb/fw/mac.c (handle_irq): only handle TRX_END; never fall back to seq ints
2013-04-01 12:48:30 -03:00
Werner Almesberger
647f3c0375
atusb/fw/: get rid of some more "int"s
...
No size change this time.
2013-03-29 19:19:49 -03:00
Werner Almesberger
a8db238cbb
atusb/fw/: convert functions returning "int" to "bool"
...
Firmware size is down from 5612 to 3590 bytes. Wow !
2013-03-29 19:14:11 -03:00
Werner Almesberger
c9ab070ffd
atusb/fw/mac.c (do_tx): add timeout for transition to TRX_STATUS_RX_[AACK_]ON
2013-03-29 18:50:54 -03:00
Werner Almesberger
211280356d
atusb/fw/mac.c: check CRC and auto-discard bad frames
2013-03-29 17:02:24 -03:00
Werner Almesberger
5fc9575e4e
atusb/fw/mac.c (do_tx): pulse SLP_TR instead of sending TRX_CMD_TX_START
2013-03-29 15:03:03 -03:00
Werner Almesberger
88c7e64e38
atusb/fw/mac.c (txing, queued_tx_ack): change from "int" to "bool"
2013-02-20 18:48:53 -03:00
Werner Almesberger
de8bcc1925
atusb/fw/mac.c: always wait for stability before changing transceiver state
2013-02-20 13:05:33 -03:00
Werner Almesberger
852aaf1b66
atusb/fw/: reset MAC state on ATUSB_RF_RESET
2013-02-13 09:30:21 -03:00
Werner Almesberger
911eb4d4b5
fw/mac.c (handle_irq): read REG_IRQ_STATUS also if we ignore the value
...
Else, we won't get any further interrupts.
2013-02-13 01:35:23 -03:00
Werner Almesberger
eeeb5599f8
atusb/fw/mac.c: reserved code 0 and added notification of TX completion
...
- mac.c (queued_tx_ack, rx_done, handle_irq): on TX completion, send a
a zero byte on EP 1
- mac.c (handle_irq): don't receive zero-sized frames (they're
malformed anyway), so that size zero can be used to signal TX
completion
2011-07-13 14:22:49 -03:00
Werner Almesberger
da7803a746
atusb/fw/: some small "HardMAC" fixes
2011-07-12 17:48:17 -03:00
Werner Almesberger
862b554e2d
libatrf: added HardMAC functions
...
This function set isn't really usable for real communication. Its main
purpose is to help with testing the firmware.
- tools/lib/driver.h (struct atrf_driver): added driver functions for
HardMAC access
- tools/include/atrf.h (atrf_rx_mode, atrf_rx, atrf_tx),
tools/lib/atrf.c: functions to enable/disable HardMAC mode and to
send/receive frames
2011-07-12 17:45:59 -03:00
Werner Almesberger
c1071309d8
atusb/fw/: added "HardMAC" support (not yet using the TRX's MAC)
...
- include/atusb/ep0.h (enum atspi_requests), ep0.c (my_setup): added
new "HardMAC" requests ATUSB_RX_MODE and ATUSB_TX
- mac.h, mac.c: basic "HardMAC" procedure
- board_app.c (INT0_vect): call MAC-specific interrupt handler if
provided
- Makefile (OBJS): added mac.o
2011-07-12 12:26:07 -03:00