Ok figured out how to get custom code from the Arduino IDE onto the pHAT. Before I was assuming that you left stuff in tact for booting but basically you send the bin to 0x0000 so the esptool command looks like this:
gpio write 2 0; gpio write 0 0; sleep 1; gpio write 0 1; python ../esptool/esptool.py -p /dev/ttyAMA0 -b 115200 write_flash -fs 32m -ff 80m 0x0000 HelloServer.cpp.generic.bin
Once done here is a handy way to start minicom:
gpio write 2 1; gpio write 0 0; sleep 1; gpio write 0 1; minicom -b 115200 -o -D /dev/ttyAMA0
Here is the server starting up: