I want to sense the voltage across the resistor R1 (i.e convert it into digital form). I only have comparators available with me and no other hardware (ADC is not available). Is there any way I could digitize this voltage across R1. from the circuit we can see the output of comparator would go from 0-5V as the voltage V1 is varied from 0-5V or if the voltage is fixed to 5V then the output will always be high (5V). Similarly, if we make the current flow in opposite direction the output will go from 0 to -5V or remain at -5V when supply is not varied. so the comparator acts as a 1 bit ADC. But a multibit output is required to sense the varying voltage across R1. The digital data has to be taken into an FPGA. So any suggestions in this regards.
The second image is the solution i had found FPGA ADC. This also uses a single ended analog input, whereas i have a differential input across a resistor.
- So i am again attaching a circuit diagram to make things clear The load shown is not the real load. The voltage across the current sensor has to be converted to digital and i have simple delta sigma ADC available which will be made using the LVDS receivers in the FPGA. So how to convert this differential voltage into digital using delta sigma ADC ? The purpose of all this is i have to sense the charging and discharging current of a lithium ion battery using a fpga that fits in a portable device.So i want to keep external components at a minimal and the fpga uses a delta sigma ADc made in the fashion shown in ADC block diagram