To benefit from the chunked ringbuffer if large frames are being sent,
we need to allocate more than one ethernet frame length to it.
Rename the define and make it overwriteable by the user.
`DOSE_TIMER_DEV` is defined in `board.h`, so we have to include it.
It's not included by the header (and should not), so move the check
to the .c file.
By moving all the single byte struct elements to the end, we can reduce
padding inside `dose_t` and ensure that `recv_buf` is always aligned.
This saves some RAM:
master
------
text data bss dec hex filename
36384 136 12944 49464 c138 tests/driver_dose/bin/samr21-xpro/tests_driver_dose.e
this patch
----------
text data bss dec hex filename
36484 136 12936 49556 c194 tests/driver_dose/bin/samr21-xpro/tests_driver_dose.elf
Some CAN transceivers have a standby pin that has to be pulled low
in order to use it.
If the interface is disabled we can set it to high again to save some
power.
A fixed timeout is either too long for high symbol rates or too short
for low symbol rates.
To fix this, calculate the timeout based on the symbol rate.
For this, the old 5ms timeout is equivalent to 58 bytes being transmitted
at 115200 baud (8 data bit + start & stop bit).
I rounded this to 50 bytes which should yield 4340 µs.