]> pere.pagekite.me Git - homepage.git/blob - blog/index.rss
Generated.
[homepage.git] / blog / index.rss
1 <?xml version="1.0" encoding="utf-8"?>
2 <rss version='2.0' xmlns:lj='http://www.livejournal.org/rss/lj/1.0/' xmlns:atom="http://www.w3.org/2005/Atom">
3 <channel>
4 <title>Petter Reinholdtsen</title>
5 <description></description>
6 <link>https://people.skolelinux.org/pere/blog/</link>
7 <atom:link href="https://people.skolelinux.org/pere/blog/index.rss" rel="self" type="application/rss+xml" />
8
9 <item>
10 <title>Time to translate the Bullseye edition of the Debian Administrator&#39;s Handbook</title>
11 <link>https://people.skolelinux.org/pere/blog/Time_to_translate_the_Bullseye_edition_of_the_Debian_Administrator_s_Handbook.html</link>
12 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Time_to_translate_the_Bullseye_edition_of_the_Debian_Administrator_s_Handbook.html</guid>
13 <pubDate>Mon, 12 Sep 2022 15:45:00 +0200</pubDate>
14 <description>&lt;p align=&quot;center&quot;&gt;&lt;img align=&quot;center&quot; src=&quot;http://people.skolelinux.org/pere/blog/images/2020-10-20-debian-handbook-nb-testprint.jpeg&quot; width=&quot;60%&quot;/&gt;&lt;/p&gt;
15
16 &lt;p&gt;(The picture is of the previous edition.)&lt;/p&gt;
17
18 &lt;p&gt;Almost two years after the previous Norwegian Bokmål translation of
19 the &quot;&lt;a href=&quot;https://debian-handbook.info/&quot;&gt;The Debian Administrator&#39;s
20 Handbook&lt;/a&gt;&quot; was published, a new edition is finally being prepared. The
21 english text is updated, and it is time to start working on the
22 translations. Around 37 percent of the strings have been updated, one
23 way or another, and the translations starting from a complete Debian Buster
24 edition now need to bring their translation up from 63% to 100%. The
25 complete book is licensed using a Creative Commons license, and has
26 been published in several languages over the years. The translations
27 are done by volunteers to bring Linux in their native tongue. The
28 last time I checked, it complete text was available in English,
29 Norwegian Bokmål, German, Indonesian, Brazil Portuguese and Spanish.
30 In addition, work has been started for Arabic (Morocco), Catalan,
31 Chinese (Simplified), Chinese (Traditional), Croatian, Czech, Danish,
32 Dutch, French, Greek, Italian, Japanese, Korean, Persian, Polish,
33 Romanian, Russian, Swedish, Turkish and Vietnamese.&lt;/p&gt;
34
35 &lt;p&gt;The translation is conducted on
36 &lt;a href=&quot;https://hosted.weblate.org/projects/debian-handbook/&quot;&gt;the
37 hosted weblate project page&lt;/a&gt;. Prospective translators are
38 recommeded to subscribe to
39 &lt;a href=&quot;http://lists.alioth.debian.org/mailman/listinfo/debian-handbook-translators&quot;&gt;the
40 translators mailing list&lt;/a&gt; and should also check out
41 &lt;a href=&quot;https://debian-handbook.info/contribute/&quot;&gt;the instructions for
42 contributors&lt;/a&gt;.&lt;/p&gt;
43
44 &lt;p&gt;I am one of the Norwegian Bokmål translators of this book, and we
45 have just started. Your contribution is most welcome.&lt;/p&gt;
46
47 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
48 activities, please send Bitcoin donations to my address
49 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
50 </description>
51 </item>
52
53 <item>
54 <title>Automatic LinuxCNC servo PID tuning?</title>
55 <link>https://people.skolelinux.org/pere/blog/Automatic_LinuxCNC_servo_PID_tuning_.html</link>
56 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Automatic_LinuxCNC_servo_PID_tuning_.html</guid>
57 <pubDate>Sat, 16 Jul 2022 22:30:00 +0200</pubDate>
58 <description>&lt;p&gt;While working on a CNC with servo motors controlled by the
59 &lt;a href=&quot;https://en.wikipedia.org/wiki/LinuxCNC&quot;&gt;LinuxCNC&lt;/a&gt;
60 &lt;a href=&quot;https://en.wikipedia.org/wiki/PID_controller&quot;&gt;PID
61 controller&lt;/a&gt;, I recently had to learn how to tune the collection of values
62 that control such mathematical machinery that a PID controller is. It
63 proved to be a lot harder than I hoped, and I still have not succeeded
64 in getting the Z PID controller to successfully defy gravity, nor X
65 and Y to move accurately and reliably. But while climbing up this
66 rather steep learning curve, I discovered that some motor control
67 systems are able to tune their PID controllers. I got the impression
68 from the documentation that LinuxCNC were not. This proved to be not
69 true&lt;/p&gt;
70
71 &lt;p&gt;The LinuxCNC
72 &lt;a href=&quot;http://linuxcnc.org/docs/html/man/man9/pid.9.html&quot;&gt;pid
73 component&lt;/a&gt; is the recommended PID controller to use. It uses eight
74 constants &lt;tt&gt;Pgain&lt;/tt&gt;, &lt;tt&gt;Igain&lt;/tt&gt;, &lt;tt&gt;Dgain&lt;/tt&gt;,
75 &lt;tt&gt;bias&lt;/tt&gt;, &lt;tt&gt;FF0&lt;/tt&gt;, &lt;tt&gt;FF1&lt;/tt&gt;, &lt;tt&gt;FF2&lt;/tt&gt; and
76 &lt;tt&gt;FF3&lt;/tt&gt; to calculate the output value based on current and wanted
77 state, and all of these need to have a sensible value for the
78 controller to behave properly. Note, there are even more values
79 involved, theser are just the most important ones. In my case I need
80 the X, Y and Z axes to follow the requested path with little error.
81 This has proved quite a challenge for someone who have never tuned a
82 PID controller before, but there is at least some help to be found.
83
84 &lt;p&gt;I discovered that included in LinuxCNC was this old PID component
85 at_pid claiming to have auto tuning capabilities. Sadly it had been
86 neglected since 2011, and could not be used as a plug in replacement
87 for the default pid component. One would have to rewriting the
88 LinuxCNC HAL setup to test at_pid. This was rather sad, when I wanted
89 to quickly test auto tuning to see if it did a better job than me at
90 figuring out good P, I and D values to use.&lt;/p&gt;
91
92 &lt;p&gt;I decided to have a look if the situation could be improved. This
93 involved trying to understand the code and history of the pid and
94 at_pid components. Apparently they had a common ancestor, as code
95 structure, comments and variable names were quite close to each other.
96 Sadly this was not reflected in the git history, making it hard to
97 figure out what really happened. My guess is that the author of
98 &lt;a href=&quot;https://github.com/LinuxCNC/linuxcnc/blob/master/src/hal/components/at_pid.c&quot;&gt;at_pid.c&lt;/a&gt;
99 took a version of
100 &lt;a href=&quot;https://github.com/LinuxCNC/linuxcnc/blob/master/src/hal/components/pid.c&quot;&gt;pid.c&lt;/a&gt;,
101 rewrote it to follow the structure he wished pid.c to have, then added
102 support for auto tuning and finally got it included into the LinuxCNC
103 repository. The restructuring and lack of early history made it
104 harder to figure out which part of the code were relevant to the auto
105 tuning, and which part of the code needed to be updated to work the
106 same way as the current pid.c implementation. I started by trying to
107 isolate relevant changes in pid.c, and applying them to at_pid.c. My
108 aim was to make sure the at_pid component could replace the pid
109 component with a simple change in the HAL setup loadrt line, without
110 having to &quot;rewire&quot; the rest of the HAL configuration. After a few
111 hours following this approach, I had learned quite a lot about the
112 code structure of both components, while concluding I was heading down
113 the wrong rabbit hole, and should get back to the surface and find a
114 different path.&lt;/p&gt;
115
116 &lt;p&gt;For the second attempt, I decided to throw away all the PID control
117 related part of the original at_pid.c, and instead isolate and lift
118 the auto tuning part of the code and inject it into a copy of pid.c.
119 This ensured compatibility with the current pid component, while
120 adding auto tuning as a run time option. To make it easier to identify
121 the relevant parts in the future, I wrapped all the auto tuning code
122 with &#39;#ifdef AUTO_TUNER&#39;. The end result behave just like the current
123 pid component by default, as that part of the code is identical. The
124 &lt;a href=&quot;https://github.com/LinuxCNC/linuxcnc/pull/1820&quot;&gt;end result
125 entered the LinuxCNC master branch&lt;/a&gt; a few days ago.&lt;/p&gt;
126
127 &lt;p&gt;To enable auto tuning, one need to set a few HAL pins in the PID
128 component. The most important ones are &lt;tt&gt;tune-effort&lt;/tt&gt;,
129 &lt;tt&gt;tune-mode&lt;/tt&gt; and &lt;tt&gt;tune-start&lt;/tt&gt;. But lets take a step
130 back, and see what the auto tuning code will do. I do not know the
131 mathematical foundation of the at_pid algorithm, but from observation
132 I can tell that the algorithm will, when enabled, produce a square
133 wave pattern centered around the &lt;tt&gt;bias&lt;/tt&gt; value on the output pin
134 of the PID controller. This can be seen using the HAL Scope provided
135 by LinuxCNC. In my case, this is translated into voltage (+-10V) sent
136 to the motor controller, which in turn is translated into motor speed.
137 So at_pid will ask the motor to move the axis back and forth. The
138 number of cycles in the pattern is controlled by the
139 &lt;tt&gt;tune-cycles&lt;/tt&gt; pin, and the extremes of the wave pattern is
140 controlled by the &lt;tt&gt;tune-effort&lt;/tt&gt; pin. Of course, trying to
141 change the direction of a physical object instantly (as in going
142 directly from a positive voltage to the equivalent negative voltage)
143 do not change velocity instantly, and it take some time for the object
144 to slow down and move in the opposite direction. This result in a
145 more smooth movement wave form, as the axis in question were vibrating
146 back and forth. When the axis reached the target speed in the
147 opposing direction, the auto tuner change direction again. After
148 several of these changes, the average time delay between the &#39;peaks&#39;
149 and &#39;valleys&#39; of this movement graph is then used to calculate
150 proposed values for Pgain, Igain and Dgain, and insert them into the
151 HAL model to use by the pid controller. The auto tuned settings are
152 not great, but htye work a lot better than the values I had been able
153 to cook up on my own, at least for the horizontal X and Y axis. But I
154 had to use very small &lt;tt&gt;tune-effort&lt;tt&gt; values, as my motor
155 controllers error out if the voltage change too quickly. I&#39;ve been
156 less lucky with the Z axis, which is moving a heavy object up and
157 down, and seem to confuse the algorithm. The Z axis movement became a
158 lot better when I introduced a &lt;tt&gt;bias&lt;/tt&gt; value to counter the
159 gravitational drag, but I will have to work a lot more on the Z axis
160 PID values.&lt;/p&gt;
161
162 &lt;p&gt;Armed with this knowledge, it is time to look at how to do the
163 tuning. Lets say the HAL configuration in question load the PID
164 component for X, Y and Z like this:&lt;/p&gt;
165
166 &lt;blockquote&gt;&lt;pre&gt;
167 loadrt pid names=pid.x,pid.y,pid.z
168 &lt;/pre&gt;&lt;/blockquote&gt;
169
170 &lt;p&gt;Armed with the new and improved at_pid component, the new line will
171 look like this:&lt;/p&gt;
172
173 &lt;blockquote&gt;&lt;pre&gt;
174 loadrt at_pid names=pid.x,pid.y,pid.z
175 &lt;/pre&gt;&lt;/blockquote&gt;
176
177 &lt;p&gt;The rest of the HAL setup can stay the same. This work because the
178 components are referenced by name. If the component had used count=3
179 instead, all use of pid.# had to be changed to at_pid.#.&lt;/p&gt;
180
181 &lt;p&gt;To start tuning the X axis, move the axis to the middle of its
182 range, to make sure it do not hit anything when it start moving back
183 and forth. Next, set the &lt;tt&gt;tune-effort&lt;/tt&gt; to a low number in the
184 output range. I used 0.1 as my initial value. Next, assign 1 to the
185 &lt;tt&gt;tune-mode&lt;/tt&gt; value. Note, this will disable the pid controlling
186 part and feed 0 to the output pin, which in my case initially caused a
187 lot of drift. In my case it proved to be a good idea with X and Y to
188 tune the motor driver to make sure 0 voltage stopped the motor
189 rotation. On the other hand, for the Z axis this proved to be a bad
190 idea, so it will depend on your setup. It might help to set the
191 &lt;tt&gt;bias&lt;/tt&gt; value to a output value that reduce or eliminate the
192 axis drift. Finally, after setting &lt;tt&gt;tune-mode&lt;/tt&gt;, set
193 &lt;tt&gt;tune-start&lt;/tt&gt; to 1 to activate the auto tuning. If all go well,
194 your axis will vibrate for a few seconds and when it is done, new
195 values for Pgain, Igain and Dgain will be active. To test them,
196 change &lt;tt&gt;tune-mode&lt;/tt&gt; back to 0. Note that this might cause the
197 machine to suddenly jerk as it bring the axis back to its commanded
198 position, which it might have drifted away from during tuning. To
199 summarize with some halcmd lines:&lt;/p&gt;
200
201 &lt;blockquote&gt;&lt;pre&gt;
202 setp pid.x.tune-effort 0.1
203 setp pid.x.tune-mode 1
204 setp pid.x.tune-start 1
205 # wait for the tuning to complete
206 setp pid.x.tune-mode 0
207 &lt;/pre&gt;&lt;/blockquote&gt;
208
209 &lt;p&gt;After doing this task quite a few times while trying to figure out
210 how to properly tune the PID controllers on the machine in, I decided
211 to figure out if this process could be automated, and wrote a script
212 to do the entire tuning process from power on. The end result will
213 ensure the machine is powered on and ready to run, home all axis if it
214 is not already done, check that the extra tuning pins are available,
215 move the axis to its mid point, run the auto tuning and re-enable the
216 pid controller when it is done. It can be run several times. Check
217 out the
218 &lt;a href=&quot;https://github.com/SebKuzminsky/MazakVQC1540/blob/bon-dev/scripts/run-auto-pid-tuner&quot;&gt;run-auto-pid-tuner&lt;/a&gt;
219 script on github if you want to learn how it is done.&lt;/p&gt;
220
221 &lt;p&gt;My hope is that this little adventure can inspire someone who know
222 more about motor PID controller tuning can implement even better
223 algorithms for automatic PID tuning in LinuxCNC, making life easier
224 for both me and all the others that want to use LinuxCNC but lack the
225 in depth knowledge needed to tune PID controllers well.&lt;/p&gt;
226
227 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
228 activities, please send Bitcoin donations to my address
229 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
230 </description>
231 </item>
232
233 <item>
234 <title>My free software activity of late (2022)</title>
235 <link>https://people.skolelinux.org/pere/blog/My_free_software_activity_of_late__2022_.html</link>
236 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/My_free_software_activity_of_late__2022_.html</guid>
237 <pubDate>Mon, 20 Jun 2022 14:30:00 +0200</pubDate>
238 <description>&lt;p&gt;I guess it is time to bring some light on the various free software
239 and open culture activities and projects I have worked on or been
240 involved in the last year and a half.&lt;/p&gt;
241
242 &lt;p&gt;First, lets mention the book
243 &lt;a href=&quot;http://www.hungry.com/~pere/publisher/&quot;&gt;releases I managed to
244 publish&lt;/a&gt;. The Cory Doctorow book &quot;Hvordan knuse
245 overvåkningskapitalismen&quot; argue that it is not the magic machine
246 learning of the big technology companies that causes the surveillance
247 capitalism to thrive, it is the lack of trust busting to enforce
248 existing anti-monopoly laws. I also published a family of
249 dictionaries for machinists, one sorted on the English words, one
250 sorted on the Norwegian and the last sorted on the North Sámi words.
251 A bit on the back burner but not forgotten is the Debian
252 Administrators Handbook, where a new edition is being worked on. I
253 have not spent as much time as I want to help bring it to completion,
254 but hope I will get more spare time to look at it before the end of
255 the year.&lt;/p&gt;
256
257 &lt;p&gt;With my Debian had I have spent time on several projects, both
258 updating existing packages, helping to bring in new packages and
259 working with upstream projects to try to get them ready to go into
260 Debian. The list is rather long, and I will only mention my own
261 isenkram, openmotor, vlc bittorrent plugin, xprintidle, norwegian
262 letter style for latex, bs1770gain, and recordmydesktop. In addition
263 to these I have sponsored several packages into Debian, like audmes.&lt;/p&gt;
264
265 &lt;p&gt;The last year I have looked at several infrastructure projects for
266 collecting meter data and video surveillance recordings. This include
267 several ONVIF related tools like onvifviewer and zoneminder as well as
268 rtl-433, wmbusmeters and rtl-wmbus.&lt;/p&gt;
269
270 &lt;p&gt;In parallel with this I have looked at fabrication related free
271 software solutions like pycam and LinuxCNC. The latter recently
272 gained improved translation support using po4a and weblate, which was
273 a harder nut to crack that I had anticipated when I started.&lt;/p&gt;
274
275 &lt;p&gt;Several hours have been spent translating free software to
276 Norwegian Bokmål on the Weblate hosted service. Do not have a
277 complete list, but you will find my contributions in at least gnucash,
278 minetest and po4a.&lt;/p&gt;
279
280 &lt;p&gt;I also spent quite some time on the Norwegian archiving specification
281 Noark 5, and its companion project Nikita implementing the API
282 specification for Noark 5.&lt;/p&gt;
283
284 &lt;p&gt;Recently I have been looking into free software tools to do company
285 accounting here in Norway., which present an interesting mix between
286 law, rules, regulations, format specifications and API interfaces.&lt;/p&gt;
287
288 &lt;p&gt;I guess I should also mention the Norwegian community driven
289 government interfacing projects Mimes Brønn and Fiksgatami, which have
290 ended up in a kind of limbo while the future of the projects is being
291 worked out.&lt;/p&gt;
292
293 &lt;p&gt;These are just a few of the projects I have been involved it, and
294 would like to give more visibility. I&#39;ll stop here to avoid delaying
295 this post.&lt;/p&gt;
296
297 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
298 activities, please send Bitcoin donations to my address
299 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
300 </description>
301 </item>
302
303 <item>
304 <title>LinuxCNC translators life just got a bit easier</title>
305 <link>https://people.skolelinux.org/pere/blog/LinuxCNC_translators_life_just_got_a_bit_easier.html</link>
306 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/LinuxCNC_translators_life_just_got_a_bit_easier.html</guid>
307 <pubDate>Fri, 3 Jun 2022 21:10:00 +0200</pubDate>
308 <description>&lt;p&gt;Back in oktober last year, when I started looking at the
309 &lt;a href=&quot;https://en.wikipedia.org/wiki/LinuxCNC&quot;&gt;LinuxCNC&lt;/a&gt; system, I
310 proposed to change the documentation build system make life easier for
311 translators. The original system consisted of independently written
312 documentation files for each language, with no automated way to track
313 changes done in other translations and no help for the translators to
314 know how much was left to translated. By using
315 &lt;a href=&quot;https://po4a.org/&quot;&gt;the po4a system&lt;/a&gt; to generate POT and PO
316 files from the English documentation, this can be improved. A small
317 team of LinuxCNC contributors got together and today our labour
318 finally payed off. Since a few hours ago, it is now possible to
319 translate &lt;a href=&quot;https://hosted.weblate.org/projects/linuxcnc/&quot;&gt;the
320 LinuxCNC documentation on Weblate&lt;/a&gt;, alongside the program itself.&lt;/p&gt;
321
322 &lt;p&gt;The effort to migrate the documentation to use po4a has been both
323 slow and frustrating. I am very happy we finally made it.&lt;/p&gt;
324
325 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
326 activities, please send Bitcoin donations to my address
327 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
328 </description>
329 </item>
330
331 <item>
332 <title>geteltorito make CD firmware upgrades a breeze</title>
333 <link>https://people.skolelinux.org/pere/blog/geteltorito_make_CD_firmware_upgrades_a_breeze.html</link>
334 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/geteltorito_make_CD_firmware_upgrades_a_breeze.html</guid>
335 <pubDate>Wed, 20 Apr 2022 11:50:00 +0200</pubDate>
336 <description>&lt;p&gt;Recently I wanted to upgrade the firmware of my thinkpad, and
337 located the firmware download page from Lenovo (which annoyingly do
338 not allow access via Tor, forcing me to hand them more personal
339 information that I would like). The
340 &lt;a href=&quot;https://support.lenovo.com/no/en/search?query=thinkpad firmware bios upgrade iso&amp;SearchType=Customer search&amp;searchLocation=Masthead&quot;&gt;download
341 from Lenovo&lt;/a&gt; is a bootable ISO image, which is a bit of a problem
342 when all I got available is a USB memory stick. I tried booting the
343 ISO as a USB stick, but this did not work. But genisoimage came to
344 the rescue.&lt;/p&gt;
345
346 &lt;P&gt;The geteltorito program in
347 &lt;a href=&quot;http://tracker.debian.org/cdrkit&quot;&gt;the genisoimage binary
348 package&lt;/a&gt; is able to convert the bootable ISO image to a bootable
349 USB stick using a simple command line recipe, which I then can write
350 to the most recently inserted USB stick:&lt;/p&gt;
351
352 &lt;blockquote&gt;&lt;pre&gt;
353 geteltorito -o usbstick.img lenovo-firmware.iso
354 sudo dd bs=10M if=usbstick.img of=$(ls -tr /dev/sd?|tail -1)
355 &lt;/pre&gt;&lt;/blockquote&gt;
356
357 &lt;p&gt;This USB stick booted the firmware upgrader just fine, and in a few
358 minutes my machine had the latest and greatest BIOS firmware in place.&lt;/p&gt;
359 </description>
360 </item>
361
362 <item>
363 <title>Playing and encoding AV1 in Debian Bullseye</title>
364 <link>https://people.skolelinux.org/pere/blog/Playing_and_encoding_AV1_in_Debian_Bullseye.html</link>
365 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Playing_and_encoding_AV1_in_Debian_Bullseye.html</guid>
366 <pubDate>Sat, 16 Apr 2022 08:40:00 +0200</pubDate>
367 <description>&lt;p&gt;Inspired by the recent news of
368 &lt;a href=&quot;https://slashdot.org/story/22/04/03/2039219/intel-beats-amd-and-nvidia-with-arc-gpus-full-av1-support&quot;&gt;AV1
369 hardware encoding support from Intel&lt;/a&gt;, I decided to look into
370 the state of AV1 on Linux today. AV1 is a
371 &lt;a href=&quot;https://web.archive.org/web/20160618103850/http://www.digistan.org/open-standard:definition&quot;&gt;free
372 and open standard&lt;/a&gt; as defined by Digistan without any royalty
373 payment requirement, unlike its much used competitor encoding
374 H.264. While looking, I came across an 5 year
375 &lt;a href=&quot;https://askubuntu.com/questions/1061908/how-to-encode-and-playback-video-with-the-av1-codec-on-bionic-beaver-18-04&quot;&gt;old
376 question on askubuntu.com&lt;/a&gt; which in turn inspired me to check out
377 how things are in Debian Stable regarding AV1. The test file listed
378 in the question (askubuntu_test_aom.mp4) did not exist any more, so I
379 tracked down a different set of test files on
380 &lt;a href=&quot;https://av1.webmfiles.org/&quot;&gt;av1.webmfiles.org&lt;/a&gt; to test them
381 with the various video tools I had installed on my machine. I was
382 happy to discover that AV1 decoding and playback worked with almost
383 every tool I tested:
384
385 &lt;table align=&quot;center&quot;&gt;
386 &lt;tr&gt;&lt;td&gt;mediainfo&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
387 &lt;tr&gt;&lt;td&gt;dragonplayer&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
388 &lt;tr&gt;&lt;td&gt;ffmpeg / ffplay&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
389 &lt;tr&gt;&lt;td&gt;gnome-mplayer&lt;/td&gt; &lt;td&gt;fail&lt;/td&gt;&lt;/tr&gt;
390 &lt;tr&gt;&lt;td&gt;mplayer&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
391 &lt;tr&gt;&lt;td&gt;mpv&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
392 &lt;tr&gt;&lt;td&gt;parole&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
393 &lt;tr&gt;&lt;td&gt;vlc&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
394 &lt;tr&gt;&lt;td&gt;firefox&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
395 &lt;tr&gt;&lt;td&gt;chromium&lt;/td&gt; &lt;td&gt;ok&lt;/td&gt;&lt;/tr&gt;
396 &lt;/table&gt;
397
398 &lt;p&gt;AV1 encoding is available in Debian Stable from the aom-tools
399 version 1.0.0.errata1-3 package, using the aomenc tool. The encoding
400 using the package in Debian Stable is quite slow, with the frame rate
401 for my 10 second test video at around 0.25 fps. My 10 second video
402 test took 16 minutes and 11 seconds on my test machine.&lt;/p&gt;
403
404 &lt;p&gt;I tested by first running ffmpeg and then aomenc using the recipe
405 provided by the askubuntu recipe above. I had to remove the
406 &#39;--row-mt=1&#39; option, as it was not supported in my 1.0.0 version. The
407 encoding only used a single thread, according to &lt;tt&gt;top&lt;/tt&gt;.&lt;/p&gt;
408
409 &lt;blockquote&gt;&lt;pre&gt;
410 ffmpeg -i some-old-video.ogv -t 10 -pix_fmt yuv420p video.y4m
411 aomenc --fps=24/1 -u 0 --codec=av1 --target-bitrate=1000 \
412 --lag-in-frames=25 --auto-alt-ref=1 -t 24 --cpu-used=8 \
413 --tile-columns=2 --tile-rows=2 -o output.webm video.y4m
414 &lt;/pre&gt;&lt;/blockquote&gt;
415
416 &lt;p&gt;As version 1.0.0 currently have several
417 &lt;a href=&quot;https://security-tracker.debian.org/tracker/source-package/aom&quot;&gt;unsolved
418 security issues in Debian Stable&lt;/a&gt;, and to see if the recent
419 backport &lt;a href=&quot;https://tracker.debian.org/pkg/aom&quot;&gt;provided in
420 Debian&lt;/a&gt; is any quicker, I ran &lt;tt&gt;apt -t bullseye-backports install
421 aom-tools&lt;/tt&gt; to fetch the backported version and re-encoded the
422 video using the latest version. This time the &#39;--row-mt=1&#39; option
423 worked, and the encoding was done in 46 seconds with a frame rate of
424 around 5.22 fps. This time it seem to be using all my four cores to
425 encode. Encoding speed is still too low for streaming and real time,
426 which would require frame rates above 25 fps, but might be good enough
427 for offline encoding.&lt;/p&gt;
428
429 &lt;p&gt;I am very happy to see AV1 playback working so well with the
430 default tools in Debian Stable. I hope the encoding situation improve
431 too, allowing even a slow old computer like my 10 year old laptop to
432 be used for encoding.&lt;/p&gt;
433
434 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
435 activities, please send Bitcoin donations to my address
436 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
437 </description>
438 </item>
439
440 <item>
441 <title>Få en slutt på Digitale utslipp</title>
442 <link>https://people.skolelinux.org/pere/blog/F__en_slutt_p__Digitale_utslipp.html</link>
443 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/F__en_slutt_p__Digitale_utslipp.html</guid>
444 <pubDate>Mon, 14 Mar 2022 22:00:00 +0100</pubDate>
445 <description>&lt;p&gt;På onsdag sendte jeg følgende epost til Utdanningsetaten i Oslo
446 kommune (UDE). Fikk beskjed om at min henvendelse har saksnummer
447 22/7559-1 i den
448 &lt;a href=&quot;https://www.oslo.kommune.no/etater-foretak-og-ombud/utdanningsetaten/postjournal-utdanningsetaten/&quot;&gt;offentlige
449 postjournalen til UDE&lt;/a&gt;. Jeg er spent på hva slags respons jeg får.
450 Mistenker jo de fleste som sprer sine nettsideleseres
451 personopplysninger til utlandet ikke har tenkt så nøye igjennom hva de
452 gjør, og at det er håp om at de tenker seg litt nøyere om hvis de blir
453 klar over problemstillingen. Vet du noen som burde få tilsvarede
454 beskjed og spørsmål? Kanskje du kan sende dem en epost. Hvis alle
455 bidrar blir det kanskje litt bedre.&lt;/p&gt;
456
457 &lt;blockquote&gt;
458 &lt;p&gt;To: postmottak (at) osloskolen.no
459 &lt;br&gt;Subject: Digitale utslipp fra osloskolens nettsider&lt;/p&gt;
460
461 &lt;p&gt;Hei.&lt;/p&gt;
462
463 &lt;p&gt;Jeg ser at osloskolens nettsider har digitale utslipp av
464 personopplysninger til Google, Facebook og andre, blant annet omtalt
465&amp;lt;URL: &lt;a href=&quot;https://aktuelt.osloskolen.no/personvernerklaring-for-osloskolen/informasjonskapsler/&quot;&gt;https://aktuelt.osloskolen.no/personvernerklaring-for-osloskolen/informasjonskapsler/&lt;/a&gt;
466 &gt;.&lt;/p&gt;
467
468 &lt;p&gt;&amp;lt;URL: &lt;a href=&quot;https://webbkoll.dataskydd.net/&quot;&gt;https://webbkoll.dataskydd.net/&lt;/a&gt; &gt; kan være et nyttig verktøy for å holde øye med utslippsomfanget på ulike sider.&lt;/p&gt;
469
470 &lt;p&gt;Kanskje det er en ide å gjøre noe med det, jamfør &amp;lt;URL: &lt;a href=&quot;https://www.digi.no/artikler/debatt-det-enkleste-tiltaket-er-a-skru-av-google-analytics/517378&quot;&gt;https://www.digi.no/artikler/debatt-det-enkleste-tiltaket-er-a-skru-av-google-analytics/517378&lt;/a&gt; &gt;?&lt;/p&gt;
471
472 &lt;p&gt;Et alternativ til Google Analytics kan være en lokalt installert
473 utgave av &amp;lt;URL:
474 &lt;a href=&quot;https://matomo.org/&quot;&gt;https://matomo.org/&lt;/a&gt; &gt;. Den og flere
475 andre alternativer kan finnes via
476 &amp;lt;URL: &lt;a href=&quot;https://www.digi.no/artikler/sverige-vil-skrote-amerikansk-skytjeneste-her-er-alternativene/516223?key=5QsV0wRG&quot;&gt;https://www.digi.no/artikler/sverige-vil-skrote-amerikansk-skytjeneste-her-er-alternativene/516223?key=5QsV0wRG&lt;/a&gt; &gt;
477 på bakgrunn av at svenske myndigheter har innsett at dagens praksis
478 nok er både lite lur og ulovlig. Der henger Norge litt etter, men
479 osloskolen har her mulighet til å være litt i forkant. :)&lt;/p&gt;
480
481 &lt;p&gt;Fint om dere kan gi beskjed hvilket saksnummer denne henvendelsen får i
482 offentlig postjournal når den er mottatt.&lt;/p&gt;
483
484 &lt;/blockquote&gt;
485
486 &lt;/p&gt;Flere og flere innser at slik spredning av personopplysninger er
487 ugreit. Det har pågått i mange år. Ser jeg blogget
488 &lt;a href=&quot;https://people.skolelinux.org/pere/blog/Det_er_jo_makta_som_er_mest_s_rbar_ved_massiv_overv_kning_av_Internett.html&quot;&gt;første
489 gang om Google Analytics i 2013&lt;/a&gt; og
490 &lt;a href=&quot;https://people.skolelinux.org/pere/blog/Snurpenot_overv_kning_av_sensitiv_personinformasjon.html&quot;&gt;analyserte
491 omfanget i 2015&lt;/a&gt;, men det er et langt lerret å bleke.&lt;/p&gt;
492
493 &lt;p&gt;Som vanlig, hvis du bruker Bitcoin og ønsker å vise din støtte til
494 det jeg driver med, setter jeg pris på om du sender Bitcoin-donasjoner
495 til min adresse
496 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.
497 Merk, betaling med bitcoin er ikke anonymt. :)&lt;/p&gt;
498 </description>
499 </item>
500
501 <item>
502 <title>Publish Hargassner wood chip boiler state to MQTT</title>
503 <link>https://people.skolelinux.org/pere/blog/Publish_Hargassner_wood_chip_boiler_state_to_MQTT.html</link>
504 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Publish_Hargassner_wood_chip_boiler_state_to_MQTT.html</guid>
505 <pubDate>Sat, 12 Mar 2022 06:30:00 +0100</pubDate>
506 <description>&lt;p&gt;Recently I had a look at a
507 &lt;a href=&quot;https://www.hargassner.at/&quot;&gt;Hargassner&lt;/a&gt;
508 &lt;a href=&quot;https://www.hargassner.at/en/products/wood-chip-boiler.html&quot;&gt;wood
509 chip boiler&lt;/a&gt;, and what kind of free software can be used to monitor
510 and control it. The boiler can be connected to some cloud service via
511 what the producer call an Internet Gateway, which seem to be a
512 computer connecting to the boiler and passing the information gathered
513 to the cloud. I discovered the boiler controller got an IP address on
514 the local network and listen on TCP port 23 to provide status
515 information as a text line of numbers. It also provide a HTTP server
516 listening on port 80, but I have not yet figured out what it can do
517 beside return an error code.&lt;/p&gt;
518
519 &lt;p&gt;If I am to believe various free software implementations talking to
520 such boiler, the interpretation of the line of numbers differ between
521 type of boiler and software version on the boiler. By comparing the
522 list of numbers on the front panel of the boiler with the numbers
523 returned via TCP, I have been able to figure out several of the
524 numbers, but there are a lot left to understand. I&#39;ve located several
525 temperature measurements and hours running values, as well as oxygen
526 measurements and counters.&lt;/p&gt;
527
528 I decided to write a simple parser in Python for the values I figured
529 out so far, and a simple MQTT injector publishing both the interpreted
530 and the unknown values on a MQTT bus to make collecting and graphing
531 simpler. The end result is available from the
532 &lt;a href=&quot;https://gitlab.com/petterreinholdtsen/hargassner2mqtt&quot;&gt;hargassner2mqtt
533 project page&lt;/a&gt; on gitlab. I very much welcome patches extending the
534 parser to understand more values, boiler types and software versions.
535 I do not really expect very few free software developers got their
536 hands on such unit to experiment, but it would be fun if others too find
537 this project useful.&lt;/p&gt;
538
539 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
540 activities, please send Bitcoin donations to my address
541 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
542 </description>
543 </item>
544
545 <item>
546 <title>Run your industrial metal working machine using Debian?</title>
547 <link>https://people.skolelinux.org/pere/blog/Run_your_industrial_metal_working_machine_using_Debian_.html</link>
548 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Run_your_industrial_metal_working_machine_using_Debian_.html</guid>
549 <pubDate>Wed, 2 Mar 2022 18:40:00 +0100</pubDate>
550 <description>&lt;p&gt;After many months of hard work by the good people involved in
551 &lt;a href=&quot;https://en.wikipedia.org/wiki/LinuxCNC&quot;&gt;LinuxCNC&lt;/a&gt;, the
552 system was accepted Sunday
553 &lt;a href=&quot;https://tracker.debian.org/pkg/linuxcnc&quot;&gt;into Debian&lt;/a&gt;.
554 Once it was available from Debian, I was surprised to discover from
555 &lt;a href=&quot;https://qa.debian.org/popcon.php?package=linuxcnc&quot;&gt;its
556 popularity-contest numbers&lt;/a&gt; that people have been reporting its use
557 since 2012. &lt;a href=&quot;http://linuxcnc.org/&quot;&gt;Its project site&lt;/a&gt; might
558 be a good place to check out, but sadly is not working when visiting
559 via Tor.&lt;/p&gt;
560
561 &lt;p&gt;But what is LinuxCNC, you are probably wondering? Perhaps a
562 Wikipedia quote is in place?&lt;/p&gt;
563
564 &lt;blockquote&gt;
565 &quot;LinuxCNC is a software system for numerical control of
566 machines such as milling machines, lathes, plasma cutters, routers,
567 cutting machines, robots and hexapods. It can control up to 9 axes or
568 joints of a CNC machine using G-code (RS-274NGC) as input. It has
569 several GUIs suited to specific kinds of usage (touch screen,
570 interactive development).&quot;
571 &lt;/blockquote&gt;
572
573 &lt;p&gt;It can even control 3D printers. And even though the Wikipedia
574 page indicate that it can only work with hard real time kernel
575 features, it can also work with the user space soft real time features
576 provided by the Debian kernel.
577 &lt;a href=&quot;https://github.com/linuxcnc/linuxcnc&quot;&gt;The source code&lt;/a&gt; is
578 available from Github. The last few months I&#39;ve been involved in the
579 translation setup for the program and documentation. Translators are
580 most welcome to
581 &lt;a href=&quot;https://hosted.weblate.org/engage/linuxcnc/&quot;&gt;join the
582 effort&lt;/a&gt; using Weblate.&lt;/p&gt;
583
584 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
585 activities, please send Bitcoin donations to my address
586 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
587 </description>
588 </item>
589
590 <item>
591 <title>Updated vlc bittorrent plugin in Debian (version 2.14)</title>
592 <link>https://people.skolelinux.org/pere/blog/Updated_vlc_bittorrent_plugin_in_Debian__version_2_14_.html</link>
593 <guid isPermaLink="true">https://people.skolelinux.org/pere/blog/Updated_vlc_bittorrent_plugin_in_Debian__version_2_14_.html</guid>
594 <pubDate>Mon, 14 Feb 2022 08:00:00 +0100</pubDate>
595 <description>&lt;p&gt;I am very happy to report that a new version of the
596 &lt;a href=&quot;https://tracker.debian.org/pkg/vlc-plugin-bittorrent&quot;&gt;VLC
597 bittorrent plugin&lt;/a&gt; was just uploaded into debian. The changes
598 since last time is mostly code clean in the download code. The package
599 is currently in Debian unstable, but should be available in Debian
600 testing son. To test it, simply install it like this:&lt;/p&gt;
601
602 &lt;p&gt;&lt;pre&gt;
603 apt install vlc-plugin-bittorrent
604 &lt;/pre&gt;&lt;/p&gt;
605
606 &lt;p&gt;After it is installed, you can try to use it to play a file
607 downloaded live via bittorrent like this:
608
609 &lt;p&gt;&lt;pre&gt;
610 vlc https://archive.org/download/Glass_201703/Glass_201703_archive.torrent
611 &lt;/pre&gt;&lt;/p&gt;
612
613 &lt;p&gt;It can also use magnet links and local .torrent files like the ones
614 provided by the Internet Archive. Another example is the &lt;a
615 href=&quot;https://archive.org/details/LoveNest&quot;&gt;Love Nest&lt;/a&gt; Buster
616 Keaton movie, where one can click on the &#39;Torrent&#39; link to get going.&lt;/p&gt;
617
618 &lt;p&gt;As usual, if you use Bitcoin and want to show your support of my
619 activities, please send Bitcoin donations to my address
620 &lt;b&gt;&lt;a href=&quot;bitcoin:15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&quot;&gt;15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b&lt;/a&gt;&lt;/b&gt;.&lt;/p&gt;
621 </description>
622 </item>
623
624 </channel>
625 </rss>