Skip to content

StrawDigisFromArtDaqFragments needs cleanup #1855

Description

@brownd1978

this code has developed organically while debugging artdaq issues and could use a cleanup. The main issues are:

  • the code uses a mix of c++ and c-style casts, with types and const not being respected. A consistent use of c++ casts would be better. Even better would be if the fragment-related objects provided casting functions themselves, though that is outside the scope of this repo.
  • the module uses data members to cache data descriptions (nSamples_ , np_per_hit_, etc) which are set on reading the first valid packet, but aren't reset between runs, where they can change
  • the decoding is spaghetti code. A more encapsulated set of functions would be easier to maintain and debug.
  • the bounds checks aren't complete, and are interspersed with the decoding. Factorizing out the bounds checks (per fragment, per DTC, etc) would make the code easier to understand.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions