You should state which processor you intend to use since DMA is where all the speed gains are. Unfortunately, the majority of Arduinos don't support it. The Due does, maybe one of the newer, non-atMega boards does as well, don't know.
Nah. The existing SPI library really wants to be bi-directional, all the time, and loses a lot of performance because of that. It could be a lot faster even even without DMA. (But not without implementing new APIs. There was a significant discussion on the Developer's list relatively recently: Redirecting to Google Groups
I conducted some Ethernet UDP tests and I got some strange results:
The setup is:
ARDUINO UNO connected to ARDUINO MEGA through Ethernet
With Ethernet shield on each one (including W5100), SPI 4 Mbits or 8 Mbits
Using Ethernet Library,
UNO transmitting continuously UDP packets of 128 bytes
MEGA receiving the packets and printing out a message every time a particular byte within the packet is different from the transmitted value.
Results: An error message within an average of every 50 packets.
What is more interesting is that:
The error rate for a particular byte in the message increases with the position of this byte in the message. For example, if for byte #40 the error rate is 1 every 50 messages, for byte #100 the error rate is 1 out of only 20 messages.
The reading of these error values occurs at the same messages. For example if we order the transmitted messages from start with 0, 1, .....the errors would occur always at messages 8, 120, 180, ...
I would appreciate any comments about these results, including any idea for decreasing those error rates.
Errors on a properly installed Ethernet network should be quite rare, whereas yours are fairly common.
The 'predicatability' of the errors you are seeing sound like a problem with your software, bit errors across Ethernet would tend to ocurr at random through a packet.
Edit:
On reflection, a Ethernet working in a collision domain could produce those errors, but I have not seen a collision based Ethernet in use for years, in twisted pair media that is.
The connection between the 2 ARDUINOs (with Ethernet shields on each one) was a direct point to point Ethernet cable. That makes those results really strange.
I am trying some more changes in Software, before I post the sketches.