As I add new network interfaces, they will need to allocate some buffers, due to the limited free memory I assume I should not support multiple network interface (e.g. linux style). I'm starting with ESP8266 but plan to add support for a few different network interfaces.
Currently the buffers appear to be allocated in a special memory for the on-chip ethernet. I also want to be mindful of how this ports to non-LPC1769 hardware.
1. As far as memory use goes we could:
- Pick one interface in settings file, others don't work.
- Pick Primary/Secondary in settings file - e.g. WiFi network not found on boot, enable ethernet. Use same buffer for both.
- Ethernet+1, enable ethernet as standard, allow configuration of second interface. Requires 2x buffers.
- Ethernet+1 shared. As above but try to put some scheme in place so network cards can share the memory. Likely performance and code complexity hit.
2. As far as ROM use, should we
- Leave all drivers enabled by default, with the possibility of #defining them out
- Leave them #defined out, requiring them enabled individually
3. I need a UART to myself so really not the debug/command UART0. Am I cool to reconfigure spi0 (P0.15, P0.16) as UART1 and use that (only if WiFi is enabled)? I tried to find a way for UART and LCD to coexist but cant see one. Too many pins are taken.