Previous Next        Current Page: NeXtMidas Training / X-Midas Interoperability / NeXtOpt / Using NeXtOpt
back
+ Start Here   
+ Background   
+ Common Midas Concepts   
+ Getting Started - Part 1   
+ Getting Started - Part 2   
+ Working with Files   
+ Option Trees   
+ Macros - Part 1 (Basics)   
+ Macros - Part 2 (Graphics)   
+ NetBeans - Part 1 (Setup)   
+ NetBeans - Part 2 (GUIs)   
+ NetBeans - Part 3 (Profiler)   
+ Eclipse - Part 1 (Setup)   
+ Eclipse - Part 2 (GUIs)   
+ Primitives   
+ WebStart   
+ Maps & Imagery   
- X-Midas Interoperability   
   + Overview   
   + XBC   
   + Lab 1   
   - NeXtOpt   
      - NeXtOpt Setup   
      - Using NeXtOpt   
      - Shared Functions   
      - Messages   
         - Configured Messages   
         - Unconfigured Messages   
         - Translated Messages   
+ RMIF & Remoting   
+ Installing NeXtMidas   
+ Support & Maintenance   
+ File Handlers   


  • Using NeXtOpt:
    • NeXtOpt runs all NeXtMidas commands in a shared JVM.
      Starting the shared JVM:
      X-Midas> nm/on/bg/id=999
      Running a NeXtMidas command in the shared JVM:
      X-Midas> nm <nextmidas command>
      X-Midas> nm plot nxm.sys.dat.world.shp
      Stopping the shared JVM:
      X-Midas> nm/off
    • Use inside a macro:
      startmacro
        nm/on/bg/id=999  ! Start the JVM, permitting messages with /ID switch
        xpipe/setup on
          waveform _mypipe sf 1e9
          nm plot xmpipe:_mypipe
        xpipe off
        nm/off    ! Stop the JVM
      endmacro
      
    Don't Make This Mistake:
    Caution sign To send/receive messages from NeXtMidas to X-Midas and vice versa, start the JVM with /ID=[n] switch. The value of the ID is not important, 999 is a good unique one. The X-Midas message queue should be installed before the JVM (e.g. X-Midas> message up).

    Then, the NeXtMidas macro/primitive to receive the X-Midas message must have been started from an X-Midas macro with "NM <command>/ID=<id>".

back