MCS

Cbf Controller

On

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam collections {
  BackGroundColor LightBlue
  BorderColor DodgerBlue
}

skinparam database {
  BackgroundColor LightGreen
  BorderColor DarkGreen
}

title On Command Sequence MCS 0.9.3\n

participant "CSP_Mid\n.LMC" as lmc

box "MCS"
participant "Mid.CBF\nController" as controller
participant "Talon\nLRU" as lru
participant "Power\nSwitch" as switch
end box

participant "PDU\n" as pdu

box "HPS"
database "Files" as files
participant "HPS\nMaster" as hpsmaster
collections "HPS\nDevices" as hpsdevices
participant "FPGA\n" as fpga
end box

lmc        ->  controller   : On()
controller ->  lru          : PowerOn
lru        ->  switch       : On()
switch     ->  pdu          : On(outlets)
controller -> files         : Copy Binaries
controller -> hpsmaster **  : Start
controller -> hpsmaster ++  : Configure()
hpsmaster  -> fpga          : program bitstream
hpsmaster  -> hpsdevices ** : Start
controller <- hpsmaster --  : success


@enduml

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam collections {
  BackGroundColor LightBlue
  BorderColor DodgerBlue
}

skinparam database {
  BackgroundColor LightGreen
  BorderColor DarkGreen
}

title On Command Sequence MCS 0.9.3 - Detailed\nOne Talon Board

participant "CSP_Mid\n.LMC" as lmc

box "MCS"
participant "Mid.CBF\nController" as controller
participant "Mid.CBF\nSubarray" as subarray
participant "Mid.CBF\nVCC" as vcc
participant "Mid.CBF\nFSP" as fsp 
participant "Mid.CBF\nFspCorr\nSubarray" as corrsubarray
participant "Mid.CBF\nFspPst\nSubarray" as pstsubarray
participant "Mid.CBF\nFspPss\nSubarray" as psssubarray
participant "Talon\nLRU" as lru
participant "Power\nSwitch" as switch
database "Files" as mcsfiles
end box

participant "PDU\n" as pdu

box "HPS"
database "Files" as files
participant "HPS\nMaster" as hpsmaster
participant "VCC" as hpsvcc
participant "VCC\nBand1&2" as hpsvccband1
participant "FSP" as hpsfsp
participant "FSP\nCorr" as hpsfspcorr
participant "HPS\nDevices" as hpsdevices
participant "FPGA" as talon
end box

lmc        ->  controller   : On()

controller ->  vcc          : receptorID
controller ->  vcc          : freqOffsetK
controller ->  vcc          : freqOffsetDeltaF

controller ->  mcsfiles      : load talon_config_file
controller <-  mcsfiles      : talon_config_file

controller ->  lru          : PowerOn
lru        ->  switch       : On()
switch     ->  pdu          : On(outlets)
lru        ->  lru          : PowerMode.On

controller -> files         : Copy Binaries and bitstream
controller -> hpsmaster **  : Start
controller -> hpsmaster ++  : Configure()
hpsmaster  -> talon          : program bitstream
hpsmaster  -> hpsdevices ** : Start
controller <- hpsmaster --  : success

controller   -> subarray      : On
subarray     -> corrsubarray  : On
corrsubarray -> corrsubarray  : PowerMode.On
subarray     -> pstsubarray   : On
pstsubarray  -> pstsubarray   : PowerMode.On
subarray     -> psssubarray   : On
psssubarray  -> psssubarray   : PowerMode.On
subarray     -> subarray      : PowerMode.On
controller   -> vcc           : On
vcc          -> hpsvcc        : Connect
vcc          -> hpsvccband1   : Connect
vcc          -> hpsvcc        : InitParam(freqOffsetK, freqoffsetDeltaF)
vcc          -> vcc           : PowerMode.On
controller   -> fsp           : On
fsp          -> corrsubarray  : On
corrsubarray -> corrsubarray  : PowerMode.On
fsp          -> pstsubarray   : On
pstsubarray  -> pstsubarray   : PowerMode.On
fsp          -> psssubarray   : On
psssubarray  -> psssubarray   : PowerMode.On
fsp          -> fsp           : PowerMode.On
controller   -> controller    : PowerMode.On




@enduml

Cbf Subarray

Configure Scan

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

title MCS Configure Scan with Corr and PST BF\n

participant "TMC\n" as tmc
participant "CSP_Mid\n.LMC" as lmc

box "MCS"
participant "Mid.CBF\nController" as controller
participant "Mid.CBF\nSubarray" as subarray
participant "VCC\n" as vcc
participant "FSP\n" as fsp
participant "FspCorr\nSubarray" as fspcorr
participant "FspPst\nSubarray" as fsppst
end box

participant "HPS\nDevices" as hps

lmc         -> subarray     : ConfigureScan(json_str)
subarray    -> subarray     : validateInput

group Each FSP
subarray    -> fsp          : Unsubscribe to state/healthstate
end group

subarray    -> tmc          : Unsubscribe all events

group Each VCC
subarray    -> vcc          : GoToIdle
end group

group Each FSP Corr
subarray    -> fspcorr      : GoToIdle
end group

group Each FSP PST
subarray    -> fsppst      : GoToIdle
end group

group Each FSP
subarray    -> fsp          : RemoveSubarrayMembership(subarrayID)
end group
 
group Each VCC
subarray    -> vcc          : ConfigureBand(int)
subarray    -> vcc          : ConfigureScan(json_str)
vcc         -> hps          : configure HPS VCC
end group

subarray    -> tmc          : subscribe delay model
subarray    -> tmc          : subscribe Doppler phase correction
subarray    -> tmc          : subscribe Jones matrix
subarray    -> tmc          : subscribe timing beam weights

group Each VCC
subarray    ->vcc           : ConfigureSearchWindow(data)
end group

group Each FSP
subarray    -> fsp          : AddSubarrayMembership(subarrayID)
subarray    -> fsp          : SetFunctionMode(str)
subarray    -> fsp          : subscribe to state/healthstate changes
fsp         -> hps          : configure HPS FSP
end group

group Each FSP Corr
subarray    -> fspcorr          : ConfigureScan(json_str)
fspcorr         -> hps          : configure HPS FSP Corr
end group

group Each FSP PST
subarray    -> fsppst          : ConfigureScan(json_str)
fsppst         -> hps          : configure HPS FSP PST
end group

@enduml

MCS to HPS

MCS to HPS VCC Top Level Devices

  • TBD: Confirm no change from Correlation

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam maxMessageSize 100
skinparam ResponseMessageBelowArrow true

title PST BF MCS VCC Configure Scan\n"Each VCC" Details\n

box "MCS"
participant "Mid.CBF\nSubarray" as subarray
participant "VCC\n" as vcc
end box

box "HPS"
participant "VCC\nContr" as hpsvcccont
participant "VCC\nBand1&2" as hpsvccband1
collections  "Low\nLevel\nDevice\nServers" as llds

subarray    -> vcc          : ConfigureBand(freqBand:int)
vcc         -> hpsvcccont   : ConfigureBand(freqBand:int)
hpsvcccont  -> hpsvccband1  : On
vcc         -> hpsvccband1  : SetInternalParameters(gains)
hpsvccband1 -> llds         : configure low level device servers
subarray    -> vcc          : ConfigureScan(configID, freqBand:int, fsp:JSONstr)
vcc         -> hpsvccband1  : ConfigureScan(configID, freqBand:int, fsp:JSONstr)
hpsvccband1 -> llds         : configure low level device servers

@enduml

MCS to HPS FSP Top Level Device

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam ResponseMessageBelowArrow true

title MCS FSP PST BF Configure Scan\n"Each FSP PST" Details\n

box "MCS"
participant "Mid.CBF\nSubarray" as subarray
participant "FSP\nPst\n" as fsppst
end box

box "HPS"
participant "FSP\nPST" as hpsfsppst
collections "Low\nLevel\nDevice\nServers" as llds

subarray    -> fsppst       : ConfigureScan(\nsub_id\nfsp_id\nfunc_mode\nfs_id\nzoom_factor\nzoom window tuning\nintegration_factor\nchannel_offset\nchannel_averaging_map\nconfig_id\nfreq_band\nband5tuning\nfreq_band_offset_1\nfreq_band_offset_2\nsubarray_recep_id\nfs_sample_rates\ntiming_beams:JSON str:\nbeam_id\nenable_output\npst_recep_ids\noutput_host\noutput_mac\noutput_port)
fsppst      -> hpsfsppst    : ConfigureScan(\nsub_id\nfsp_id\nfs_id\nzoom_factor\nzoom window tuning\nintegration_factor\nchannel_offset\nchannel_averaging_map\noutput_link_map\nconfig_id\nfreq_band\nband5tuning\nfreq_band_offset_1\nfreq_band_offset_2\nsubarray_recep_id\nfs_sample_rates\ntiming_beams:JSON str:\nbeam_id\nenable_output\npst_recep_ids\noutput_host\noutput_mac\noutput_port\nrdt_fo_valid_int\nrdt_num_lsq_pt\nrdt_fo_fill_thresh\nrdt_fo_low_thresh\nrdt_set_input_sample_rate\nrdt_set_output_sample_rate\npst_ch_gain)
hpsfsppst   -> llds         : configure

@enduml

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam ResponseMessageBelowArrow true

title MCS FSP CORR Configure Scan Band 1, 2 \n"Each FSP Corr" Details\n

box "MCS"
participant "Mid.CBF\nSubarray" as subarray
participant "FSP\nCorr\n" as fspcorr
end box

box "HPS"
participant "FSP\nCorr" as hpsfspcorr
participant "Packet\nStream\nRepair" as psr
participant "Resampler\nDelay\nTracker" as rdt 
participant "Fine\nChannel" as fc 
participant "Corner\nTurner" as ct 
participant "Corre-\nlator" as corr

group Each FSP Corr 
subarray    -> fspcorr      : ConfigureScan(\nsub_id\nfsp_id\nfunc_mode\nfs_id\nzoom_factor\nzoom window tuning\nintegration_factor\nchannel_offset\nchannel_averaging_map\noutput_link_map\noutput_host\noutput_mac\noutput_port\nconfig_id\nfreq_band\nband5tuning\nfreq_band_offset_1\nfreq_band_offset_2\nsubarray_recep_id\nfs_sample_rates\ncorr_recep_id)
fspcorr     -> hpsfspcorr   : ConfigureScan(\nsub_id\nfsp_id\nfunc_mode\nfs_id\nzoom_factor\nzoom window tuning\nintegration_factor\nchannel_offset\nchannel_averaging_map\noutput_link_map\noutput_host\noutput_mac\noutput_port\nconfig_id\nfreq_band\nband5tuning\nfreq_band_offset_1\nfreq_band_offset_2\nsubarray_recep_id\nfs_sample_rates\ncorr_recep_id\nrdt_fo_valid_int\nrdt_num_lsq_pt\nrdt_fo_fill_thresh\nrdt_fo_low_thresh\nrdt_set_input_sample_rate\nrdt_set_output_sample_rate\nfine_ch_gain\nddr4ct_min_int_time_num_samp\nddr4ct_read_threshold\nddr4ct_read_timeout_thres\ncorr_num_freq_channel)
group Each receptor to be correlated (corr_recep_id)
hpsfspcorr  -> hpsfspcorr   : calc psr packet rate
hpsfspcorr  -> psr          : Write(packet_rate)
note right                  : packet_rate=510/2/\nfs_sample_rate*450
hpsfspcorr  -> rdt          : Stop
hpsfspcorr  -> rdt          : Write(fo_valid_int\nnum_lsq_pt\nfo_fill_thresh\nfo_low_thresh)
hpsfspcorr  -> rdt          : SetInputSampleRate(set_input_sample_rate)
hpsfspcorr  -> rdt          : SetOutputSampleRate(set_output_sample_rate)
hpsfspcorr  -> rdt          : Start
hpsfspcorr  -> fc           : Write(gain)
end group Each receptor to be correlated (corr_recep_id)
group Each Corner Turner
hpsfspcorr  -> ct           : Read(number_of_samples)
hpsfspcorr  <- ct           : number_of_samples
hpsfspcorr  -> hpsfspcorr   : calc iteration length
note right                  : iteration length = min_int_time_num_samp/\n(num_samples-1)
hpsfspcorr  -> ct           : Write(iteration_length\nread_threshold\nread_timeout_thres\nclear_under_run_status\nclear_read_timeout_status)
hpsfspcorr  -> ct           : Subscribe(antenna_status)
end Each Corner Turner
hpsfspcorr  -> hpsfspcorr   : calc freq_channel_offset
hpsfspcorr  -> corr         : Write(num_freq_channel\nfreq_channel_offset\ninteg_multiple\nsub_id\nsubarray_recep_id)
hpsfspcorr  -> corr         : ProgramLta
end group Each FSP Corr

@enduml

HPS

HPS VCC Top Level to Low Level Devices

  • TBD: Confirm no change from Correlation

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

skinparam maxMessageSize 100
skinparam ResponseMessageBelowArrow true

title PST BF HPS VCC Configure Scan\n"Each VCC" Details\n

box "MCS"
participant "VCC\n" as vcc
end box

box "HPS"
participant "VCC\nContr" as hpsvcccont
participant "VCC\nBand1&2" as hpsvccband1
participant "Circuit\nSwitch" as cs
participant "VCC" as hpsvcc
participant "WB\nInput\nBuffer" as wbib

vcc         -> hpsvcccont   : ConfigureBand(freqBand:int)
hpsvcccont  -> hpsvccband1  : On
vcc         -> hpsvccband1  : SetInternalParameters(gains)
hpsvccband1 -> hpsvcc       : Write(gain)
vcc         -> hpsvccband1  : ConfigureScan(configID, freqBand:int, fsp:JSONstr)
hpsvccband1 -> cs           : Write(input_select:array)
hpsvccband1 -> hpsvccband1  : Calc frame_count
note right                  : frame_count=(round(3960*\n1000000\n+freqOffsetK*offsetDeltaF)\n/1000000)/18
hpsvccband1 -> hpsvcc       : Write(frame_count)
hpsvccband1 -> hpsvccband1  : Calc stream_rate
note right                  : stream_rate=\n3.96e9+(freqOffsetK)*1800)/18
hpsvccband1 -> wbib         : Write(receive_enable:true, stream_rate, packet_rate:295, noise_diode:1024)

@enduml

HPS FSP Top Level to Low Level Devices

Ref: Mid CBF AA1 PST Firmware Diagram

Configure Scan

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

title HPS Configure FSP for PST Beamforming Scan\n

box "MCS"
participant "Fsp PST\nSubarray" as fsppst
end box

box "HPS"
participant "FSP\nPST" as hpsfsppst
participant "Packet Stream\nRepair" as psr
participant "Resampler\nDelay Tracker" as rdt
participant "PST 4K\nChannelizer" as channelizer
participant "Sync\nBuffer" as buffer
participant "Beam\nSummer" as summer
participant "PST\nPacketizer" as packetizer
participant "Host\nLUT" as lut
end box

fsppst     -> hpsfsppst   : ConfigureScan(json_str)

group Each VCC included in PST Beam (TBD: Confirm)
hpsfsppst  -> hpsfsppst   : calc psr packet rate
note right                : + how do we map RDT, FC, PSR\nblocks to vcc (instead of recepID)?
hpsfsppst  -> psr         : write packet rate
note right                : packet_rate for receptor=\n510/2/\nfs_sample_rate*450
hpsfsppst  -> rdt         : stop
hpsfsppst  -> rdt         : write attributes
hpsfsppst  -> rdt         : set input sample rate
hpsfsppst  -> rdt         : set output sample rate
hpsfsppst  -> rdt         : start
end group

hpsfsppst -> channelizer : write gain([..])
hpsfsppst -> buffer      : reset()
hpsfsppst -> buffer      : write dwell_time()
hpsfsppst -> summer      : write vcc_ids([..])
hpsfsppst  -> packetizer : write meta_first_channel_frequency()
hpsfsppst -> lut         : write config(TBD)

@enduml

Scan

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

title HPS PST Beamforming Scan\n

box "MCS"
participant "Fsp PST\nSubarray" as fsppst
end box

box "HPS"
participant "FSP\nPST" as hpsfsppst
participant "Packet Stream\nRepair" as psr
participant "Resampler\nDelay Tracker" as rdt
participant "PST 4K\nChannelizer" as channelizer
participant "Sync\nBuffer" as buffer
participant "Beam\nSummer" as summer
participant "PST\nPacketizer" as packetizer
participant "Host\nLUT" as lut
end box

fsppst     -> hpsfsppst   : Scan()

@enduml

Test Vector Generation

The Test Vector Generator enables more direct testing of the beamformer (beam summer) by injecting well-defined test signals into the PST Sync Buffer, by-passing the preceding components. See the pst_processing.vhd diagram for details.

@startuml
'https://plantuml.com/sequence-diagram

skinparam backgroundColor #EEEBDC
skinparam sequence {
ParticipantBorderColor DodgerBlue
ParticipantBackgroundColor DeepSkyBlue
ActorBorderColor DarkGreen
ActorBackgroundColor Green
BoxBorderColor LightBlue
BoxBackgroundColor #F0FFFF
}

title PST Beamforming Test Vector Generation\n

box "MCS"
participant "Fsp PST\nSubarray" as fsppst
end box

box "HPS"
participant "FSP\nPST" as hpsfsppst
participant "Test Vector\nGenerator" as test_vec
participant "Sync\nBuffer" as buffer
participant "Beam\nSummer" as summer
participant "PST\nPacketizer" as packetizer
participant "Host\nLUT" as lut
end box

fsppst    -> hpsfsppst   : ConfigureTest(json)
hpsfsppst -> test_vec    : reset()
hpsfsppst -> test_vec    : configure(json)
hpsfsppst -> buffer      : reset()
hpsfsppst -> buffer      : write dwell_time()
hpsfsppst -> summer      : write vcc_ids([..])
hpsfsppst -> packetizer  : write meta_first_channel_frequency()
hpsfsppst -> lut         : write config(TBD)

fsppst    -> hpsfsppst   : StartTest()
hpsfsppst -> test_vec    : start_generation()
...
fsppst    -> hpsfsppst   : StopTest()
hpsfsppst -> test_vec    : stop_generation()

@enduml