Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Can I automate reconnections via broadband dongle software interface?


  • Please log in to reply
4 replies to this topic
x26s
  • Members
  • 3 posts
  • Last active: Jun 28 2014 07:17 PM
  • Joined: 25 Jun 2014

My problem is that the tata photon plus dongle keeps disconnecting from the server side after a while. I need an automation script which can check if the internet is active or disconnected for specified time intervals (seconds, minutes etc) maybe just like ping testers;

if so, reconnect by automating the connect button clicking. This might be the difficult part, since I don't see any hotkey combination for the connect button.

Is this possible with autohotkey?

If possible, can some of the experts here guide me? I am a noob and am trying to achieve this with one of autoit3 or autohotkey.

Thanks.



girlgamer
  • Moderators
  • 3263 posts
  • Last active: Feb 01 2015 09:49 AM
  • Joined: 04 Jun 2010

If it's an "inactivity" disconnect, then once you identify what the system

recognizes as "activity" it should be possible to script an activity that the

system will allow as an activity to keep you connected. The second point

revolves around how long an "inactivity" must be before a disconnect occurs.

That could be handled by either a freerunning timer and/or some form of dead time

monitor like A_TimeIdle or A_TimeIdlePhysical.


The universe is a wondrous place! The faster you create unbreakable code, the faster the universe creates people that can break it. All scripting follows the rule Rule Of Twos -- 1) Good, 2) Fast 3) Cheap -- pick any Two.
I guarantee absolutely nothing about any code I provide except that it works in my machine. ●
MMO Fighter   KeyLooperDemo   Key Spammer   TinyClickRecorder  GGs Password Generator.ahk
For the newest version of AutoHotkey and some killer scripts go here.
Rock-on%20kitten.gif


x26s
  • Members
  • 3 posts
  • Last active: Jun 28 2014 07:17 PM
  • Joined: 25 Jun 2014

Thanks for the reply!

Quite the contrary: it is a "activity" disconnect, meaning the disconnection is from the server. The Indian ISP Tata Photon is a bigtime fraud. In an unlimited connection deal, one gets speeds upto 256KB/s (read maximum70-100KB/s in reality) until about 11GB is exhausted. Thereafter, we get 20kB/s roughly for the rest of the month. And unsurprisingly, the disconnection problem comes during the Minus 11GB part of the UNLIMITED deal of these bigtime frauds.

 

The get-around for this is reconnecting immediately. I have tried this using ping testers (PingADingDing/EasyNetMonitor) which give an alarm when the net goes off, but the problem is they drain the bandwidth slowly, and I have to manually reconnect every time it disconnects.

 

I just figured out that a bandwidth monitor (networkx in particular) gives alarms when the bandwidth falls below specified level, by just monitoring the downloads and not pinging. Unfortunately, networkx has some bug with the reporting and messes up the KB with MB. Bandwidth monitor doesnt have alarm option for decreasing speeds.

 

So the solution seems to be: 1. Monitor bandwidth 2. As soon as it drops to 0 for more than specified time (say 15 seconds), send a reconnect signal to the interface.



girlgamer
  • Moderators
  • 3263 posts
  • Last active: Feb 01 2015 09:49 AM
  • Joined: 04 Jun 2010
Wow, that sounds like a pretty serious limitation. But perhaps a
script is possible if you can log the bandwidth data. It might be
possible to read the log or even scan the onscreen bandwidth display
for a zero transfer rate on download rather than upload and set a
timer to check it each second over a 15-second duration. Once
the timer determines the data has in fact been compromised, it
may be able to send a reconnect if the dongle will accept the
virtual keystrokes AHK is capable of.

Lot of If's I know but it's a start.

The universe is a wondrous place! The faster you create unbreakable code, the faster the universe creates people that can break it. All scripting follows the rule Rule Of Twos -- 1) Good, 2) Fast 3) Cheap -- pick any Two.
I guarantee absolutely nothing about any code I provide except that it works in my machine. ●
MMO Fighter   KeyLooperDemo   Key Spammer   TinyClickRecorder  GGs Password Generator.ahk
For the newest version of AutoHotkey and some killer scripts go here.
Rock-on%20kitten.gif


x26s
  • Members
  • 3 posts
  • Last active: Jun 28 2014 07:17 PM
  • Joined: 25 Jun 2014

I managed to automate the process, so that i can leave the dongle on for the entire night.

I use networkx which monitors the bandwidth and allows to set alarms/run tasks at predetermined speeds.

 

When the speed drops below 15kB/s within 15 seconds I assume it has disconnected. (Maybe leaving this for longer might make it more reliable in detecting a true disconnection).

Anyway, when the criteria is met, networkx is set to run the .ahk file that runs macro obtained with "Mouse Recorder" for AHK.

 

The macro itself is very risky; it fails even if some changes occur within a few pixels...for example, if the interface window moves a bit....lol...It is funny to watch it work though!

The right solution would be to automate without the macro i.e.,

1. do exactly like networx (monitor bandwidth and when it drops to zero),

2. send reconnect signal without activating the dongle software interface.