Hi Alain, Thanks for your help. It turns out that the main reason I cant get it to go faster seems to be the time it needs to carry out the analog to digital conversions if I took out the get ADCloop and the getbatlevel it goes like the clappers. If I reintroduce either it slows right down. I have all the averaging loops for both and the signals are still steady and the speed went up to 40 samples per second. I then reduced the times it went to get the battary level to every 150 samples. I am now getting 80 samples per second which is quite acceptable. It didnt seem to make a differance changing the clock to 40mHz using HSPLL and a 10Mhz crystal, but I have left it at that.
Again many thanks Alain for your help. Its great knowing that this forum is here with such helpful people.
cheers and many thanks John
Bookmarks