Page 3 of 3

Re: One Wire Example - Failure on linking

Posted: Wed Jul 07, 2010 1:53 pm
by Benj
Hello Jan,

Have you changed the clock speed setting in the Flowcode project options to be 8000000?

Re: One Wire Example - Failure on linking

Posted: Wed Jul 07, 2010 4:47 pm
by Jan Lichtenbelt
Hello Ben,

I expeceted an automactic synchronisation. But setting the Flowcode option to 8 Mhz, the blinking test program is now working well with the internal clock. The 1-wire program, with 8 MHz internal clock, improved in a way that no bus error is detected anymore. But the temperature reading gives only the deflaut value of 85 oC. In contrast, using the external oscillator (19.6608 MHz) gives the correct temperature, which is nice today, 25 oC. There must be a (small?) deviation when using the internal clock. Do you have suggestions for improvement?

Kind regards

Jan Lichtenbelt

Re: One Wire Example - Failure on linking

Posted: Wed Jul 21, 2010 9:46 am
by Jan Lichtenbelt
I developed the 1-wire program, but I got an error which I do not understand. In the flowcode attached, I use an Init macro, which is called only once and shows 'WAIT' on the LCD. However not connecting any sensor should give the error message "No sensor". But what happens is that the program repeat starting all the time (which is shown by the counter in the Init macro showed after 'WAIT' on the first LCD line). Programmatically this should be impossible, but it happens nevertheless. What do I do wrong?

WHO CAN HELP????

Jan Lichtenbelt

As usual, I can not wait and started to find the error myself. The problem is an overflow of the char DevID[64] array of the 1-wire program, as used by e.g. by oo_scanbus. This means with no sensor attached, the number of device can become > 8. To prevent this kind of overflow I extended the oo_scanbus procedure as shown in the attached file. I strongly advice that this extra security line should become standard, when using the 1-wire flowcode.

Re: One Wire Example - Failure on linking

Posted: Thu Jul 22, 2010 7:27 am
by Jan Lichtenbelt
Next problem.

I changed the 1-wire port from A0 to A1. A0 port is working correctly, while port A1 gives the error "NO SENSOR". The microcontroller used, is PIC 16F88. Does someone has experince is this problem?

Re: One Wire Example - Failure on linking

Posted: Wed Oct 27, 2010 2:28 pm
by gggwww
Jan,

Were you ever able to get this to work?

Regards,
George