{"action":"created","issue":{"url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/29","labels_url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/29/labels{/name}","comments_url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/29/comments","events_url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/29/events","html_url":"https://github.com/lovepark/libo3d3xx/issues/29","id":120856179,"number":29,"title":"Question for the firmware team: Active Application at index \"0\"","user":{"login":"tpanzarella","id":645771,"avatar_url":"https://avatars.githubusercontent.com/u/645771?v=3","gravatar_id":"","url":"https://api.github.com/users/tpanzarella","html_url":"https://github.com/tpanzarella","followers_url":"https://api.github.com/users/tpanzarella/followers","following_url":"https://api.github.com/users/tpanzarella/following{/other_user}","gists_url":"https://api.github.com/users/tpanzarella/gists{/gist_id}","starred_url":"https://api.github.com/users/tpanzarella/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpanzarella/subscriptions","organizations_url":"https://api.github.com/users/tpanzarella/orgs","repos_url":"https://api.github.com/users/tpanzarella/repos","events_url":"https://api.github.com/users/tpanzarella/events{/privacy}","received_events_url":"https://api.github.com/users/tpanzarella/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/lovepark/libo3d3xx/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-07T20:06:10Z","updated_at":"2015-12-07T20:18:52Z","closed_at":null,"body":"@graugans I'm experiencing a behavior that I am wondering if it should be considered *normal* or if there is something I can do to prevent it from occurring. I believe this is a question for you and your team.\r\n\r\n**NOTE:** All file redirections in the below shell examples are attached to this issue for review.\r\n\r\nLet's assume I have the camera set at factory defaults:\r\n\r\n```\r\n$ o3d3xx-reset\r\n$ o3d3xx-dump > /tmp/camera_baseline.json.txt\r\n$ o3d3xx-ls\r\n* [1] id=559769693, name=Sample Application, description=\r\n```\r\n[camera_baseline.json.txt](https://github.com/lovepark/libo3d3xx/files/54482/camera_baseline.json.txt)\r\n\r\nSo, we know by default the imager will be set to single frequency dual exposure (aka `under5m_moderate`). Now, I want to change the imager for my application to, for example, double frequency single exposure (aka `upto30m_low`):\r\n\r\n```\r\n$ echo '{\"o3d3xx\":{\"Apps\":[{\"Index\":\"1\",\"Imager\":{\"Type\":\"upto30m_low\"}}]}}' | o3d3xx-config\r\n$ o3d3xx-dump > /tmp/camera2.json.txt\r\n$ o3d3xx-ls\r\n* [1] id=559769693, name=Sample Application, description=\r\n```\r\n[camera2.json.txt](https://github.com/lovepark/libo3d3xx/files/54496/camera2.json.txt)\r\n\r\nSo far so good. Now, I want to increase the frame rate. Let's set it to 10 Hz:\r\n\r\n```\r\n$ echo '{\"o3d3xx\":{\"Apps\":[{\"Index\":\"1\",\"Imager\":{\"FrameRate\":\"10\"}}]}}' | o3d3xx-config\r\n$ o3d3xx-dump > /tmp/camera_10Hz.json.txt\r\n$ o3d3xx-ls\r\n* [1] id=559769693, name=Sample Application, description=\r\n```\r\n[camera_10Hz.json.txt](https://github.com/lovepark/libo3d3xx/files/54501/camera_10Hz.json.txt)\r\n\r\nWe are still good. Now, suppose I want to set the frame rate to 15Hz:\r\n\r\n```\r\n$ echo '{\"o3d3xx\":{\"Apps\":[{\"Index\":\"1\",\"Imager\":{\"FrameRate\":\"15\"}}]}}' | o3d3xx-config\r\n$ o3d3xx-dump > /tmp/camera_15Hz.json.txt\r\n$ o3d3xx-ls\r\n  [1] id=559769693, name=Sample Application, description=\r\n```\r\n[camera_15Hz.json.txt](https://github.com/lovepark/libo3d3xx/files/54504/camera_15Hz.json.txt)\r\n\r\n**BOOM!** Here is the problem. We can see that we still have the application on the camera but it is no longer marked as active. In fact, via inspection, we can see that the `ActiveApplication` is actually `0`:\r\n\r\n```\r\n$ o3d3xx-dump | grep -i 'ActiveApplication'\r\n            \"ActiveApplication\": \"0\",\r\n```\r\n\r\nSo, if we try to set it back to `1`, we can see that we get no complaints, yet, the setting does not stick.\r\n\r\n```\r\n$ echo '{\"o3d3xx\":{\"Device\":{\"ActiveApplication\":\"1\"}}}' | o3d3xx-config\r\n$ o3d3xx-ls\r\n  [1] id=559769693, name=Sample Application, description=\r\n$ o3d3xx-dump | grep -i 'ActiveApplication'\r\n            \"ActiveApplication\": \"0\",\r\n```\r\n\r\nNow, if we step the frame rate back down to 10Hz and reactivate the application, everything is OK again:\r\n\r\n```\r\n$ echo '{\"o3d3xx\":{\"Apps\":[{\"Index\":\"1\",\"Imager\":{\"FrameRate\":\"10\"}}],\"Device\":{\"ActiveApplication\":\"1\"}}}' | o3d3xx-config\r\n$ o3d3xx-ls\r\n* [1] id=559769693, name=Sample Application, description=\r\n```\r\n\r\nIs this the intended behavior? Are there known `FrameRate` settings that will cause this for a given imager type? \r\n\r\nAs can be gleaned from the attached JSON dumps, I'm running the development version of the `libo3d3xx` code (`0.3.0`) and the `1.2.533` firmware on the camera."},"comment":{"url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/comments/162648065","html_url":"https://github.com/lovepark/libo3d3xx/issues/29#issuecomment-162648065","issue_url":"https://api.github.com/repos/lovepark/libo3d3xx/issues/29","id":162648065,"user":{"login":"tpanzarella","id":645771,"avatar_url":"https://avatars.githubusercontent.com/u/645771?v=3","gravatar_id":"","url":"https://api.github.com/users/tpanzarella","html_url":"https://github.com/tpanzarella","followers_url":"https://api.github.com/users/tpanzarella/followers","following_url":"https://api.github.com/users/tpanzarella/following{/other_user}","gists_url":"https://api.github.com/users/tpanzarella/gists{/gist_id}","starred_url":"https://api.github.com/users/tpanzarella/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpanzarella/subscriptions","organizations_url":"https://api.github.com/users/tpanzarella/orgs","repos_url":"https://api.github.com/users/tpanzarella/repos","events_url":"https://api.github.com/users/tpanzarella/events{/privacy}","received_events_url":"https://api.github.com/users/tpanzarella/received_events","type":"User","site_admin":false},"created_at":"2015-12-07T20:18:52Z","updated_at":"2015-12-07T20:18:52Z","body":"Thanks Christian!\r\n\r\n@graugans  As an FYI... you may want to flash the test camera with the `1.2.533` firmware as I have not had time yet to work with the `1.3.x` stuff. For example, I think I recall you mentioning that the `Output100K` parameter has changed and likely a few other things too. So, other additional/unexpected breakages may also occur between `libo3d3xx` and that version of the camera-side code.\r\n\r\nBTW, **C++11** training sounds fun. Enjoy!\r\n"}}