Thursday, May 9, 2013

Next step - controlled sources and power electronics

The thought of spending the next few weeks sorting out the exception handling put me off completely. So I decided to skip that stage and move on to expanding the library instead. Whats the point of having my own project if I can't do what I want?

So, now designing the interface for a controllable object for example a controllable voltage source. The primary objective with this software is that an advanced user should be able to code whatever he wants as the control code. Taking my requirements specifically, I would like the control code that I write to be able to translate into a C program that I can compile into a DSP.

So, with any controllable object, what are the major interface requirements?
1. Inputs - preferrably in the form of meaurements from meters
2. Control outputs - can be defined in the parameter specification sheet.
3. An event generator - when must the control values be updated.

With no. 1 and no. 2 the objective will be that the user should have convenient interface to access the outputs of measurement meters and  update the controls without getting too much into the way objects are defined. So this means, I would have to add another layer between the "component_objects" dictionary in the main and the control code. So the next question, how will this interface be decided? In most simulators, input ports are defined and these are connected to signals in the outer layer. This might be one way to design an interface. Ask the user to choose what are the inputs to the control code.

With no. 3 the purpose of an event generator is that different objects have to be upated at different rates - i.e multi-rate sampling. So the control code must execute when the object with the nearest update time is called. Also, how to ensure that objects are updated only when necessary?

No comments:

Post a Comment