0

I've recently changed my hardware from RPI2 (boot from flash card, Raspbian 8 Jessie) to RPI3 (boot from usb->ssd, Raspbian 9 Stretch), cabling and sensors are the same.

On the new RPI when I do "top", the command "w1_bus_master1" appears once every 8-10 seconds at the top with a CPU Usage of about 30% for 1-2 seconds. I can't remember having this phenomenon on my old PI.

The only thing I can kind-of relate to this, is my 1-wire module that I use for reading the temperature and humidity values of 3 sensors. But "my" actual reading (using a python script to read and save in a SQL DB) is done once every 2 minutes, so this w1_bus_master1 is running independently.

If this is a daemon how come it is bringing a peak every 10 seconds? Or did I installed something wrong?

Here my installation process

Mofified the /boot/config.txt file to include the line

dtparam=i2c_arm=on

Modified the /etc/modules file to include the following 2 lines:

i2c-bcm2708
i2c-dev

Modified /etc/owfs.conf to include the following:

######################## SOURCES ########################
! server: server = localhost:4304
server: device=/dev/i2c-1
######################### OWFS ##########################
mountpoint = /mnt/1wire
allow_other
######################## OWHTTPD #########################
http: port = 2121
####################### OWFTPD ##########################
ftp: port = 2120
####################### OWSERVER ########################
server: port = localhost:4304

For starting owfs at boot I created a /etc/init.d/owfs with following content:

#!/bin/sh
### BEGIN INIT INFO
# Provides: owfs
# Required-Start: $remote_fs $syslog $network $named
# Required-Stop: $remote_fs $syslog $network $named
# Should-Start: owfs
# Should-Stop: owfs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: 1-wire file system mount & update daemon
# Description: Start and stop 1-wire file system mount & update daemon.
### END INIT INFO

CONFFILE=/etc/owfs.conf
DESC="1-Wire file system mount"
NAME="owfs"
DAEMON=/usr/bin/$NAME
case "$1" in
  start)
    echo "Starting $NAME"
    $DAEMON -c $CONFFILE
  ;;
  stop)
    echo "Stopping $NAME"
    killall $NAME
  ;;
  *)
    echo "Usage: $N {start|stop}" >&2
    exit 1
  ;;
esac

Made file executable and added to defaults...

chmod +x /etc/init.d/owfs
update-rc.d owfs defaults

After boot, I can read data by doing (for example) cat /mnt/1wire/XX.XXXXXXX/temperature, everything works fine.. Just the peaks every 10 seconds are disturbing, how to fix that?

  • That sounds like normal behaviour. I can't think of a reason for the Pi model making any difference. – joan Jan 4 at 16:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.