Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 21:13 27 Mar 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : CMM2: DS18B20 Temp sensor problem

     Page 7 of 7    
Author Message
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 2374
Posted: 09:51am 13 Mar 2025
Copy link to clipboard 
Print this post

  Quote  Does it make a difference to?
tempr start(xx):pause xx:? tempr(xx)
No, as that works you don't need the function.

The output for the test program is about the same as one of my non-genuine units. With that one I can eliminate the Pause with Tempr Start GPxx,3 : ? tempr(xx)
 
dddns
Senior Member

Joined: 20/09/2024
Location: Germany
Posts: 150
Posted: 09:58am 13 Mar 2025
Copy link to clipboard 
Print this post

As the time to get a result can't be eliminated and "start tempr xx" eliminates the need to wait as well, for me everything is fine as it is.
 
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 2374
Posted: 12:10pm 13 Mar 2025
Copy link to clipboard 
Print this post

In the new PicoMite firmware V6.00.02RC0 Peter has added:-
  Quote  function TEMPR(Pinno [,timeout]) 'new optional parameter timeout to override the default (200mSec) to allow for slow devices
command TEMPR START GPno [,resolution(0-3)] [,timeout]  'new optional  parameter timeout to override the default (100, 200, 400, or 800mSec) to allow for slow devices

Edited 2025-03-13 22:10 by phil99
 
dddns
Senior Member

Joined: 20/09/2024
Location: Germany
Posts: 150
Posted: 02:06pm 13 Mar 2025
Copy link to clipboard 
Print this post

mine seems to be now even faster than the specs :))

> do:timer=0:tempr start gp15,3,474:? tempr(gp15),timer:loop
23.75   483.978
23.75   483.885
23.75   483.947
23.75   483.948
23.75   483.945
23.8125         483.951
23.75   483.947
23.8125         483.951
23.8125         483.95
23.8125         483.948
23.75   483.953
23.75   483.953
23.8125         483.944
23.75   483.954
23.8125         483.953
23.875  483.95
23.875  483.956
23.9375         483.953
24      483.943
23.9375         483.958


> do:timer=0:tempr start gp15,3:? tempr(gp15),timer:loop
23.75   809.8
23.875  809.876
23.8125         809.944
23.8125         809.951
23.875  809.955
23.8125         809.953
23.8125         809.946
23.8125         809.951
23.8125         809.948
23.8125         809.943
23.8125         809.959
23.875  809.945
23.8125         809.95
23.8125         809.951


The magic 473ms seems to work for all modes, but no ms less..even for mode 0
Edited 2025-03-14 00:11 by dddns
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9800
Posted: 03:17pm 13 Mar 2025
Copy link to clipboard 
Print this post

  Quote  The magic 473ms seems to work for all modes, but no ms less..even for mode 0


Hmmm - not exactly to the data sheet
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6181
Posted: 08:36pm 13 Mar 2025
Copy link to clipboard 
Print this post

  Quote  The magic 473ms seems to work for all modes, but no ms less..even for mode 0

Based on my test code, your chip pretends to change mode but takes the same time for each resolution.
That is not possible.
Your chip is of uncertain accuracy and bears no resemblance to the data sheet figures.

Peter has added code to allow these dubious chips to be used more easily but it in no way makes them "genuine"
If you change the chip, you will have to determine the timing again so they are not readily replaceable. Each one needs calibrating for each resolution of interest.

Jim
VK7JH
MMedit
 
     Page 7 of 7    
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2025