Comments (11)
- Does it happen on both channels?
- The input signal is definitely clean?
- If you do small 10 mV amplitude around an offset close to those levels, does it occur more often?
If it's really code dependent: I think the ADC SPI clk is now twice as fast as before (v1.0). Maybe it's hitting a timing issue. I'd check slower SPI clk (25 MHz) and with a scope on the bus.
from stabilizer.
- It happens on both channels.
- Input signal is clean.
- At small amplitude around these voltage levels it happens more often.
Channel 0
** 50Hz, 2 Vpp, 0 mVDC**
** left-hand side of previous screenshot**
** right-hand side of previous screenshot**
** 400 Hz, 2.5 mVpp, 160.8 mVDC**
** 400 Hz, 10 mVpp, 160.8 mVDC**
with reference signal from generator
from stabilizer.
160 mV is exactly at the 10 bit carry toggle. My guess is ADC sample/conversion/SPI timing.
from stabilizer.
I think multiple spikes at low amplitudes are due to noise at the input.
from stabilizer.
I think multiple spikes at low amplitudes are due to noise at the input.
Noise as a root cause isn't consistent with it being triggered at a specific digital code independent of offset, amplitude, slew rate.
@nkuh
If you want to play with the ADC SPI timing, read up on how the sampling and processing is timed and what the datasheets want, check the ADC SPI lines on a scope, and then mess with this:
stabilizer/stabilizer/src/main.rs
Line 201 in 547fe1b
from stabilizer.
Noise as a root cause isn't consistent with it being triggered at a specific digital code independent of offset, amplitude, slew rate.
I didn't mean as a root cause. I mean that the noise at the input causes the error, that happens at an exact voltage, to appear multiple times in quick succession because the input crosses that threshold multiple times.
from stabilizer.
Sure. Among other things the intrinsic ADC input noise is finite. That's sufficient. But it's not the problem.
from stabilizer.
I did some investigation here and this appears to be caused by the DAC hardware when transitioning across specific binary code boundaries. Below is a capture of the CSn line (dark blue) and the stabilizer output (light blue). Note that in the middel pulse, the small spike can be seen in the negative direction immediately after the DAC code is updated.
Note that probing the CSn line introduces some noise on the output. Below is what the capture looks like without CSn probed:
Upon further analysis, it appears that this glitch was specifically occurring when the DAC transitions across the 10-bit boundary (e.g. from 0x83FF to 0x8400) and is transient. In the following sample, stabilizer output was modified to output 0x83FF and 0x8400 in an alternating pattern at a 50KHz update period. The SPI frequency was also lowered to 5MHz.
It can be observed that every transition causes a transient spike in the opposite direction of the transition (e.g. we get a positive spike when transitioning from 0x8400 -> 0x83FF).
This appears to be a hardware issue and there's not much we can do to mitigate this in firmware. I'm spawning an issue in the hardware repository to track this.
from stabilizer.
Because this appears to be a hardware issue, this is being continued in sinara-hw/Stabilizer#83 and I'm closing the issue here.
from stabilizer.
Sound analysis. Is ch2 in this shot between DAC and output AFE opamps ro after the AFE at the SMA output?
from stabilizer.
CH2 is measured at the SMA output connected over a 50 Ohm impedance coaxial cable into the o-scope.
from stabilizer.
Related Issues (20)
- Stabilizer as streaming data sink
- rename driver interlock/interlock to interlock/interlocked HOT 1
- `y_min` value trumps `y_max` HOT 2
- Document influxdb/telegraf/grafana HOT 2
- Peripheral clock seems to be off. HOT 3
- Error print leads to spurious panics HOT 4
- move the alarm topic somewhere else or reduce traffic HOT 1
- PID coefficients settings
- Lock `miniconf-mqtt` python utilities to a tag HOT 3
- use dhcp default gateway as default broker HOT 1
- reconnect to flapping broker HOT 4
- Driver laser module header board bringup notes. HOT 2
- Put Driver DAC init first in setup.rs HOT 2
- Panic without connected debug probe does not trip the laser interlock. HOT 1
- Implement voltage sense at the header board HOT 1
- ramp IIR ignores IIR limits HOT 1
- Turn off when LM75 temperatures are out of range HOT 1
- fix ramp iir limits for negative currents HOT 1
- Stabilizer + Pounder panics on bootup HOT 12
- HITL Run Status is being ignored
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stabilizer.