I work with electronics test equipment. I like to be able to automate tests using their remote control interfaces. I would like to build a pattern, a base class, that I can apply to all devices that follow the SCPI protocol. I would like to avoid half-assing the implementation like every time before. I wan't to bite the bullet and do this the right way once and for all. I do not use LabView so I can't just download their drivers.
I pounded out something that got me close, but it's not all the way there. If it looks like mad ramblings just ignore it. Any pointers on the right design pattern will really help!
I have designed it the way you see it because I want the usability to be nice and clean like:
double instantaneousCurrent = instrument.Measurement.Current.Instantaneous.Get();
or
double powerSetPoint = double.Parse(Console.ReadLine());
instrument.Load.ConstantPower.Set(powerSetPoint);
Each node in the would ideally put your statement another "." deeper down the instrument object.
I can't figure out how to pear this down enough to make it readable here. So I have the base pattern design here and a limited implementation here.
Aucun commentaire:
Enregistrer un commentaire