2005-11-07 05:43 AM
2005-05-15 05:25 AM
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 ? Marek2005-05-15 02:53 PM
Can you put the codes and graph of MCU and DS18b20? I have used ST72324 to read DS18b20 and it runs OK..
2005-05-17 09:48 AM
2005-05-19 03:09 PM
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 ]2005-05-19 09:43 PM
OK - put your code on the forum, I will use it willfully. I think, that other ST7 programers also.
Regards Marek2005-05-22 07:41 PM