Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add selection for HV/LV #7

Open
jonschumacher opened this issue Oct 20, 2017 · 8 comments
Open

Add selection for HV/LV #7

jonschumacher opened this issue Oct 20, 2017 · 8 comments

Comments

@jonschumacher
Copy link
Collaborator

This issue is related to #5: The input stage has some flaws which are being corrected by a filter. This filter has two constants AA and BB which differ for LV and HV.

@tknopp
Copy link
Owner

tknopp commented Oct 20, 2017

I also want to store the mapping IntToVolt on the RP. The server should provide a calibration procedure for this. Here, LV and HV need to be selected

@tknopp
Copy link
Owner

tknopp commented Oct 23, 2017

We should use the eeprom stuff that is implemented in the regular RP API:

https://github.com/RedPitaya/RedPitaya/blob/1dfabae67968cc76548e461c7d123a284d3df725/api/src/calib.c

If that is done the DAC API should use voltage.

@jongra
Copy link

jongra commented May 6, 2021

Is there a working solution for the selection today?

To be honest, I didn't realy understand how to do the calibration you mentioned.

@jonschumacher
Copy link
Collaborator Author

Unfortunately not yet. We do not use the „high“ voltage input path. I would recommend to just do a test sweep in the relevant frequency range with a calibrated signal generator and compare the acquired amplitude with the setting from the signal generator. If this comparison is fine for you, this issue might not even be relevant for you. Or did you already experience problems?

@jongra
Copy link

jongra commented May 7, 2021

Thank you for your answer.
In general, using a signal generator as a reference would work for us.
My problem is more that I have to use the 1V scale (LV mode) for finer voltage resolution and smaller absolute noise.

@tknopp
Copy link
Owner

tknopp commented May 7, 2021

So there is two different issues here:

  1. We have a transfer function in the input due to the decimation. This implies that higher frequencies are damped.
  2. Our interface currently only provides integers.

What we do regarding 2. is shown here: https://github.com/MagneticParticleImaging/MPIMeasurements.jl/blob/master/src/DAQ/RedPitayaScpiNew.jl#L160
So we have two calibration values (scaling and offset) that we use to convert int to volt. Roughly the values are:
scaling = 0.00012957305 offset = 0.015548877
for LV.

@jongra
Copy link

jongra commented May 7, 2021

Sorry, but for 1 I don't understand what you mean with "transfer function".

Regarding number 2, I don't really care if the data format is in integers or floats. I guess the conversion can be done later on in the software.
As far as I understand from the redpitaya schematics, a jumper decides the coupling of the voltage input to a fixed amplifier and further to the fixed ADC. So, I'll get a better voltage resolution when I'm using the LV jumper position. The software part than has to adjust the numerical scaling of the ADC output - I think this is what you suggested. However, you referred to a completely different repository. Where can I find the scaling in the RedPitayaDAQServer project?

@jonschumacher
Copy link
Collaborator Author

jonschumacher commented May 7, 2021

Concerning the transfer function I would like to refer to Wikipedia. The DAQ project just outputs the raw data of the 14 Bit ADC. The full scale value of the ADC is manipulated with said jumper.
The missing scaling is exactly what is meant within this issue and in #10 and is an open problem which is solved indirectly in the referenced package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants