project8 / psyllid

Data acquisition package for the ROACH2 system
Other
0 stars 1 forks source link

New config file paradigm #21

Closed nsoblath closed 7 years ago

nsoblath commented 7 years ago

Psyllid needs a new config-file paradigm to support production use of the software. The current version has sufficed well for development, but is too simplistic for what we'll need to do.

Comments are welcome.

To-do list

Example configuration file

For a 3-channel FPA DAQ:

amqp:
    broker: localhost
    broker-port: 5672
    request-exchange: requests
    alert-exchange: alerts
    queue: psyllid
    listen-timeout-ms: 100

daq:
    activate-at-startup: true

streams:
    - preset: str-1ch-fpa

      device:
          n-channels: 1
          bit-depth: 8
          data-type-size: 1
          sample-size: 2
          record-size: 4096
          acq-rate: 100 # MHz
          v-offset: 0.0
          v-range: 0.5

      prs:
          length: 10
          port: 23530
          interface: eth1
          n-blocks: 64
          block-size: 4194304
          frame-size: 2048

    - preset: str-1ch-fpa

      device:
          n-channels: 1
          bit-depth: 8
          data-type-size: 1
          sample-size: 2
          record-size: 4096
          acq-rate: 100 # MHz
          v-offset: 0.0
          v-range: 0.5

      prs:
          length: 10
          port: 23530
          interface: eth2
          n-blocks: 64
          block-size: 4194304
          frame-size: 2048

    - preset:  # this preset is identical to str-1ch-fpa; it's given like this as a demonstration of how to specify a preset in a configuration file
          name: str-1ch-fpa-alt
          nodes:
            - { type: packet-receiver-fpa,   name: prs }
            - { type: tf-roach-receiver,     name: tfrr }
            - { type: streaming-writer,      name: strw }
            - { type: term-freq-data,        name: term }
          connections:
            - "prf.out_0:tfrr.in_0"
            - "tfrr.out_0:strw.in_0"
            - "tfrr.out_1:term.in_0"

      device:
          n-channels: 1
          bit-depth: 8
          data-type-size: 1
          sample-size: 2
          record-size: 4096
          acq-rate: 100 # MHz
          v-offset: 0.0
          v-range: 0.5

      prs:
          length: 10
          port: 23530
          interface: eth3
          n-blocks: 64
          block-size: 4194304
          frame-size: 2048
nsoblath commented 7 years ago

Completed in commit 5d5dabe650afaac018be07b2ed74591f373c48e1