VQ8-CXP6D applet does not output 12 bits as it should

  • I have a very simple applet for a 1280x1024@12bits camera.
    It compiles correctly, I can flash a board with it.

    But when I try to use it with RT MicroDisplay or my own software, the FG_FORMAT of the "Output" Operator always appears as a grayed, disabled FG_GRAY instead of FG_GRAY12.

    Thus, my software interprets it as a 8b image instead of unpacking it from 12b, and the result is wrong.


    Is there any reason for that ?CXP-Mono12-1280x1024-synchro+trigger.va

  • Some more information:
    If I set the camera operator to Mono10 and adapt the design to 10b, the Output operator FG_FORMAT appears, as expected, as FG_GRAY10.

    If I set the camera operator to Mono12, cast bit width to 10b at the end, the Output operator FG_FORMAT appears, as expected, as FG_GRAY10.

    If I set the camera operator to Mono10 and cast bit width to 12b for the rest of the design, the Output reverts to this incorrect FG_GRAY instead of expected FG_GRAY12

    (Visual applets 3.1.2 build 77127)

    [edit]

    The standard Acq_SingleCXP6x4AreaGray *does* allow FG_GRAY12, but I really need a specific design.

  • Dear Pierre,


    I hope I understand or interpret your question correctly:

    The DMA transfer (DmaToPC's FG_FORMAT) mentions the wrong bitdepth?

    • 8 bit instead of 12?
    • Can you please check if the camera is sending 8/10/12 bit as expected?

    In case the camera sends 8 bit and the design expects 12, the representation of the data would look wrong for 12 bit visualization.

  • The camera is definitely sending Mono12, and as you can see the design propagates the 12b up to the DmaToPC output.

    But inside MicroDisplay (or my software using SiSo SDK), the output format is automatically set to FG_GRAY and FG_GRAY12 is not even an option !

    See screenshots.


    microdiagnostics.PNG


    microdisplay-8.PNG


    microdisplay-force-rw.PNG


    microdisplay-no12.PNG

  • Hello Pierre,


    VisualApplets can only set FG_FORMAT to FG_GRAY, FG_GRAY16, FG_COL24 and FG_COL48. So when you set a link bit width of 12 bit, VisualApplets will ignore it and set the default 8 bit instead.


    FG_FORMAT is used for displaying in microDisplay. You can use the workaround to force microDisplay using 12 bit. For your software SDK integration FG_FORMAT can be ignored if you wish to.


    Johannes


    Johannes Trein
    Group Leader R&D
    frame grabber

    Basler AG



  • Hello,

    I don't really understand.


    Aa standard applet allow FG_GRAY, FG_GRAY10, FG_GRAY12, FG_GRAY16 at least, and 12b uis not a problem with them.

    But you claim that a custom visual applet will only support FG_GRAY, FG_GRAY16, FG_COL24 and FG_COL48


    First, this is surprising, since anyway, the byte stream is valid : if I emit a 12b stream, I get a 12b stream, whatever the FG_FORMAT value. Why would it be limited in that case ? This is just a incorrect information returned by the applet.


    Second, it works with FG_GRAY10 : if I set a 10b stream, FG_FORMAT is set to FG_GRAY10 and my client software is informed that it must be interpreted as 10b. Why would 10b be different from 12b ?

  • Hi

    ... if I emit a 12b stream, I get a 12b stream, whatever the FG_FORMAT value. Why would it be limited in that case ? This is just a incorrect information returned by the applet.

    Yes it works but the setting of FG_FORMAT is simply not defined in VisualApplets.


    it works with FG_GRAY10 : if I set a 10b stream, FG_FORMAT is set to FG_GRAY10 and my client software is informed that it must be interpreted as 10b. Why would 10b be different from 12b ?

    You are right, there is no difference. 12 bit is simply not defined as it was not supported in older versions at all and not added to VisualApplets once it was extended. We have a feature request in our database for this.


    Johannes


    Johannes Trein
    Group Leader R&D
    frame grabber

    Basler AG