ConsultingJoe Posted August 22, 2007 Share Posted August 22, 2007 (edited) **TESTERS NEEDEDPlease, let me know what you think.WHAT DO THESE NUMBERS MEANRequired:Comcast BroadbandSurfboard ModemHTTP.au3IE.au3Autoit Betaexpandcollapse popup#include <HTTP.au3> #include <IE.au3> #include <GuiConstants.au3> $title = "Comcast Signal" ;Verify modem is present Ping( "192.168.100.1", 100 ) If @error Then MsgBox(0, $title, "Error locating modem at 192.168.100.1") Exit EndIf ;Verify modem by page title $ie = _IECreate( "192.168.100.1", 0, 0 ) $pagetitle = _IEPropertyGet ( $ie, "title" ) _IEQuit( $ie ) If $pagetitle <> "Modem Configuration: Status - Connection" Then MsgBox( 0, $title, "Error, Incorrect modem. Sorry" ) Exit EndIf Global $snr, $downpower, $uppower DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0) ; turn themes off for colors $Form1 = GUICreate($title, 200, 180, 193, 115) $snr_label = GUICtrlCreateLabel( "Loading", 8, 20, 55, 17 ) $snr_progress = GUICtrlCreateProgress(65, 20, 127, 17, 0x1) GUICtrlSetData( -1, 100 ) GUICtrlSetColor( -1, 0x00ff00 ) $downpower_label = GUICtrlCreateLabel( "Loading", 8, 59, 55, 17 ) $downpower_progress = GUICtrlCreateProgress(65, 59, 127, 17, 0x1) GUICtrlSetData( -1, 100 ) GUICtrlSetColor( -1, 0x00ff00 ) $uppower_label = GUICtrlCreateLabel( "Loading", 8, 97, 55, 17 ) $uppower_progress = GUICtrlCreateProgress(65, 97, 127, 17, 0x1) GUICtrlSetData( -1, 100 ) GUICtrlSetColor( -1, 0x00ff00 ) GUICtrlCreateLabel("Signal To Noise Ratio", 8, 3, 182, 17, $SS_RIGHT) GUICtrlCreateLabel("Downstream Power Level", 8, 41, 182, 17, $SS_RIGHT) GUICtrlCreateLabel("Upstream Power Level", 8, 79, 182, 17, $SS_RIGHT) $reset_button = GUICtrlCreateButton("Restart Modem", 8, 120, 89, 23, 0) $restore_button = GUICtrlCreateButton("Restore Defaults", 104, 120, 89, 23, 0) $modem_button = GUICtrlCreateButton("Modem Config", 8, 150, 89, 23, 0) $refresh_button = GUICtrlCreateButton("Refresh", 104, 150, 89, 23, 0) GUISetState(@SW_SHOW) update() AdlibEnable( "update", 3000 ) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $refresh_button update() Case $reset_button If MsgBox( 4, $title, "Are you sure you would like to restart your modem?" ) = 6 Then ResetReq() Case $restore_button If MsgBox( 4, $title, "Are you sure you would like to restort your modem to factory defaults?" ) = 6 Then RestoreReq() Case $modem_button Run(@ComSpec & " /c " & 'start http://192.168.100.1', "", @SW_HIDE) EndSwitch WEnd Func update() If GetStatus() = 1 Then GUICtrlSetData( $snr_label, $snr ) GUICtrlSetData( $downpower_label, $downpower ) GUICtrlSetData( $uppower_label, $uppower ) $snr = StringFormat( "%.1f", $snr ) $downpower = StringFormat( "%.1f", $downpower ) $uppower = StringFormat( "%.1f", $uppower ) If $snr < 30 Then GUICtrlSetColor( $snr_progress, 0xff0000 ) ElseIf $snr < 33 And $snr > 29 Then GUICtrlSetColor( $snr_progress, 0xffff00 ) Else GUICtrlSetColor( $snr_progress, 0x00ff00 ) EndIf $snr = Round(($snr/60)*100) If Abs($downpower) > 10 Then GUICtrlSetColor( $downpower_progress, 0xff0000 ) ElseIf Abs($downpower) < 5 And Abs($downpower) > 10 Then GUICtrlSetColor( $downpower_progress, 0xffff00 ) Else GUICtrlSetColor( $downpower_progress, 0x00ff00 ) EndIf $downpower = 100-(Abs($downpower)*9) If Abs($uppower-45) > 10 Then GUICtrlSetColor( $uppower_progress, 0xff0000 ) ElseIf Abs($uppower-45) < 5 And Abs($uppower-45) > 10 Then GUICtrlSetColor( $uppower_progress, 0xffff00 ) Else GUICtrlSetColor( $uppower_progress, 0x00ff00 ) EndIf $uppower = 100-(Abs($uppower-45)*9) Else $snr = "NO" $downpower = "MODEM" $uppower = "DETECTED" GUICtrlSetData( $snr_label, $snr ) GUICtrlSetData( $downpower_label, $downpower ) GUICtrlSetData( $uppower_label, $uppower ) EndIf GUICtrlSetData( $snr_progress, $snr ) GUICtrlSetData( $downpower_progress, $downpower ) GUICtrlSetData( $uppower_progress, $uppower ) EndFunc Func GetStatus() $ie = _IECreate( "http://192.168.100.1/RgSignal.asp", 0, 0 ) $table = _IETableGetCollection ($ie, 2) $table = _IETableWriteToArray ($table) If IsArray($table) Then Global $downpower = StringReplace( $table[1][5], "The Downstream Power Level reading is a snapshot taken at the time this page was requested. Please Reload/Refresh this Page for a new reading", "" ) Global $snr = $table[1][3] $table = _IETableGetCollection ($ie, 3) $table = _IETableWriteToArray ($table) If IsArray($table) Then Global $uppower = $table[1][3] EndIf _IEQuit($ie) Return 1 Else _IEQuit($ie) Return 0 EndIf EndFunc Func ResetReq() $soc = _HTTPConnect("192.168.100.1") If @error Then MsgBox( 0, $title, "Error opening socket" ) _HTTPPost("192.168.100.1", "/goform/RgConfig", $soc, "RestoreFactoryDefault=0&ResetReq=1") If @error Then MsgBox( 0, $title, "Error at POST request" ) _HTTPClose($soc) EndFunc Func RestoreReq() $soc = _HTTPConnect("192.168.100.1") If @error Then MsgBox( 0, $title, "Error opening socket" ) _HTTPPost("192.168.100.1", "/goform/RgConfig", $soc, "RestoreFactoryDefault=1&ResetReq=0") If @error Then MsgBox( 0, $title, "Error at POST request" ) _HTTPClose($soc) EndFunc Edited August 28, 2007 by CyberZeroCool [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 23, 2007 Author Share Posted August 23, 2007 What, no one has Comcast? [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 24, 2007 Author Share Posted August 24, 2007 Comon people, I can't believe no one has comcast and this modem. [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
PartyPooper Posted August 24, 2007 Share Posted August 24, 2007 (edited) Believe it, I have a similar modem but not Comcast. Edited August 24, 2007 by PartyPooper Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 24, 2007 Author Share Posted August 24, 2007 Believe it, I have a similar modem but not Comcast.Aww, thats bogus.Larry lives in a few miles away from me, if hes has high speed it would be comcast. [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 28, 2007 Author Share Posted August 28, 2007 Script Updated, Check first post. Added modem verifier. [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
James Posted August 28, 2007 Share Posted August 28, 2007 Could this be changed to netgear, belkin etc? Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 28, 2007 Author Share Posted August 28, 2007 (edited) Could this be changed to netgear, belkin etc?This is for a modem only. and not all modems will tell you the signal status. Edited August 28, 2007 by CyberZeroCool [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
James Posted August 28, 2007 Share Posted August 28, 2007 I'll check if NetGear tells you signal strength. Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
NELyon Posted August 29, 2007 Share Posted August 29, 2007 Sorry, i litterally got rid of comcast yesterday Maybe i should have seen this sooner. Link to comment Share on other sites More sharing options...
ConsultingJoe Posted August 30, 2007 Author Share Posted August 30, 2007 Sorry, i litterally got rid of comcast yesterday Maybe i should have seen this sooner.Aww, too bad [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
ssubirias3 Posted September 4, 2007 Share Posted September 4, 2007 (edited) Comon people, I can't believe no one has comcast and this modem.Just found your script today and I had started working on a similar script, too funny! My surfboard uses signal.html not RgSignal.asp. Perhaps have the script check one of the version numbers on the help page to determine if the script should use .asp or .html links. Software Version: SB5100-2.3.2.5-SCM01-NOSHHardware Version: 1MIB Version: IIGUI Version: 1.0VxWorks Version: 5.4Edit: The other thing I'd suggest adding is the MAC and Serial numbers since anytime I've called Comcast to report a problem they always ask for this information. Also I had planned to bring in the last 5 log entries into a listview along with some other features. Thanks again for sharing the idea and code! Edited September 4, 2007 by ssubirias3 Link to comment Share on other sites More sharing options...
ConsultingJoe Posted September 4, 2007 Author Share Posted September 4, 2007 Just found your script today and I had started working on a similar script, too funny! My surfboard uses signal.html not RgSignal.asp. Perhaps have the script check one of the version numbers on the help page to determine if the script should use .asp or .html links. Edit: The other thing I'd suggest adding is the MAC and Serial numbers since anytime I've called Comcast to report a problem they always ask for this information. Also I had planned to bring in the last 5 log entries into a listview along with some other features. Thanks again for sharing the idea and code!Thanks. [center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center] Link to comment Share on other sites More sharing options...
NELyon Posted September 4, 2007 Share Posted September 4, 2007 Talk about unlucky. I am getting comcast CABLE back, but not internet Link to comment Share on other sites More sharing options...
Gestalt Posted September 4, 2007 Share Posted September 4, 2007 I have Comcast, but I have a Linksys modem, not the Surfboard. Link to comment Share on other sites More sharing options...
drummerdude Posted September 22, 2007 Share Posted September 22, 2007 I have, what can i help you with? Link to comment Share on other sites More sharing options...
PerryRaptor Posted September 24, 2007 Share Posted September 24, 2007 (edited) It works! If you make the colored scale bars reflect yellow for low, green for acceptable, and red over limit would be nice. Edited September 24, 2007 by PerryRaptor Link to comment Share on other sites More sharing options...
Gradius Posted May 31, 2008 Share Posted May 31, 2008 (edited) Fixed some bugs and now is compatible with Motorola. Tested on SB5101 modem. Software Version: SB5101-2.4.1.6-SCM02-NOSH Hardware Version: 1 MIB Version: II GUI Version: 1.0 expandcollapse popup; ; Cable Modem Signal v0.1c ; Fixed some bugs and made it compatible with Motorola Cable modems ; by Gradius ~ 31/05/2008 ~ 11:30h am (GMT-4) ; #include <HTTP.au3> #include <IE.au3> #include <GuiConstants.au3> $title = "Cable Modem Signal v.1c" ;Ask for modem Ping("192.168.100.1",100) If @error then MsgBox(0, $title, "Error, modem not found (or disconnected) at 192.168.100.1") Exit EndIf ;Verify modem by page title $ie = _IECreate("192.168.100.1",0,0) $pagetitle = _IEPropertyGet ($ie,"title") _IEQuit($ie) If $pagetitle <> "Modem Configuration: Status - Connection" then MsgBox(0, $title, "Error, incompatible device. Sorry.") Exit EndIf Global $snr,$downpower,$uppower DllCall("uxtheme.dll","none","SetThemeAppProperties","int",0); turn themes off for colors $Form1 = GUICreate($title,220,180,193,115) $snr_label = GUICtrlCreateLabel("Loading...",8,20,55,17) $snr_progress = GUICtrlCreateProgress(65,20,147,17,0x1) GUICtrlSetData(-1,100) GUICtrlSetColor(-1,0x00ff00) $downpower_label = GUICtrlCreateLabel("Loading...",8,59,55,17) $downpower_progress = GUICtrlCreateProgress(65,59,147,17,0x1) GUICtrlSetData(-1,100) GUICtrlSetColor(-1,0x00ff00) $uppower_label = GUICtrlCreateLabel("Loading...",8,97,55,17) $uppower_progress = GUICtrlCreateProgress(65,97,147,17,0x1) GUICtrlSetData(-1,100) GUICtrlSetColor(-1,0x00ff00) GUICtrlCreateLabel("Signal to Noise Ratio",8,3,182,17,0) GUICtrlCreateLabel("Downstream Power Level",8,42,182,17,0) GUICtrlCreateLabel("Upstream Power Level",8,80,182,17,0) $reset_button = GUICtrlCreateButton("Restart Modem",18,120,89,23,0) $restore_button = GUICtrlCreateButton("Restore Defaults",114,120,89,23,0) $modem_button = GUICtrlCreateButton("Modem Config",18,150,89,23,0) $refresh_button = GUICtrlCreateButton("Refresh",114,150,89,23,0) GUISetState(@SW_SHOW) update() AdlibEnable("update",3000) While 1 ;Verify if modem is online on every update Ping("192.168.100.1",100) If @error then MsgBox(0, $title, "Error, modem offline and/or disconnected !") Exit EndIf ;end of verify routine $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $refresh_button update() Case $reset_button If MsgBox(4, $title, "Are you sure you would like to restart your modem ?") = 6 then ResetReq() Case $restore_button If MsgBox(4, $title, "Are you sure you would like to restore your modem to factory defaults ?") = 6 then RestoreReq() Case $modem_button Run(@ComSpec & " /c " & 'start http://192.168.100.1', "", @SW_HIDE) EndSwitch WEnd Func update() ;Verify if modem is online on every update Ping("192.168.100.1",100) If @error then MsgBox(0, $title, "Error, modem offline and/or disconnected !") Exit EndIf ;end of verify routine If GetStatus() = 1 then GUICtrlSetData($snr_label,$snr) GUICtrlSetData($downpower_label,$downpower) GUICtrlSetData($uppower_label,$uppower) ;$snr = StringFormat("%.1f",$snr) ;$downpower = StringFormat("%.1f",$downpower) ;$uppower = StringFormat("%.1f",$uppower) If $snr < 30 then GUICtrlSetColor($snr_progress,0x0000ff) ElseIf $snr < 33 and $snr > 39 then GUICtrlSetColor($snr_progress,0xffff00) Else GUICtrlSetColor($snr_progress,0x00ff00) EndIf ;$snr = Round(($snr/60)*100) If Abs($downpower) > 10 then GUICtrlSetColor($downpower_progress,0xff0000) ElseIf Abs($downpower) < 5 and Abs($downpower) > 10 then GUICtrlSetColor($downpower_progress,0xffff00) Else GUICtrlSetColor($downpower_progress,0x00ff00) EndIf $downpower = 10-(Abs($downpower)*9) If Abs($uppower-45) > 10 then GUICtrlSetColor($uppower_progress,0x0000ff) ElseIf Abs($uppower-45) < 5 and Abs($uppower-45) > 10 then GUICtrlSetColor($uppower_progress,0xffff00) Else GUICtrlSetColor($uppower_progress,0x00ff00) EndIf ;$uppower = 100-(Abs($uppower-45)*9) Else $snr = "NO" $downpower = "MODEM" $uppower = "DETECTED" GUICtrlSetData($snr_label,$snr) GUICtrlSetData($downpower_label,$downpower) GUICtrlSetData($uppower_label,$uppower) EndIf GUICtrlSetData($snr_progress,$snr) GUICtrlSetData($downpower_progress,$downpower) GUICtrlSetData($uppower_progress,$uppower) EndFunc Func GetStatus() $ie = _IECreate("http://192.168.100.1/RgSignal.asp",0,0) $table = _IETableGetCollection ($ie,2) $table = _IETableWriteToArray ($table) If IsArray($table) then Global $downpower = StringReplace($table[1][5], "The Downstream Power Level reading is a snapshot taken at the time this page was requested. Please Reload/Refresh this Page for a new reading.", "") Global $snr = $table[1][3] $table = _IETableGetCollection ($ie,3) $table = _IETableWriteToArray ($table) If IsArray($table) then Global $uppower = $table[1][3] EndIf _IEQuit($ie) Return 1 Else _IEQuit($ie) Return 0 EndIf EndFunc Func ResetReq() MsgBox (0, $title, "Restarting Modem...") $soc = _HTTPConnect("192.168.100.1") If @error then MsgBox(0, $title, "Error while opening socket !") _HTTPPost("192.168.100.1", "/goform/RgConfig", $soc, "DhcpServer=0&saveChanges=1&ResetReq=1") If @error then MsgBox(0, $title, "Error at POST request !") _HTTPClose($soc) Exit EndFunc Func RestoreReq() MsgBox (0, $title, "Restarting Modem...") $soc = _HTTPConnect("192.168.100.1") If @error then MsgBox(0, $title, "Error while opening socket !") _HTTPPost("192.168.100.1", "/goform/RgConfig", $soc, "RestoreFactoryDefault=1&ResetReq=0") If @error then MsgBox(0, $title, "Error at POST request !") _HTTPClose($soc) Exit EndFunc Enjoy! Gradius Edited May 31, 2008 by Gradius Link to comment Share on other sites More sharing options...
theguy0000 Posted May 31, 2008 Share Posted May 31, 2008 I have comcast, but the modem says Arris, and doesn't look like the picture... It's for Digital Voice too. The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Link to comment Share on other sites More sharing options...
PartyPooper Posted June 1, 2008 Share Posted June 1, 2008 Links to where we can find HTTP.AU3 and IE.AU3 might help. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now