Interesting that this isn't based on lwIP. lwIP can operate happily in just 1 kilobyte of RAM, although lower RAM limits hurt performance quite heavily (can't reorder TCP packets, so you have to wait for the far end to retransmit them if they arrive out of order).