forked from http://git.code.sf.net/p/elphel/jp4-tools