Script

Micro-Manager Z stack acquisition

Publication ID: ICY-T6D4J7

Short Description

This java script show how to perform a small Z-Stack acquisition trough Micro-Manager. WARNING: You need to start Micro-Manager for Icy plugin before executing the script.

Versions

  • Version 1 • Released on: 2017-08-16 15:48:14
    Download
    Description:

    initial version

    importClass(Packages.icy.sequence.Sequence)
    importClass(Packages.plugins.tprovoost.Microscopy.MicroManager.MicroManager)
    importClass(Packages.plugins.tprovoost.Microscopy.MicroManager.tools.StageMover)
    
    z = 0
     // create the result sequence
    sequence = new Sequence()
    
     // move to position (5, 5, 5)
     StageMover.moveXYAbsolute(5, 5)
    StageMover.moveZAbsolute(5)
    
     // acquire 1 image
     image = MicroManager.snapImage()
     // set it in resulting sequence at position 0
     sequence.setImage(0, z++, image)
     // shift microscope Z position by 10
     StageMover.moveZRelative(10)
    
     // acquire 1 image
     image = MicroManager.snapImage()
     // set it in resulting sequence at position 0
     sequence.setImage(0, z++, image)
     // shift microscope Z position by 10
     StageMover.moveZRelative(10)
    
      // acquire last image
     image = MicroManager.snapImage()
     // set it in resulting sequence at position 0
     sequence.setImage(0, z, image)
    
     // show the sequence in Icy
    gui.addSequence(sequence)

Leave a Review