The CoKOA(Correction of Keystone and Optical Aberrations) is a powerful feature of RDC which compensates a perspective distortion such as keystone and optical distortion,  pincushion, chromatic aberration and so on.

This post describes two ways of using CoKOA in Vista Studio™ GUI tool and in linux console application of Vista Cube™ SDK. If you do not use both, you should make use of API code in Vista Cube™ (Refer to VistaCube_User_Guid_RDC200.pdf for details).

Our demo aims to transform a square-shaped screen to a trapezoid-shaped one like below.

Vista Studio™ Case :

  • Open Vista Studio™ and then click a CoKOA Feature tap.
  • Type Keystone parameters as the above image.
    • Left Top X : 150
    • Right Top X : 150
  • (Optional) You can view the simulated image by clicking a Simulate button.
  • (Optional) You can also save the image by clicking a Save button and the LUT values that is used for its transformation
  • Click a Burn button.  It causes CoKOA LUT values to be calculated and then to be downloaded into flash memory in RDC.
  • After a download finish, click a Show button to see the result.
  • (Optional) Instead of clicking a Burn button, you can use a Direct Show button. (It makes the almost same result with the very fast speed)
  • If you want to keep this CoKOA turn-on even after reboot,  you should set cokoa_en_boot bit to “1”.

 <- e.g in RDC200 init file.

  • In your RDC init file, modify the 0x75 address to be 0x80 (that is cokoa_en_boot = 1 ).
  • If you do not use Chromatic aberration function means the same R/G/B of them,  set a cokoa_en_ca(0x74 0x80 1 0) bit to be “0”(There will be operation reduction).
  • Download it into flash of RDC.
    • Click a Download button on main menu of Vista Studio™.

    • In a Download dialog, select the modified init file only.

    • Click a Start button.

  • Reboot and then check the result.

Vista Cube™ Case :

  • Execute linux console application of Vista Cube™.
    • This console application is provided in source level, so you should build it with your i2c interface according to your target system (Refer to this blog).
    • As run it, you will see a lot of prompt messages.
  • Type l in order to create CoKOA LUT. 
  • Type 1 ( If you just only make a CoKOA LUT file, type 2).
  • Follow the prompt messages to insert CoKOA parameters.
    • Type 1920 1080
    • Type 150 0
    • Type 150 0
    • Type 0 0
    • Type 0 0
    • Type 0 0 0
    • Type 0 0 0
    • Type 1.0
  • If the entered-parameters like the above image is correct,  type y. CoKOA LUT will be automatically calculated and then be downloaded it into flash of RDC.
    • Note : Even if you finish download without error, CoKOA won’t enable.
  • To activate the CoKOA LUT you just download, you should use a cokoa_en_boot bit like Vista Studio™ case.
    • Edit your RDC200 init file so that the 0x75 address has 0x80. (0x75 0x80 1 0)
    • The cokoa_en_ca(0x74 0x80 1 0) bit is the same as Vista Studio™ case.
    • Download the init file by using RDC init on the prompts of linux console application.
    • Reboot and check the result.
  • (Optional) You can use Direct CoKOA you saw in Vista Studio™ case.
    • Type o
    • Type 0
    • Follower the next prompt messages to write CoKOA parameters
      • NOTE : This time, only Keystone function for Direct CoKOA is supported in linux console application of VistaCube™.
    • Lastly, after checking the values you entered, type y.  You can see the results immediately.

 

 

CoKOA paramters:
  • ks_lt_x: X position at left-top corner for keystone effect,  represented by 2’s complement and its range is -256 ~ 255
  • ks_lt_y: Y position at left-top corner for keystone effect, represented by 2’s complement and its range is -64 ~ 63
  • ks_rt_x: X position at right-top corner for keystone effect, represented by 2’s complement and its range is -256 ~ 255
  • ks_rt_y: Y position at right-top corner for keystone effect, represented by 2’s complement and its range is -64 ~ 63
  • ks_lb_x: X position at left-bottom corner for keystone effect, represented by 2’s complement and its range is -256 ~ 255
  • ks_lb_y : Y position at left-bottom corner for keystone effect, represented by 2’s complement and its range is -64 ~ 63
  • ks_rb_x: X position at right-bottom corner for keystone effect, represented by 2’s complement and its range is -256 ~ 255
  • ks_rb_y: Y position at right-bottom corner for keystone effect, represented by 2’s complement and its range is -64 ~ 63
  • k1: 1st radial distortion coefficient, represented by multiplying 1000 and its range is ~0.5 ~ 0.5
  • k2 : 2nd radial distortion coefficient, represented by multiplying 1000 and its range is ~0.5 ~ 0.5
  • k3 : 3rd radial distortion coefficient, represented by multiplying 1000 and its range is ~0.5 ~ 0.5
  • chrm_r :  Ratio for red chromatic distortion, represented by unsigned integer and its range is 0 ~ 100
  • chrm_b: Ratio for green chromatic distortion, represented by unsigned integer and its range is 0 ~ 100
  • chrm_g: Ratio for blue chromatic distortion, represented by unsigned integer and its range is 0 ~ 100
  • interp : Interpolation ratio, represented by multiplying 1000 and its range is 0.5 ~ 1.5
  • cokoa_en_ca{RDC200 Register Address 0x74<7>} : chrm_r applies equally to chrm_b and chrm_g.  It is useful when fast CoKOA
    • 0 : diable, 1: enable
  • cokoa_en_boot{RDC200 Register Address 0x75<7>} : a system flag bit which determines whether or not CoKOA will active when booting.
    • 0 : diable, 1: enable

 

 

Related Posts

Vista Cube

[VistaStudio/VistaCube] Description of Config file.

This post describes what is Config file and what is included in it. Definition : Config file named “fw_rdc200.cfg” is a set of parameters/flags that are used in firmware of RDC200. If this config file Read more…

Vista Cube

[VistaCube] Quick Stand-Alone Porting Guide.

This post describes how to port the Vista Cube™ for RDCx00/RDP Flash Image download feature in stand-alone application, such as a firmware for MCU. We assume that our stand-alone porting environment is on Win10 x64  Read more…

Vista Cube

[VistaCube] Quick Android/Linux Porting Guide.

This post describes how to port Vista Cube™ for RDC200/RDP550F initialization using 1)Linux console application or 2) Android Java Application. We assume that our porting environment is on Android Linux and our target products are Read more…