The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,862 other subscribers

Archive for the ‘Raspberry Pi’ Category

Powering Raspberry Pi devices from a Fritz!Box USB connection

Posted by jpluimers on 2017/03/30

I tried to power both Raspberry B+ and Raspberry 2 B devices via the USB ports of both a Fritz!Box 7490 and Fritz!Box 7360.

At first this works, but the Raspberry B+ devices over time would become unstable: not being able to ping and/or boot.

So below are some links on power requirements and powering Raspberry Pi A, B, A+, B+, 2B and zero.

Fazit/TL;DR: use an external power supply when available.

Read the rest of this entry »

Posted in *nix, Development, Fritz!, Fritz!Box, Hardware Development, Internet, Linux, openSuSE, Power User, Raspberry Pi, SuSE Linux | Leave a Comment »

Mac OS X – serial communication programs

Posted by jpluimers on 2017/03/30

Some links that helped me getting FTDI USB serial communication to Raspberry Pi systems going:

–jeroen

Posted in Apple, Communications Development, Development, Hardware Development, Hardware Interfacing, iMac, Legacy Ports: COM, Mac, Mac OS X / OS X / MacOS, MacBook, MacBook Retina, MacBook-Air, MacBook-Pro, MacMini, OS X 10.10 Yosemite, OS X 10.9 Mavericks, Power User, Raspberry Pi, USB | Leave a Comment »

`-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)` on fresh Raspbian on Raspberry

Posted by jpluimers on 2017/03/24

Every time I logged onto a freshly installed Rasbian system (Debian Jessie), I had this message:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Aug 27 19:52:33 2016 from 192.168.171.24
-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)

Asking for the locale settings would give this:

jeroenp@raspberrypi:~ $ locale
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=en_GB.UTF-8
LANGUAGE=
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=en_US.UTF-8

Searching for raspbian jessie “-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)” I found fix locale issue #15 · scaleway/image-debian@543e9b4 [WayBack] that fixes Locale issue on Debian Jessie · Issue #15 · scaleway/image-debian · GitHub [WayBack]:

When logging into to a freshly booted debian jessie image:

-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
-bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)

Source: Locale issue on Debian Jessie · Issue #15 · scaleway/image-debian

I changed the crux of that solution to this one:

echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && locale-gen

When running, it showed this:

# echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && locale-gen
Generating locales (this might take a while)...
  en_GB.UTF-8... done
  en_US.UTF-8... done
Generation complete.

And logging this:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Aug 27 20:26:34 2016 from 192.168.171.24

Problem solved: 1 line of code!

–jeroen

Posted in *nix, Arduino, Debian, Development, Hardware Development, Linux, Power User, Raspberry Pi, Raspbian | 1 Comment »

The woods and trees of OpenSuSE on single-board computers – image abbreviations – and getting it installed using OS X

Posted by jpluimers on 2017/02/27

Finding the right image

There are many single-board computers on the OpenSuSE hardware-compatibility list (HCL), including:

A lot of them have ready to go images, often for Tumbleweed, however none of the pages explain the below image differences hence the one-line for each:

Since I wanted a headless system, JeOS was what I needed.

As it wasn’t available for my ODroid C1+ but was for my Raspberry Pi 2 and as my main machine is a 15″ Retina MacBook Pro Late 2013 [WayBack] below are the steps I used to get the image working.

Installing the Raspberry Pi 2 image using OS X

The below Raspberry Pi2 link will redirect to the correct image in the generic download directory http://download.opensuse.org/repositories/devel:/ARM:/Factory:/Contrib:/RaspberryPi2/images/

http://download.opensuse.org/repositories/devel:/ARM:/Factory:/Contrib:/RaspberryPi2/images/openSUSE-Tumbleweed-ARM-JeOS-raspberrypi2.armv7l.raw.xz

For other Raspberry Pi versions, you can find them here:

http://download.opensuse.org/repositories/devel:/ARM:/Factory:/Contrib:/RaspberryPi3/images/openSUSE-Tumbleweed-ARM-JeOS-raspberrypi3.aarch64.raw.xz

http://download.opensuse.org/ports/armv6hl/tumbleweed/images/openSUSE-Tumbleweed-ARM-JeOS-raspberrypi.armv6l-Current.raw.xz

I installed on a 8 gigabyte SD card that revealed itself as /dev/disk1 using this diskutil command (via osx – List all devices connected, lsblk for Mac OS X – Ask Different [WayBack])

diskutil list

So this wrote the image to SD card in a sudo su - prompt:

targetDevice="disk2"
unxz --keep openSUSE-Tumbleweed-ARM-JeOS-raspberrypi2.armv7l-2016.08.20-Build2.1.raw.xz; \
diskutil umount "/dev/${targetDevice}s1"; \
dd bs=1m of="/dev/r${targetDevice}" if=openSUSE-Tumbleweed-ARM-JeOS-raspberrypi2.armv7l-2016.08.20-Build2.1.raw; \
sync; \
diskutil list; \
diskutil eject "/dev/${targetDevice}"

or if you want to select which image to “burn”:

targetDevice="disk2"
imageName="openSUSE-Tumbleweed-ARM-JeOS-raspberrypi2.armv7l-2016.08.20-Build2.1.raw"
imageName="openSUSE-Tumbleweed-ARM-JeOS-raspberrypi.armv6l-2016.11.23-Build2.22.raw"
imageName="openSUSE-Tumbleweed-ARM-JeOS-raspberrypi3.aarch64-2017.01.12-Build3.2.raw"
unxz --keep ${imageName}.xz; \
diskutil umount "/dev/${targetDevice}s1"; \
dd bs=1m of="/dev/r${targetDevice}" if=${imageName}; \
sync; \
diskutil list; \
diskutil eject "/dev/${targetDevice}"

A few notes:

Read the rest of this entry »

Posted in *nix, Development, Hardware, Hardware Development, Linux, Odroid, openSuSE, Power User, Raspberry Pi, Single-Board Computers, SuSE Linux, Tumbleweed | 1 Comment »

#220 feature `SKIP_FIRMWARE` by jpluimers · Pull Request #221 · Hexxeh/rpi-update

Posted by jpluimers on 2016/12/13

Reminder to self: Fix #220 feature SKIP_FIRMWARE by jpluimers · Pull Request #221 · Hexxeh/rpi-update

It’s bash. How hard can it be.

(no that was a rhetorical question).

–jeroen

Posted in *nix, *nix-tools, Debian, Development, Hardware Development, Linux, openSuSE, Power User, Raspberry Pi, Raspbian, SuSE Linux, Tumbleweed | Leave a Comment »

Meet PoisonTap, the $5 tool that ransacks password-protected computers | Ars Technica

Posted by jpluimers on 2016/11/23

Too bad Ars Technica redirects https to http while preaching anyone should use https.

Anyway: OS device driver install and network configuration should probably be less automatic than it is now.

All the more reason to go fully https (hello LetsEncrypt, goodbye Embarcadero).

A video showing how it works is below.

The clever device emulates a USB ethernet adapter (that virtually every operating system has default drivers for) then fakes being 1.0.0.1 handing out DHCP address 1.0.0.10 with a netmask of 128.0.0.1 thereby routing almost all network traffic over it.

It makes a tiny peace of the internet unreachable (like 1.0.0.1 itself in Brisbane Australia).

More details on how it works at [WayBackSamy Kamkar: PoisonTap – exploiting locked computers over USB.

Lets not leave this out:

Securing Against PoisonTap

Server-Side Security

If you are running a web server, securing against PoisonTap is simple:

  • Use HTTPS exclusively, at the very least for authentication and authenticated content
    • Honestly, you should use HTTPS exclusively and always redirect HTTP content to HTTPS, preventing a user being tricked into providing credentials or other PII over HTTP
  • Ensure Secure flag is enabled on cookies, preventing HTTPS cookies from leaking over HTTP
  • When loading remote Javascript resources, use the Subresource Integrity script tag attribute
  • Use HSTS to prevent HTTPS downgrade attacks

Desktop Security

  • Adding cement to your USB and Thunderbolt ports can be effective
  • Closing your browser every time you walk away from your machine can work, but is entirely impractical
  • Disabling USB ports is also effective, though also impractical
  • Locking your computer has no effect as the network and USB stacks operate while the machine is locked, however, going into an encrypted sleep mode where a key is required to decrypt memory (e.g., FileVault2 + deep sleep) solves most of the issues as your browser will no longer make requests, even if woken up

–jeroen

via Joe C. Hecht – Google+

Read the rest of this entry »

Posted in Development, Hardware Development, Raspberry Pi | Leave a Comment »

Raspberry Pi voordeel set | SosSolutions.nl

Posted by jpluimers on 2016/09/01

Raspberry Pi voordeel bundels. Raspberry Pi supersnel en gratis bij u thuisbezorgd! Want bij ons geldt; voor 16:00 besteld? Morgen in huis!

Source: Raspberry Pi voordeel set | SosSolutions.nl

Posted in Development, Hardware Development, Raspberry Pi | Leave a Comment »

Somfy Smoove Origin RTS Protocol | PushStack

Posted by jpluimers on 2016/05/24

Interesting: Somfy Smoove Origin RTS Protocol | PushStack a base to start Hacking Somfy.

The Somfy protocol is tricky as it uses rolling keys.

More interesting links:

These are in Dutch, but very interesting as they show how to do reverse engineering and getting it to work hardware wise:

Read the rest of this entry »

Posted in Arduino, Development, Hardware Development, Hardware Interfacing, Raspberry Pi | Leave a Comment »

Obsolescence Guaranteed – PiDP-8 – powered by a Raspberry Pi

Posted by jpluimers on 2016/05/02

If you have a Raspberry Pi left, then you can make this:

The PiDP-8/I is a modern replica of the 1968 PDP-8/I computer. It’s open-source hardware, so schematics, design files & software are available.

via: Obsolescence Guaranteed | PiDP-8

–jeroen

Posted in Development, Hardware Development, Raspberry Pi | Leave a Comment »

Replace Boxee by Raspberry Pi as most TV support doing video+USB keybard over HDMI

Posted by jpluimers on 2016/02/22

If for instance your Boxee gets old or breaks down, you can use a Raspberry Pi as a replacement with Kodi as media player.

This combination will understand the Video+USB over HDMI which most TV supports officially named HDMI-CEC , but most vendors “invented” their own names (see list below).

The core is the kodi support for CEC.

Basically it comes down to using three cables going to the Pi: Power from TV (or some other source), HDMI to TV, and wired Ethernet. And a distribution for RaspberryPi containing kodi will work, for instance from OpenELEC Mediacenter – Download: Raspberry Pi Builds

Chad MILLER has more details on how to get this to work: My Boxee box is getting old, but I knew of no replacements. The problem is I …

Names known for HDMI-CEC via Wikipedia:

Anynet+ (Samsung), Aquos Link (Sharp), BRAVIA Link and BRAVIA Sync (Sony), HDMI-CEC (Hitachi), E-link (AOC), Kuro Link (Pioneer), INlink (Insignia), CE-Link and Regza Link (Toshiba), RIHD (Remote Interactive over HDMI) (Onkyo), RuncoLink (Runco International), SimpLink (LG), T-Link (ITT), HDAVI Control, EZ-Sync, VIERA Link (Panasonic), EasyLink (Philips), and NetCommand for HDMI (Mitsubishi).

Because of the naming, turning on CEC can be confusing: How to Enable HDMI-CEC on Your TV, and Why You Should

–jeroen

Posted in *nix, *nix-tools, Development, Hardware Development, Hardware Interfacing, HDMI, Linux, Power User, Raspberry Pi | Leave a Comment »