I have a flask server (on RPI4B) that runs over wifi, but need to use an IoT network due to an upcoming remote installation. Traditionally, I’ve always the flask server with app.run(host=’0.0.0.0’ port=5000)
I’ve installed a 3G/4G<E Base HAT, and can access the rpm via wlan0 but not wwan0.
The 3G/4G<E Hat is installed in ECM mode, and I can ping sixfab.com successfully from it (“ping -I wwan0 -c 5 sixfab.com”) returns 5 responses without error/
I’ve eliminated the wlan0 gateway (DHCPCD.conf has added line “interface wlan0”, “nogateway”).
I’ve set the metric for wwan0 to 100 (“interface wwan0”, metric 100”)
Route -n confirms this.
Using the wlan0 IP, http://192.168.1.238:5000/hello returns a “Hello” as it should.
Using the wwan0 IP, http://192.168.225.37:5000/hello returns “failed to open page, server not responding”.
I’m not a network guru, so I’ve probably overlooked something simple. Any ideas?
The fact that the server software work for wlan0 says that’s not it. The ability to ping says the hardware is installed ok.
Any suggestions are most welcome!!
Chuck