]> pere.pagekite.me Git - homepage.git/blobdiff - blog/archive/2016/03/index.html
Generated.
[homepage.git] / blog / archive / 2016 / 03 / index.html
index 75d9441722cfd956407c995237077e01ece43295..f27fb43773722b664c958d8b4585d5380e6b4b9b 100644 (file)
 
     <h3>Entries from March 2016.</h3>
     
 
     <h3>Entries from March 2016.</h3>
     
+    <div class="entry">
+      <div class="title">
+        <a href="http://people.skolelinux.org/pere/blog/Full_battery_stats_collector_is_now_available_in_Debian.html">Full battery stats collector is now available in Debian</a>
+      </div>
+      <div class="date">
+        23rd March 2016
+      </div>
+      <div class="body">
+        <p>Since this morning, the battery-stats package in Debian include an
+extended collector that will collect the complete battery history for
+later processing and graphing.  The original collector store the
+battery level as percentage of last full level, while the new
+collector also record battery vendor, model, serial number, design
+full level, last full level and current battery level.  This make it
+possible to predict the lifetime of the battery as well as visualise
+the energy flow when the battery is charging or discharging.</p>
+
+<p>The new tools are available in <tt>/usr/share/battery-stats/</tt>
+in the version 0.5.1 package in unstable.  Get the new battery level graph
+and lifetime prediction by running:
+
+<p><pre>
+/usr/share/battery-stats/battery-stats-graph /var/log/battery-stats.csv
+</pre></p>
+
+<p>Or select the 'Battery Level Graph' from your application menu.</p>
+
+<p>The flow in/out of the battery can be seen by running (no menu
+entry yet):</p>
+
+<p><pre>
+/usr/share/battery-stats/battery-stats-graph-flow
+</pre></p>
+
+<p>I'm not quite happy with the way the data is visualised, at least
+when there are few data points.  The graphs look a bit better with a
+few years of data.</p>
+
+<p>A while back one important feature I use in the battery stats
+collector broke in Debian.  The scripts in
+<tt>/usr/lib/pm-utils/power.d/</tt> were no longer executed.  I
+suspect it happened when Jessie started using systemd, but I do not
+know.  The issue is reported as
+<a href="https://bugs.debian.org/818649">bug #818649</a> against
+pm-utils.  I managed to work around it by adding an udev rule to call
+the collector script every time the power connector is connected and
+disconnected.  With this fix in place it was finally time to make a
+new release of the package, and get it into Debian.</p>
+
+<p>If you are interested in how your laptop battery is doing, please
+check out the
+<a href="https://tracker.debian.org/pkg/battery-stats">battery-stats</a>
+in Debian unstable, or rebuild it on Jessie to get it working on
+Debian stable. :) The upstream source is available from
+<a href="https://github.com/petterreinholdtsen/battery-stats">github</a>.
+As always, patches are very welcome.</p>
+
+      </div>
+      <div class="tags">
+        
+        
+        Tags: <a href="http://people.skolelinux.org/pere/blog/tags/debian">debian</a>, <a href="http://people.skolelinux.org/pere/blog/tags/english">english</a>.
+        
+        
+      </div>
+    </div>
+    <div class="padding"></div>
+    
+    <div class="entry">
+      <div class="title">
+        <a href="http://people.skolelinux.org/pere/blog/UsingQR____Electronic__paper_invoices_using_JSON_and_QR_codes.html">UsingQR - "Electronic" paper invoices using JSON and QR codes</a>
+      </div>
+      <div class="date">
+        19th March 2016
+      </div>
+      <div class="body">
+        <p>Back in 2013 I proposed
+<a href="http://people.skolelinux.org/pere/blog/_Electronic__paper_invoices___using_vCard_in_a_QR_code.html">a
+way to make paper and PDF invoices easier to process electronically by
+adding a QR code with the key information about the invoice</a>.  I
+suggested using vCard field definition, to get some standard format
+for name and address, but any format would work.  I did not do
+anything about the proposal, but hoped someone one day would make
+something like it.  It would make it possible to efficiently send
+machine readable invoices directly between seller and buyer.</p>
+
+<p>This was the background when I came across a proposal and
+specification from the web based accounting and invoicing supplier
+<a href="http://www.visma.com/">Visma</a> in Sweden called
+<a href="http://usingqr.com/">UsingQR</a>.  Their PDF invoices contain
+a QR code with the key information of the invoice in JSON format.
+This is the typical content of a QR code following the UsingQR
+specification (based on a real world example, some numbers replaced to
+get a more bogus entry).  I've reformatted the JSON to make it easier
+to read.  Normally this is all on one long line:</p>
+
+<p><img src="http://people.skolelinux.org/pere/blog/images/2016-03-19-qr-invoice.png" align="right"><pre>
+{
+ "vh":500.00,
+ "vm":0,
+ "vl":0,
+ "uqr":1,
+ "tp":1,
+ "nme":"Din Leverandør",
+ "cc":"NO",
+ "cid":"997912345 MVA",
+ "iref":"12300001",
+ "idt":"20151022",
+ "ddt":"20151105",
+ "due":2500.0000,
+ "cur":"NOK",
+ "pt":"BBAN",
+ "acc":"17202612345",
+ "bc":"BIENNOK1",
+ "adr":"0313 OSLO"
+}
+</pre></p>
+
+</p>The interpretation of the fields can be found in the
+<a href="http://usingqr.com/wp-content/uploads/2014/06/UsingQR_specification1.pdf">format
+specification</a> (revision 2 from june 2014).  The format seem to
+have most of the information needed to handle accounting and payment
+of invoices, at least the fields I have needed so far here in
+Norway.</p>
+
+<p>Unfortunately, the site and document do not mention anything about
+the patent, trademark and copyright status of the format and the
+specification.  Because of this, I asked the people behind it back in
+November to clarify.  Ann-Christine Savlid (ann-christine.savlid (at)
+visma.com) replied that Visma had not applied for patent or trademark
+protection for this format, and that there were no copyright based
+usage limitations for the format.  I urged her to make sure this was
+explicitly written on the web pages and in the specification, but
+unfortunately this has not happened yet.  So I guess if there is
+submarine patents, hidden trademarks or a will to sue for copyright
+infringements, those starting to use the UsingQR format might be at
+risk, but if this happen there is some legal defense in the fact that
+the people behind the format claimed it was safe to do so.  At least
+with patents, there is always
+<a href="http://www.paperspecs.com/paper-news/beware-the-qr-code-patent-trap/">a
+chance of getting sued...</a></p>
+
+<p>I also asked if they planned to maintain the format in an
+independent standard organization to give others more confidence that
+they would participate in the standardization process on equal terms
+with Visma, but they had no immediate plans for this.  Their plan was
+to work with banks to try to get more users of the format, and
+evaluate the way forward if the format proved to be popular.  I hope
+they conclude that using an open standard organisation like
+<a href="http://www.ietf.org/">IETF</a> is the correct place to
+maintain such specification.</p>
+
+<p><strong>Update 2016-03-20</strong>: Via Twitter I became aware of
+<a href="https://news.ycombinator.com/item?id=11319492">some comments
+about this blog post</a> that had several useful links and references to
+similar systems.  In the Czech republic, the Czech Banking Association
+standard #26, with short name SPAYD, uses QR codes with payment
+information.  More information is available from the Wikipedia page on
+<a href="https://en.wikipedia.org/wiki/Short_Payment_Descriptor">Short
+Payment Descriptor</a>.  And in Germany, there is a system named
+<a href="http://www.bezahlcode.de/">BezahlCode</a>,
+(<a href="http://www.bezahlcode.de/wp-content/uploads/BezahlCode_TechDok.pdf">specification
+v1.8 2013-12-05 available as PDF</a>), which uses QR codes with
+URL-like formatting using "bank:" as the URI schema/protocol to
+provide the payment information.  There is also the
+<a href="http://www.ferd-net.de/front_content.php?idcat=231">ZUGFeRD</a>
+file format that perhaps could be transfered using QR codes, but I am
+not sure if it is done already.  Last, in Bolivia there are reports
+that tax information since november 2014 need to be printed in QR
+format on invoices.  I have not been able to track down a
+specification for this format, because of my limited language skill
+sets.</p>
+
+      </div>
+      <div class="tags">
+        
+        
+        Tags: <a href="http://people.skolelinux.org/pere/blog/tags/english">english</a>, <a href="http://people.skolelinux.org/pere/blog/tags/standard">standard</a>.
+        
+        
+      </div>
+    </div>
+    <div class="padding"></div>
+    
     <div class="entry">
       <div class="title">
         <a href="http://people.skolelinux.org/pere/blog/Making_battery_measurements_a_little_easier_in_Debian.html">Making battery measurements a little easier in Debian</a>
     <div class="entry">
       <div class="title">
         <a href="http://people.skolelinux.org/pere/blog/Making_battery_measurements_a_little_easier_in_Debian.html">Making battery measurements a little easier in Debian</a>
@@ -100,7 +284,23 @@ I would love some help to improve the system further.</p>
 
 <li><a href="http://people.skolelinux.org/pere/blog/archive/2016/02/">February (2)</a></li>
 
 
 <li><a href="http://people.skolelinux.org/pere/blog/archive/2016/02/">February (2)</a></li>
 
-<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/03/">March (1)</a></li>
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/03/">March (3)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/04/">April (8)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/05/">May (8)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/06/">June (2)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/07/">July (2)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/08/">August (5)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/09/">September (2)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/10/">October (3)</a></li>
+
+<li><a href="http://people.skolelinux.org/pere/blog/archive/2016/11/">November (8)</a></li>
 
 </ul></li>
 
 
 </ul></li>
 
@@ -333,41 +533,41 @@ I would love some help to improve the system further.</p>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/bitcoin">bitcoin (9)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/bitcoin">bitcoin (9)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/bootsystem">bootsystem (15)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/bootsystem">bootsystem (16)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/bsa">bsa (2)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/chrpath">chrpath (2)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/bsa">bsa (2)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/chrpath">chrpath (2)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/debian">debian (121)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/debian">debian (141)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/debian edu">debian edu (154)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/debian edu">debian edu (158)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/digistan">digistan (10)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/digistan">digistan (10)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/dld">dld (15)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/dld">dld (16)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/docbook">docbook (20)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/docbook">docbook (23)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/drivstoffpriser">drivstoffpriser (4)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/drivstoffpriser">drivstoffpriser (4)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/english">english (303)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/english">english (333)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/fiksgatami">fiksgatami (23)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/fildeling">fildeling (12)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/fiksgatami">fiksgatami (23)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/fildeling">fildeling (12)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/freeculture">freeculture (25)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/freeculture">freeculture (29)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/freedombox">freedombox (9)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/freedombox">freedombox (9)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/frikanalen">frikanalen (16)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/frikanalen">frikanalen (18)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/h264">h264 (20)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/intervju">intervju (42)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/h264">h264 (20)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/intervju">intervju (42)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/isenkram">isenkram (11)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/isenkram">isenkram (13)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/kart">kart (19)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/kart">kart (19)</a></li>
 
@@ -381,21 +581,21 @@ I would love some help to improve the system further.</p>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/mesh network">mesh network (8)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/mesh network">mesh network (8)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/multimedia">multimedia (37)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/multimedia">multimedia (39)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/nice free software">nice free software (7)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/nice free software">nice free software (8)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/norsk">norsk (273)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/norsk">norsk (283)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/nuug">nuug (177)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/nuug">nuug (182)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/offentlig innsyn">offentlig innsyn (22)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/offentlig innsyn">offentlig innsyn (26)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/open311">open311 (2)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/open311">open311 (2)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/opphavsrett">opphavsrett (58)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/opphavsrett">opphavsrett (62)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/personvern">personvern (92)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/personvern">personvern (95)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/raid">raid (1)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/raid">raid (1)</a></li>
 
@@ -405,27 +605,27 @@ I would love some help to improve the system further.</p>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/rfid">rfid (3)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/rfid">rfid (3)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/robot">robot (9)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/robot">robot (10)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/rss">rss (1)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/rss">rss (1)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/ruter">ruter (4)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/ruter">ruter (5)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/scraperwiki">scraperwiki (2)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/scraperwiki">scraperwiki (2)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/sikkerhet">sikkerhet (45)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/sikkerhet">sikkerhet (52)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/sitesummary">sitesummary (4)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/sitesummary">sitesummary (4)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/skepsis">skepsis (4)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/skepsis">skepsis (5)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/standard">standard (48)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/standard">standard (49)</a></li>
 
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/stavekontroll">stavekontroll (3)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/stavekontroll">stavekontroll (5)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/stortinget">stortinget (10)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/stortinget">stortinget (10)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/surveillance">surveillance (36)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/surveillance">surveillance (43)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/sysadmin">sysadmin (2)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/sysadmin">sysadmin (2)</a></li>
 
@@ -433,7 +633,7 @@ I would love some help to improve the system further.</p>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/valg">valg (8)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/valg">valg (8)</a></li>
 
- <li><a href="http://people.skolelinux.org/pere/blog/tags/video">video (55)</a></li>
+ <li><a href="http://people.skolelinux.org/pere/blog/tags/video">video (59)</a></li>
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/vitenskap">vitenskap (4)</a></li>
 
 
  <li><a href="http://people.skolelinux.org/pere/blog/tags/vitenskap">vitenskap (4)</a></li>