How to get a VA Design up and running in a Python environment

  • Hi,
    I'm trying to use this script for getting images from a Coaxpress Camera connected to an imaworx CXP-12 Framegrabber.
    (I did modify the image resolution accordingly and set the camera simulator to false. I also loaded an acquisition applet that works in microDisplayX).
    However, I only get displayed Black images. What am I missing to get images from the real camera?


    I already added the following lines to check for cameras:

    Code
    sgc_init_flag = 0
    (err, sgc_handle) = s.Sgc_initBoard(fg,sgc_init_flag)
    cameracount = s.Sgc_getCameraCount(sgc_handle)
    print("camera count:", cameracount)
    (err, camhandle) = s.Sgc_getCamera(sgc_handle, 0)
    print("camera handle:", camhandle)



    this results however in (0) resp. (None)

  • I was on the right track - just a few more commands to make it work (right before the FgApcControl:


    Code
    sgc_init_flag = 0
    (err, sgc_handle) = s.Sgc_initBoard(fg,sgc_init_flag)
    portMask = s.PORTMASK0
    discoveryTimeoutms = 5000
    speed=s.LINK_SPEED_NONE
    (sgc_ports)= s.Sgc_scanPorts(sgc_handle, portMask, discoveryTimeoutms, speed)
    cameracount = s.Sgc_getCameraCount(sgc_handle)
    (err, camhandle) = s.Sgc_getCamera(sgc_handle, 0)
    err = s.Sgc_connectCamera(camhandle)
    err = s.Sgc_startAcquisition(camhandle, 1)