Hi,
Since I've had my very first Raspberry Pi and on my Raspberry Pi 2 (and 3) I have used the following udev rule in /etc/udev/rules.d/10-local.rules as per: https://wiki.archlinux.org/index.php/bluetooth under Arch Linux to automatically start my Bluetooth adpater at boot time:
$this->bbcode_second_pass_code('', 'ACTION=="add", KERNEL=="hci0", RUN+="/usr/bin/hciconfig %k up"')
Until this week when systemd was updated to version 232-4 my udev rule does not appear to run as the bluetooth adapter is in its default state of "DOWN".
If I revert to a back-up image (which has an older version of systemd) the rule works fine.
Also, if I run $this->bbcode_second_pass_code('', 'udevadm test /sys/devices/platform/soc/3f201000.uart/tty/ttyAMA0/hci0') the rule is shown as being triggered:
$this->bbcode_second_pass_code('', '
...
RUN '/usr/bin/hciconfig %k up' /etc/udev/rules.d/10-local.rules:1
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.uart/tty/ttyAMA0/hci0
DEVTYPE=host
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=10264771
run: '/usr/bin/hciconfig hci0 up'
Unload module index
Unloaded link configuration context.
')
If I run the hciconfig command myself it brings up the Bluetooth adapter fine. I have also tried replacing the command in the rule to $this->bbcode_second_pass_code('', '/usr/bin/echo foo > /tmp/foo.txt') but this does not get run either.
Could this be a bug in systemd-232-4?
Thanks,
Neil.