Skip to main content
Visitor II
November 7, 2005
Question

ST7Lite29 and DS18B20 - 1Wire

  • November 7, 2005
  • 6 replies
  • 1352 views
Posted on November 07, 2005 at 14:43

ST7Lite29 and DS18B20 - 1Wire

    This topic has been closed for replies.

    6 replies

    marek2Author
    Visitor II
    May 15, 2005
    Posted on May 15, 2005 at 14:25

    Hello

    Where can I find any software libraries to 1-Wire protocol?

    I make device with ST7Lite29, and have some problems with implementation 1-wire protocol in Cosmic C compiler 4k version.

    I set PA7 or PB6 as 1-wire-pin - open drain output, and I have problem with read state of 1-wire-pin. It always is ''1''. If I link 1-wire-pin to GND, when I read PADR (or PBDR) i always receive ''1''.

    And I have question:

    If quartz is 16MHz, mcu clock is 8MHz? 1 clock cycle is 0,125 us, 1 machine cycle is 2 clock cycle = 0,25 us, and instruction time is 1 to 3 machine cycles? It's good ?

    Marek

    Visitor II
    May 15, 2005
    Posted on May 15, 2005 at 23:53

    Can you put the codes and graph of MCU and DS18b20? I have used ST72324 to read DS18b20 and it runs OK..

    marek2Author
    Visitor II
    May 17, 2005
    Posted on May 17, 2005 at 18:48

    The original post was too long to process during our migration. Please click on the provided URL to read the original post. https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I6je&d=%2Fa%2F0X0000000buG%2FK4fvfsMBYbMN35nezdlJHNeAVfc1Zr.QJMqs91nuVWE&asPdf=false
    Visitor II
    May 19, 2005
    Posted on May 20, 2005 at 00:09

    I check your codes, there are OK except the delay time, I have no demo board to check the wave using oscillograph. I think that you should modify delay time. When I program DS18b20, the problem happened too, after I modify the delay time to fit the datasheet figure, it dispeared.

    if you have any question, please put it.

    by the way, I write assemble code to read DS18b20. if you want to get it. I would put it on the forum(quartz is 8MHz, mcu clock is 4MHz).

    [ This message was edited by: DiDiDuDu on 20-05-2005 03:41 ]

    marek2Author
    Visitor II
    May 20, 2005
    Posted on May 20, 2005 at 06:43

    OK - put your code on the forum, I will use it willfully. I think, that other ST7 programers also.

    Regards

    Marek

    Visitor II
    May 23, 2005
    Posted on May 23, 2005 at 04:41

    The original post was too long to process during our migration. Please click on the provided URL to read the original post. https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I6pB&d=%2Fa%2F0X0000000bwG%2Fd21CaTr62T.ntPoX6rtRzFzQiukn4MONjAYQAkvCFpI&asPdf=false