Skip to content

Configuring the PLM using plmctrl

José Carlos edited this page May 21, 2025 · 3 revisions

This wiki entry describes how to set up the PLM using plmctrl only.

Before using the PLM, one has to open TI's LightCrafter GUI to set up a few things as described here. We can do the same using functions using plmctrl's API.

Example using the Python wrapper:

We have to run those commands in the following order:

First, we open USB communication with the PLM. If LightCrafter is open, this command will fail.

plm.open();

Set the source to be Parallel RGB with 24 bit width:

source = 0 # Pararell RGB
port_width = 1 # 24 bits
plm.set_source(source, port_width)

Set the port swap to be ABC -> ABC. This will ensure that the PLM will read holograms from the bitpacked RGB frame in RGB-little endian fashion: R0, R1, ... R7, G0, ..., G7, B0, ... B7.

plm.set_port_swap(0, 0)
plm.set_port_swap(1, 0) # This one is only necessary if using DisplayPort

Set the pixel mode to be single pixel (HDMI) or dual pixel (DisplayPort):

# Set Pixel Mode. 1 for HDMI (Single Pixel), 2 for DisplayPort (Dual Pixel)
connection_type = 1 # 1 = HDMI, 2 = DisplayPort
plm.set_pixel_mode(connection_type)

Set the IT6535 Receiver power mode. If using DisplayPort, after this command is executed, the virtual monitor will show up. If using HDMI, the virtual monitor is already there. Also after this command, the PLM will be locked to the source (video stream) and we will be able to change the operation mode to Video Pattern mode in the next step.

connection_type = 1 # 1 = HDMI, 2 = DisplayPort
plm.set_connection_type(connection_type) # Wait 3 seconds before calling other commands.

Set the operating mode to be Video Pattern mode:

# Set video pattern mode (This is the mode we use for reading from the video stream)
plm.set_video_pattern_mode()

Set the bit lookup-table. This LUT is hardcoded here. Most likely you'll never need to change this, but if you need, you can use LightCrafter GUI. With this LUT, together with the Port Swap ABC to ABC, the PLM will read from the video screen following RGB-little endian fashion. With this function call you can also set if you want the PLM to be continuously reading from the screen (play_mode = 1) after a plm.play() command is issued, or read it only once (1 full frame -- 24 holograms).

play_mode = 1 # 0 = PlayOnce, 1 = Continuous (Repeat mode)
connection_type = 1 # 1 = HDMI, 2 = DisplayPort
# Update LUT with play mode and connection type
plm.update_lut(play_mode, connection_type)

Now, after issuing plm.play() or plm.stop() (or using the corresponding buttons from the UI), the PLM will read the holograms from the screen.

Those settings are not persistent, so if you reboot the PLM, you'll need to set it again.

Clone this wiki locally