How to make UAVs more socially acceptable

Supa Sympa

Most people are scared of things falling out of the sky, understandably, and we don’t generally like being spied on. So UAVs, or drones as the media likes to refer to them, equipped with cameras are easy targets when it comes to negative press and scare tactics. The almost overnight increase in press interest in drones, in the UK (and Europe?), started in mid October 2014 when a drone was used to fly a flag over the Serbia vs Albania Euro 2016 qualifier, starting mass brawls and chair throwing! This has prompted several examples of similar stories:

View original post 660 more words

Premier league kit colours css 2014/15

Spent some time working on a Premier League visualisation today and couldn’t find any kit colours for this year so here is one I created, for home kits. Fill being primary colour and stroke being secondary.

.arsenal {
 fill: rgba(202, 31, 31, 1);
 stroke: #eee;
 }

 .aston-villa {
 fill: rgba(176, 30, 71, 1);
 stroke: rgba(107, 141, 169, 1);
 }

 .burnley {
 fill: rgba(127, 38, 44, 1);
 stroke: rgba(139, 185, 198, 1);
 }

 .chelsea {
 fill: rgba(67, 84, 182, 1);
 stroke: #eee;
 }

 .crystal-palace {
 fill: rgba(252, 1, 46, 1);
 stroke: rgba(0, 108, 199, 1);
 }

 .everton {
 fill: rgba(18, 78, 148, 1);
 stroke: rgba(17, 51, 78, 1);
 }

 .hull-city {
 fill: rgba(246, 134, 30, 1);
 stroke: #000;
 }

 .leicester-city {
 fill: rgba(41, 82, 186, 1);
 stroke: rgba(33, 32, 31, 1);
 }

 .liverpool {
 fill: rgba(219, 0, 39, 1);
 stroke: #eee;
 }

 .manchester-city {
 fill: rgba(178, 208, 234, 1);
 stroke: rgba(36, 35, 49, 1);
 }

 .manchester-united {
 fill: rgba(190, 19, 55, 1);
 stroke: #eee;
 }

 .newcastle-united {
 fill: #eee;
 stroke: #000;
 }

 .queens-park-rangers {
 fill: #eee;
 stroke: rgba(33, 126, 196, 1);
 }

 .southampton {
 fill: rgba(197, 44, 61, 1);
 stroke: #eee;
 }

 .stoke-city {
 fill: rgba(213, 0, 38, 1);
 stroke: #eee;
 }

 .sunderland {
 fill: rgba(248, 50, 67, 1);
 stroke: #eee;
 }

 .swansea-city {
 fill: #eee;
 stroke: rgba(54, 54, 64, 1);
 }

 .tottenham-hotspur {
 fill: #eee;
 stroke: rgba(29, 38, 67, 1);
 }

 .west-bromwich-albion {
 fill: #eee;
 stroke: rgba(29, 38, 67, 1);
 }

 .west-ham-united {
 fill: rgba(99, 18, 43, 1);
 stroke: rgba(144, 210, 241, 1);
 }

Why the iWatch could make all Apple’s existing devices more exciting!

wwdc2013

After the date announcement of WWDC13 and the potential announcement of an iWatch (I believe the roman numerals are an almsot tagged on give-away)  I had  a discussion with some colleagues about the potential for this new device, both were unconvinced of the need or point of it. Based on what they were saying, I agreed: “a watch is something personal, why would I want something everyone else is wearing?”, “I just don’t see why you’d need another device when you already have an iPhone or an iPad”, “the screen will be too small”. etc

The thing is, I don’t think that an iWatch will be any of the things that they said.

If you watch any of the new Samsung Smart TV commercials,  read  about Google Glass or look at the Leap Motion, I think Apple could be about to do, again,  what it did with the iPhone, and steal the thunder of all it’s competitors, this time with wearable technology.

As a small device with a small screen, little storage capacity and little processing power the iWatch does seem quite pointless, aside from as nice niche market for Apple to get into. As a device that augments a laptop, mobile or  a potential new Apple TV device (or the existing one for that matter), it could be a real winner. With any of: a precision accelerometer, proximity sensors, bluetooth / wireless connectivity, GPS, Siri and NFC, this device could open up a whole world of possibilities for app developers of iWatch connected devices.

Currently the XBox Kinect, Playstation Play, Wii / Wii U, Samsung Smart TV and soon to be  released Leap Motion all use devices that allow users to interact through movement. Apple will follow suit with their interpretation of natural interface controllers at some point, why wouldn’t they do it with an iWatch?

Firefox sluggish / jittering jquery (or css3?) animation

I had a browser based problem with Firefox yesterday where my animation wasn’t running smoothly, even the latest version, but it was running fine in Chrome and Safari.

I searched online for a bit but didn’t find a solution. I was, at the same time, trying to remove the dotted line that’s displayed when clicking a link in Firefox.

After some trial and error it turne out both things were solved by the same thing.

Solution:
In css add:

a:focus{
 outline:none;
 }

FIXED!

Web Developers vs Programmers

I recently had a discussion on Twitter with someone who I had respect for in the web community. He was arguing about the term UX developer having a negative effect on his part of the industry. I argued that the term developer is pretty generic, it simply implies that someone is developing something.

I then read an article about lazy programmers being the best programmers, a view I’ve agreed with for a long time and had the luck to observe on many occasions first hand.

The absence of the word Developer from the  article and the missinterpretation of the term by the chap I had the (argument) discussion with niggles me slightly and prompted me to write this reply:

http://www.jacobsingh.name/comment/10576#comment-10576

In my humble opinion:

A web developer helps develop things that make up part of the web, their job should be about configuration to deliver good presentation and functionality – minimal configuration of a programmers code. Their skill-set is usually quite broad and they probably have knowledge of a few web frameworks like WordPress, some of their skills might be programming, others are likely to be using photoshop or scripting (html etc), understanding network latency, security implications, accessibility etc

A programmer (lets say a web programmer) has an in depth knowledge about one or many languages and understands how application architecture fits together, to solve specific problems. They understand the intricacies of writing code and how it affects ‘the machine’, design patterns and when and why they should be used, if at all. They can craft their code efficiently and make it robust and understand how it needs to be tested and evolved. Their code should be the tools that the web developer integrates and utilises and ultimately configures.

I realise that in a lot of cases these are the same person – I just think our industry could do well to recognise the difference a little more often especially with all the good open source software programmers are producing these days!

 

Class and Object definitions in JavaScript

A developer friend of mine emailed me with a question about Classes in Javascript:

Don’t suppose you have any literature or anything I can look at in regards to the correct structure for a javascript class (in node.js)?
I have looked all over the shop and found various different ways of doing it but am having problems.

My emailed response

Classes don’t exist in Javascript (yet), at least not natively. There is some work on EcmaScript / JavaScript.next that suggests they might but, in short:

Javascript is lexically scoped and functions are ‘1st class objects’.

You can declare and instantiate objects in many ways but the most familiar might be  like this:

function foo(bar){
    this.bar = bar;
}

var myFoo = new foo('oh hi there');
alert(myFoo.bar);

Where you’d normally use the term ‘class’, it’s implied in Javascript, as above for example,  but not explicit. There are also many different ways to approach this. Javascript does not support access levels (private, public, protected etc) natively, so you have to follow a coding style that will have the same effect.

There  many different patterns you can use, but different patterns work well for different problems and you don’t always want to use the classical (class based) style, you can do things differently in Javascript and utilise the flexibility of the language to your advantage.

Some things worth reading about:

Read mostly everything Douglas Crockford writes: (and get his book on Javascript – The good parts). Although I disagree with some things he says about coding style, it’s all relevant even though it was written a while ago.

http://www.crockford.com/

Learn these

Prototypal Inheritance

http://javascript.crockford.com/prototypal.html

 Javascript scope

http://coding.smashingmagazine.com/2009/08/01/what-you-need-to-know-about-javascript-scope/

Javascript closures

http://blog.morrisjohns.com/javascript_closures_for_dummies

Object Literals

http://www.dyn-web.com/tutorials/obj_lit.php

Currying

http://www.dustindiaz.com/javascript-curry/

Module pattern

http://www.adequatelygood.com/2010/3/JavaScript-Module-Pattern-In-Depth

That should be enough to get you started!