Re: latesttemp does not work on DS18B20

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

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 20.08.2016 um 22:49 schrieb Henrik Östman:
> I compiled Owfs with this patch and tried owread two times again, and
> with the same result. I included the logfiles, I hope there is some new
> clues inside that reveals the problem.
> Can I verify somehow that the patch has been applied correctly?
>
It has. The patch tool complains if it doesn't.

I found some short-circuit in my thoughts when orginally implementing
that feature. Please remove the previous patch (just re-run patch with
the -R option and the old diff file), then apply the attached new patch.

It should work as expected then.

Kind regards

        Jan


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

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

debugpatch2.diff (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 21.08.2016 um 02:21 schrieb Jan Kandziora:

> Am 20.08.2016 um 22:49 schrieb Henrik Östman:
>> I compiled Owfs with this patch and tried owread two times again, and
>> with the same result. I included the logfiles, I hope there is some new
>> clues inside that reveals the problem.
>> Can I verify somehow that the patch has been applied correctly?
>>
> It has. The patch tool complains if it doesn't.
>
> I found some short-circuit in my thoughts when orginally implementing
> that feature. Please remove the previous patch (just re-run patch with
> the -R option and the old diff file), then apply the attached new patch.
>
> It should work as expected then.
>
Argh, another bug. Please apply the attached diff instead.

Kind regards

        Jan



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

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

debugpatch3.diff (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: latesttemp does not work on DS18B20

Henrik Östman
:-)
Thanks now it's working again!
Can we expect this fix in the next release?

And one more thing, since this is the first time for me with an sensor that has multiple temperature resolutions.

Calling upon /lasttemp looks like its defaults to /temperature9?
So to switch between resolutions I could do this:

owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/temperature12    // Switching to 12 bit resolution
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/temperature10    // Switching to 10 bit resolution
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp

Correct?

Once again, Many Thanks!

// Henrik

Den 2016-08-21 kl. 02:37, skrev Jan Kandziora:
Am 21.08.2016 um 02:21 schrieb Jan Kandziora:
Am 20.08.2016 um 22:49 schrieb Henrik Östman:
I compiled Owfs with this patch and tried owread two times again, and
with the same result. I included the logfiles, I hope there is some new
clues inside that reveals the problem.
Can I verify somehow that the patch has been applied correctly?

It has. The patch tool complains if it doesn't.

I found some short-circuit in my thoughts when orginally implementing
that feature. Please remove the previous patch (just re-run patch with
the -R option and the old diff file), then apply the attached new patch.

It should work as expected then.

Argh, another bug. Please apply the attached diff instead.

Kind regards

	Jan




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


_______________________________________________
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

owserver.log.gz (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 21.08.2016 um 09:25 schrieb Henrik Östman:
> :-)
> Thanks now it's working again!
> Can we expect this fix in the next release?
>
Yes. But next release is still a while to go, having had the latest
release last week.

Or maybe not?


> And one more thing, since this is the first time for me with an sensor
> that has multiple temperature resolutions.
>
> Calling upon /lasttemp looks like its defaults to /temperature9?
> So to switch between resolutions I could do this:
>
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/temperature12  
> // Switching to 12 bit resolution
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/temperature10  
> // Switching to 10 bit resolution
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/lasttemp
>
> Correct?
>
This should work with the debugpatch3.diff.

.../latesttemp first reads data from the scratchpad, then looks into
data[4] to decide which resolution the data in data[0] and data[1] have.

Please check if it works that way. Otherwise we have to debug a bit more.

Kind regards

        Jan

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

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 21.08.2016 um 13:38 schrieb Henrik Östman:
> No rush for me, I can run with the patched version for now. Just so
> that I know if I can use the next stable version, I'll monitor the
> changelog.
>
I've put a cleaned up version of that patch into the git archive. Could
you please

[owfs-code]$ git pull
[owfs-code]$ make clean && make distclean && ./bootstrap && ./configure
[owfs-code]$ make

and test?

Kind regards

        Jan




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

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 21.08.2016 um 15:39 schrieb Jan Kandziora:

> Am 21.08.2016 um 13:38 schrieb Henrik Östman:
>> No rush for me, I can run with the patched version for now. Just so
>> that I know if I can use the next stable version, I'll monitor the
>> changelog.
>>
> I've put a cleaned up version of that patch into the git archive. Could
> you please
>
> [owfs-code]$ git pull
> [owfs-code]$ make clean && make distclean && ./bootstrap && ./configure
> [owfs-code]$ make
>
> and test?
>
Henrik (and anyone else who likes to test this feature), could you also
apply the appended patch and check whether you are able to read and set
the power-up value of the temperature resolution through the new
.../tempres node?

Kind regards

        Jan

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

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

tempres.diff (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: latesttemp does not work on DS18B20

Henrik Östman
I did a pull from the master branch and applied patch.

Started owserver then did a "owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/latesttemp"  which seems to work, got a "24.25" back.

Restarted owserver in debug-mode and ran this scenario:

owdir -s 192.168.10.110:4304 /uncached/28.3F28AE060000
/uncached/28.3F28AE060000/address
/uncached/28.3F28AE060000/alias
/uncached/28.3F28AE060000/crc8
/uncached/28.3F28AE060000/errata
/uncached/28.3F28AE060000/family
/uncached/28.3F28AE060000/fasttemp
/uncached/28.3F28AE060000/id
/uncached/28.3F28AE060000/latesttemp
/uncached/28.3F28AE060000/locator
/uncached/28.3F28AE060000/power
/uncached/28.3F28AE060000/r_address
/uncached/28.3F28AE060000/r_id
/uncached/28.3F28AE060000/r_locator
/uncached/28.3F28AE060000/scratchpad
/uncached/28.3F28AE060000/temperature
/uncached/28.3F28AE060000/temperature10
/uncached/28.3F28AE060000/temperature11
/uncached/28.3F28AE060000/temperature12
/uncached/28.3F28AE060000/temperature9
/uncached/28.3F28AE060000/temphigh
/uncached/28.3F28AE060000/templow
/uncached/28.3F28AE060000/tempres
/uncached/28.3F28AE060000/type

owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres  => "12"
owwrite -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres 9
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres  => "9"
owwrite -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres 10
owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres  => "10"

Restarting owserver

owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres  => "10"


Satisfied? I attached the log file.

Nice work BTW!

// Henrik

Den 2016-08-21 kl. 20:03, skrev Jan Kandziora:
Am 21.08.2016 um 15:39 schrieb Jan Kandziora:
Am 21.08.2016 um 13:38 schrieb Henrik Östman:
No rush for me, I can run with the patched version for now. Just so
that I know if I can use the next stable version, I'll monitor the
changelog.

I've put a cleaned up version of that patch into the git archive. Could
you please

[owfs-code]$ git pull
[owfs-code]$ make clean && make distclean && ./bootstrap && ./configure
[owfs-code]$ make

and test?

Henrik (and anyone else who likes to test this feature), could you also
apply the appended patch and check whether you are able to read and set
the power-up value of the temperature resolution through the new
.../tempres node?

Kind regards

	Jan


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


_______________________________________________
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

owserver.log.gz (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: latesttemp does not work on DS18B20

Jan Kandziora
Am 22.08.2016 um 00:59 schrieb Henrik Östman:

> I did a pull from the master branch and applied patch.
>
> Started owserver then did a "owread -s 192.168.10.110:4304
> /uncached/28.3F28AE060000/latesttemp"  which seems to work, got a
> "24.25" back.
>
> Restarted owserver in debug-mode and ran this scenario:
>
> [...]
>
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres => "12"
> owwrite -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres 9
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres => "9"
> owwrite -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres 10
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres => "10"
>
> Restarting owserver
>
> owread -s 192.168.10.110:4304 /uncached/28.3F28AE060000/tempres => "10"
>
>
> Satisfied? I attached the log file.
>
Yes. Very fine. I commit that patch then.

Kind regards

        Jan

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