Mindwarm Logo

admin

 

Here are some sample photos from my new Holga Digital camera (downsized to fit on the blog page).

 

 

Last year I backed the Holga Digital project on Kickstarter.  Here’s my unboxing of my Holga Artist kit with the photos taken by my Samsung Galaxy S5 smartphone.

1. Bubble-wrapped box removed from plastic envelope.

 

 

 

 

 

 

2. Opening the box reveals all the goodies.

 

 

 

 

 

 

 

 

 

 

 

3. Flash, two lenses, camera strap, book, postcards and of course multi-colored Holga Digital camera.

 

 

 

 

 

 

 

4. Batteries not included, you will need two AA batteries.

 

 

 

 

 

 

5. Insert the batteries like so.

 

 

 

 

 

 

6. Close the battery cover.

 

 

 

 

 

 

7. Get the oldest SDcard you have, insert it, then turn on the Holga.

 

8

 

 

 

 

Next blog post will include Holga photos!

 

Mobile World

 

 

 

Mindwarm now has 133 apps in app stores.  Here is the tally:

30 Google Play Store apps
23 iTunes iOS apps
54 Amazon apps
26 Barnes and Noble Nook apps

Check them out at their respective app stores:

 

 

 

Available on the App Store

 

 

 

 

 

 

 

 

 

 

 

OTTO camera

 

 

 

 

 

 

 

 

 

 

 

 

 

Back in April 2014 I backed a Kickstarter projected called “Meet OTTO – The Hackable GIF Camera” and finally last month THEY DELIVERED.

The idea was for a camera that takes photos, one frame at a time, and makes animated GIF files as its output.  The camera itself came in a fantastic blue case.

Camera and its Case

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

So now it’s onto the path of creativity!

What this Kickstarter project shows is how with small Arduino-style technology, the world of gadgets is within your grasp.  Here’s a small figure from Archie McPhee’s in Seattle turning around:

Not Godzilla but kind of a facsimile

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

The key to using OTTO is to get your creative juices flowing, even in ordinary situations.  This kind of product is new, fun, creative and a sign of what is to come by distributing computing elements in all kinds of things.

 

 

 

 

What will and won’t happen in mobile technology for the year 2015?  Our friends at PDXmobile have figured out what will happen and won’t happen in 2015.  Don’t you want to know the future?

 


Is Amazon CEO Jeff Bezos an angel?  Certainly Hachette Book Group considers him the devil.  PDXmobile has an interesting take in this battle of publisher vs. e-book distributor.  You can read it here.

 

Open Source Bridge

 

 

 

After a great conference experience at Open Source Bridge 2014 I began to scratch my head at exactly what was it I learned?

I don’t mean about how natural and wonderful tolerance and diversity feels, as it is well-practiced at OSB, or how great it is to assemble with technical people with inquisitive minds.  I mean what did I get out of the talks themselves?  So I decided to write this post based on my  notes, to remember what I learned and already knew, kind of like the Scarecrow in the Wizard of Oz when Oz hands him a diploma and he realizes he was a deep thinker all along.

I’m going to avoid mentioning the speaker’s names since I want to keep the emphasis on ideas, but if you want more information about any of these talks check out the sessions or session schedule at OpenSourceBridge.

 

1. Opening Keynote:  Battling Invisible Monsters in Tech

This was a talk mostly about Impostor Syndrome where a person has high actual ability, but a low self-perception of their own ability.  For me the interesting contrast was with Dunning-Kruger Effect where the traits are reversed, namely a person has high self-perceived ability and low actual ability.  Somehow this effect reminds me of management.

People with Impostor Syndrome tend to push themselves too hard, take on too much and burn out.

Some useful social rules were cribbed from (and attributed to) the Hacker’s School User Manual:

  1. No feigning surprise.
  2. No “well-actually’s”.
  3. No backseat driving.
  4. No subtle sexism, racism, homophobia, etc.
Don’t break other people’s hearts by putting yourself down.
Bottom line: “Fake it ’til you make it.”
“The secret of life is pretending you know what you’re doing.”
Very nice opening talk about some of the social issues we all face as workers, but especially technical workers.

2. Working Effectively with People in Government on Open Source Projects

Government people are smart and well-meaning.  There are two basic types of employees: appointees and classified employees.

Appointees

  • Serve at the pleasure of an elected official.
  • Typically are in leadership positions like heads of department.
  • Have more leeway in the work they choose to pursue.
  • Generally see “opportunities” for project.
Classified Employees
  • “Front-line” of the government.
  • Tend to stay longer than appointees.
  • Well-defined positions, on career track.
  • Less likely to get onboard a project quickly, see the “risks” in project.
  • Have out-lasted many policy initiatives.
  • Offer staying power if you get engaged with them.
People are less willing to take risks during elections such as approving new projects, adding new collaborators.  People are also less willing to take risks near the end of an administration as their term winds down.  However at the start of a new administration the opposite holds, it’s easier for a newcomer to get a project.
Budgets will tell you about priorities.  Budgets are where the money is, procurement and purchasing is the checkbook.
Operations and sustainability about the project are key.  Who will run the project after you go?  Government employees can’t maintain it.  Who’s responsible for security and privacy?
This was an insightful look at the motivations and rhythms of how our government works.

3. Power Tuning Linux: A Case Study

This was a discussion of powertop, a tool that assists you in managing your power consumption on Linux systems.

Overall power consumption for laptops is generally 81% for the screen, 8% for the CPU.  The rest is a long tail of other slivers of power consumption.

C-State = state processor uses to be idle.  You want to spend more time in the highest C-State, the higher the better.   Stay out of using C0, the lowest and most power-consuming C-State.

“powertop –auto-tune” will always tune your system for power.  It can be dangerous if device drivers don’t support being managed for power.  Ubuntu-certified devices work well for being power-tuned.

 

4. Get More Contributors!  Lessons from the Drupal Ladder

This talk was about the experience of the Drupal Ladder in improving contributions to your open source project.

The Drupal Ladder is a hierarchy of steps, how users can move up the ladder.  Essentially it’s a series of HOWTOs people can use by themselves.  These HOWTOs start very simple and build on each other.

For generating interest and starting a meeting:

  1. See what’s already been done.
  2. Organize something, doesn’t need to be the greatest — it will improve.
  3. Recruit, recruit, recruit.
For your meeting, be welcoming and avoid jargon.  No matter how many events you’ve had anticipate users who have not attended recently.
  • Be responsive.
  • Be the nicest guy in the room.
  • Make it a positive experience for everyone.
  • Use explicit invitations.
Start building institutional memory right away, plan for the day you (the organizer) will be gone.
Don’t reinvent the outreach wheel, use the groups you know for outreach.
This was a good talk on techniques to make for successful meetings designed to empower users to contribute to your open source project.

5. OAuth, IndieAuth and the Future of Authorization APIs

Earlier apps forced users to disclose their username and password, so Twitter and Flickr developed and implemented OAuth 1.0 to circumvent this problem.  Most providers implement OAuth 2.0 now.

Twitter allowed other apps to post to their site.  Quill is a text posting app that posts to your website if your site supports some things.  Taproot is another.

For IndieAuth the idea was to reinvent as little as possible, uses HTTPS, easier than cryptography.  OAuth 2.0 works on HTTPS and dropped having its own crypto from OAuth).  Servers understand HTML forms so use HTML and form-encoded data for content (vs. choosing JSON or XML).  Represent users by a URL.  Apps are also represented by a URL.  Problem with this scenario is that native apps (e.g. on smartphones) would also need some sort of public URL, even if it was a unique “About app” URL.

IndieAuth = OAuth 2.0 + Web Identity Layer (as described above)

Micropub is a vocabulary for creating and editing posts based on Microformats 2 vocabulary.  IndieAuth uses authentication by OAuth 2.0 bearer tokens and form-encoded requests.  The Micropub endpoint typically lives within your website or CMS (content management system).

Advantage is that all servers-side environments already support form-encoded requests.  Disadvantage is that every user now has to have a website (URL).

 

6. A Few Python Tips

PIP = Python Package Index.

User the package manager “pip”.  To see what’s installed use “pip freeze”.

Python 3 came out in 2008, but default on most systems is still Python 2.

My Macbook AIR with OSX 10.9 (Mavericks) has Python 2.7.5.

Control-L eliminates the line from the command history in the interpreter and clears the line.

ipython is an interpreter that lets you generate notebooks of your command output.

bpython is an interpreter that has tab autocomplete and shows you command options you have as you type.

Control-r in bpython replays all your previous commands.

dir() shows you the strings in a global namespace (known to python code you entered — introspection).

python -i foo.py  (lets you debug script in an interactive session)

pdb.set_trace() — places you into python debugger where you can step through lines with “s” for step or “c” for continue.

bpython auto-indents for you (python is whitespace-sensitive).

In Python 3 all strings are unicode while in Python 2 strings are UTF8.

 

7. How to make generics in C:  An adventure in sorting

Open source library code is at https://github.com/swenson/sort

Sorting consists of two things: (1) compare two entries and (2) swap two entries.

Cleverness is knowing the order of comparing things (e.g. how good the sort is).

In C use the concatenation operator ## to make generics out of a series of #define macros.  This mechanism effectively lets you reimplement C++ function templates in C.

The sort.h file (from github) is designed for speed, not for debugging — no special debug version.  No library, just use the sort.h header file in your projects.

 

8. OpenStreetWhat?  Mapping the World with Open Data

OpenStreetMap was founded in 2004 and is the “Wikipedia for Maps”.  OpenStreetMap is not just maps, but also the data.

www.openstreetmap.org

Foursquare, Craigslist, Flickr all use OpenStreetMap data.

Data is stored at openstreetmap.org/wiki/servers

ODbL license for data = fine to copy, distribute, transmit and adapt, but requires attribution when used.

(c) OpenStreetMap contributors

Data comes out at openstreetmap.org/wiki/planet.osm in PBF binary format (XML also).

The XML = 400 Gigabytes = whole world of data, weighty data.  Extracts are more useful than the whole huge pile.

Web tools:  openstreetmap.org uses ID editor and JOSM (another editor).

These web tools edit the map data.  There are also mobile editors for iOS (pushpin) and Android (Vespucci).

OSM = OpenStreetMap

OSM data consists of nodes, ways and relations.

Nodes = points in space.

Ways = collection of two or more points together (e.g. can collect into a polygon to represent a building).

Relations = group ways into higher level (e.g. a National Park that is multiple physical areas).

Notes = Communication to other contributors about issues at location note is left at.

OSM data is meant for here and now, no historical dating per se, just date when data “checked-in”.

OpenFantasyMap uses same tech to make a virtual world.

Using OSM data:  Get it, Use it, Attribute it.

Leaflet = open source JavaScript plugin for displaying OSM data.

Mapbox.js = JavaScript plug-in based on Leaflet.

overpass-turbo.eu = live query of OSM data, gets data returned as GeoJSON).

Local meetup Maptime PDX event hosted at Esri has all levels of experience.

 

9. The Keys to Working Remotely

Communication tools: basecamp, skype, evernote, google docs, group chat

Designers:  Dropbox, Invision app

Developers:  Github, JSFiddle, CodePen

Pros: Flexible hours, removal of distractions = productivity

Overcommunicate:

  • Do something and tell everyone.
  • Send out weekly updates.
  • Announce milestone achievements.
  • Ask for feedback.
  • Be available during work hours.
Have a routine to help you get started working and to know when to stop.

10. Make your wireless router route (or anything else) the way you want it to, with OpenWrt

OpenWrt = Build system and Linux distro

Look at OpenWrt to see list of supported devices.

Atheros radio or Raylink radio best, avoid Broadcom devices because Broadcom device drivers limited.

Can be used for data loggers, hack your router, put it in the field in a bucket and manage something remotely over WiFi (pull out data, etc.).

OpenWrt differs from ddwrt purpose.  OpenWrt is for when you want to shoehorn in your own code to do something custom.

OpenWrt is a set of makefiles based on buildroot system for embedded stuff = a set of core packages and feeds (package makefiles).

OpenWrt uses makefiles (not python or bake like OpenEmbedded Linux distros).

git clone -l /home/build/openwrt-prebaked openwrt

Atheros radio will be the default if you don’t have a .config

Generic = NOR flash memory.

Netgear WNDR3800 has 128 meg RAM, end-of-lifed in 2013.  Good choice to hack.

UCI = way of storing configuration information.

Try to back up the device image since there is data unique to each device radio (in SOC flash memory) for tuning parameters for the specific chip in the specific device.  You can overwrite these (inadvertantly) when you flash an image.

/etc/uci-defaults = scripts meant to run once, then delete themselves, usually after a package install.

Use a serial console cable (can use it for bootloader console and can solve most problems with this).

At Frye’s look at router model number and serial number.  Check OpenWrt wiki to see if supported.

 

11. Modern Home Automation

History.

X10

  • 1978
  • Originally from Italy.
  • Named after the 10th interation of project.
  • 4 bit house code (A-P) allowed 16 total devices.
  • 4 bit unit code per device.
  • 4 bit instruction — turn EVERYTHING on or off.
  • Unreliable, 70% to 80% success rate, 750 milliseconds transmit time = slow
  • Limited number of units you can attach.
European X10 = KNX = industrial, tries to be all things to all people, not device interoperable, expensive.
Insteon
  • 2003
  • powerline X10 stuff and wireless
  • moderately expensive
  • software isn’t mature
ZWave
  • from GE – General Electric
  • robust software support
  • wireless only
  • open standard based on Zigbee
  • BEST TO DATE
Commercial solutions:  Nest
  • $260
  • Tracks when you set controls & assumed you’re away unless its motion sensor detects you.
  • “learns”
  • pretty graphs online for power usage
  • Shiny API
Commercial solutions:  Philips Hue
  • wireless lighting station + lights
  • $200
  • Simple API
  • mobile interface control
Long-term solution: Ambient Web
  • Hardware = baked image, all identical
  • connects to WiFi/wired network
  • register with a central server
  • all Javascript interface
  • Mozilla side project
  • Domotiga = Raspberry Pi software image at http://domotiga.nl

12. Introduction to Scala

Object-oriented meets functional.

Runs on JVM.

Not as pure as a pure functional language.

First released in 2004.

Java interoperability

  • Scala classes can use Java classes.
  • Java classes can use Scala classes.
  • Everything you can do in Java, you can do in Scala.
Scala is used where scalability really matters.
Scala is statically-typed and can infer type from usage of the “new” operator.
Scala classes are public by default and minimize boilerplate code by automatically adding accessors, private var declaration and assignment in constructor.
Scala encourages immutability by the declaration keyword “val” which is similar to the keyword “final” in Java, but while “final” modifies a type (e.g. final int), val does not declare a type, Scala infers the type.
In Scala collections are immutable by default.  In Java collections are mutable by default.
No primitive types in Scala (e.g. no int).
Last statement in a method is the return value.
Accessor methods typically don’t have parenthesis.
Traits: Like mixens in Javascript or interfaces in Java, but can have implementation (unlike Java).  Traits also support multiple inheritance.
Scala more tersely expresses algorithms than Java.  Speaker’s experience was that equivalent Scala code was at least half the length of Java source code.

13. The 20,000 km View: How GPS works

GPS is purely passive, it can’t track you.  It gives you latitude, longitude and time.

Trilateration

  • satellites tell you how far you are from them
  • intersection of distances from multiple GPS satellites lets you figure your location
  • satellites transmit time, but speed of light delay tells you how far away it is
  • satellites travel at 14,000 km/hr
Nearest GPS satellite is 20,000 km straight up (half circumference of earth)
500 watts = power transmitter of GPS satellite, loses 18 orders of magnitude coming to earth
Direct Sequence Spread Spectrum
  • Frequency = 1.575 GHz
  • uses random spreading code
  • spread “power” out over a range of frequencies
  • similar to CDMA-encoding for mobile voice devices
US military “anti-spoofing” mode uses a secret spreading code (to prevent jamming of US military GPS).
1707 English navy disaster (Scilly) produces the 1714 Longitude prize solved by John Harrison by having a chronometer (clock) on each vessel.  So there is a military influence on positioning information.
Loran-A system in 1940.
Cyclan system in 1946.
Cytac system in 1952.
Loran-C system shut down in 2010.
Ground-based transmitters used for Loran (300 meter tall towers).
Dual-frequency for correcting ionosphere error.
Global clock sync.
1973 Pentagon thinks up GPS.
1984 to 1994 satellites launched for GPS.
1995 GPS system operational.
Initially GPS had a degraded civilian accuracy, but this was turned off in 2000.  The accuracy increased from 100 meters to 20 meter accuracy now.
GPS modernization ongoing now.  New satellites to support this will launch soon.
Other nations have GNSS systems:
  • Russia: GLONASS
  • Europe: Galileo
  • China: Compass
US military receivers are still more accurate than civilian.
The ionosphere (85 km – 600 km) delay is affected by solar wind.
This effect is frequency dependent so can use two frequencies to cancel out this problem.
L1 civilian signal = 1.575 GHz
L2 military signal = 1.227 GHz
For GPS modernization additional signals will be added, L2C & L5 for civilian.
Wide Area Augmentation System — WAAS
Measure the ionosphere delays from known location, then broadcast corrections from satellites.
Data layer
  • navigation message
  • 50 bit per second signal
  • 30 seconds to send one complete frame of GPS navigation message
GPS provider almanac
  • approximate orbital parameters for all satellites
  • 12.5 minutes to acquire (cold start)
  • now find all visible satellites in one-tenth second (using FFT on signals trying all satellite signals to see if there)
Ephemeris
  • detailed satellite orbital info
  • sent every 30 seconds
  • 18 to 48 seconds to acquire (warm start)
Hot Start
  • current ephemeris
  • accurate time
  • takes less than one second to lock to position
Assisted GPS
  • phone gets current ephemeris from Internet and good time from network
  • phones also get approximate location from cell towers
  • so phones can do a hot start
Ephemeris are a best-guess forecast, updated orbit info once per week.
Surveying
  • want accurate answer
  • receivers record data over 24 hours
  • look at where satellites actually were (from once a week updates)
  • so figure out location based on acquired data and known satellite path
GPS hardware is the worst kind of proprietary, although GPS itself is well documented by the government.
There are homebrew GPS receivers (FPGA and Raspberry Pi even).

14. Modernizing a Stagnant Toolbox

http://make.wordpress.org

WordPress started in 2003 using tools:

  • make
  • ant
  • jslint
2013 WordPress built using tools:
  • Grunt
  • Phing (task config in PHP)
  • JSHint
  • JSValidate
  • PHPUnit
Goals of tool revamp:
  • non-breaking code
  • more tools beyond the JavaScript beautification and CSS beautification running
  • more testing (unit tests)
  • more transparency
  • easy to develop
  • easy to contribute
Now every commit runs a build and pushes it to core.svn
develop.svn has “the new happy” unit tests, etc.
Grunt
  • overarching tool
  • task runner
  • older, but more stable (gulp is newer, but less stable)
  • has big community
  • has lots of modules
jshint tool used to validate JavaScript
wp-cli = command-line running of various WordPress functions.
WordPress supports PHP 5.2 forward.  (PHP 5.6 not released yet.)
Chose QUnit for JavaScript unit tests, closest to syntax of PHPUnit which was already in place.
Be sure to have goals as you change and adjust toolset for project.
Philosophies about project will guide your goals.

15. Airplanes:Sailboats::Mobile:Desktop

We didn’t understand sailboats and sailing until we invented airplanes and could understand the airflow around a wing.

So now we can understand the desktop because we have mobile devices.

We are now looking at the desktop through the lens of mobile.

Responsive design is of paramount importance for dealing with different screen sizes.

 

16. Grokking Git

Three keys to grokking git

  • nodes and labels
  • workflows
  • commands
“git gets easier once you get the basic idea that branches are homeomorphic endofunctors mapping submanifolds of a Hilbert space.” — Joke.
Git is graph manipulation commands for creating and deleting nodes and moving pointers around.
Git is a 2 trick pony: making nodes and sticking labels on them.
Git is a “graph” database, a tree structure with nodes, a directed graph database.
Each node in database is a set of changes (diffs).
Each node gets a unique SHA-1 hash code.
Every check-in creates a new node and moves a label to it.
Fast-forward: move master label to (end) branch label because no intervening changes made.
Rebasing: moving master from where it is to a branch.
Essential git commands:  status, log, init, clone, branch, checkout, add, commit, merge, rebase, push, pull

 

 

How do you solve the problem of turning off a device that has no on/off button?  This is something that PDXmobile wrestled with and pinned down.  Check out their blog post here.

 

 
No matter what human pyramid you’re sitting on, there is always heat below.  Former Mozilla CEO Brendan Eich certainly found that out — and fast.  Read what our friend at PDXmobile had to say about it.

 

Uncensored by Amazon, Barnes and Noble and Google, the Mobile Tech Report 2014 is now available for your Kindle, Nook and Android devices.  Of course Apple rejected it since it actually mentioned other technology providers besides Apple.  There’s no tolerance for other technology in the iOS walled garden.  On the other hand if you have a non-Apple e-Reader, then you can see what they don’t want to.

© 2012 Mindwarm Incorporated Suffusion theme by Sayontan Sinha