CMM2 Oscilloscope fun
| Author | Message | ||||
| KeepIS Guru Joined: 13/10/2014 Location: AustraliaPosts: 2199 |
I’ve been wanting to have a play with the ADC on the CMM2 and was prompted by TassyJim and his really nice temperature sensor capture program. I wanted to be able to quickly change the Sample Frequency and Trigger levels on the fly and quickly came up with this little Oscilloscope program. 1: Sample frequency in 100Hz steps from 100Hz to 5KHz 2: Trigger level from -3.3 to + 3.3 and single key to switch Trigger polarity 3: Trigger line on display and time period follows sample Frequency. To show Sine waves the ADC input needs a DC offset at half the value of the P-P value of the waveform. Digital signals that aren’t negative going don’t need this. A quick and dirty way to show external sine wave (AC) signals is to use a variable resistor of around 100k connected between 3v and ground, the centre slider is taken to the ADC input and the sine wave signal is coupled with a 1uf cap to the centre slider. Turning the variable resistor moves the trace up and down the screen, at 1.5 volts a sine wave with a peak to peak voltage of up to 3 volts will show without clipping. Be sure to keep any input voltage to the CMM2 ADC below 3.3v Ideally you would an OP-AMP with adjustable DC offset for audio (analogue) work or digital signals that also go negative. Incorporated in a simple circuit would be adjustable gain with selectable input voltage ranges. Such as it is, the program might be a bit of fun for someone to play with. AudCRO.zip . NANO:Inverter V 8.2ks -Â Linux AvrDude GUI script V4.1 |
||||