If your PIC has comparator, then you can use it to detect current as you wish.
The example below shows the use of an external comparator, but if your PIC has an internal one then you are good to go.
<img src="http://www.picbasic.co.uk/forum/attachment.php?attachmentid=2892&d=1223533980" >
________________
Bookmarks