Branching off commit c863188c095286ac8ce04a3074db92451dea59ed by @grantnorwood for later developments, reverting to earlier commit for release.

Signed-off-by: Måns Jonasson <mans.jonasson@iis.se>