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