-> add an autoupdate mechanism
--> the camera is not available on page load, it is never shown afterwards - increase the timeout
-> click to zoom on cameras
-> make camera frames positions configurable
--> remote cameras are presented as http:///dev/video0
-> add a view log functionality
-> add a previewer for movies
-> add a previewer for snapshots
for key, value in camera_config.items():
remote_ui_config[key.replace('@', '')] = value
+ remote_ui_config['device'] = remote.make_remote_camera_url(
+ camera_config.get('@host'),
+ camera_config.get('@port'),
+ camera_config.get('@remote_camera_id'))
+
self.finish_json(remote_ui_config)
remote.get_config(
def on_response_builder(camera_id, camera_config):
def on_response(remote_ui_config):
if remote_ui_config is None:
+ camera_url = remote.make_remote_camera_url(
+ camera_config.get('@host'),
+ camera_config.get('@port'),
+ camera_config.get('@remote_camera_id'))
+
cameras.append({
'id': camera_id,
- 'name': '<error>', # TODO add the camera url here
+ 'name': '<' + camera_url + '>',
'enabled': False,
'streaming_framerate': 1,
'framerate': 1
return request
+def make_remote_camera_url(host, port, camera_id):
+ return '%(host)s:%(port)s/config/%(camera_id)s' % {
+ 'host': host,
+ 'port': port,
+ 'camera_id': camera_id
+ }
+
+
def list_cameras(host, port, username, password, callback):
logging.debug('listing remote cameras on %(host)s:%(port)s' % {
'host': host,