M1M3 Support System
Loading...
Searching...
No Matches
LSST::M1M3::SS::BusList Class Reference

Abstract class. More...

#include <BusList.h>

Inheritance diagram for LSST::M1M3::SS::BusList:
Collaboration diagram for LSST::M1M3::SS::BusList:

Public Member Functions

 BusList (ILCSubnetData *subnetData, ILCMessageFactory *ilcMessageFactory)
 
virtual void buildBuffer ()
 (Re)-build message send to FPGA.
 
int32_t getLength ()
 
uint16_t * getBuffer ()
 
int32_t * getExpectedHPResponses ()
 
int32_t * getExpectedFAResponses ()
 
int32_t * getExpectedHMResponses ()
 
virtual void update ()
 Called when update to buffer is required.
 

Protected Member Functions

void startSubnet (uint8_t subnet)
 Writes command to start a subnet message on the bus.
 
void endSubnet ()
 Ends subnet.
 

Protected Attributes

ILCSubnetDatasubnetData
 Status of messages on a subnet.
 
ILCMessageFactoryilcMessageFactory
 
ModbusBuffer buffer
 Buffer holding data send to FPGA Command FIFO.
 
int32_t expectedHPResponses [HP_COUNT]
 
int32_t expectedFAResponses [FA_COUNT]
 
int32_t expectedHMResponses [HP_COUNT]
 
int32_t subnetStartIndex
 

Detailed Description

Abstract class.

Holds list of ILCs on the bus. Allows CSC to query ILCs of their status, command what is needed etc. This is achieved by storing (caching) ModbusBuffer with required bytes, which is updated in update call with new force demands etc.

Buses 1-4 holds only Force Actuator (FA) ILCs. Bus 5 is reserved for Hardpoint Actuator (HP).

The major challenge in commanding ILCs on the buses is to keep messages short and this system as fast as possible. Not all ILCs can be queried in a single loop for all data.

To speed up query build-up, FPGA transmitt buffer is prepared in buildBuffer methed. It is then updated at specified parts in update method.

Only required data are quieried in every loop. Other queries (e.g. ServerState,..) are distributed, and only ILC subset is updated on every loop. The subset moves in round-robin fashion.

Member Function Documentation

◆ buildBuffer()

◆ endSubnet()

void BusList::endSubnet ( )
protected

Ends subnet.

Writes IRQ trigger and sets buffer length.

Here is the caller graph for this function:

◆ startSubnet()

void BusList::startSubnet ( uint8_t subnet)
protected

Writes command to start a subnet message on the bus.

Length is filled in endSubnet() method.

Here is the caller graph for this function:

◆ update()

virtual void LSST::M1M3::SS::BusList::update ( )
inlinevirtual

Called when update to buffer is required.

Shall write new values to ILC commands etc.

Reimplemented in LSST::M1M3::SS::ActiveBusList, LSST::M1M3::SS::FreezeSensorBusList, and LSST::M1M3::SS::RaisedBusList.


The documentation for this class was generated from the following files: