Imaging solutions with Free Software & Open Hardware

Who's online

There are currently 0 users online.

Reflash.php

From ElphelWiki

This script allows initiating camera firmware update from the NFS server. It allows to specify NFS server IP/directory in the GET request as well as the script name. Script uses default values if the parameters ("NFS=" and "SCRIPT=") are not specified. Here are the usage examples:

http://192.168.0.9/reflash.php
http://192.168.0.9/reflash.php?NFS=192.168.0.15:/nfs/latest80/
http://192.168.0.9/reflash.php?NFS=192.168.0.15:/nfs/latest80/&SCRIPT=nfs_update

They all do the same as the parameters specified are exactly the same as defaults. The script returns XML response with error message or status OK if it went as far as starting remote script on NFS server. After that response camera normally (while executing the default nfs_update script) shuts down web server, writes to flash memory and reboots. It is possible to watch the progress by monitoring log and lock files in the NFS directory on the server (both file names include MAC address/camera serial number). Log file is appended, lock one is created during reflash process and deleted when the software update procedure is finished.

It is possible to provide a name of a different remote script instead of the nfs_update - i.e the one that will just update some files (with/without reboot), not all the flash memory.