Go Down

Topic: Analog port readings are noisy? Did i destroy my analog pins??? (Read 1 time) previous topic - next topic

Hi all,

Cud someone pls tell me if I blew my Arduino Atmega M2560 micro controller analog pins by doing this:

I connect 5v to the Aref pin, and I read out analog readings of a temperature and humidity sensor on two seperate pins.
It was working fine yesterday while I powered it through USB and then after thru a 5v regulated circuit. I'm able to detect temperature and humidty readings.

But today the analog pins have gone haywire! The readings are fluctuating and way off. When I remove the pins from the sensor and connect them to ground and Vcc instead of showing me 0 and 1023 they give me values like 334, 662...

Has anyone ever experienced this before?

Btw Im able to still use the digital ports to switch on and off a fan but all the analog ports give me the same readings...

Any suggestions would be gladly apreciated.

Thanks!

nickn4

Quote
Has anyone ever experienced this before?

yes, and i geus you should get used to it and try to make some solotions wich decrese the noise (at least that is wat i've been doing since the expirience)

nick
humankind cannot obtain anything without
sacrificing something of equal value in return.

iyahdub

Is that only with the regulaged PSU ?!? If so is cause its not a proper clean one, probably a cheap one which makes sense. There are big difference between a cheap and a proper nice clean PSU. The latter tend to cost a quid or two.
10 LET Loop=Infinite
20 GO TO 10

ohh so this is normal then kinda good to know I guess so long as I didnt destroy my microcontroller.  :)

Nick, when I tested out the analog ports of another of the same board with analog pins to Gnd then Vcc I get a reading of 0 and 1023... Is it possible for some boards to hav an offset voltage and the others not?
What works for you? Resistors and capacitors? Because I've tried 10k, 1k and 1M ohm resitors both in pull up and pull down with no luck :(


iyahdub, nope unfortunately its not any cheap one first I powered it through those big trainer boards in my lab then I powered it thru a 5v regulated circuit I constructed using a 7805 chip which gives me a nice clean 5v... No matter what I do I still get a noisy power signal....

Coding Badly


iyahdub

How do you know its clean ?!? U tested it ?!? Im saying this cuz i do a lot of pro audio circuits and know how noise can be a pain in the ass... Actually done something with arduino as soon as got external power, problems started. so had to sort iit through some proper filtering
10 LET Loop=Infinite
20 GO TO 10


Quote
I connect 5v to the Aref pin


Why?


Because my sensors need a 5v supply and I thought that we have to power the sensor through it therefore

iyahdub



Quote
I connect 5v to the Aref pin


Why?


Because my sensors need a 5v supply and I thought that we have to power the sensor through it therefore


?!?!?!
10 LET Loop=Infinite
20 GO TO 10

Coding Badly

#8
May 08, 2012, 07:06 am Last Edit: May 08, 2012, 07:41 am by Coding Badly Reason: 1
I connect 5v to the Aref pin ... Because my sensors need a 5v supply and I thought that we have to power the sensor through it therefore


AREF does not provide power to the sensors.

Either leave AREF unconnected or connect a 0.1 uF capacitor from AREF to GND.  Until you have an understanding of the purpose of AREF and how to use it correctly do not connect anything else to it.


Edit: quote tag fixed.

ommgg seriously?? thankk uu for telling me that! I didn't know that it's the first time I'm working with microcontrollers and I was under the implression that Aref provides a voltage! so I guess I really did fry the analog ports then :((


How do you know its clean ?!? U tested it ?!? Im saying this cuz i do a lot of pro audio circuits and know how noise can be a pain in the ass... Actually done something with arduino as soon as got external power, problems started. so had to sort iit through some proper filtering


Its is a complete pain in the ass. I tested it using a multimeter and its pretty stable at 5.0012 I assumed this means its clean...I get the feeling this is not right? I'm new to this excuse me for my pathetic mistakes... Thanks for helping out

#11
May 08, 2012, 07:29 am Last Edit: May 08, 2012, 07:42 am by Coding Badly Reason: 1

I connect 5v to the Aref pin ... Because my sensors need a 5v supply and I thought that we have to power the sensor through it therefore


AREF does not provide power to the sensors.

Either leave AREF unconnected or connect a 0.1 uF capacitor from AREF to GND.  Until you have an understanding of the purpose of AREF and how to use it correctly do not connect anything else to it.





Ohh! I use a blutooth module to send data to a hyperterminal and this requires and Aref of 5v so I have to connect that too to transmit the sensor data while connecting the sensors to the analog ports. Is this wrong??



Edit: quote tag fixed.

Coding Badly


There is no way to tell from your description if you are or are not connecting things correctly.  I suggest creating and posting a schematic.

Grumpy_Mike

Quote
I tested it using a multimeter and its pretty stable at 5.0012 I assumed this means its clea

No this will not tell you if it is clean. A multimeter can not detect oscillations on a voltage, you need a scope to do this.

It's all goood Thanks! I was connecting the Aref as well which I dont need apparently. So I just removed the Aref and its all good thanks!

Go Up