Beijer Electronics (formerly QSI Corporation)

Manufacturer of Mobile Data and Human Machine Interface Terminals.
It is currently Sun Nov 19, 2017 6:54 am

All times are UTC - 7 hours




Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Fri Mar 03, 2006 10:36 am 
Offline
User avatar

Joined: Thu Mar 02, 2006 2:12 pm
Posts: 487
Location: Salt Lake City, Utah
Question



How can I put my terminal into download mode remotely?



Answer



You can call the function SoftReset (i.e. SoftReset(RESET_LOADAPP) in your application to put the terminal into download mode.



One example of using the SoftReset function is to create a simple web server using the EthernetServer object and use a web browser such as internet explorer to put the terminal into download mode. Here is instructions on how to do this:



Create a TimerV2 object from the Basic library name ResetTimer with this code:



Code:
init parent := default

init enabled := False

init timeperiod := 1



func timeout()

    SoftReset(RESET_LOADAPP)

endfunc




Create an EthernetServerV2 object from the DataProc library with this code:



Code:
init parent := default

init protocol := net_tcp



func datareceived(channel as comm, data[] as byte, ipaddr[] as byte, foreignport as integer)

    dim ind as integer



    ind := find(data, 0, -1, "reset")

    if ind <> -1 then

        SendData(channel, "<HTML><BODY>Terminal Reseting to Load App. Mode</BODY></HTML>")

        NetClose(GetComMessageSource())

        ResetTimer.enabled= true

    endif

endfunc




When you attempt to open a page to the IPAddress of the unit with "reset" in the URL, the the unit will be reset into download mode.

Example URL: http://192.168.1.1/reset The reset is delayed by the Timer 1 second to give the transmit of the web page & connection close time to execute

_________________
Ron L.

http://www.beijerelectronicsinc.com/


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 7 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group