guraknugen:
I'm just trying to understand the question:
When the feature is on, there is a sine wave (or square wave) alternating from 0 V to 12 V, is that right?
And when the feature is off, it's 0 V all the time, right?
And all you want to do now, is to detect whether there's 0 V or the sine/square wave.
If that's what you are looking after, why do you need to measure the frequency? Why not just filter the signal to a continuous DC signal and go from there? A resistor and a capacitor should be all you need, shouldn't it? Or maybe just divide the signal to 5 V peak and read it directly with the Arduino. If no signal for, let's say 500 ms, then the feature is off, otherwise it's on.
100–900 what? mV?
And the ”+12 V” in that drawing, is that the sine/square wave?
Did you actually look at the signal with oscilloscope? If not, why not and how did you find out it's a square/sine wave? And if you did, was it a sine or a square wave…? Can't be both, right…?
Tnx for the answer!
Let's start from the beg:
guraknugen:
When the feature is on, there is a sine wave (or square wave) alternating from 0 V to 12 V, is that right?
And when the feature is off, it's 0 V all the time, right?
And all you want to do now, is to detect whether there's 0 V or the sine/square wave.
Right, but i want to know this as fast as possible (not like waiting 3 seconds and see if the analog read, read more then 1, if you know what i mean) And also, as efficient as possible ( not like using a capacitor discharge resistor lower then 100k, because it's a car battery and it's important not to waste energy)
guraknugen:
A resistor and a capacitor should be all you need, shouldn't it? Or
This is what i already done but it's not smooth because i don't know what values for the capacitor and resistor should i use, because i don't know the freqvency
guraknugen:
100–900 what? mV?
Reading from an arduino(5V)
guraknugen:
And the ”+12 V” in that drawing, is that the sine/square wave?
Did you actually look at the signal with oscilloscope? If not, why not and how did you find out it's a square/sine wave? And if you did, was it a sine or a square wave…? Can't be both, right…?
I only have a multimeter, not even one osciloscope in my whole city i think
...
so i don't know nothing about the wave, i only know there is a wave and i'm wondering if i can use some of my available board to measure the frequency of this unknown wave.