Domoticz on Orange Pi zero

Quote

Having played a lot with Raspberry Pi, I decided it is time for something else: the Orange Pi.

The Orange Pi Zero plus to be precise. The Zero is a potent, very small, Raspberry like machine with Ethernet, Wifi and standard USB port out of the box. They can be bought for some 12 EUR, for instance at Banggood.

Here is my manual for getting the Orange up and running and installing Domoticz, Mosquitto, Homekit and more.

For getting things started you can use this excellent tutorial:

Install Domoticz on an Orange Pi Lite (WiFi) under Armbian

Basically this is what you do:
first get Armbian for the Zero plus
https://dl.armbian.com/orangepizeroplus/Debian_stretch_next.7z

Put the image on an micro Sd-card, using Etcher.

Load the SD-card in the your Zero.

The first step is a bit of a nuisance. You have to get the Zero connected to your Wifi network and log in through SSH.
Luc Small has a good tutorial for this.

One way of getting in the Zero, is by connecting it to an ethernet cable connecting to your router.
Luc writes:

To boot your Orange Pi Zero for the first time:

  • Insert your micro SD card imaged with Armbian into the micro SD slot on the Orange Pi Zero.
  • Connect your Orange Pi Zero using an Ethernet cable to your router.
  • Connect your 5V power supply to the Orange Pi Zero via the micro USB connection.
  • Plug your 5V power supply into the mains.
  • Within a minute or two the LEDs on the ethernet port of the Orange Pi Zero should start to flash, indicating network activity. Assuming your router is configured for DHCP, the Orange Pi Zero should automatically obtain an IP address on your network.

    In order to log into the Orange Pi Zero, we need to know the IP address it has been assigned. Probably the easiest way to obtain this is to login to the administration interface of your router (usually provided as a web interface). It varies from model to model, but many routers will provide a screen which lists DHCP leases. With any luck it will be possible to identify the Orange Pi Zero in the list of DHCP leases and see which IP address it has been allocated. One approach is to take note of the IP addresses in the list before connecting your Orange Pi Zero to the network. Then connect your Orange Pi Zero to the network and to power, wait for it to boot (a minute or two) and refresh the list of DCHP leases. It should now have an extra entry and that entry should correspond to the IP address assigned to your Orange Pi Zero.

    Once you have the Zero’s IP address you can log in using SSH or PuTTY.
    On a Mac open a terminal window. (applications->terminal)

    type
    ssh root@IPADDRESS
    You will be asked for the password for user root. By default the password is 1234

    You will immediately be asked to change your password. To do so:

    Enter your (current) UNIX password as 1234 and press enter.

    At the Enter new UNIX password prompt, enter a new password and press enter.
    At the Retype new UNIX password prompt, enter the new password again and press enter.
    Next you will be asked to create a new account. This is a less privileged account for everyday use:

    At the Creating new account. Please provide a username (eg. your forename) prompt, enter a username for the new account and press enter.

    (Creating a user domoticz
    Even if it is not necessary, it is better to create a user domoticz

    adduser domoticz
    The new user is added to the sudo group to allow it to use this command.

    adduser domoticz sudo
    Change current user

    su domoticz)

    At the Enter new UNIX password prompt, enter a password for this account and press enter.
    At the Retype new UNIX password prompt, enter the password again and press enter.
    You will be asked to enter your Full Name and few other details. Enter them, if applicable, or simply press enter for blank.
    When asked Is the information correct? [Y/n], press the y key and then press enter.
    Within a few seconds you should be presented with a welcome message and a prompt:
    Congratulations – you have logged into your Orange Pi Zero for the first time.

    (we follow this site below:

    Install Domoticz on an Orange Pi Lite (WiFi) under Armbian


    )
    Before we go into the installation of Domoticz on the Orange Pi, let’s start by updating the system.

    sudo apt-get update
    sudo apt-get upgrade

    Now we can install domoticz

    sudo curl -L install.domoticz.com | bash
    Follow the instructions presented on screen.

    Due to a change in the libraries, this is not the version we can use. We have to switch to the beta version. First we need to update to the current beta.

    cd

    Domoticz should now work. Test this by surfing to the address provided in the setup.

    Time to install
    Node Red and Mosquitto

    bash <(curl -sL https://raw.githubusercontent.com/node-red/raspbian-deb-package/master/resources/update-nodejs-and-nodered) apt-get install mosquitto

    On the importance of the serial comma (the Oxford comma)

    Quote

    Commas matter, full stop.

    Here is an example.
    The canning, processing, preserving, freezing, drying, marketing, storing, packing for shipment or distribution of:
    (1) Agricultural produce;
    (2) Meat and fish products; and
    (3) Perishable foods.

    This comes from Maine law, which requires time-and-a-half pay for each hour worked after 40 hours. It, however, carved out exemptions for the above. Simple, right?

    Three truck drivers sued a dairy company in 2014 for what they said was four years’ worth of overtime they had been denied. Mind you, overtime should be paid at 150%, not small beer.

    What does the part after the last comma in the first sentence ‘packing for shipment or distribution of’ mean? Is it packing for (shipment or distribution), or does it mean the distribution of the three categories is exempted.
    The court has now ruled that this indeed is unclear. The dairy company in Portland, Me., agreed to pay $5 million to the drivers. No small beer indeed.

    In the meantime, the Maine legislature has addressed the issue and reformulated the provision:
    "The canning; processing; preserving; freezing; drying; marketing; storing; packing for shipment; or distributing of:
    (1) Agricultural produce;
    (2) Meat and fish products; and
    (3) Perishable foods."

    All work on said products is overtime after 40 hours. Quite what one would expect, imho.

    source: NYTimes, 9 Feb 2018

    De anti-doping en data protectie trilogie

    Quote

    De Wet uitvoering antidopingbeleid: De gespannen relatie tussen anti-dopingmaatregelen en gegevensbescherming, deel 1- de anti-doping wereld
    van der Sloot, B., Paun, M. & Leenes, R. 2017 In : Privacy & Informatie. 2017-1

    De Wet uitvoering antidopingbeleid: De gespannen relatie tussen anti-dopingmaatregelen en gegevensbescherming, deel 2
    van der Sloot, B., Paun, M. & Leenes, R. 2017 In : Privacy en informatie. 2017-3

    De Wet uitvoering antidopingbeleid: De gespannen relatie tussen anti-dopingmaatregelen en gegevensbescherming, deel 3 
    van der Sloot, B., Paun, M. & Leenes, R. 2017 In : Privacy & Informatie.

    Principles. For what they’re worth

    Quote

    Mark these words uttered by Whatsapp founder Koum in June 2012:

    “Advertising isn’t just the disruption of aesthetics, the insults to your intelligence and the interruption of your train of thought,” added Koum, a future member of Facebook’s board of directors, with a say on how the social networking company will be run. “Remember, when advertising is involved you the user are the product.”

    [via USA Today]