Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
set txpace 30
transmit "****^M"
waitfor ">"
transmit "john^M"
transmit "****^M"
waitfor ">"
transmit "logi xxxxxx^M"
pause 1
transmit "xxxxx^M"
mspause 50
call myproc
waitfor ">"
endproc
proc myproc
integer iDay, iMonth, iYear, iMin, iHour, iSec
string sSend
ltimeints $LTIME iYear iMonth iDay iHour iMin iSec
strfmt sSend "STAD %02d %02d %d %02d %02d %02d" iDay iMonth iYear iHour iMin iSec
set txpace 30
transmit "****^M"
waitfor ">"
transmit "ld 2^M"
waitfor "."
transmit "TTAD^M"
waitfor "."
transmit sSend
transmit "^M"
waitfor "."
transmit "****^M"
endproc[code]
been a while since i posted this one.. the only reason i opened this post was to see why stad was at reply 14. that one takes time and date off of your pc.. then use network time sync behind that if you need network sync.. i use that one to login every morming, this room is very secure and the pc is password protected.. you can rem out the logi portion, or end with a log out.. the transmit "john^M" logs out any switch
john poole
bellsouth business
columbia,sc
;Set date and time plus check DST.
;===============================================================
; Works best if you have NTP enabled on this PC.
proc main
integer iDay, iMonth, iYear, iMin, iHour, iSec, TimeDelta
string DMYHMS
TimeDelta=6 ; Approx delay in script....
set txpace 75
Transmit "****^M"
waitfor ">"
transmit "LD 2^M"
waitfor "."
termwrites "System time before adjusting:`n`r"
pause 2
transmit "TTAD^M"
waitfor "."
; Calculate date and time string.
ltimeints $LTIME iYear iMonth iDay iHour iMin iSec
; Adjust for delay in script.
iSec=iSEc+TimeDelta
if iSec>60 ; Seconds must not be greater that 60.
iSec=iSec-60
iMin=iMin+1
if iMin>60 ; Minutes must not be greater that 60.
iMin=iMin-60
iHour=iHour+1
endif
endif
; Put the parts together.
strfmt DMYHMS "STAD %02d %02d %d %02d %02d %02d^M" iDay iMonth iYear iHour iMin iSec
; and send it to the switch
transmit DMYHMS
waitfor "."
pause 6
termwrites "System time after adjusting:`n`r"
pause 1
transmit "TTAD^M"
waitfor "."
pause 1
termwrites "This is the current DST settings: `n`r"
pause 1
transmit "TDST^M"
waitfor "."
pause 1
transmit "****^M"
endproc