Humidity Sensor H25k5A Help !!!!

Hi,

I have tryed to connect a humidity sensor (H25K5A) to my arduino, but dont know to make the calculations
I have look at the datasheet, and are useing the calculations from it, but it only prints the number "5.00" out.

http://www.komponenten.es.aau.dk/fileadmin/komponenten/Data_Sheet/Sensorer/H25K5A_spec.pdf

Can anyone help me with the calculations ?

Read this before posting a programming question

How to use this forum

What kind of answer is that?

I just want help with the calculations for the humidity sensor....

I have this code so fare:
void loop()
{
fugtighedMaal = analogRead(fugtighedSensor);
fugtighed = (50000 / (50000 + fugtighedMaal)*5);
Serial.println(fugtighed);
delay(250);
}

What kind of answer is that?

Without seeing all of your code, in code tags to avoid it being mangled by the forum software, it is not possible to give any help because it is impossible to see what type of variables you are using, how and where they are declared and initialised and how the inputs are set up. That is why you were directed to the 2 links given.

Her is my code:

int b1 = 2;
int fugtighedSensor = A1;

void setup()
{
pinMode(b1, INPUT_PULLUP);

pinMode(fugtighedSensor, INPUT);

Serial.begin(9600);
}

void loop()
{

fugtighedMaal = analogRead(fugtighedSensor);
fugtighed = (50000 / (50000 + fugtighedMaal)*5);
Serial.println(fugtighed);
delay(250);
}

I am sorry to say that your code does not compile, neither did you put it in code tags as suggested.

error: 'fugtighedMaal' was not declared in this scope
error: 'fugtighed' was not declared in this scope

it's not that had to get it the code to compile just make a int off frugtighedMaal and fugtighed....

But i still need answers, for how to make the calculations work.

There is a lot of discussion and an offer of (non-Arduino) code here.
http://forum.arduino.cc/index.php/topic,15272.0.html

funderskov:
it's not that had to get it the code to compile just make a int off frugtighedMaal and fugtighed....

But i still need answers, for how to make the calculations work.

I can get the bl**dy code to compile very easily by declaring the variables, but how do I know how you declared them ? For all I know you declared them as bytes or chars. With that in mind I don't know whether any of the code you posted is what you are actually running.

funderskov:
What kind of answer is that?

I just want help with the calculations for the humidity sensor....

I have this code so fare:
void loop()
{
fugtighedMaal = analogRead(fugtighedSensor);
fugtighed = (50000 / (50000 + fugtighedMaal)*5);
Serial.println(fugtighed);
delay(250);
}

The answer asked to read those links. Clearly you didn't because your reply still does not use code tags. As a courtesy to the people you are asking help from, read the forum rules. Did you understand this answer?

Unfortunately, this is a typical forum post: Many entries without any substantial help!
Why does that have to be? I no longer enjoy the forum!

Occasion: I was looking for help with the sensor H25K5A.