Python script to restart modem and check if internet is up