The common ATCA driver is responsible for the following:
This class is responsible for DaqMux 0 and 1 configurations, JESD Top (AMC) 0 and 1, Waveform engine, Build information, and temperature information.
The static function if the parent class ATCACommonFw allows the instantiation of API class. It seems to return an instantiation of the child class as follows:
ATCACommonFw IATCACommonFw::create(Path p) { return IEntryAdapt::check_interface<ATCACommonFwAdapt, DevImpl>(p); }
The code to instantiate the API is as follows
atcaCommon = IATCACommonFw::create(p_atcaCommon);
The stream can be created using the createStream method in the API. Streams can be instantiated separately by calling the CPSW stream creation function directly as follows
try { _stream[0] = IStream::create(p_root->findByName(stream0)); } catch (InvalidArgError &e) { // Don't print error if the stream name is empty, as the user didn't // want to create this channel anyway. } catch (CPSWError &e) { fprintf(stderr, "CPSW Error: %s, file: %s, line: %d\n", e.getInfo().c_str(), __FILE__, __LINE__); }
This class is responsible for configuring the timing cross bar. The timing cross bar is nothing more than four multiplexers configuring four outputs choosing from four sources
The functions available are simply to instantiate a crossbar, and to configure and read current configuration.
CPSW throws CPSWError errors, but the driver does not. It does propagate however the exception CPSWError in some contexts and performs some prints to stderr. Upper layers should catch exceptions of type CPSWError.