On 11/28/2016 03:33 PM, Arne Raaen wrote:
> Hi,
>
> I think what Jan explained is that DS2408 itself accepts only the full
> byte.
>
> So when you write a single PIO, owserver does the caching and rewrites
> the whole byte
I did understand, what Jan meant, but did not understand why I never 
seen a random switching of outputs for 6 years! I am running the heating 
system of our house with it.
So if there is a problem in owfs buffering the bytes, what am I doing 
different to not see it?

>
> My basic setup is an Intel-based linux PC (several years old), running
> Ubuntou 16.04   with owserver from the package, 3.1p1.
> About 10 m cat-5 cable between the LinkUSB and the Hobbyboards card.
>
> I also tested a Raspberry 1B, with just a short cable between the
> LinkUSB and the Hobbyboards card, which may have improved the situation
> a little bit
I did run a Rasberry for a while and moved to BananaPi last year.
I as well use the LinkUSB, but I use a selfmade IO-board, which has 3 
DS2408 on it. 12 outputs and 12 inputs.

> (that's why I attempted to strengthen my ground line), but the problems
> persisted, perhaps at a lower rate.

My wiring is about 30m and I use only telephone cable.
The 12V and the 5V are externally powered. I do have the power (still) 
on the same cable together with the 1wire signals, but it seems to work 
ok - never touch a running system.

>
> Since I rewrote my code to only write when needed  (i.e. read owserver
> first and write only if there is change), I have seen no problems for
> almost 2 months.
I am curious what fixed the problem: the reduced rate of writing or the 
reading inbetween.

I do a lot of reading as well: the task that communicates to the graphic 
display (HMI) of the heating system reads the IOs every second and the 
HMI gets updated accordingly.
One particular output gets written every second. It is an alive signal, 
indicating that software and bus are up and running. The signal switches 
an LED on and off and a relay switches on when the signal is not 
triggered for a while which in turn sounds a horn (it is in the cellar, 
so somebody can hear and react to it). The horn has not been heard of 
for quite a while ;)

Otherwise the outputs gets written only rarely: maybe 40 to 50 times in 
24 hours.

>
> That's why I naively thought "high traffic" might be the problem. But
> the way I interpret Jan, the failure in caching properly (although not
> understood) is not likely to be related to "overloading".

again, why don't I see this???

>
> That could still be consistent with my observations, I guess,  I have
> gone from 6x60x24 writes per day to a few.
>
> Apart from the HobbyBoards DS2408 I have  nearly 20 DS18B20 and a few
> DS2406, all parasitically powered, and a powered DS2450 on the bus.
On the same bus I have 25 powered DS18B20 which I read every 30 seconds 
after a simultaneous command.

>
>
> Arne
Thanks Arne for explaining your system more detailed. What does your 
system do?

Cheers Martin

>
>
>
>
>
>
>
>
>
> On 28.11.2016 09.30, Martin Patzak (GMX) wrote:
>> On 11/18/2016 08:11 PM, Jan Kandziora wrote:
>>> Am 18.11.2016 um 10:45 schrieb Arne Raaen:
>>>> Hi,
>>>>
>>>> I have a HobbyBoards relay card based on DS2408, used with LinkUSB
>>>>
>>>> I used a routine (unconditionally) updating PIO.0 through PIO.5 every
>>>> minute.
>>>>
>>>> I observed that PIO.6 and PIO.7 would be activated at random intervals,
>>>> typically a few times per day or less.
>>>>
>>> You cannot set single PIOs on the DS2408, owfs has to set them all as
>>> one. That's why owfs maintains the last state written to the PIO byte.
>>> As you found out the byte stored within owfs may be incorrect for
>>> circumstances we have yet to check.
>> Well, that is rather news to me. I do set single PIOs on two DS2408 in
>> my application.
>> I NEVER expirienced a problem with random switching IOs - I run my
>> heating system since 2010 with owfs, so I don't think I have been lucky
>> all this time ;)
>>
>> Would be interesting to know what exact system and environment the
>> random switching appears in.
>>
>> I can write up my system or answer more detailed questions if it might
>> help. Just ask.
>>
>> Cheers Martin
>>
>>> In the meantime, store the desired output pattern within your
>>> application and write PIO.ALL (or PIO.BYTE) instead of individual bits.
>>> That should make your problem go away immediately.
>>>
>>> Kind regards
>>>
>>>     Jan
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> _______________________________________________
>>> Owfs-developers mailing list
>>> Owfs-developers@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>>>
>> ------------------------------------------------------------------------------
>> _______________________________________________
>> Owfs-developers mailing list
>> Owfs-developers@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Owfs-developers mailing list
> Owfs-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>


------------------------------------------------------------------------------
_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to