def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self,env,name)
        self.inp=inp
        self.outp=outp
        
        # parameters
        self.printing_delay=1
        self.cleaning_delay=1
        self.num_pcbs_per_cleaning=2
        
        # Consumables: 
        # (Solder and adhesive reserves:)
        # default values for initial amount and capacity are 0.
        # these parameters are to be set by the user
        # in the top-level system description
        self.solder_capacity = 0.0
        self.solder_initial_amount = 0.0

        self.adhesive_capacity = 0.0
        self.adhesive_initial_amount =0.0

               
        # states
        self.define_states(states=["idle","waiting_for_refill","printing","cleaning","waiting_to_output"],start_state="idle")
        self.process=env.process(self.behavior())
        
        # this is the operator we interrupt 
        # when the solder/adhesive reserves are low.
        #
        self.refill_operator=None
        
               
        self.solder_reserve = None
        self.adhesive_reserve=None
    def __init__(self, env, name, num_stages, delay_per_stage):
        BaseOperator.__init__(self, env, name)

        self.num_stages = num_stages
        self.delay_per_stage = delay_per_stage

        #default parameter values
        self.start_time = 0

        #A conveyor belt has at-least two stages
        assert (isinstance(self.num_stages, int) and (num_stages >= 2))
        assert (isinstance(self.delay_per_stage, int))
        assert (isinstance(self.start_time, int))

        # create input and output buffers
        # corresponding to the first and last stages
        self.input_buf = simpy.Store(env, capacity=1)
        self.output_buf = simpy.Store(env, capacity=1)

        # a list to model stages
        self.stages = [None for i in range(num_stages)]

        #states
        self.define_states(["empty", "moving", "stalled"], start_state="empty")

        # start behavior
        self.process = env.process(self.behavior())
Beispiel #3
0
    def __init__(self,env,name,inp,outp):
        BaseOperator.__init__(self,env,name)
        self.inp=inp
        self.outp=outp

        self.start_time=0

        #states
        self.define_states(["idle","printing","waiting_for_refill"])

        # this is the operator we interrupt 
        # when the solder/adhesive reserves are low.
        #
        self.refill_operator=None
        
        # Consumables: 
        # (Solder and adhesive reserves:)
        # default values for initial amount and capacity are 0.
        # these parameters are to be set by the user
        # in the top-level system description
        self.solder_capacity = 0
        self.solder_initial_amount = 0

        self.adhesive_capacity = 0
        self.adhesive_initial_amount =0
        
        self.solder_reserve = None
        self.adhesive_reserve=None


        # start behavior
        self.process=env.process(self.behavior())
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        # parameters
        self.processing_delay = 1
        self.reel_replacement_interval = 2

        # state variables
        self.num_pcbs_processed_since_last_reel_replacement = 0

        # states
        self.define_states(states=[
            "idle", "waiting_for_reel_replacement", "processing",
            "waiting_to_output"
        ],
                           start_state="idle")
        self.process = env.process(self.behavior())

        # this is the operator we interrupt
        # for performing reel replacements
        self.reel_replacement_operator = None

        # instantiate a SimPy buffer used as a flag.
        # An occupied buffer indicates that a reel replacement operation
        # has been completed by an external operator.
        self.reel_replacement_done = simpy.Store(env, capacity=1)
    def __init__(self, env, name, capacity):
        BaseOperator.__init__(self, env, name)

        self.capacity = capacity

        #default parameter values
        self.delay = 1
        self.start_time = 0.5

        #A conveyor belt has at-least two stages
        assert (isinstance(capacity, int) and (capacity >= 2))

        # create input and output buffers
        # corresponding to the first and last stages
        self.input_buf = simpy.Store(env, capacity=1)
        self.output_buf = simpy.Store(env, capacity=1)

        # a list to model stages
        self.stages = [None for i in range(capacity)]

        #states
        self.define_states(["stalled", "moving"])

        # start behavior
        self.process = env.process(self.behavior())
 def __init__(self, env, name):
     BaseOperator.__init__(self,env,name)
     
     # list of tasks assigned 
     # to this operator
     self.task_list=[]
     
     # start behavior
     self.behavior=env.process(self.behavior())
Beispiel #7
0
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        self.delay = 0
        self.start_time = 0

        self.process = env.process(self.behavior())
Beispiel #8
0
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp
        self.delay = 1

        #states
        self.define_states(states=["idle", "loading"], start_state="idle")
        self.process = env.process(self.behavior())
Beispiel #9
0
    def __init__(self, env, name, inp, outp):

        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        #parameters, and default values
        self.delay = 10
        self.start_time = 0
        self.on_temp = 100

        #start behavior
        self.process = env.process(self.behavior())
Beispiel #10
0
    def __init__(self, env, name):
        BaseOperator.__init__(self, env, name)

        # list of tasks assigned
        # to this operator
        self.assigned_tasks_list = []

        # start behavior
        self.behavior = env.process(self.behavior())
        self.define_states(states=["idle", "busy"], start_state="idle")

        #queued-up tasks to be performed.
        self.pending_tasks_queue = []
Beispiel #11
0
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self,env,name)
        self.inp=inp
        self.outp=outp

        #default parameter values
        self.delay=0
        self.start_time=0

        self.define_states(["idle","busy","waiting_to_output"])

        #start behavior
        self.process=env.process(self.behavior())
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        #states
        self.define_states(["idle", "busy"])

        #default parameter values
        self.PCB_stack_size = 10
        self.start_time = 0

        self.process = env.process(self.behavior())
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        # parameters
        self.capacity = 1
        self.k = 0  # turn on the RFO as soon as capacity-k items have accumulated in the buffer.
        self.buffering_mode = "LIFO"  #can be "LIFO" or "FIFO"
        self.buffer = None

        # states
        self.define_states(states=["bypass", "filling", "emptying"],
                           start_state="bypass")
        self.process = env.process(self.behavior())

        # pointer to Reflow Oven for controlling it
        self.reflow_pointer = None

        # operational mode can be "BYPASS" or "BUFFERING_ENABLED"
        self.operational_mode = "BYPASS"
Beispiel #14
0
    def __init__(self, env, name, inp, outp):
        
        BaseOperator.__init__(self,env,name)

        self.inp=inp
        self.outp=outp

        #default parameter values
        self.num_stages=4
        self.delay=1
        self.start_time=0
        
        #create a list to model stages in the reflow oven
        self.stage=[None for i in range(self.num_stages)]
        
        #states
        self.define_states(["idle","busy"])


        #start behavior
        self.process=env.process(self.behavior())
Beispiel #15
0
    def __init__(self, env, name, inp, outp):
        BaseOperator.__init__(self, env, name)
        self.inp = inp
        self.outp = outp

        # parameters
        self.num_stages = 1
        self.delay_per_stage = 1

        # Operational Modes.
        self.operational_mode = "AUTONOMOUS"  #can be set to "EXTERNAL_CONTROL"

        # External control signal that is used
        # only when the operational_mode is EXTERNAL_CONTROL
        self.external_signal = "TURN_ON"  # can be "TURN_OFF".

        # states
        self.define_states(states=[
            "off", "setup", "temperature_maintain_unoccupied",
            "temperature_maintain_occupied"
        ],
                           start_state="off")

        # Parameters that determine the setup time
        #(time to raise the temperature of teh oven to a required value.)
        self.temp_max = 200.0  # Temp (degrees Celcius) in maintain state.
        self.temp_room = 30.0  # Temp (degrees Celcius) ambient.
        self.temp_current = 0.0  # variable that strores the current temperature.
        self.timestamp_turn_OFF = 0  # time instant at which the oven was last turned OFF.
        self.cooling_rate_constant = 0.5  # constant that determines cooling rate
        self.heating_rate_constant = 170.0  # constant that determines heating rate (degrees celcius per hour)
        self.setup_time = 0  #<== value is dynamically computed using the above parameters.

        # create a list to model stages
        self.stages = []

        # start behavior
        self.process = env.process(self.behavior())