I ran into a similar problem. In the end, the issue was that I had to make sure that I was setting the host for the mobile app to be the exact same ip address as what is used in the interval program. For example, if you run the interval program by calling

python ospi.py

then you want to point your mobile app to the same IP and port (

If, however, you use the loopback (, as in

python ospi.py

then you’ll need to use the loopback in your mobile app configuration.

I think this all has to do with some pickiness on the part of the interval program as to whether it’s opening up local or network sockets for accepting incoming connections.

Personally, I have my configuration set to use the loopback IP address (, but if you want to also connect directly to the interval program UI (the one that isn’t quite as sharp looking) then you have to use the outward facing IP address of the RPi.

Edit: If you don’t know what the IP address is that the interval program is set to use, you can check the running processes by SSHing into the RPi and executing

ps -ax

look for the entry that looks like:

 4254 ?        Sl     0:29 /usr/bin/python /home/pi/OSPi/ospi.py

The IP address that I’m using is at the end there (