Model 2461 Interactive SourceMeter® Instrument Reference Manual Section 8: TSP command reference2461-901-01 A/November 2015 8-291Examplereset()smu.digitize.func = smu.FUNC_DIGITIZE_VOLTAGEsmu.digitize.samplerate = 50000trigger.model.setblock(1, trigger.BLOCK_BUFFER_CLEAR, defbuffer1)trigger.model.setblock(2, trigger.BLOCK_DELAY_CONSTANT, 0)trigger.model.setblock(3, trigger.BLOCK_DIGITIZE, defbuffer1,trigger.COUNT_INFINITE)trigger.model.setblock(4, trigger.BLOCK_WAIT, trigger.EVENT_DISPLAY)trigger.model.setblock(5, trigger.BLOCK_DIGITIZE, defbuffer1,trigger.COUNT_STOP)trigger.model.setblock(6, trigger.BLOCK_NOTIFY, trigger.EVENT_NOTIFY1)trigger.model.initiate()waitcomplete()print(defbuffer1.n)Reset the instrument.Set the function to digitize voltage.Set block 1 to clear defbuffer1.Set block 2 to set a delay of 0.Set block 3 to make digitize measurements infinitely.Set block 4 to wait until the front-panel TRIGGER key is pressed.Set block 5 to stop making digitize measurements.Set block 6 to send a notification.Start the trigger model.Output the number of readings.Also seebuffer.make() (on page 8-14)Digitize block (on page 3-110)trigger.model.setblock() — trigger.BLOCK_LOG_EVENTThis function allows you to log an event in the event log when the trigger model is running.Type TSP-Link accessible Affected by Where saved Default valueFunction Yes Restore configurationInstrument resetPower cycleConfiguration script Not applicableUsagetrigger.model.setblock(blockNumber, trigger.BLOCK_LOG_EVENT, eventNumber, message)blockNumber The sequence of the block in the trigger modeleventNumber The event number:• trigger.LOG_INFON• trigger.LOG_WARNN• trigger.LOG_ERRORNWhere N is 1 to 4; you can define up to four of each typeYou can also set trigger.LOG_WARN_ABORT, which aborts the trigger modelimmediately and posts a warning event log messagemessage A string up to 31 characters