Mes trouvailles du jour : 11 April 2016

  • Synology DSM root password for ssh | Primal Cortex’s Weblog
    si l’accès root en SSH au synology ne fonctionne plus, voici la solution :
    ———
    After getting the DSM 6.0 upgrade, I’ve become unable to login as root using SSH, even though I’ve been able to do it before the upgrade (DSM 5.5 or something like that).
    The solution:
    1. SSH to machine as admin user.
    2. Enter command “sudo su” and providing admin password.
    3. Enter command “synouser -–setpw root “.
    Now I’m able to logon as root using SSH again, and I didn’t have to mess with telnet.
    (Permalink)
  • That One Privacy Guy’s VPN Comparison Chart – Google Sheets
    Superbe comparatif des sevices VPN. Merci à l’auteur, enfin une liste détaillée complète !
    (via seb)
    (Permalink)

Kobo Glo/HD enable without registering or account

Mount the device by USB, right click “open on terminal”

[code language="css"]
echo "insert into user values('foo', 'foo', 'foo', 'foo', 'foo','foo','foo','foo','foo','foo','foo','foo','foo');" | sqlite3 .kobo/KoboReader.sqlite
[/code]

Eject the device, and voilà!

What the heck, I want an ebook, not registering!

Mes trouvailles du jour : 2 March 2016

  • Hofstadter’s Law
    Hofstadter’s Law: It always takes longer than you expect, even when you take into account Hofstadter’s Law.
    Tellement vrai, tous ceux qui doivent tenir des délais savent de quoi ça parle…
    (Permalink)

Mes trouvailles du jour : 1 March 2016

USB connected digital multimeter and graph plotting (UNI-T UT61E and sigrok)

Ever wanted to have nice plot (U/I curve, whatever) simply plotted?

I got 2 UNI-T UT61E with USB cable (50€ each)

With sigrok you can easily get data from many device with a single command:

sigrok-cli –driver=uni-t-ut61e:conn=BUS.DEVICE -O analog  –continuous

Where BUS and DEVICE is replaced with the output of lsusb

lsusb
Bus 002 Device 002: ID 8087:8001 Intel Corp.
Bus 003 Device 086: ID 1a86:e008 QinHeng Electronics HID-based serial adapater
Bus 003 Device 087: ID 1a86:e008 QinHeng Electronics HID-based serial adapater

In my case, as I’ve 2 devices, so 2 different commands are used:

sigrok-cli –driver=uni-t-ut61e:conn=3.86 -O analog  –continuous

sigrok-cli –driver=uni-t-ut61e:conn=3.87 -O analog  –continuous

 

But what about logging in the same file the two ouputs simultaneously?

Here comes the magical function: paste and joined pipe:

paste <(sigrok-cli –driver=uni-t-ut61e:conn=3.86 -O analog  –continuous) <(sigrok-cli –driver=uni-t-ut61e:conn=3.87 -O analog  –continuous) > measure.csv

 

I’ll let you deal with the uber simple csv processing with octave or libreoffice calc (mV, mA range condition, etc…), as this blog entry is mainly used as a personal notepad.

 

Note: if you have trouble connected with sigrok, with an error. You may need to disable the power feature, with the script pointed by blog.philippklaus.de

#!/bin/bash
# see http://www.erste.de/UT61/index.html
for dat in /sys/bus/usb/devices/*; do 
  if test -e $dat/manufacturer && grep -q "WCH.CN" $dat/manufacturer; then
    echo "Suspending ${dat}."
    echo auto > ${dat}/power/control
    echo 0 > ${dat}/power/autosuspend 
  fi      
done