Skip to content
Nicolas Peschke edited this page Aug 27, 2020 · 15 revisions

Usage as droplet sorter

Prerequisites

  • RedPitaya
  • Cloned pyrpl repository on the open_fpga_fads branch
  • Oscilloscope (for an unbiased view of what the RedPitaya is seeing and doing)
  • Function generator (just for testing/evaluation purposes)

Setup

Installing Pyrpl

  • Create a conda environment for pyrpl
conda create -y -n pyrpl-env numpy scipy paramiko pandas nose pip pyqt qtpy pyqtgraph pyyaml
activate pyrpl-env
  • Clone the pyrpl repository at the branch and install pyrpl
git clone https://github.com/npeschke/pyrpl@open_fpga_fads
cd pyrpl
python setup.py develop

RedPitaya

Follow the pyrpl guide for preparing the hardware.

Afterwards copy the pyrpl/fads_logger directory to your RedPitaya

cd pyrpl/fads_logger
scp * root@<RedPitaya Hostname>:/root/mybin/logger

Connect to the RedPitaya over ssh and build the logger application

ssh root@<RedPitaya Hostname>
cd /root/mybin/logger

make

This should even start the logger. For now this can be aborted using Ctrl-C

Starting logging to a file

Run the following command

bash /root/mybin/logger/fads_logger > /PATH/TO/LOGFILE

and replace the path with one of your liking.

CAUTION: This will overwrite the file if it already exists.

CAUTION: Keep the caveats in mind

Logfile contents

Currently, the logfile contains the following columns:

  1. Droplet ID (Basic autoincrementing counter of everything that reached min_intensity_threshold)
  2. Droplet Intensity maximum (Raw value from the ADC before conversion)
  3. Droplet Intensity maximum (Scaled to the HV +-20V range of the RedPitaya but NOT calibrated)
  4. Droplet width in FPGA clock cycles (125 MHz clock)
  5. Droplet width in milliseconds
       43580            -189    -0.461426               9115    0.072920
       43581            -186    -0.454102              38719    0.309752
       43582            -187    -0.456543               6801    0.054408
       43583            -186    -0.454102              21628    0.173024
       43584            -187    -0.456543              23211    0.185688

Running pyrpl

Run the run_pyrpl.py script on your computer (not the RedPitaya)

python scripts/run_pyrpl config=example_config hostname=<RedPitaya Hostname>

and follow the instructions for a basic setup.

Droplet Sorting

  • Add the asgs, scopes and the fadss modules to the gui.
  • Set the following defaults

  • Connect the photodetector to IN1 and the high voltage amplifier to OUT1

  • Run the experiment

  • Thresholds can be tweaked using the scope screen and when daisy-chaining a Oscilloscope

    • Take care of potential impedance mismatches between Photodetector and the High-Z RedPitaya scope
Clone this wiki locally