Hello, I’m trying to measure the UV index using the sensor SEN00700P, checking the wiki (seeedstudio.com/wiki/Grove_-_UV_Sensor) I found the code shown below for an Arduino. They explained that they converted the photocurrent into the corresponding voltage value collected by the Arduino. The output voltage and the UV index are linear. The question is, the output on the screen is already the UV index, if not how can I transform this lecture into the corresponding UV index value? I appreciate any help you can provide.
void setup(){
Serial.begin(9600);
}
void loop()
{
int sensorValue;
long sum=0;
for(int i=0;i<1000;i++)
{
sensorValue=analogRead(A0);
sum=sensorValue+sum;
delay(2);
}
sum =sum/1000.0;
Serial.print(“The voltage value:”);
Serial.print(sum*4980.0/1023.0);
Serial.println(“V”);
delay(20);
Serial.print("\n");
}