Merge Network code with webserver etc

Add some re entrancy fixes to circbuffer and ringbuffer
Allow network to be eliminated from build with make NONETWORK=1