hackableFM
New Member
I am trying to put together a PIC & LCD project which is capable of reading the output voltage and current of two seperate P.S.U's.
I have no problem in making a device for one P.S.U. (I have built such a gadget in the past) so the hardware & program for the PIC aren't a major issue here, What I need to know is how do I manage to measure the two seperate P.S.U. Without commoning their 'Gnd' terminals. I would like to keep these seperate if at all possible.
I have considered using 2 x 16F877 or 16F690 PIC's (Just because I have them) and two seperate LCD units but this I feel would just look untidy, costly and it's not the way I would like it done.
I have in the past used a 16F877 using code snippets from other sample programs with...
ADCON1 = %10000000 ' Set analogue input, Vref is Vdd
This I understand sets the analogue inputs up so that any voltage fed into the analogue inputs are reference to gnd.
I have had a look at the Datasheet and I simply cannot make sense of how to setup the ADCON register, The datasheet whilst extremely useful for certain things just completely baffles me on other things, this is one of them. I believe from what I have read that you can use two pins as reference points but I have no idea how to go about this. Can anyone help? Or is there a hardware way to accomplish what I need?
Many thanks.
hackableFM...
I have no problem in making a device for one P.S.U. (I have built such a gadget in the past) so the hardware & program for the PIC aren't a major issue here, What I need to know is how do I manage to measure the two seperate P.S.U. Without commoning their 'Gnd' terminals. I would like to keep these seperate if at all possible.
I have considered using 2 x 16F877 or 16F690 PIC's (Just because I have them) and two seperate LCD units but this I feel would just look untidy, costly and it's not the way I would like it done.
I have in the past used a 16F877 using code snippets from other sample programs with...
ADCON1 = %10000000 ' Set analogue input, Vref is Vdd
This I understand sets the analogue inputs up so that any voltage fed into the analogue inputs are reference to gnd.
I have had a look at the Datasheet and I simply cannot make sense of how to setup the ADCON register, The datasheet whilst extremely useful for certain things just completely baffles me on other things, this is one of them. I believe from what I have read that you can use two pins as reference points but I have no idea how to go about this. Can anyone help? Or is there a hardware way to accomplish what I need?
Many thanks.
hackableFM...