@komoya Thanks, your suggestion to remove the brackets on “#ifndef(ESP8266)” worked like a charm. Managed to compile and get the code on my Wemos D1 Mini working.
Not sure why you could not receive the initial WIFI SSID from the device. Mine worked fine. However, some issues I faced were:
1. ESP8266 core 2.4.1 did not work. Had to use the older 2.2.0 core. Perhaps you could experiment with different versions to solve the WIFI SSID problem.
2. The latest SSD1306 OLED driver from the link earlier on this thread did not work. Had to locate an older version here. Just use the latest version on the list.