Problem reading temperatures of 85 degree Celsius

classic Classic list List threaded Threaded
29 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)

Hello OWFS-developers,

I am experiencing delays and also time-outs when reading temperatures of very very close to and equal to 85 degrees Celsius.

I am using a BananaPI with a LinkUSB as hardware.

As software I am using on the system side owserver 3.1p1-6 and on the application side python together with pyownet as client to owserver.


I have 25 DS18B20, which are powered.

My application is a heating system, where a wood burning oven heats up two 800l buffer containers of water to a max temperature of 95 degree Celsius.

Every 30s simultaneous is written, followed by a two second wait, before starting reading back the temperatures sequentially. The time for an average read of one sensor is about 0.2 seconds at maximum resolution. I am monitoring the time of each read and when the read exceeds 0.25 seconds I log this.
Additionally every read I do with pyownet is used with a time-out of 1s, meaning, if after 1 second owserver did not reply a value, I abort and go to the next sensor.

When the buffers get slowly discharged, the temperature of the sensors at the buffers slowly drifts to the 85 degree mark.

Here is the thing:

While slowly drifting towards the 85 deg C mark, at first the sensor takes longer to read. The read time is then typically around 0.75s. That happens for a couple of cycles, before then the reading times out - longer than 1s, in which case the read is aborted and the next sensor gets read. It can alternate between time-out and elongated reading time. When a temperature is read, it is 85.0 something or later 84.9 something. After a while the reading is back with longer reads, Finally everything is back to normal and the temperature is below 85 degrees C.

That happens successively for all the 10 sensor (5 at each buffer in various hights) .

I am aware that the 18S20 did report an error with 85 deg C, but the 18B20 should not do this.

Is there something in owfs that would re-read in case a value of exactly 85 deg C would be returned by a sensor?

Or is it the LinkUSB that is the culprit.

Does anybody else experience the same phenomenon?

Cheers Martin


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Jan Kandziora
Am 04.12.2016 um 12:07 schrieb Martin Patzak (GMX):
>
> I am experiencing delays and also time-outs when reading temperatures of
> very very close to and equal to 85 degrees Celsius.
>
This is a complicated situation as 85°C is the default power-up value
the sensor uses. When you have power failures during the conversion, you
cannot tell it apart from a valid 85°C reading.


>
> I have 25 DS18B20, which are powered.
>
That's good, as the most problems arise from supplying insufficient
parasite power (aka 4.7k pullup to 3.3V)


> My application is a heating system, where a wood burning oven heats up
> two 800l buffer containers of water to a max temperature of 95 degree
> Celsius.
>
> Every 30s simultaneous is written, followed by a two second wait, before
> starting reading back the temperatures sequentially.
>
Please update to owfs-3.1p4. It has a new "latesttemp" node, which is
meant for exactly this setup. Trigger simulatenous/temperature, wait a
second in your user program, then read all the temperature values
sampled from the "latesttemp" node.


>
> I am aware that the 18S20 did report an error with 85 deg C, but the
> 18B20 should not do this.
>
> Is there something in owfs that would re-read in case a value of exactly
> 85 deg C would be returned by a sensor?
>
Yes, there is a try-again-mechanism when you read the "temperature" and
"temperatureXX" nodes. Update and use "latesttemp" instead.

Please see the updated manpages, too.

Kind regards

        Jan



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)
Hello Jan,

thanks for the swift and in-depth reply to my problem:

On 12/04/2016 07:31 PM, Jan Kandziora wrote:
Am 04.12.2016 um 12:07 schrieb Martin Patzak (GMX):
I am experiencing delays and also time-outs when reading temperatures of
very very close to and equal to 85 degrees Celsius.

This is a complicated situation as 85°C is the default power-up value
the sensor uses. When you have power failures during the conversion, you
cannot tell it apart from a valid 85°C reading.

Oh, I see

      
My application is a heating system, where a wood burning oven heats up
two 800l buffer containers of water to a max temperature of 95 degree
Celsius.

Every 30s simultaneous is written, followed by a two second wait, before
starting reading back the temperatures sequentially.

Please update to owfs-3.1p4. It has a new "latesttemp" node, which is
meant for exactly this setup. Trigger simulatenous/temperature, wait a
second in your user program, then read all the temperature values
sampled from the "latesttemp" node.
Thanks for pointing out, that there are changes in the latest version, that a relevant to the problem.
So, I did update, and gave it a try with simple testprogramm accessing the latesttemp node.
For testing I read only two sensors. First the one that is close to 85 deg C and another one just for seeing the next read done.

The new node works fine too, but unfortunately I get an error, when a sensor is right at 85 deg C:


Traceback (most recent call last):
  File "read_a_temp.py", line 15, in <module>
    sensed = op.read('/28.676A20060000/latesttemp')
  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read
    raise OwnetError(-ret, self.errmess[-ret], path)
pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid transaction: '/28.676A20060000/latesttemp'

here is the python test-code:

import time
from pyownet import protocol

op = protocol.proxy("razmaban",port=4304)


op.write('/simultaneous/temperature', '1')

time.sleep(1)   # give the sensors time to convert their temps

print 'reading now...'

sensed = op.read('/28.676A20060000/latesttemp')
print sensed

sensed = op.read('/28.DD5915020000/latesttemp')
print sensed




First time I have seen this error message, what does it mean?



I am aware that the 18S20 did report an error with 85 deg C, but the
18B20 should not do this.

Is there something in owfs that would re-read in case a value of exactly
85 deg C would be returned by a sensor?

Yes, there is a try-again-mechanism when you read the "temperature" and
"temperatureXX" nodes. Update and use "latesttemp" instead.

Please see the updated manpages, too.
I did install owfs-doc 3.1p4, but I searched for 'latesttemp' and for 'simultaneous', but I couldn't find anything.
Where do I find the updated information?

Cheers Martin


------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)

The new node works fine too, but unfortunately I get an error, when a sensor is right at 85 deg C:


Traceback (most recent call last):
  File "read_a_temp.py", line 15, in <module>
    sensed = op.read('/28.676A20060000/latesttemp')
  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read
    raise OwnetError(-ret, self.errmess[-ret], path)
pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid transaction: '/28.676A20060000/latesttemp'

hold on, my test was done in a rush, so I forgot to stop the task reading the temps from the temperature node.
Could that have anything to do with error message?

I cant test more today, because that was the last sensor over 85 deg C, so I have to wait until tomorrow morning...



------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Stefano Miccoli

On 05 Dec 2016, at 09:35, Martin Patzak (GMX) <[hidden email]> wrote:


The new node works fine too, but unfortunately I get an error, when a sensor is right at 85 deg C:


Traceback (most recent call last):
  File "read_a_temp.py", line 15, in <module>
    sensed = op.read('/28.676A20060000/latesttemp')
  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read
    raise OwnetError(-ret, self.errmess[-ret], path)
pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid transaction: '/28.676A20060000/latesttemp'

hold on, my test was done in a rush, so I forgot to stop the task reading the temps from the temperature node.
Could that have anything to do with error message?

As long as you have a single owserver process running, there can be any number of concurrent clients, or even concurrent access via the same pyownet.protocol.proxy object from different threads… I do not think this is the problem.

BTW, pyownet.protocol.OwnetError simply reports the owserver error number (in this case 22) along with the error description available from /settings/return_codes/text.ALL (in this case "legacy - Invalid transaction”) and the path that caused the error.

Me too, I’ve never experienced a 22 error: we need the help of a owfs wizard.

Stefano


I cant test more today, because that was the last sensor over 85 deg C, so I have to wait until tomorrow morning...


------------------------------------------------------------------------------
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers


------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)



On 12/05/2016 05:42 PM, Stefano Miccoli wrote:

On 05 Dec 2016, at 09:35, Martin Patzak (GMX) <[hidden email]> wrote:


The new node works fine too, but unfortunately I get an error, when a sensor is right at 85 deg C:


Traceback (most recent call last):
  File "read_a_temp.py", line 15, in <module>
    sensed = op.read('/28.676A20060000/latesttemp')
  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read
    raise OwnetError(-ret, self.errmess[-ret], path)
pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid transaction: '/28.676A20060000/latesttemp'

hold on, my test was done in a rush, so I forgot to stop the task reading the temps from the temperature node.
Could that have anything to do with error message?

As long as you have a single owserver process running, there can be any number of concurrent clients, or even concurrent access via the same pyownet.protocol.proxy object from different threads… I do not think this is the problem.
yes, I can confirm, I do use concurrent clients and never had problems.
I was more-so thinking, that owserver might take a sensor 'offline' or something like that, when a value of exactly 85 deg C is read. When I then at that time try to read that sensor it might come to this strange error???


BTW, pyownet.protocol.OwnetError simply reports the owserver error number (in this case 22) along with the error description available from /settings/return_codes/text.ALL (in this case "legacy - Invalid transaction”) and the path that caused the error.
I do get sometimes

[Errno 1] Startup - command line parameters invalid: '28.CF7915020000/temperature'

but this is rare, so I thought I better not mention it right now - but hey, now I did ;-)


Me too, I’ve never experienced a 22 error: we need the help of a owfs wizard.
Yes, let's see what our 'Wizard of OWFS' (aka Jan) has to say to this.

Martin

------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Stefano Miccoli

On 05 Dec 2016, at 18:11, Martin Patzak (GMX) <[hidden email]> wrote:

[Errno 1] Startup - command line parameters invalid: '28.CF7915020000/temperature'

but this is rare, so I thought I better not mention it right now - but hey, now I did ;-)

this error, despite it’s misleading description, occurs when you try to read a non present owfs node. In your case this means that the sensors has temporarily disappeared from the bus… (I experienced this, but usually this is not a problem, since it is sufficient to retry the read.)

S.

------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)



On 12/05/2016 06:29 PM, Stefano Miccoli wrote:

On 05 Dec 2016, at 18:11, Martin Patzak (GMX) <[hidden email]> wrote:

[Errno 1] Startup - command line parameters invalid: '28.CF7915020000/temperature'

but this is rare, so I thought I better not mention it right now - but hey, now I did ;-)

this error, despite it’s misleading description, occurs when you try to read a non present owfs node. In your case this means that the sensors has temporarily disappeared from the bus… (I experienced this, but usually this is not a problem, since it is sufficient to retry the read.)
yes, retrying helps. I wonder if this is software? But where? It is rare enough, and so I ignored it for now.

Stefano, thanks for sharing!

Martin




------------------------------------------------------------------------------

_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Jan Kandziora
In reply to this post by Martin Patzak (GMX)
Am 05.12.2016 um 09:35 schrieb Martin Patzak (GMX):

>
>> The new node works fine too, but unfortunately I get an error, when a
>> sensor is right at 85 deg C:
>>
>>
>> /Traceback (most recent call last)://
>> //  File "read_a_temp.py", line 15, in <module>//
>> //    sensed = op.read('/28.676A20060000/latesttemp')//
>> //  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read//
>> //    raise OwnetError(-ret, self.errmess[-ret], path)//
>> //pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid
>> transaction: '/28.676A20060000/latesttemp'
>> /
>
> hold on, my test was done in a rush, so I forgot to stop the task
> reading the temps from the temperature node.
> Could that have anything to do with error message?
>
> I cant test more today, because that was the last sensor over 85 deg C,
> so I have to wait until tomorrow morning...
>
Please confirm that you can repeat the error condition first.

Kind regards

        Jan


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)


On 12/06/2016 01:41 AM, Jan Kandziora wrote:

> Am 05.12.2016 um 09:35 schrieb Martin Patzak (GMX):
>>> The new node works fine too, but unfortunately I get an error, when a
>>> sensor is right at 85 deg C:
>>>
>>>
>>> /Traceback (most recent call last)://
>>> //  File "read_a_temp.py", line 15, in <module>//
>>> //    sensed = op.read('/28.676A20060000/latesttemp')//
>>> //  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read//
>>> //    raise OwnetError(-ret, self.errmess[-ret], path)//
>>> //pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid
>>> transaction: '/28.676A20060000/latesttemp'
>>> /
>> hold on, my test was done in a rush, so I forgot to stop the task
>> reading the temps from the temperature node.
>> Could that have anything to do with error message?
>>
>> I cant test more today, because that was the last sensor over 85 deg C,
>> so I have to wait until tomorrow morning...
>>
> Please confirm that you can repeat the error condition first.
yes, I could repeat it today. This time I stopped first the other task
reading the temperature nodes.
I cannot read a straight value of 85 degC, instead I get this
transaction error. The values I can read are just above or just below 85
degC.

I can provide debug from owserver if it would help you figuring out
whats going on. Please advise.

You mentionened the manuals recieved an update regarding the new
latesttemp node. I am sorry to ask this, but where do I find this. I did
update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it
somewhere else I should be looking?

Martin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Sven Giermann
I have no idea of what pyownet does or how it is implemented...
But I know from another project, that DS1820 reports 85.0 deg C when it encounters errors. Unfortunately without any other error flag! That's why I implemented a way to accept a temperature of 85.0 only, if the previously read temp was in that range (82-88), otherwise I just skip this reading and try once again.

Maybe pyownet knows of this behaviour (it's by design and described in DS1820 datasheet) and therefore throws an error, when it reads exactly 85 deg C?!


2016-12-06 9:42 GMT+01:00 Martin Patzak (GMX) <[hidden email]>:


On 12/06/2016 01:41 AM, Jan Kandziora wrote:
> Am 05.12.2016 um 09:35 schrieb Martin Patzak (GMX):
>>> The new node works fine too, but unfortunately I get an error, when a
>>> sensor is right at 85 deg C:
>>>
>>>
>>> /Traceback (most recent call last)://
>>> //  File "read_a_temp.py", line 15, in <module>//
>>> //    sensed = op.read('/28.676A20060000/latesttemp')//
>>> //  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read//
>>> //    raise OwnetError(-ret, self.errmess[-ret], path)//
>>> //pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid
>>> transaction: '/28.676A20060000/latesttemp'
>>> /
>> hold on, my test was done in a rush, so I forgot to stop the task
>> reading the temps from the temperature node.
>> Could that have anything to do with error message?
>>
>> I cant test more today, because that was the last sensor over 85 deg C,
>> so I have to wait until tomorrow morning...
>>
> Please confirm that you can repeat the error condition first.
yes, I could repeat it today. This time I stopped first the other task
reading the temperature nodes.
I cannot read a straight value of 85 degC, instead I get this
transaction error. The values I can read are just above or just below 85
degC.

I can provide debug from owserver if it would help you figuring out
whats going on. Please advise.

You mentionened the manuals recieved an update regarding the new
latesttemp node. I am sorry to ask this, but where do I find this. I did
update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it
somewhere else I should be looking?

Martin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Colin Law
In my code (in a node-red environment) if I get a value of 85 then I
retry after a timeout (1 sec I think) and only if I get three 85 in a
row do I accept it as 85.

Colin

On 6 December 2016 at 10:04, Sven Giermann <[hidden email]> wrote:

> I have no idea of what pyownet does or how it is implemented...
> But I know from another project, that DS1820 reports 85.0 deg C when it
> encounters errors. Unfortunately without any other error flag! That's why I
> implemented a way to accept a temperature of 85.0 only, if the previously
> read temp was in that range (82-88), otherwise I just skip this reading and
> try once again.
>
> Maybe pyownet knows of this behaviour (it's by design and described in
> DS1820 datasheet) and therefore throws an error, when it reads exactly 85
> deg C?!
>
>
> 2016-12-06 9:42 GMT+01:00 Martin Patzak (GMX) <[hidden email]>:
>>
>>
>>
>> On 12/06/2016 01:41 AM, Jan Kandziora wrote:
>> > Am 05.12.2016 um 09:35 schrieb Martin Patzak (GMX):
>> >>> The new node works fine too, but unfortunately I get an error, when a
>> >>> sensor is right at 85 deg C:
>> >>>
>> >>>
>> >>> /Traceback (most recent call last)://
>> >>> //  File "read_a_temp.py", line 15, in <module>//
>> >>> //    sensed = op.read('/28.676A20060000/latesttemp')//
>> >>> //  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in
>> >>> read//
>> >>> //    raise OwnetError(-ret, self.errmess[-ret], path)//
>> >>> //pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid
>> >>> transaction: '/28.676A20060000/latesttemp'
>> >>> /
>> >> hold on, my test was done in a rush, so I forgot to stop the task
>> >> reading the temps from the temperature node.
>> >> Could that have anything to do with error message?
>> >>
>> >> I cant test more today, because that was the last sensor over 85 deg C,
>> >> so I have to wait until tomorrow morning...
>> >>
>> > Please confirm that you can repeat the error condition first.
>> yes, I could repeat it today. This time I stopped first the other task
>> reading the temperature nodes.
>> I cannot read a straight value of 85 degC, instead I get this
>> transaction error. The values I can read are just above or just below 85
>> degC.
>>
>> I can provide debug from owserver if it would help you figuring out
>> whats going on. Please advise.
>>
>> You mentionened the manuals recieved an update regarding the new
>> latesttemp node. I am sorry to ask this, but where do I find this. I did
>> update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it
>> somewhere else I should be looking?
>>
>> Martin
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Developer Access Program for Intel Xeon Phi Processors
>> Access to Intel Xeon Phi processor-based developer platforms.
>> With one year of Intel Parallel Studio XE.
>> Training and support from Colfax.
>> Order your platform today.http://sdm.link/xeonphi
>> _______________________________________________
>> Owfs-developers mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>
>
>
> ------------------------------------------------------------------------------
> Developer Access Program for Intel Xeon Phi Processors
> Access to Intel Xeon Phi processor-based developer platforms.
> With one year of Intel Parallel Studio XE.
> Training and support from Colfax.
> Order your platform today.http://sdm.link/xeonphi
> _______________________________________________
> Owfs-developers mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Jan Kandziora
In reply to this post by Martin Patzak (GMX)
Am 06.12.2016 um 09:42 schrieb Martin Patzak (GMX):

>
> yes, I could repeat it today. This time I stopped first the other task
> reading the temperature nodes.
> I cannot read a straight value of 85 degC, instead I get this
> transaction error. The values I can read are just above or just below 85
> degC.
>
> I can provide debug from owserver if it would help you figuring out
> whats going on. Please advise.
>
Yes please.

> You mentionened the manuals recieved an update regarding the new
> latesttemp node. I am sorry to ask this, but where do I find this. I did
> update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it
> somewhere else I should be looking?
>
In the DS18B20 et al. manpages. Please give a link to that package you
installed. Maybe it's broken.


Kind regards

        Jan

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Jan Kandziora
In reply to this post by Sven Giermann
Am 06.12.2016 um 11:04 schrieb Sven Giermann:
> I have no idea of what pyownet does or how it is implemented...
> But I know from another project, that DS1820 reports 85.0 deg C when it
> encounters errors.
>
Sven, 85°C isn't an error code but the power-on value the chip has. When
you read it, it means the chip was de-powered during temperature
conversion, usually by using parasite power and encountering a pullup
problem.


> Unfortunately without any other error flag! That's why I
> implemented a way to accept a temperature of 85.0 only, if the previously
> read temp was in that range (82-88), otherwise I just skip this reading and
> try once again.
>
This is exactly what owfs does and what leads to this error.

Currently I'm in favor of throwing all that 85°C "fixup" code out of
owfs completely. If there's an error in your electrical setup, you have
to fix it there, not by throwing more and more software workarounds at it.

Kind regards

        Jan

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)
In reply to this post by Sven Giermann



On 12/06/2016 11:04 AM, Sven Giermann wrote:
I have no idea of what pyownet does or how it is implemented...
But I know from another project, that DS1820 reports 85.0 deg C when it encounters errors. Unfortunately without any other error flag! That's why I implemented a way to accept a temperature of 85.0 only, if the previously read temp was in that range (82-88), otherwise I just skip this reading and try once again.
yes, it is good to have this kind of sanity check. But of course there is the possibly left, that you encounter an error while you are in the intervall of 82 to 88.
In this case one could read 85 repeatedly and must eventually ask if there is an error...

Important sensor I did double up physically in my system. Hey, those things are cheaper than writing a lot of lines of code ;-)


Maybe pyownet knows of this behaviour (it's by design and described in DS1820 datasheet) and therefore throws an error, when it reads exactly 85 deg C?!
I am most definatly sure that pyownet does do this. Especially since the author of pyownet Stefano Miccoli already answered to this problem yesterday, and he did not mention anything of the like...

Regarding the error report of a sensor:
I checked now again the data sheet of the DS18B20 and this sensor does NOT report an error with 85 degC. However, like Jan already stated before it says:

*The power-on reset value of the temperature register is +85°C.

And there is the problem. The new node latesttemp should fix the problem, but somehow I am experiencing problems...

Thank You for Your thoughts

Martin

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)
In reply to this post by Colin Law


On 12/06/2016 11:31 AM, Colin Law wrote:
> In my code (in a node-red environment) if I get a value of 85 then I
> retry after a timeout (1 sec I think) and only if I get three 85 in a
> row do I accept it as 85.
my problem is, that I cannot read a value 85 degC at all, I do however
get error messages or time-outs, depending...

Thank You for your input

Martin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Stefano Miccoli
In reply to this post by Sven Giermann

On 06 Dec 2016, at 11:04, Sven Giermann <[hidden email]> wrote:

I have no idea of what pyownet does or how it is implemented...
But I know from another project, that DS1820 reports 85.0 deg C when it encounters errors. Unfortunately without any other error flag! That's why I implemented a way to accept a temperature of 85.0 only, if the previously read temp was in that range (82-88), otherwise I just skip this reading and try once again.

Maybe pyownet knows of this behaviour (it's by design and described in DS1820 datasheet) and therefore throws an error, when it reads exactly 85 deg C?!

No, the pyownet.protocol module is low level, and makes no assumptions on the owserver protocol message semantics.

In particular the pyownet.protocol.OwnetError exception is raised only when the owserver returns an error code in the reply message: see

In this case the error condition should be totally server side, and independent from a particular client implementation.

BTW: in module/owlib/src/c/ow_1820.c

static ZERO_OR_ERROR FS_10latesttemp(struct one_wire_query *owq)
{
        return GB_to_Z_OR_E(OW_10latesttemp(&OWQ_F(owq), 1, PN(owq)));
}

static ZERO_OR_ERROR FS_22latesttemp(struct one_wire_query *owq)
{
        return GB_to_Z_OR_E(OW_22latesttemp(&OWQ_F(owq), 1, PN(owq)));
}

These lines should be responsible to throw an exception when reading 85 °C.

S.



2016-12-06 9:42 GMT+01:00 Martin Patzak (GMX) <[hidden email]>:


On 12/06/2016 01:41 AM, Jan Kandziora wrote:
> Am 05.12.2016 um 09:35 schrieb Martin Patzak (GMX):
>>> The new node works fine too, but unfortunately I get an error, when a
>>> sensor is right at 85 deg C:
>>>
>>>
>>> /Traceback (most recent call last)://
>>> //  File "read_a_temp.py", line 15, in <module>//
>>> //    sensed = op.read('/28.676A20060000/latesttemp')//
>>> //  File "/home/mnm/pyownet/src/pyownet/protocol.py", line 545, in read//
>>> //    raise OwnetError(-ret, self.errmess[-ret], path)//
>>> //pyownet.protocol.OwnetError: [Errno 22] legacy - Invalid
>>> transaction: '/28.676A20060000/latesttemp'
>>> /
>> hold on, my test was done in a rush, so I forgot to stop the task
>> reading the temps from the temperature node.
>> Could that have anything to do with error message?
>>
>> I cant test more today, because that was the last sensor over 85 deg C,
>> so I have to wait until tomorrow morning...
>>
> Please confirm that you can repeat the error condition first.
yes, I could repeat it today. This time I stopped first the other task
reading the temperature nodes.
I cannot read a straight value of 85 degC, instead I get this
transaction error. The values I can read are just above or just below 85
degC.

I can provide debug from owserver if it would help you figuring out
whats going on. Please advise.

You mentionened the manuals recieved an update regarding the new
latesttemp node. I am sorry to ask this, but where do I find this. I did
update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it
somewhere else I should be looking?

Martin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)
In reply to this post by Jan Kandziora

Unfortunately without any other error flag! That's why I
implemented a way to accept a temperature of 85.0 only, if the previously
read temp was in that range (82-88), otherwise I just skip this reading and
try once again.

This is exactly what owfs does and what leads to this error.

Currently I'm in favor of throwing all that 85°C "fixup" code out of
owfs completely. If there's an error in your electrical setup, you have
to fix it there, not by throwing more and more software workarounds at it.
LIKE


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Martin Patzak (GMX)
In reply to this post by Jan Kandziora



On 12/06/2016 11:53 AM, Jan Kandziora wrote:
Am 06.12.2016 um 09:42 schrieb Martin Patzak (GMX):
yes, I could repeat it today. This time I stopped first the other task 
reading the temperature nodes.
I cannot read a straight value of 85 degC, instead I get this 
transaction error. The values I can read are just above or just below 85 
degC.

I can provide debug from owserver if it would help you figuring out 
whats going on. Please advise.

Yes please.
ok will do on the weekend the latest. Which error-level should I apply?

You mentionened the manuals recieved an update regarding the new 
latesttemp node. I am sorry to ask this, but where do I find this. I did 
update owfs-doc to 3.1p4 but cannot find latesttemp anywhere. Is it 
somewhere else I should be looking?

In the DS18B20 et al. manpages. Please give a link to that package you
installed. Maybe it's broken.
Shame on me, I did not even know there is a manual to EACH sensor!!! I was looking in owfs, owserver and so forth...

man DS18B20

and low and behold, there it is! Thank You, Jan!

Martin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
Reply | Threaded
Open this post in threaded view
|

Re: Problem reading temperatures of 85 degree Celsius

Stefano Miccoli
In reply to this post by Martin Patzak (GMX)
maybe we should simply patch 

--- a/module/owlib/src/c/ow_1820.c
+++ b/module/owlib/src/c/ow_1820.c
@@ -384,7 +384,7 @@ static ZERO_OR_ERROR FS_10temp(struct one_wire_query *owq)

 

 static ZERO_OR_ERROR FS_10latesttemp(struct one_wire_query *owq)
 {
-       return GB_to_Z_OR_E(OW_10latesttemp(&OWQ_F(owq), 1, PN(owq)));
+       return GB_to_Z_OR_E(OW_10latesttemp(&OWQ_F(owq), allow_85C, PN(owq)));
 }

 

 static ZERO_OR_ERROR FS_10temp_link(struct one_wire_query *owq)
@@ -412,7 +412,7 @@ static ZERO_OR_ERROR FS_22temp(struct one_wire_query *owq)

 

 static ZERO_OR_ERROR FS_22latesttemp(struct one_wire_query *owq)
 {
-       return GB_to_Z_OR_E(OW_22latesttemp(&OWQ_F(owq), 1, PN(owq)));
+       return GB_to_Z_OR_E(OW_22latesttemp(&OWQ_F(owq), allow_85C, PN(owq)));
 }

 

 // use sibling function for fasttemp to keep cache value consistent

S.

On 06 Dec 2016, at 12:09, Martin Patzak (GMX) <[hidden email]> wrote:


Unfortunately without any other error flag! That's why I
implemented a way to accept a temperature of 85.0 only, if the previously
read temp was in that range (82-88), otherwise I just skip this reading and
try once again.

This is exactly what owfs does and what leads to this error.

Currently I'm in favor of throwing all that 85°C "fixup" code out of
owfs completely. If there's an error in your electrical setup, you have
to fix it there, not by throwing more and more software workarounds at it.
LIKE

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Owfs-developers mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/owfs-developers
12