Ejemplo n.º 1
0
    #fig.canvas.restore_region(background)
    #fig.canvas.blit(ax.bbox)
    #time.sleep(delay)

    

    return True

# Print the usage
usage()

# Set Logging
log = logfile("foldbuf_monitor.py")

# Get all of the useful values
g = Status(log)
g.read()
nchan = g["OBSNCHAN"]
totnchan = g["TOTNCHAN"]
npoln = g["NPOL"]
BW = g["OBSBW"]
fctr = g["OBSFREQ"]
blocsize = g["BLOCSIZE"]
nbin = g["NBIN"]


# Access the data buffer which contain fold buffer, ie: 2
d = Databuf(2)

# argument is the current fold block in the data buffer
data = d.data(g["FBLOCK"])
Ejemplo n.º 2
0
                run = 0
            c = stdscr.getch()


# Default look at GPU 1 over 2
gpu_id = 1

try:
    gpu_id = int(sys.argv[1])
    print "Select GPU #%d" % gpu_id
except:
    gpu_id = 1

# Get log file
log = logfile("status_monitor.py")

# Connect to guppi status, data bufs
g = Status(log, gpu_id)
g.show()
try:
    d = Databuf()
except:
    print "Databuf does not exist. Please run nuppi_daq"
    sys.exit()

# Wrapper calls the main func
try:
    curses.wrapper(display_status, g, gpu_id)
except KeyboardInterrupt:
    print "Exiting..."