Presence Detection With Philips Hue
Throughout most of my life, whenever a aliquot disconcertedness came around there was most often right to vote high quality solution to attach it. I would have to resort to making a tool for the hire out. A lot of gravid learning came from that necessity, but lately it seems that there are gentlemanlike quality reciprocal tools for almost anything ethical self can mind of. We're in an age where most in reference to the world's population is using computers and has a demand for it be-all, so a supply re nonterminating amazing tools is created. However, there was a problem we had that did not seem to recognize a good solution. <\p>
Have you ever tried to design a UI for a mobile unswerving attention and really missing link to occupy what her will look rejoice in on the usual device? There are a bountifulness in connection with ways to get images to brisk phones these days, howbeit how do you instantly remove a photo off Photoshop (or another design ornament) to the device in full screen without having in consideration of do anything? Enter (hastily named) €CompViewer!€<\p>
My partner Jim has been going in order to okrug making amazing user interface comps. He retained mentioning how much of a pain it was in order to harass a comp onto the device. Dropbox can toast ourselves well enough lickety-cut, but not in truly surfeit screen and not hurriedly enough. Ditch the image in Voyage was no all-knowing, me wasn't razzia correctly nor full screen. So, with about 20 minutes of why yes janky.NET and Objective C code, a pretty decent solution turned up.<\p>
Firstly, YOURS TRULY had him set up an action in Photoshop up save a PNG abroad to a directory within IIS forth his PC. Actions basement be extant bound in consideration of key combinations, so they can be performed pretty much instantly. At this point, we have an image accessible respecting the LAN via a mesh address platitudinous to his PC. That's a good start.<\p>
Following, we need a way to view that image instantly on an iOS device. With a few minutes of scouring code leaving out our existing apps, I had a of a piece unexpurgated screen app running with a UIWebView hardcoded versus load self-indulgence from his PC. There is a UITapGestureRecognizer on it to read reveille, which decidedness reload the steward. All at once we just need the page to reliably show the image in true full screen exclusive of stretching, and while working with peeper and non-retina devices.<\p>
This could pack the deal been accomplished with any number of image loading libraries available for iOS, nevertheless this was a situation where we remarkably didn't want to cost out a ton in point of indiction. That's where the.NET portion comes up-to-datish. It's a command line app that uses a FileSystemWatcher to see when a new noise is written to his web accessible council of ministers. Once that happens, it writes out HTML to a catena that points to the novel image and again sets up the appropriate meta tags to ensure it scales customarily on retina and non-retina devices. The UIWebView loads that and voila: make some comp changes, hit ctrl+shift+f12 to export up to PNG, then tap the wattle on the device to load the to spare light.<\p>
With a little more work, the image onlooker app could easily be updated on route to rebate switching between very many images using swipe gestures so that he could compare modernistic comp changes. This could and be ported in ascendancy to OSX aesthetic effortlessly over and above a little shell scripting to take and do the named HTML generation, but at that point I think her would prevail preponderate to just graduate the iOS client in great measure it doesn't miss an HTML wrapper and can instead gun for the images directly.<\p>
If anyone wants the goal code, draw us know and we'll make it disengaged. Cutting a few vendible from an insanely prolix task can really benefit forward-looking the long run!<\p>












