6

The two strips on either side of the bread board, color red and blue (typically) are power rails, and each strip is all connected. Your circuit connections that are on that strip are shorted together and will not work. I suggest following his layout exactly to begin with, and once you've learned the basics of breadboard connections, you can start doing your ...


5

You calculation of the data rate is wrong: Serial.println() adds CRLF (i.e. "\r\n") to terminate the line, That's 2 bytes, not one. Each byte is sent by the serial port as one start bit, followed by 8 data bits, followed by one stop bit. That's 10 bits in terms of timing. In the worst case scenario (value ≥ 1000), you are sending 6 bytes, or 60 ...


5

Since you used Arduino tag..., you don't need an opamp. Instead you can select ADC reference voltage on your arduino to 1.1V. This way you don't need any additional parts and you get the whole precision range. analogReference(INTERNAL1V1); http://www.arduino.cc/en/Reference/AnalogReference


4

In your interrupt handler, ADC_Handler(), you set sample_buffer_full when the buffer is full. I don't see anywhere in the code where sample_buffer_full ever gets reset (cleared) once it's been set. While sample_buffer_full is set, it disables the body of the interrupt handler – ie, the handler's structure is if (!sample_buffer_full) { ...body of handler.....


4

According to the datasheet (page 375) the minimum voltage you are allowed to have as a reference voltage for the ADC is 1V.


3

I would recommend you to check Nick Gammon's example on using the analog comparator by means of configuring the relevant flag bits of registers in the ATmega328. Sample code from the link, by Nick: volatile boolean triggered; ISR (ANALOG_COMP_vect) { triggered = true; } void setup () { Serial.begin (115200); Serial.println ("Started."); ...


3

ADS7835 from Texas Instrument. can be interfaced with Arduino Mega or Raspberry Pi It is interfaced through SPI, 12 bit data, and up to 500kHz throughput rate.


3

First, a preliminary note: according to the datasheet, the only time you need a delay in your program is after reading the whole array and before sending the next sync pulse. All the other timing requirements are shorter than a single CPU cycle of your Mega, so no need to add extra delays. the camera didn't move so I assume that it should give back ...


3

Sorry, but.. Why integration? Just use a peak detector like this one: The output will "float" to the peak value of the input signal, minus the voltage drop across the diode: The output oscillates between 9.7V and 9.2V, which is a 5% maximum error. If you want to reduce it, sample with a sample rate not multiple of 50Hz and average the measures. The RC ...


3

Here's a major problem: void loop() { uint8_t i; float average; float average_two; float average_three; float stuckintime; for (i = 0; i < NUMSAMPLES; i++) { samples[i] = analogRead(THERMISTORPIN); samples_two[i] = analogRead(THERMISTORPIN2); samples_three[i] = ...


3

It is possible to decode DTMF tones with only a few common external components. The trick is to turn the analog audio into a digital signal, and then check the timing between the leading and trailing edges in order to figure out which tone is present. First, create a 1.1V bias using a voltage divider. This bias will connect to both a capacitor that is ...


3

As John Taylor said, DTMF is not a single tone but two tones transmitted simultaneously, which select the digit from a two-dimensional grid. (Dual tone multi-frequency). This allow 16 possible combinations from only 8 distinct tones. There are chips available specifically for the task of decoding DTMF, but it's always nice to try and find a one-chip ...


3

Just to as a complement to Majenko's answer (which I second), there are a couple of flaws in your program that may be related to your problem: lowest is always zero, as it is initialized to 0 and cannot increase your computation of the mean is incorrect: the mean is the sum of the readings divided by their number you fail to reset lowest and highest between ...


3

1) You only have one ADC on board and all the pins run through a mux. You can only read one pin at time. If you're willing to give up some resolution then you might can read a little faster but it gets tough. What's worse is that when you are switching pins really fast it can mess with your readings so that for some things, especially when input ...


2

DTMF is actually two non-harmonically related frequencies transmitted at the same time as opposed to a single frequency tone that can be measured with the above process, hence Dual-Tone-Multi-Frequency: You can use the Rohm BU8872 series devices which decodes the 4 x 4 multi tone combinations directly into a 4 bit digital result per the grid above. This ...


2

A datasheet for the HX711 is https://cdn.sparkfun.com/datasheets/Sensors/ForceFlex/hx711_english.pdf (On your board, it looks like E+ is AVDD and E- is AGND.) Each of your two load cells could be a half-bridge of a wheatstone bridge, with excitation on the white and black, and sensing on the red like: I have a similar loadcell with the colors as Blue-...


2

With an Arduino Uno, you can get 9615 samples per second from an analog input, and do the data processing at the same time. That's more than enough to reliably detect a peak. For this, you have to set the ADC to "free running mode" and do the processing in the ADC interrupt service routine. Se this answer for a detailed explanation and code. Oh, and instead ...


2

I need to sample voltage at a very high rate (say for like 10000 Hz) and with a very good precision(at least 10-12 bit ADC will do). 10Ksps and 12bit-resolution adcs are fairly common for onboard ADC. you should be able to find lots of mcus that have adc modules that can do that. even for an external adc, that's not difficult at all. because of the speed, ...


2

Let's take a look at a typical function for reading this sensor. This is from the Adafruit_VCNL4010 library and is for reading the proximity: uint16_t Adafruit_VCNL4010::readProximity(void) { uint8_t i = read8(VCNL4010_INTSTAT); i &= ~0x80; write8(VCNL4010_INTSTAT, i); write8(VCNL4010_COMMAND, VCNL4010_MEASUREPROXIMITY); while (1) { //...


2

You seem to be interested mainly in ATSAMD21. There is an application note from Atmel, AT11480: Analog Comparator Application Examples, which may be of interest for you. From the Getting started section (3.1, page 8): The AC [Analog Comparator] example project has to be opened from New Example Project option in Atmel Studio. Using the option Atmel ...


2

As Edgar has mentioned you are confusing things slightly. First there is your sampling frequency. According to the Shannon-Nyquist theorem that is at a minimum of 2x the maximum frequency in your signal. So that is 2x100 = 200Hz. That's the number of samples per second in your sample set. Secondly is your sample size, which is directly related to the FFT ...


2

It is not possible to sample two signals at the exact same time with an Arduino Uno. The Arduino has only one ADC, so you have to sample one signal, switch channels, sample the other, switch channels again, etc. If this is acceptable for your project, then yes, it is perfectly feasible with an Arduino Uno. But you will have to dig into the datasheet and ...


2

Here is the proper way to implement a polynomial function. It's a direct application of Horner's method: // Polynomial function for output 1. static float f1(float x) { return (((8.8e-4 * x - 0.0034) * x + 0.37) * x - 6.7) * x + 1.7e2; } You would use it like this: void loop() { for (int x = 0; x < 10; x++) { analogWrite(LED, f1(x)); ...


2

You can't magic more resolution out of thin air (well, you can, but it slows down your sampling - you would "oversample" and average a number of sequential samples). Instead you need to boost your signal before it gets to the ADC using an op-amp. The simplest circuit (which also inverts the signal, but you don't really care about that I suspect) is: ...


2

First of all, the ADC on the Uno is 10 bits, not 12. The naive approach of having analogRead() in a tight loop can give you up to 8.9 kS/s (112 µs per sample), but you won't be able to do much else, as the CPU spends most of it's time just waiting for the ADC to do its job. If you configure the ADC manually, then you can set it into the so ...


1

I suggest you consider as “top value of the falling edge” the maximum of the values you have read during a specified time window before the edge is detected. This means you have to compute the maximum at the time you detect the edge. If you instead continuously compute a running maximum, then you are going to get a global maximum. Amended source: bool ...


1

TRRS relates to the style of the jack plug used: Tip Ring Ring Sleeve. You still need to amplify the signal with a microphone preamp the same as your electret (in fact it will be an electret in there anyway). And then the Arduino cannot process human speech. You may be able to use a voice recognition module to get it to respond to specific commands, but the ...


1

It is very unclear what you are trying to achieve here. You are clocking the ADC at its maximum frequency, which has it take one reading every 13 µs, and yet you are delaying for 10 ms after sending one reading through the serial port. So basically your Matlab program is getting one reading out of every 769 you take. If you want fast data ...


1

If you use an ISR to retrieve the ADC result, you will need to protect the read of the variable. An interrupt may occur when reading aval in the loop(), as this is a 16-bit value and the read requires several instructions. This may give corrupt values. void loop() { noInterrupts(); val = aval; interrupts(); val = map(val, 0, 1023, 0, 255); ...


1

You don't seem to understand how to wire an OP-AMP. Here is a quick tutorial on their basics: https://www.youtube.com/watch?v=kqCV-HGJc6A The thing is that you are missing a LOT of resistors. An usual OP-AMP circuit contains many resistors to determine the amount of amplification and more... The tutorial explains quite well what resistor and where do you ...


Only top voted, non community-wiki answers of a minimum length are eligible