Problems with 1-Wire DS2438 and PIC16F88


Closed Thread
Results 1 to 13 of 13

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Try changing the mode to 2 before reading the data (no reset pulse).

    Code:
        OWIN  GB1net,2,[STR DSbuffer\9]              ' Read 9 bytes

  2. #2
    Join Date
    Jan 2009
    Location
    Alabama,USA
    Posts
    232


    Did you find this post helpful? Yes | No

    Default The world is not always as it appears!

    OK, so you shouldn’t always jump to conclusions even if you have reason to do so. As stated in my previous post the scratchpad/config file is reading back $OF after being set to $00. I assumed the Vad was not working. I was wrong. It is working. It now appears the configuration bit Page $00 byte $00 bit.3 is clearing to allow Vad to function however ReadScratchpad config register always reads default values (?) The Vad is working fine. My only gripe is that I have to set the Vad bit on every loop before a convert. All other registers are changing as they should and read values as expected. I’ve ask Maxim if this is normal, no reply as yet. It acts as if the config register changes to default when read, weird.
    Darrel, thanks for the reply, your right about the mode. I am still going to play around with the ReadScratchpad command to see if I can find some trick to make the DS2438 function as I think it should. Grain Moisture Content project is underway.

  3. #3
    Join Date
    Feb 2011
    Posts
    3


    Did you find this post helpful? Yes | No

    Default

    I have the feeling that there is some problem with his sensor. Most probably it is damaged to a considerable extent and that is the reason why he is unable to gather data. I would request him to replace it with a new one. I am pretty sure that it will solve the issue.

  4. #4
    Join Date
    Jan 2009
    Location
    Alabama,USA
    Posts
    232


    Did you find this post helpful? Yes | No

    Default

    Hi mosajii,
    The problem was that the scratchpad would not keep the control bits, which had been set, once the conversions were been made. On the DS2438 you must clear bit.3 of the scratchpad to enable the Vad. This bit should stay clear until the user sets it to enable Vss as A/D. Instead the scratchpad would reset to $0F after all conversions and read back of the scratchpad. This means I must set the control bit on each loop rather than only once as it should be. The devise is collecting data as it should. It is just irritating to have to reset the scratchpad on each loop. Maxim never responded to my inquire about this behavior.

  5. #5
    Join Date
    Jan 2009
    Location
    Alabama,USA
    Posts
    232


    Did you find this post helpful? Yes | No

    Default

    correction: until the user sets it to enable Vdd as A/D

Members who have read this thread : 2

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts