Marc's Public Blog - Linux Hacking


All | Aquariums | Arduino | Btrfs | Cars | Cats | Clubbing | Dining | Diving | Electronics | Exercising | Flying | Hiking | Linux | Linuxha | Public | Rc | Sciencemuseums | Snow | Solar | Trips

This page has a few of my blog entries about linux, but my main linux page is here
Picture of Linus


Table of Content for linux:

More pages: January 2017 October 2016 August 2016 July 2016 June 2016 February 2016 January 2016 May 2015 March 2015 January 2015 October 2014 May 2014 April 2014 March 2014 January 2014 November 2013 September 2013 May 2013 March 2013 January 2013 December 2012 August 2012 May 2012 March 2012 January 2012 December 2011 August 2011 July 2011 January 2011 October 2010 August 2010 June 2010 April 2010 March 2010 January 2010 December 2009 November 2009 September 2009 August 2009 July 2009 May 2009 January 2009 December 2008 November 2008 October 2008 January 2008 November 2007 August 2007 July 2006 January 2006 August 2005 April 2005 November 2004 March 2004 February 2004




2017/01/17 Linux.conf.au 2017, Hobart
π 2017-01-17 00:00 in Linux
As another full circle LCA, this one came back to Hobart, Tasmania (our last time was in 2009|/perso/linux/post_2009-01-21_Linux_conf_au-2009-in-Tasmania.html].



As every year, a nice collection of talks












and of course great parties too:






And afer a week, it was over, 'till next year:



See more images for Linux.conf.au 2017, Hobart
2017/01/16 IoTuz Driver for our ESP32 board built at Open Hardware Miniconf at Linux.Conf.au 2017
π 2017-01-16 00:00 in Arduino, Linux
I went to meet the Open Hardware Miniconf team to hang out the previous day and see them at work finishing the last boards:


last minute hardware patching
last minute hardware patching


The IoTuz board was a challenge compared to previous years. It was based on the still new ESP32 and had very little example code. Most of the hardware had never been exercised since the board had been designed, and with a few other people I took the task to heart. Within the week, I was able to get the SPI touch screen working at the same time than the LCD (which required cable select switching via I/O expander lines. It took longer to get the two APA106 (neopixel-like) LEDs to work:

I had the first etch-a-sketch working :)
I had the first etch-a-sketch working :)

So, that all in January. But IoTuz was the gift that kept on giving. It had all those I/O bits that didn't work at all and no one had ever used. Hell, some of them had no existing drivers at all (Neopixel no support under arduino IDE, IO expander needed some access functions, No support for the IR receiver, touch screen needed a few hacks, joystick needed some code to support the huge dead zone in the center), while some other hardware worked out of the box with existing drivers (temp/humidity and accelerometer). The rotary encoder also needed custom ESP32 interrupt code to work properly (nothing too fancy, but there was no existing driver to use).

So, I embarqued into a mega library/object to support most of the hardware and ended up with almost 1000 lines of code for my IoTuz library, and another thousand lines or so for the main example code (examples/fulldemo) and that does not include 3rd party code of existing demos I was able to re-use and port to IoTuz.

In the end, that took about 100 hours of work since I had to write/port drivers as I went along, and learn how some of that hardware was even supposed to work :) (ok, non trivial time was also spent finding and chasing platform bugs which have now been fixed, as well as merging driver code with upstream maintainers).

Here is a quick video summary (longer videos at the bottom):

And here is the result (thanks to https://github.com/marcmerlin/IoTuz 's examples/fulldemo)

I made an adjustable touch menu system
I made an adjustable touch menu system


drawing circles with the accelerometer by rotating the board
drawing circles with the accelerometer by rotating the board

touch color selector
touch color selector

hardware scroll of bitmap using the rotary encoder
hardware scroll of bitmap using the rotary encoder



Just like the joystick not being very precise or centered right, the touchscreen isn't quite the same for everyone, but especially in my case I broke my touchscreen, had to buy another one and that one was wired reversed, so I designed a screen touch screen calibrator which auto adjusts and supports touch screens that are inversed like mine:


Enough bla-blah, show me the code: https://github.com/marcmerlin/IoTuz

And here are some video clips:

Hardware Intro

IoTuz Controls

IoTuz Infrared Support

IoTuz Demos

IoTuz Breakout and Tetris

Again, here's the code: https://github.com/marcmerlin/IoTuz

2016/10/05 Linuxcon Europe 2016, Berlin
π 2016-10-05 00:00 in Linux
For my 3rd and last Linuxcon of the year, I presented my Open Source at Google talk in Berlin, and my talk was well received despite my non ideal delivery due to bad sleeping in the hotel room
That was my first Linuxcon in Europe, and it was nice to see a different crowd. While the weather in Berlin was pretty crappy, the conference was not :)










See more images for Linuxcon Europe 2016, Berlin
2016/08/23 Linuxcon 2016, Toronto
π 2016-08-23 00:00 in Linux
After Linuxcon in Japan, we went to the one in Toronto. It had 10 parallel tracks at time, it was a very packed schedule.




kind of weird to see a keynote on Microsoft showing their 'longstanding' contributions to linux
kind of weird to see a keynote on Microsoft showing their 'longstanding' contributions to linux


Funny how microsoft was playing all "we love linux and we have for a long time", when they're still actively extorting money for companies that dare to use linux and aren't paying microsoft windows licenses:

  • http://techrights.org/2016/02/10/extorting-acer-with-patents
  • http://techrights.org/2016/03/10/charm-offensives-distract
  • http://techrights.org/2016/04/29/microsoft-continues-extortion
  • I gave my talk on Open Source at Google and it was well received:


    Show floor:



    The last evening, we had a nice party where people were eoncuraged to dress up:






    ice cream made onsite
    ice cream made onsite

    See more images for Linuxcon 2016, Toronto
    2016/07/13 Linuxcon JP 2016, and my talk on Open Source at Google
    π 2016-07-13 00:00 in Linux
    It was nice to be back at LinuxconJP for another year. This time, I gave a talk about Open Source at Google



    There were other talks and keynotes of course:









    Good times, thanks to all the organizers, volunteers and speakers.

    2016/06/01 Toguard HD 7" Full HD 1080p Android GPS navigation Touch Screen Car Dash Cam Dual lens WiFi
    π 2016-06-01 00:00 in Cars, Linux
    This is a very welcome update to the 5" mirror. You can read my review of the 5" mirror. This is the product link: http://www.amazon.com/Toguard-Mirror-Navigation-Screen-Android/dp/B01FJZ4ZRE

    It is a very welcome update, the older mirror. The camera is nicely integrated now, the screen bigger, and most importantly, the android system has more memory, so you can now easily run other apps like google maps (with the old mirror, you ran out of memory all the time). This is really the update I was waiting for. The old mirror has a super annoying start and stop music and voice. They have now been removed. This is great!

    After connecting to Wifi (2.4Ghz only), you can run google maps or google play store, sign in your google account, and get your saved location searches on google maps (so that you don't have to type them on the mirror, the software keyboard is not very easy to use). As a trick type "ok maps" in the google maps search window, and in most countries, it will download maps for offline use. You can install other apps from the android market, bit it waze, or whatever else you fancy.

    Let's compare the form factor, the mirrors are almost the same size (but the new mirror has nice straps built in), however the main difference is where the display goes. The old mirror put it on the side so that you could read the screen on the left, and see cars behind you on the center and right. The new mirror has a bigger display in the middle and I'm not sure if I prefer that, I think it may be a matter of getting used to it. This is because you're now supposed to look at cars behind you by looking through the display and unfocussing your eyes. It works, but I think you don't see as well. Also, if there is a lot of daylight behind you, the daylight will not make it possible to read the screen (but at least you'll see the cars behind you). I think I kind of prefered the android screen on the side like in the 5" version, but the tradeoff is that you get a small screen which may be harder to read depending on your eyes (I have excellent vision, so in my case I can read both screens fine, but you may not be able to read the 5" one as well):



    this gives you an idea of how you see cars through the screen
    this gives you an idea of how you see cars through the screen

    The camera is built in and more tidy, that's definitely a plus:


    Here are the main points:

  • I have to say again that Toguard/Jeemak US is one of those new Chinese companies that actually cares about customer support and doing the right thing. I have to give them credit for this and hope more companies will do the same. The product is far from perfect, but from my interactions with them, they really care about making it better.
  • The provided written manual is very good. It really is good, kudos for that, especially because how unusual it is for Chinese products.
  • The device is a full featured quad core android tablet in side your rear view mirror. It's still running the older android kitkat which is more memory efficient, and comes with more RAM, so things run smoothly now.
  • You get a real android tablet in a 7" factor. You can add our google account, install google maps or waze and you could even install calendar or gmail if you wish.
  • The wifi is 2.4Ghz only and would be used to install apps at home, or tether to your phone, but that's a bad choice because wifi tethering is very expensive on batteries for your phone. Still, it's better than nothing, and ok for you if you have a fancy car that provides its own wifi hot spot.
  • The unit ships with sygic and polnav mobile. Polnav didn't seem to really work or have data I could get for the US, but sygic seems like a good navigation app that works offline. You can also use google maps offline if you wish. Too bad you cannot tether via bluetooth.
  • While you cannot use the missing bluetooth to route audio from the mirror to your car, it comes with an FM transmitter, so you can route audio to your car radio.
  • The rear camera is low quality, but I'll take that over nothing, it can come in handy if you get hit from behind, it will do fine to prove that. The front camera in the 7" mirror looks bigger and better, but in my testing conditions, it didn't so very well for capturing license plates of moving cars. I think the lighting conditions were non optimal and caused this because I've seen a video from someone else taken by the same camera, and it was much better quality than what I captured. This is another way to say that you should expect better quality in some conditions than what I posted.
  • The GPS is a great addition for the base price (many dashcams do not include it by default). First I thought mine wasn't working well, until the nice Toguard support told me that it had to be mounted with with glue sticker facing down (I had glued it to my windshield next to the mirror, which meant it was upside down).
  • The device comes with about 16GB of flash free, which is very generous, and handles external sdcards perfectly. Flash is used to install android apps, and video recording is done on the external sdcard.
  • Toguard removed the stock android settings app, which arguably is a bit complicated and replaced it with a custom settings app that has just the basics
  • Downsides:

  • The flipside of the custom settings app is that it lacks advanced settings that android enthusiasts may like. But for instance this has caused issues with timezone settings (you have to manually change the time for the timezone you're in). Similarly, you can't install a new keyboard from android market and switch to it since you can't access the settings. To be fair, average users won't care and will probably be happier with the simplified but limited settings app.
  • The android status bar where you can find quick settings and info from some apps, is gone. Average users won't care, power users of android might.
  • The unit is flashable, so in theory you can install new firmware, but it requires a complicated procedure using customized windows software (I tried that while reviewing an early version of the hardware). I expect that it will likely not be end user upgradable.
  • The video recorder works fine, but it does not allow changing EV settings, nor can it be used as a parking camera with motion detection.
  • There is no more hardware menu key. You cannot long hold the menu key to switch apps, you have to go back to home, select the app and switch. Not a huge deal, but it's slower if you switch apps often.
  • Sadly it does not come with bluetooth. Bluetooth would have been a perfect way to get internet from your phone via bluetooth tethering without killing your batteries. While having callers show up on BT could be useful for some, most cars do this now, so I don't really need that feature, and the audio from that mirror isn't great anyway.
  • The rear camera wire is not good though because it contains a big adapter bulge in the middle which makes it impossible to route inside your car due to how thick that bit is.
  • The rear camera is only 480p and poor quality but it will read a place from a car that is stopped behind yours. If any car is moving, the picture will be unusable for license plates but good enough to see that someone else hit you (it is mostly the same camera than the older 5" mirror).
  • The rear camera has a red wire you're supposed to connect to your rear headlights. This is however difficult to do on my car, and I wish they had just used a light sensor to remove the extra wiring requirement. In my testing, I did not wire the night vision LED, although to be honest, I doubt they can do much except maybe to video the outline of someone who would come on foot to break your rear window. If you're driving, headlights from cars behind you totally overwhelm the camera.
  • Because the hardware does not support motion detection, wiring to always on power is not very useful.
  • So, my verdict?

  • If you are looking for a mirror that can run android apps and you are ok with a very well integrated dual dashcam, to show that the other car hit you, and you didn't reverse into it, this will work. If someone who does a hit and run on you stops before driving off, you may not get their plate. If you're hoping to get the plate from someone who cut you off, it may or may not work for that depending on lighting conditions
  • If you want best video quality and don't need dual cam, the Wheel Witness HD Pro is the best one I've seen so far, read my review, but keep in mind that it's a big single dashcam without android.
  • If you don't really want/need to add 3rd party android apps, and all you want is a basic dual cam rear view mirror, then the old 5" will likely work just as well for you while having the advantage of keeping the screen separate from the mirror area you use to see cars behind you
  • But to repeat myself, if you're looking for a smart mirror that can run android apps while also being a dual dashcam. This device is definitely best in class today. You should be happy with it.
  • Shots from the camera:

    in some cases of moving cars, you can barely read the plate
    in some cases of moving cars, you can barely read the plate

    most times, it's almost readable, but not quite
    most times, it's almost readable, but not quite

    same here
    same here

    low speed, close to car, but not close enough
    low speed, close to car, but not close enough

    finally
    finally

    2016/02/29 Hacking a thinkpad slim tip adapter to output more than 90W (required to charge a Thinkpad P70)
    π 2016-02-29 00:00 in Electronics, Linux
    The thinkwiki power connector page explains very nicely how Lenovo power supplies come in round and slimp (rectangular) tip, and can be 35, 45, 65, 90, 135, 170, and 230W. The way the laptop knows how much power it can draw, is by measuring a resistor between the center pin and ground. So far, most of my power supplies had been 90W, and all my thinkpads, including the T540p, were ok enough with that, even if maybe they were not always charging at full speed.

    However, when I got my thinkpad P70, although it also uses around 25W in typical use, which means plenty of extra wattage on a 90W power supply to charge the battery, the P70 was unfortunately designed not to charge under any condition unless it recognizes a power supply that's at least 135W (it ships with a 170W power supply, and it's a huge monster brick). I'm pretty mad at lenovo for that because they could totally have designed the P70 to charge at a slower rate from a 90W power supply, or at least when the laptop is sleeping, but no, even when it's sleeping, it will just not charge at all. Sadly, this means that the RAVPower 23000mAh Portable Charger Power Bank External Battery Pack I bougght, was able to power the laptop, but not charge it. I guess in this case, it's not a huge issue since energy would be wasted trying to charge the laptop battery instead of just powering it, but still, that was disappointing.

    here, the pack is powering my laptop at 20V, 2.1A
    here, the pack is powering my laptop at 20V, 2.1A

    The P70 will function off a 90W power supply by just not discharging its battery, and consuming around 1.5A at 20V (i.e. 30W), so that meant that not only I had to buy some bulky 135W power supplies (less bulky than 170W thankfully), but also that I was now unable to use my travel iGo 110W 12V DC power supply, which I use to charge in cars. For AC, I did buy a Lenovo ThinkPad 135W (Slim Tip) Replacement AC Adapter for lenovo ThinkPad T440p 20AN 20AW, Lenovo ThinkPad T540p 20BE 20BF: https://www.amazon.com/gp/product/B00HOMBO0M


    But for car use, I was upset about the situation, so I read up and realized I only had to change the resistor in my barrel connector to slimtip adapter and that would likely allow my thinkpad to start charging from my 110W iGo power supply. The hard part was finding where the resistor was since I had to replace a small resistor with a bigger one (the other way around, I could have trivially added a resistor in series).

    So, I started with the AC Charger Power Supply Adapter Converter Cable Cord For Lenovo ThinkPad : https://www.amazon.com/gp/product/B00T013J44 and had to find where the resistor was hidden. After cutting the cable in 2, I convfirmed it was on the slimtip side, so I had to take the plug apart until I found it.



    After that, it was just a matter of adding a new resistor, and in the end, I added a resistor bridge, so that I could select no resistor, 550 Ohm (90W), 1kOhm (135W), or even 1.9kOhm (170W). For my laptop, though 135W was enough, and my iGo only delivers 110W anyway.



    I added a amp/volt meter (RioRand 2in1 4.5-30V/10A Digital Voltage Detector DC Current Volt Amp Meter|http://www.amazon.com/gp/product/B00JE42W86]), so I can tell how much current is flowing and whether I might be exceeding the wattage of the power supply. When my laptop is running, and the battery charging, it's now using 5.6A (just about 110W)


    So problem solved. I'm not super happy at Lenovo for having stupidly designed their Thinkpad P70 not to charge from a 90W power supply under any use case, even at reduced speed, or even with the laptop sleeping or off, but since I already had the laptop, I was stuck with it, so this little resistor hack did the trick. Hope this helps someone.

    2016/02/22 Thinkpad P70 NVME vs M2 Sata vs 2.5inch Sata SSD
    π 2016-02-22 00:00 in Linux
    So far I had been using the Lenovo T540 which I got because of its 3K 15" screen, but I really hated that generation of thinkpads due to the lack of mouse buttons (hence the bluetack on the pad, used to know where I can click to emulate buttons 1, 2, and 3), and someone who decided it would be great to remove almost all LEDs, including caps lock, and hard drive activity. So when the P70 came out, I was very interested in it, not just because they fixed the LED and mouse button situation, but especially because of the first thinkpad with a 4K screen. The P50 has the same resolution in 15", but I figured if I'm going to have 4K's worth of dots (8 million pixels), I might as well have a 17" screen.

    So let's be honest and say that it is a big a heavy laptop, but that was an acceptable tradeoff for me. CPU wise, it's actually no faster than the T540, but the big new thing is the 2 M2 slots in addition to capacity for 2 2.5" Sata drives, like the T540 (one goes in place of the DVD Burner using a special tray).

    yes, it's big
    yes, it's big

    the 2 M2 slots are on the right, and the 2nd drive goes under where the SSD is visible in this picture
    the 2 M2 slots are on the right, and the 2nd drive goes under where the SSD is visible in this picture

    size of M2 sticks compared to the SSD (with free shot of the 96Wh battery :) )
    size of M2 sticks compared to the SSD (with free shot of the 96Wh battery :) )

    Comparison with the T540
    Comparison with the T540

    So the P70 can currently house 5TB of storage and I was interested to see how well the M2 slots worked compared to the Sata ones under linux. First thing to note is that currently M2 slots can only house 512MB of storage each vs 2TB for the 2.5" Sata slots that have more room. Sadly, Lenovo is still not selling the Drive Caddy Adapter for the P70, but the good news is that you can buy this $17 Soogood 2nd HDD SSD Hard Drive Caddy Adapter Use For Lenovo Thinkpad T440p T540p W540p from Amazon, unscrew the little tab from the DVD Drive, screw it on the drive caddy adapter, and it'll work in the P70.

    To try that out, I got the following (with price by GB as of 2016/02), in increasing price per GB: - 4.6c/GB: Seagate 2TB Laptop HDD SATA 6Gb/s 32MB Cache 2.5-Inch Internal Bare Drive (ST2000LM003) - 30c/GB: SATA6G: Samsung 850 EVO 2 TB 2.5-Inch SATA III Internal SSD (MZ-75E2T0B/AM) - 33c/GB: M2/SATA Samsung 850 EVO 500 GB M.2 3.5-Inch SSD (MZ-N5E500BW) - 64c/GB: M2/NVMe: Samsung 950 PRO -Series 512GB PCIe NVMe - M.2 Internal SSD 2-Inch MZ-V5P512BW

    So it's interesting to note that SSDs still cost 6.5x more than a hard drive (actually I was surprised to see how cheap the 2.5" 2TB hard drive was). Next, it's good to know that M2/Sata SSDs cost about the same price per GB than full size Sata SSDs. And last, at twice the price, the M2/NVMe SSD is no bigger than the SATA M2 version, but clearly more expensive. It's supposed to be up to 4 times faster in bulk transfer rate due to the use of 4 PCI lanes, but I was curious to see how much faster it would actually be for real use with linux.

    First, is looking at support. To make things interesting, I decided to make the NVMe SSD my boot drive. The Thinkpad bios of course supports it fully, but a big gotcha is that it'll only boot if you use a GPT partition with EFI. Setting that up from scratch was a pain, but I got through it, and it's out of topic for this post.


    Next, is linux support. Thankfully linux has supported NVME for a while now. I just set CONFIG_BLK_DEV_NVME=y in my kernel so that I didn't have to worry about the module being in my initrd. Device partitions show up as /dev/nvme0n1p1 and so forth.

    Now, the benchmarks. For my main filesystems, I have btrfs on top of dmcrypt, created with:

    cryptsetup luksFormat --align-payload=8192 -s 256 -c aes-xts-plain64 /dev/device

    In the tests below, I did used hdparm, iozone, and 2 kinds of dd, ddd with data, and dd0 copying just /dev/zero:

    ddd test: sync; dd if=/mnt/ram/file of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=100M
    dd0 test: sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M

    Let me start with the summary conclusions first, since this is what most people probably care about:

  • NVMe is faster for big contiguous I/O, even through dmcrypt, that's good.
  • M2 NVMe and M2 sata do not seem to go through buffer cache for writes, but SATA/6GB does
  • When using buffer cache, SATA/6GB beats NVMe/M2 and SATA/M2 by a lot on block reads. Why?
  • For random I/O, NVMe is up to 50% faster, and faster with ext4 than btrfs
  • Encrypted NVMe is a bit faster than non encrypted Sata/M2
  • At $328 for 512GB M2/NVMe vs $168 for 500GB M2/Sata, unless you're doing big contiguous I/O, the 2x price difference is hard to justify, cached I/O and random I/O are not significantly faster on NVMe.
  • More detailled summaries related to the test results below:

  • NVMe only really looks faster on big block sequential read/write (indeed 4X read, 2X write). On Random I/O, it's no faster. Other overheads seem to kill its performance advantage.
  • 2TB Sata 6GB SSD is faster for read/write encrypted than NVMe is non encrypted (except hdparm). Looks like the block caching layer works better for Sata than NVMe?
  • iozone through block cache is faster on M2/SATA than M2/NVMe, very weird.
  • iozone direct I/O shows NVMe is fastest (by 50% only) and external SATA just a bit faster than M2/Sata. Clearly the block caching layer hides differences for iozone.
  • when using dmcrypt, NVMe is only marginally faster in iozone than Sata/M2 or Sata/6G
  • kernel build speed is same on SATA/M2 and NVMe/M2, encrypted or not, but SATA6G is 10% faster (probably the same effect that block cache works better on SATA/6G than SATA/M2 or NVMe/M2)
  • Thankfully on big sequential IO (ddd test), NVMe finally shows being 4x faster on read, and 2.5x faster on write.
  • ext4 does better on iozone -I (directIO) than btrfs, 2x as fast on random read for NVMe
  • So there you go. I realize that my test suite may not have been perfect, but hopefully the results are helpful to others. I'm hoping linux will get fixed, or that I can find a tunin g parameter to bridge the gab in cached IO speed between Sata 6G 2.5" and M2 slots. Below are test results in more details are you go down the page.

    Here are test results for cached IO:

    		SATA/M2 dmcrypt	 SATA/M2	NVMe dmcrypt	NVMe		SATA6GB/dmcrypt
    hdparm -t	 534MB/s	 517MB/s	1307MB/s	2140MB/s	 534MB/s
    

    ddd 10GB read 550MB/s 560MB/s 2000MB/s 2400MB/s 550MB/s ddd 10GB write 500MB/s 503MB/s 1300MB/s 1200MB/s 506MB/s

    dd with /dev/zero hits optimizations that actually penalize NVMe: dd0 10GB read 7GB/s 6.7GB/s 2.3GB/s 4.4GB/s 6.6GB/s dd0 10GB write 495MB/s 503MB/s 1.3GB/s 1.3GB/s 2.0GB/s

    iozone -e -a -s 4096 -i 0 -i 1 -i 2 (cache makes Sata6G faster than M2, weird): ioz read 4KB 1760MB/s 1790MB/s 675MB/s 766MB/s 7863MB/s ioz write 4KB 268MB/s 298MB/s 295MB/s 291MB/s 777MB/s ioz ranread4KB 5535MB/s 7392MB/s 3185MB/s 7261MB/s 7892MB/s ioz ranwrite4KB 288MB/s 329MB/s 205MB/s 381MB/s 796MB/s

    For comparison, I then used directio to bypass the caching layer:

    iozone -I -e -a -s 4096 -i 0 -i 1 -i 2 (direct IO):
    		SATA/M2 dmcrypt	 SATA/M2	 NVMe dmcrypt	 NVMe		 SATA6GB
    										 dmcrypt notcrypted
    		 btrfs		 btrfs   ext4	 btrfs		 btrfs   ext4	 btrfs     ext4
    ioz read 4KB	 255MB/s	 303MB/s 408MB/s 303MB/s	 396MB/s 562MB/s 310MB/s 379MB/s
    ioz write 4KB	 195MB/s	 238MB/s 344MB/s 257MB/s	 358MB/s 361MB/s 233MB/s 365MB/s
    ioz ranread4KB	 305MB/s	 351MB/s 482MB/s 476MB/s	 699MB/s1434MB/s 309MB/s 475MB/s
    ioz ranwrite4KB	 265MB/s	 223MB/s 392MB/s 260MB/s	 217MB/s 315MB/s 254MB/s 366MB/s

    Details of each test, per type of drive;

    ===============================================================================
    saruman M2 SATA 512GB encrypted btrfs
    

    saruman:/tmp# hdparm -t /dev/mapper/cryptroot Timing buffered disk reads: 1604 MB in 3.00 seconds = 534.03 MB/sec

    iozone -e -a -s 4096 -i 0 -i 1 -i 2: random random kB reclen write rewrite read reread read write 4096 4 257076 281089 1761711 6094733 6066754 290373 4096 512 277108 295167 1588844 8426437 11128258 318731 4096 4096 268940 308248 1760087 8062616 8377131 320802

    iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 38626 45227 102236 111141 30936 64317 4096 512 138467 128878 134674 137832 140067 126248 4096 4096 195439 273100 255379 307300 305605 265093

    saruman:/mnt/mnt# sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M 10485760000 bytes (10 GB) copied, 21.1761 s, 495 MB/s 10485760000 bytes (10 GB) copied, 1.49373 s, 7.0 GB/s

    kernel 4.4.1 make -j8: real 17m54.712s user 126m26.620s sys 6m21.948s

    btrfs send/receive encrypted partition to non encrypted, 87GB: 10mn30

    saruman M2 SATA non encrypted btrfs ----------------------------------- saruman:/mnt/mnt4# hdparm -t /dev/sdc4 /dev/sdc4: Timing buffered disk reads: 1554 MB in 3.00 seconds = 517.93 MB/sec

    iozone -e -a -s 4096 -i 0 -i 1 -i 2: random random kB reclen write rewrite read reread read write 4096 4 285020 297565 1739944 7434579 6605595 305785 4096 512 310937 336617 1298278 3703511 5483860 299416 4096 4096 298433 317101 1790911 7392988 7434579 337476 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 47219 93497 118900 126065 39160 86462 4096 512 214381 213388 194307 209215 206951 209289 4096 4096 238792 221839 303768 352951 351342 223618 ext4 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 119524 146035 150173 159105 53090 140697 4096 512 358954 354810 366466 423088 419760 375542 4096 4096 344087 398828 408259 478337 482569 392487

    saruman:/mnt/mnt3# sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M 10485760000 bytes (10 GB) copied, 20.8537 s, 503 MB/s 10485760000 bytes (10 GB) copied, 1.55651 s, 6.7 GB/s

    kernel 4.4.1 make -j8: real 17m55.612s user 126m31.952s sys 6m27.452s

    ******************************************************************************** saruman M2 NVMe 512GB encrypted btrfs

    saruman:/tmp# hdparm -t /dev/mapper/cryptroot2 /dev/mapper/cryptroot2: Timing buffered disk reads: 3924 MB in 3.00 seconds = 1307.56 MB/sec

    iozone -e -a -s 4096 -i 0 -i 1 -i 2: random random kB reclen write rewrite read reread read write 4096 4 284205 341651 742181 6195843 6178018 341101 4096 512 314351 319573 864883 8865630 8902382 384993 4096 4096 295741 201042 675234 3281854 3185110 205974 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 80042 83160 122616 127129 41421 53963 4096 512 168713 153333 167710 209923 198123 168026 4096 4096 257968 258566 303023 490828 476440 260014

    saruman:/mnt/mnt2# sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M 10485760000 bytes (10 GB) copied, 8.01494 s, 1.3 GB/s 10485760000 bytes (10 GB) copied, 4.63397 s, 2.3 GB/s

    kernel 4.4.1 make -j8: real 17m57.513s user 126m58.360s sys 6m25.164s

    btrfs send/receive encrypted partition to non encrypted, 87GB: 7mn (33% faster than Sata M2)

    saruman M2 NVMe non encrypted btrfs ----------------------------------- saruman:/mnt/mnt4# hdparm -t /dev/nvme0n1p4 /dev/nvme0n1p4: Timing buffered disk reads: 6422 MB in 3.00 seconds = 2140.38 MB/sec

    iozone -e -a -s 4096 -i 0 -i 1 -i 2: random random kB reclen write rewrite read reread read write 4096 4 274808 271851 684271 2634219 2280673 177630 4096 512 290191 336755 668196 3362795 4039655 184779 4096 4096 291427 340345 766588 7355007 7261741 381768 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 94814 117116 147645 159695 44075 108039 4096 512 271130 267800 239969 325933 301841 271062 4096 4096 358602 275933 396591 719099 699939 217665 ext4 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2: 4096 4 107281 200735 205900 263035 54832 124219 4096 512 537478 374641 525060 1173664 1139338 558807 4096 4096 361545 526137 562632 1483477 1434069 315883

    saruman:/mnt/mnt4# sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M 10485760000 bytes (10 GB) copied, 7.90653 s, 1.3 GB/s 10485760000 bytes (10 GB) copied, 2.35863 s, 4.4 GB/s

    kernel 4.4.1 make -j8: real 17m54.221s user 126m46.264s sys 6m10.592s

    ******************************************************************************** saruman Samsung Evo 850 2TB SSD encrypted btrfs

    hdparm -t Timing buffered disk reads: 1606 MB in 3.00 seconds = 534.87 MB/sec

    iozone -e -a -s 4096 -i 0 -i 1 -i 2: random random kB reclen write rewrite read reread read write 4096 4 513924 738957 8586475 9144037 8017464 697665 4096 512 772100 820362 9287391 10136778 10586522 840551 4096 4096 719099 777517 7863339 8047509 7892238 796108

    iozone -I -e -a -s 4096 -i 0 -i 1 -i 2 4096 4 76626 47961 92886 80947 36063 63788 4096 512 135087 138998 143127 150981 144393 132219 4096 4096 233245 234058 310797 311552 309855 254080

    ext4 iozone -I -e -a -s 4096 -i 0 -i 1 -i 2 (unencrypted) 4096 4 118013 141212 130575 111534 42343 138654 4096 512 336347 312192 332847 414404 424542 342707 4096 4096 365227 364638 379298 484160 475122 366536

    saruman:/tmp# sync; dd if=/dev/zero of=file bs=100M count=100 conv=fdatasync; dd if=file of=/dev/null bs=1M 10485760000 bytes (10 GB) copied, 5.23919 s, 2.0 GB/s 10485760000 bytes (10 GB) copied, 1.58287 s, 6.6 GB/s

    kernel 4.4.1 make -j8: real 16m4.305s user 104m0.816s sys 7m2.832s

    2016/02/01 ESPlant, Arduino Miniconf at Linux.Conf.AU 2016
    π 2016-02-01 00:00 in Arduino, Linux
    Another year, another arduino miniconf, this year, the LCA open hardware folks brought us the ESPlant, a new board meant to monitor plants, and based off the ESP8266, the super cheap wifi chip that can now be used with the arduino IDE and libraries thanks to a compat layer.

    Jon, opening the miniconf
    Jon, opening the miniconf

    The Melbourne Hardware Hacking team who worked on this
    The Melbourne Hardware Hacking team who worked on this





    Jon gave a cool talk on the hardware assembly machine he built to put those boards together, impressive:



    Short of having a plant nearby, I concentrated on making pretty lights on the LED strip :)


    blinkie achieved :)
    blinkie achieved :)

    I added my blinky code here: https://github.com/marcmerlin/ESPlant

    Demo:

    2016/02/01 Linux.conf.au 2016, Geelong
    π 2016-02-01 00:00 in Linux
    Another year, another LCA, this time by Geelong, Australia (located 1h from Melbourne and 1h from Ballarat, 2 previous LCA locations).

    Like every year, it was great to see everyone again.

    A few pictures from the conf:

    where we stayed, Deakin, University
    where we stayed, Deakin, University


    The robot miniconf had cool little robots:




    During the radio miniconf, we did some beacon finding with yagis:




    LCA still had a custom designed board that encodes HDMI video into open video formats on linux via USB:


    Among the talks, tridge gave a demo of his new code for quadplanes (quadcopters that turn into planes) for the next challenge they're preparing for:




    Catching up with people in the hallway track and evening parties was good as usual:



    Stephen, keeping a great WiFi network working like every year
    Stephen, keeping a great WiFi network working like every year


    nothing beats seeing tridge in person to work with him on my ardupilot crash plane into the ground bug :)
    nothing beats seeing tridge in person to work with him on my ardupilot crash plane into the ground bug :)




    After a week, it was all over again. We all had a great time, thanks all:


    I hung out with the Melbourne Open Hardware Hackers after conf close, before getting ready for our great ocean road trip the next day:


    See more images for Linux.conf.au 2016, Geelong

    More pages: January 2017 October 2016 August 2016 July 2016 June 2016 February 2016 January 2016 May 2015 March 2015 January 2015 October 2014 May 2014 April 2014 March 2014 January 2014 November 2013 September 2013 May 2013 March 2013 January 2013 December 2012 August 2012 May 2012 March 2012 January 2012 December 2011 August 2011 July 2011 January 2011 October 2010 August 2010 June 2010 April 2010 March 2010 January 2010 December 2009 November 2009 September 2009 August 2009 July 2009 May 2009 January 2009 December 2008 November 2008 October 2008 January 2008 November 2007 August 2007 July 2006 January 2006 August 2005 April 2005 November 2004 March 2004 February 2004