home *** CD-ROM | disk | FTP | other *** search
/ Thomson (Residential) / TGSTPv7203.iso / mac / HIW / xml / scen_uw_generic_mac.xml < prev   
Extensible Markup Language  |  2008-02-11  |  6KB  |  106 lines

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE fsm SYSTEM "fsm.dtd">
  3. <!-- 
  4.     Generic upgrade scenario for devices that support MDAP and BOOTP.
  5.  
  6.     Application properties:
  7.     - originalUserid: Current username of the device.
  8.     - originalPassword: Current password of the device.
  9.     - factoryUsername: Username of the build.
  10.     - factoryPassword: Password of the build.
  11.   - serialFilter: Regexp to filter device search on serial number. Default '*'
  12.   - nameFilter: Regexp to filter device search on device name. Default '*'
  13.   - upgrade.restore.templates [0|1]: backup .tpl files
  14.   - upgrade.restore.configuration [0|1]: backup .ini files
  15.   - upgrade.restore.softwareKeys [0|1]: backup .swk files. A reboot of the device will be required
  16.     after restoring them.
  17.   - upgrade.restore.languagePacks [disable|backup|*highest|exact]: how to restore .lng files:
  18.       - disable: do nothing
  19.       - backup: Restore the highest version that's available in the temporary directory.
  20.       - highest: Restore the highest version that's available in the languagepack directory, 
  21.         or if no compatible builds can be found there, from the temporary directory.
  22.       - exact:Only restore the language packs with the same version as the new build. 
  23.         Check the languagepack directory first, then the temporary directory.
  24.   - buildImagePath: Path where the build images are located.
  25.   - languagePackPath: Path where the language packs for the new build are located.
  26.     - expertMode: Built-in.
  27.     - applicationPath: Built-in
  28.  
  29.     - finishText: User friendly string specifying the result of the upgrade.
  30.  
  31.   Exit events:
  32.   - finished
  33.  
  34.   Modules referred:
  35.   - mod_upgrade_backupconfig.xml
  36.   - mod_upgrade_configinterface.xml
  37.   - mod_upgrade_restoreconfig.xml
  38.   - mod_upgrade_restorelangpacks.xml
  39.   - mod_upgradedevice.xml
  40.   - mod_devicefinder.xml
  41.   - mod_selectbuildimage.xml
  42.   - mod_selectdevice.xml
  43.  
  44. -->
  45.  
  46. <fsm>
  47.   <name>tr(Upgrade scenario)</name>
  48.   <property key="finishTextSuccess" value="tr(You have succesfully upgraded your device.<br/>Click Finish to close the Firmware Recovery Tool.)"/>
  49.   <property key="finishTextNearSuccess" value="tr(You have succesfully upgraded your device, but the following non-fatal error(s) occurred:</center><ul><li>%1</li></ul><center>Click Finish to close the Firmware Recovery Tool.)"/>
  50.   <states>
  51.     <state file="mod_devicefinder.xml" name="deviceFinder" weight="5" navigation="tr(Checking your Thomson Gateway)">
  52.       <property key="timeout" value="3"/><!-- search for devices for 10 secs -->
  53.     </state>
  54.     <state file="mod_setdeviceproperties.xml" name="setDeviceProperties" weight="1"/>
  55.     <state file="mod_selectbuildimage.xml" name="checkBuild" weight="2" navigation="tr(Select firmware image)"/>
  56.     <state file="mod_upgradedevice.xml" name="upgradeDevice" weight="80" navigation="tr(Upgrading your Thomson Gateway)"/>
  57.     <state type="showPageError" name="errorPage"/>
  58.   </states>
  59.   <events>
  60.     <event name="finished" />
  61.   </events>
  62.   <transitions>
  63.       <!-- system check -->
  64.     <transition startstate="deviceFinder">
  65.       <propertymap target="nameFilter" function="$app.nameFilter"/>
  66.       <propertymap target="serialFilter" function="$app.serialFilter"/>
  67.       <propertymap target="authenticationMode" function="user"/>
  68.       <propertymap target="systemUserid" function="$app.systemUserid"/>
  69.       <propertymap target="systemPassword" function="$app.systemPassword"/>
  70.     </transition>
  71.     <!-- device found, go to build check -->
  72.     <transition fromstate="deviceFinder" tostate="setDeviceProperties" event="foundDevice">
  73.       <!-- output --><propertymap target="app.device" function="$device"/>
  74.       <!-- output --><propertymap target="fsm.originalUserid" function="property($device,'user')"/>
  75.       <!-- output --><propertymap target="fsm.originalPassword" function="property($device,'password')"/>
  76.       <propertymap target="device" function="$device"/>
  77.       <propertymap target="filePath" function="concat($app.applicationPath, '/xml/devices.xml')"/>
  78.     </transition>
  79.     <transition fromstate="setDeviceProperties" tostate="checkBuild" event="finished">
  80.       <!-- output --><propertymap target="app.device" function="$device"/>
  81.       <propertymap target="device" function="$device"/>
  82.       <propertymap target="buildImagePath" function="concat($app.applicationPath,'/',$app.buildImagePath)"/>
  83.     </transition>
  84.     <transition fromstate="checkBuild" tostate="upgradeDevice" event="finished">
  85.       <propertymap target="buildImage" function="$buildImage"/>
  86.       <propertymap target="originalUserid" function="$fsm.originalUserid"/>
  87.       <propertymap target="originalPassword" function="$fsm.originalPassword"/>
  88.       <propertymap target="factoryUsername" function="$app.factoryUsername"/>
  89.       <propertymap target="factoryPassword" function="$app.factoryPassword"/>
  90.             <propertymap target="languagePackPath" function="concat($app.applicationPath,'/',$app.languagePackPath)"/>
  91.     </transition>
  92.     <transition fromstate="upgradeDevice" toexit="finished" event="success">
  93.       <propertymap target="app.finishText" function="$fsm.finishTextSuccess"/>
  94.     </transition>
  95.     <transition fromstate="upgradeDevice" toexit="finished" event="failedRestore">
  96.       <propertymap target="app.finishText" function="replace($fsm.finishTextNearSuccess, '%1', join($errorText, '</li><li>'))"/>
  97.     </transition>
  98.     <transition fromstate="deviceFinder" tostate="errorPage" event="foundNoDevices">
  99.       <propertymap target="errorType" function="NotFound"/>
  100.     </transition>
  101.     <transition fromstate="deviceFinder" tostate="errorPage" event="authenticationFailed">
  102.       <propertymap target="errorType" function="AuthenticationFailure"/>
  103.     </transition>
  104.   </transitions>
  105. </fsm>
  106.