PiFace 2 - Sensor/Counter not working

Moderator: fantom

macieiks
Posts: 56
Joined: Tuesday 07 July 2015 12:00
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by macieiks » Tuesday 04 August 2015 11:13

@bizziebiz,

I can confirm it too, I am running V2.2563 (stable) and I can see update each 10 sec in logs (even if there is no impulse from S0 meter). However my counter's stats does not increase and states all the time 0.000kWh as I mentioned before. Which version of domoticz (stable / beta) should I run and test to get it working?
RPI2 + RFLink + PiFace D2 + Aeon Z-Wave Gen5 + Foscams FI9821P&R2 + MySensors + UPS APC Back-UPS 950VA
RPI2 + RFXtrx433e + Foscams FI9821P + MySensors + UPS APC Back-UPS 950VA
RPIB+ + TP-Link MR3420 + Huawei E173 GarageDomoticz :)

NickHead
Posts: 164
Joined: Tuesday 29 October 2013 19:30
Target OS: Linux
Domoticz version:
Location: North East Coast of the UK
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by NickHead » Tuesday 04 August 2015 15:17

I went here and did some of the examples.

Mine wouldn't count, now it does, not sure if correct yet.

I was fed up of hearing other had the same problem as me and I searched for ages and came up with this,

http://www.element14.com/community/mess ... face#93804

also put this in my PI2, something to do with RPI Update.
sudo apt-get --reinstall install libraspberrypi-bin libraspberrypi-dev libraspberrypi-doc libraspberrypi0 raspberrypi-bootloader

sudo reboot

Make sure you backup/be safe before any modifications.

I take no responsibility for doing this, however, I did do it and restored faith in my PiFace Digital 2.

Hope it helps.
A lot of stuff that is doing my head in.

cwiekol
Posts: 4
Joined: Sunday 11 October 2015 11:23
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by cwiekol » Tuesday 10 November 2015 10:19

This one seems to solve my problem. Before i had only 4 inputs visible in devices section of domoticz, now i see all inputs and outputs.. Will test in the evening if they are acting as they should. Thanks NickHead.
sudo apt-get --reinstall install libraspberrypi-bin libraspberrypi-dev libraspberrypi-doc libraspberrypi0 raspberrypi-bootloader

sudo reboot

NickHead
Posts: 164
Joined: Tuesday 29 October 2013 19:30
Target OS: Linux
Domoticz version:
Location: North East Coast of the UK
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by NickHead » Tuesday 10 November 2015 18:39

Yes, it did with mine for a while, then it went wrong.

I am using a different approach now, so not sure on the status of this fix.

Regards

Nick
A lot of stuff that is doing my head in.

MrFrankie
Posts: 17
Joined: Tuesday 16 July 2013 8:45
Target OS: Raspberry Pi
Domoticz version: V2.2585
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by MrFrankie » Thursday 12 November 2015 7:52

Oh good to see that there is a solution. It was so frustrating that it was not working correct.
At this moment I don't use the PiFace. I converted everything to MySensors and EasyESP. It's a bit more portable and easier to debug in my opinion. But who knows...

Thanks NickHead for the solution.

cwiekol
Posts: 4
Joined: Sunday 11 October 2015 11:23
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by cwiekol » Saturday 21 November 2015 11:21

last thing which i have done like ten days ago was also disabling device tree:

sudo raspi-config
8 advanced options
A5 Device Tree

and reboot..

Now i'm on
Linux raspberrypi 4.1.7+ #817 PREEMPT Sat Sep 19 15:25:36 BST 2015 armv6l GNU/Linux

and

2015-11-21 10:20:29.822 Domoticz V2.3566 (c)2012-2015 GizMoCuz
2015-11-21 10:20:29.823 Build Hash: 332f2d5, Date: 2015-11-09 19:00:36
2015-11-21 10:20:29.825 System: Raspberry Pi

and piFace is working all right..

hope that helps...

badz
Posts: 4
Joined: Friday 05 February 2016 19:09
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by badz » Friday 05 February 2016 19:11

Hi,
I have been struggling big time with my Piface2 in domoticz.
After doing this fix, I have everything working smoothly.
https://github.com/domoticz/domoticz/pull/426
try it and tell me
PS: This is has been already merged in master on github .. just "git pull;make" to get the latest when using source code

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Friday 05 August 2016 16:25

Hi,

Still having probems with this - setting the first parameter (enabled) in piface.conf to true sets the device up as Lighting 1 - putting it as false and I get no devices. What is the correct value for the piface.conf for a watermeter?

User avatar
Sine
Posts: 55
Joined: Monday 02 February 2015 16:57
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Sine » Tuesday 09 August 2016 0:40

From my config:

Code: Select all

piface.0.input.7.enabled=false
piface.0.input.7.pin_type=level
piface.0.input.7.count_enabled=true
piface.0.input.7.count_update_interval_sec=10

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Wednesday 10 August 2016 0:01

Thanks. Tried that but still don't get the utility come up in the devices. Wonder what the difference is?

Jan Jansen
Posts: 164
Joined: Wednesday 30 April 2014 20:27
Target OS: Raspberry Pi
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Jan Jansen » Friday 12 August 2016 16:35

Wich kernel are you running? Today i did a rpi-update (new kernel 4.4.?). After that update my piface did not work anymore. After then i installed kernel 4.1.18+ again, everything worked as desired. I hope that history does not repeat (kernel related to driver piface)

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Monday 15 August 2016 1:47

Hi,

I'm using 4.4.13+ Maybe that's the problem. I'll try with 4.1.18+. ........

I tried it with 3.10.25+ and it still didn't work! So maybe not the kernel.

Jan Jansen
Posts: 164
Joined: Wednesday 30 April 2014 20:27
Target OS: Raspberry Pi
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Jan Jansen » Monday 15 August 2016 7:50

Hi,

At the moment my Pi B (2 Pifaces connected) is running 4.4.13+. Setting raspi-config > Advanced options > SPI enable.
Running 4.1.18+ Setting raspi-config > Advanced options > Device tree > disable.

The crux for me was setting the Raspi -config.

Perhaps you 've seen it : WIKI > Piface > General notes and connecting the SO bus.

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Saturday 20 August 2016 23:38

My Piface is working... Just not the devices showing in Domoticz.

User avatar
Sine
Posts: 55
Joined: Monday 02 February 2015 16:57
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Sine » Saturday 27 August 2016 12:07

You set domoticz to allow for new devices right?

I don't exactly know how this is handled, but I suspect it needs to see a few pules when it is in "allow new devices mode"

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Monday 29 August 2016 19:55

No I didn't! I'll try that next.

nigels0
Posts: 232
Joined: Thursday 23 January 2014 13:43
Target OS: Raspberry Pi
Domoticz version: 3.8153
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by nigels0 » Saturday 15 October 2016 12:01

Unfortunately no change

NickHead
Posts: 164
Joined: Tuesday 29 October 2013 19:30
Target OS: Linux
Domoticz version:
Location: North East Coast of the UK
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by NickHead » Friday 21 October 2016 0:07

Code: Select all

from time import sleep

import pifacedigitalio

pifacedigitalio.init()

pifacedigital = pifacedigitalio.PiFaceDigital()

pifacedigital.leds[7].toggle()

sleep(0.5)

pifacedigital.leds[7].toggle()
try running this on the pi and see if it kickstarts the piface

P.S. It is a python script
A lot of stuff that is doing my head in.

Piacco
Posts: 17
Joined: Friday 14 November 2014 10:33
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Piacco » Sunday 03 September 2017 0:34

I use my piface to register my watermeter. What i noticed is that the RXFmeter only updates when i'am using water. When i'am not using any water for a while the RFXmeter becomes red. I thought the RFXmeter was updated every 10sec (count_update_interval_sec=10 in the piface.conf file).
In the hardware setting i have the data timeout for the piface board disabled, is this normal behavior?

Jan Jansen
Posts: 164
Joined: Wednesday 30 April 2014 20:27
Target OS: Raspberry Pi
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: PiFace 2 - Sensor/Counter not working

Post by Jan Jansen » Sunday 03 September 2017 7:35

Yes it is normal behavior.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests