In the previous article I talked about external meters and pmda-denki. Now lets see how much power certain hardware components need.
Pmda-denki usage
pmda-denki is now in PCP upstream. One can use the code from
there, via packages build regularly, or wait for the next PCP
release to make it into the Linux distros. With that done,
and pmda-denki being installed, metrics regarding electrical
power are available. On laptops where pmda-denki can access
both sources:
TL’DR
- With a Linux laptop, you can quite accurately measure the systems current overall power consumption while on battery. This allows to compare if the new version of your software uses more power than the old one.
- On Intel/AMD systems, power consumption of cpu’s can be measured with RAPL - good enough to compare cpu workloads.
- You can read these metrics directly from sysfs and do some simple computations, or use the PCP/pmda-denki tool. pmda’s are agents, enabling the Performance Co-Pilot (PCP) software to archive the metrics for historical reference, and more.
- From what I have seen, it pays off to choose the software you use wisely: for example, the the applications playing h264 consume different amounts of energy. When you run on battery in a train, that can make a difference.
Why measure power consumption?
We all use ‘powertop’ on Linux to see the current power consumption. Since some time, I was wondering about further ways of measuring and recording the power consumption of my Thinkpad, and graphing it. How much power is used when idling, when I’m not logged in and running powertop? How accurate can one measure the consumption of single components like NVMe disk from the Linux side?
What I can compare..
Disclaimer: I have just experienced 2 employers in Germany, and 2 employers in Japan. Also, not only the location/country you work in is relevant for ‘what work feels like’, but also the company. My first German employer was a big IT service provider, with many customers in Germany, some more spread over Europe and just few in the rest of the world. My second employer in Germany was an American based company with customers all over the world, that felt already different.
First I worked and payed taxes in Germany. From 2016 on, in Japan. Time to think about the differences in paying taxes, and how they are used. I dislike doing taxes, would prefer if everything would be deducted automatically.. but taxes are there to stay. The differences between both contries are interesting!
Income tax in Germany
In Germany, income taxes are automatically deducted from the monthly wages. One a year, one has to do a ‘income tax declaration’. Some are diving into these papers and do that by themself, others do it themself supported by software. I decided the most painless was for me to visit a tax adviser once a year, who did the tax declaration for me. Quite convenient, and not very expensive.
Background: I’m a German, living in Japan. Details are here.
The visitor visa
In March 2008, I went to Japan for the first time. For 3 month I would live and work in Tokyo. As German citizen, or being from other 1st world countries, that is easy: for business as well as holiday you can get a visa for staying up to 3 months in Japan. No application in advance required, simply fill out the paper upon arrival in Japan.
So, having seen Norbert and @codewiz mentioning Plasma frequently, I decided to give it a try. My desktop box is Fedora33, which comes with a quite current version of Plasma.
Some years ago, I tried gnome - but Gnomes “let’s make it as simple as possible, leave buttons out”-strategy does not stick well with me. I don’t want a dumbed down window manager.
I use WindowMaker since dozends of years. It’s nice and lean, but does not seem to have a future with Wayland. I use xdm with an old style ~/.xsession file.
Onsen? Ryokan?
Japan being on the intersection of seismic plates is leading to earthquakes, but also to hot water which is used in bathes, so called Onsen. A Ryokan is a traditional style of hotel in Japan, with tatami mat covered rooms, often a bath attached, including good meals and services like preparing futon beds in the evening for visitors. Japanese sometimes go to Onsenmeguri, which means ’travel with stay in an onsen'.
There is great food in Japan, let me share a week of autumn food in Japan. I do not eat much for breakfast, but for lunch I visit various places.
Keema-Nattou Curry
Fridays Keema-Nattou curry with rice. Keema is minced meet, Nattou is a speciality from Japan often eaten for breakfast, these are fermented soybeans. Fermented means ‘has been changed’, like sauerkraut in Germany, or Kimuchi in Korea. Also in the curry: carrot, potato, pepper, okura (a vegetable not known in Germany), broccoli. 2 cooked eggs of unspecified origin, not from chicken.
Intro
I get weekly Japanese lessons via Skype. At the moment we are reading Japanese news articles: discussing grammar and rare words, and the topic itself. After 5 years, my teacher knows me well enough to select topics which are interesting to me. Recently we read the article Is it hard to live in Japan?.
Seems like my teacher shortened the article to 5 points - after reading the original I find the shorter version more to the point. I will quote the authors points, and compare with Germany and other countries.
The previous article introduces into HDMI grabbers on Linux.
When is latency relevant?
My first use case was to play a game on a device like the Nintendo Switch, with the HDMI output only visible via grabber. While playing with various options and software, I needed a way to nicely measure the latency between the HDMI signal output, and the picture displayed on my screen. How to do that? Best is to show the current time, sufficiently accurate, on both
HDMI grabbing?
These are devices you connect you a computer (might be a tiny one like a Raspberry Pi), and which convert HDMI input from a cable into something useful for further processing. I’m sharing here details from my experiments with 2 grab devices, and using Linux for processing.
So practically, what can I do with this?
My usecase is that I have just a single monitor, with just a single HDMI connector. I saw that HDMI grab devices came down to 1200円(~10€), I wondered how useful they were to grab/display/record games running on the Nintendo Switch.
Climbing Mount Fuji at Night: Ascend covers the ascend.
For 2 hours I was waiting in the cold at the summit, drinking green tea from the vending machines. Due to the cold, I could not sleep or stay at one place without moving - and that was even with proper jacket, I had seen people climbing up in short trousers, probably not waiting for the daylight but directly descending.
Eventually a hut opened, people streamed in and ate udon. At 4:15, the first light could be seen, people started to stare towards east. Some wrapped the body in tinfoil, curious how well that works. Looking downwards, I saw the clouds, this time not seen from a plane but the Fujisan. At 5:02, the sun finally came up, and the Japanese national anthem was played.