I have been troubled with a simple circuit that uses an 8M to monitor two ds18b20 temperature probes and operate a servo.
When I use sertxd to see the temperatures the program runs smoothly, but as soon as I rem the sertxd command out I start to get erratic readings out of the probes. (Sertxd creates a flutter on the servo so needs removing)
This happens even when the servo is disconnected so isn't a straight case of noise.
I have found a solution without understanding why this works and post this in the hope it may be useful to somebody in the future.
The servo is on 'out 0'. After each servo command I have added a low 0 and the problem magically goes away. I spotted that the servo pin stays high once called in a program and pushing it low seems to eradicate the spurious readings on the temp probes.
Can anyone suggest why this solution works?
When I use sertxd to see the temperatures the program runs smoothly, but as soon as I rem the sertxd command out I start to get erratic readings out of the probes. (Sertxd creates a flutter on the servo so needs removing)
This happens even when the servo is disconnected so isn't a straight case of noise.
I have found a solution without understanding why this works and post this in the hope it may be useful to somebody in the future.
The servo is on 'out 0'. After each servo command I have added a low 0 and the problem magically goes away. I spotted that the servo pin stays high once called in a program and pushing it low seems to eradicate the spurious readings on the temp probes.
Can anyone suggest why this solution works?