{"id":1171,"date":"2021-07-20T12:28:43","date_gmt":"2021-07-20T16:28:43","guid":{"rendered":"https:\/\/techministry.blog\/?p=1171"},"modified":"2021-07-20T12:28:43","modified_gmt":"2021-07-20T16:28:43","slug":"controlling-a-canon-xf-series-camera-using-a-stream-deck-and-companion-by-reverse-engineering-the-canon-browser-remote","status":"publish","type":"post","link":"https:\/\/techministry.blog\/?p=1171","title":{"rendered":"Controlling a Canon XF Series camera using a stream deck and Companion by reverse-Engineering the Canon BrowSer Remote"},"content":{"rendered":"\n<p>It&#8217;s been awhile since I posted! Earlier in the year, we had a few unexpected expenses come up in our family. I started spending my spare time in the evenings doing custom freelance programming to help meet the needs. I have been doing this for a few months now which has helped us out.<\/p>\n\n\n\n<p>God continues to bring new visitors to this blog and I have been able to return emails, phone calls, Zooms, and help so many people implement the ideas and software that I&#8217;ve created here. It is truly a blessing to see how God has used this little blog I started a few years ago.<\/p>\n\n\n\n<p>I&#8217;m excited to share a new project that I have been working on with my team: Control of our Canon XF cameras through a stream deck. We have a couple of these cameras here at my church, the Canon XF 705 series:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/techministry.blog\/wp-content\/uploads\/2021\/07\/img_2244.png?w=1024\" alt=\"\" class=\"wp-image-1207\" \/><\/figure>\n\n\n\n<p>I have been mentoring the guys who work part time in A\/V here with me on how to write code and specifically code modules for the Companion project that we use so heavily here. We decided it would be great if we had control of these particular cameras at our shader station alongside the shader control of our Marshall cameras (I wrote about that <a href=\"https:\/\/techministry.blog\/2021\/03\/11\/using-a-stream-deck-and-a-raspberry-pi-to-create-a-remote-control-panel-to-adjust-marshall-cameras-over-ip-with-rs-485-control\/\">here<\/a>) and our broadcast cameras.<\/p>\n\n\n\n<p>These Canon cameras come with a LAN port (you can also use wifi) and it runs a little web server called the Browser Remote which allows you to have full control of all the camera functions, from focus\/zoom\/iris\/gain all the way to recording, white balance, and shutter control. If there&#8217;s a button on the camera, chances are you can control it from the browser remote. You can even see a live preview of the camera!<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/techministry.blog\/wp-content\/uploads\/2021\/07\/browserremote.png?w=1024\" alt=\"\" class=\"wp-image-1205\" \/><figcaption>The built in browser remote functions of the Canon XF series.<\/figcaption><\/figure>\n\n\n\n<p>So we started doing some digging, and realized that there is an internal API on the camera that returns a lot of the data in simple JSON sets. Once you initiate a login request to the camera, it returns an authentication token, which must be sent along with every future request.<\/p>\n\n\n\n<p>For feedbacks on the camera state, we simply poll the camera every second or so. The browser remote page itself seems to do this as well, so we just emulated that.<\/p>\n\n\n\n<p>The browser remote unfortunately only allows one user at a time to be logged in, so when our Companion module is in use, the actual browser remote page can&#8217;t be used. But for our purposes, that&#8217;s not really an issue since we just want to have button control of the iris\/gain functions when we use these cameras during live services. Now I don&#8217;t have to ask my operators to iris up or down, I can just do it right from the stream deck!<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/techministry.blog\/wp-content\/uploads\/2021\/07\/img_2240.png?w=1024\" alt=\"\" class=\"wp-image-1206\" \/><\/figure>\n\n\n\n<p>Here&#8217;s a little walkthrough video that shows the module in action:<\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-rich is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<div class=\"embed-youtube\"><iframe loading=\"lazy\" title=\"Controlling a Canon XF camera using Bitfocus Companion and a Stream Deck\" width=\"840\" height=\"473\" src=\"https:\/\/www.youtube.com\/embed\/VI9UtIrVUVg?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe><\/div>\n<\/div><\/figure>\n\n\n\n<p>The <a href=\"https:\/\/github.com\/bitfocus\/companion-module-canon-xf\">module<\/a> will soon be a part of the Companion beta builds, so if you have a Canon XF series camera, go check it out!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It&#8217;s been awhile since I posted! Earlier in the year, we had a few unexpected expenses come up in our family. I started spending my spare time in the evenings doing custom freelance programming to help meet the needs. I have been doing this for a few months now which has helped us out. God &hellip; <a href=\"https:\/\/techministry.blog\/?p=1171\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Controlling a Canon XF Series camera using a stream deck and Companion by reverse-Engineering the Canon BrowSer Remote&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[17,19,38,50,51,66],"class_list":["post-1171","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-church","tag-companion","tag-ministry","tag-production","tag-programming","tag-stream-deck"],"_links":{"self":[{"href":"https:\/\/techministry.blog\/index.php?rest_route=\/wp\/v2\/posts\/1171","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/techministry.blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/techministry.blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/techministry.blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/techministry.blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1171"}],"version-history":[{"count":0,"href":"https:\/\/techministry.blog\/index.php?rest_route=\/wp\/v2\/posts\/1171\/revisions"}],"wp:attachment":[{"href":"https:\/\/techministry.blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1171"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/techministry.blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1171"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/techministry.blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1171"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}