Using Densitron UReady 1U and UReady 2U Displays for with Raw Panel

The SKAARHOJ xpanel-touch package allows users to create browser-accessible software UIs, appearing on the local network as Raw Panel devices.

Densitron presents compelling touch screen options for use with xpanel-touch. Their rack-mountable designs are notable. Additionally, certain screens come equipped with an internal computer, enabling direct web browser operation on the screen without requiring an external driving computer.

Our Product Rance.png

Options include:

This guide will assist in quickly setting up such configurations.

UReady 2U (with built-in x86) setup 

The UReady 2U displays, and likely the 4U versions as well, are available with HDMI like a regular monitor or with a built-in computer. This setup guide focuses on the latter.Lubunto.jpg

Initial Setup:

  1. Out-of-the-Box Functionality:

    • The units come pre-installed with the Lubuntu distribution, which should work immediately upon setup. This simplifies the process, requiring only the setup of an autostart sequence to open the browser in full-screen mode.
  2. Preparing for Setup:

    • Since our unit did not have an SSH server installed, you will need a keyboard and, preferably, a mouse.
    • The default username and password are "densitron/densitron."
  3. Physical Setup:

    • Connect your keyboard and mouse to the unit.
    • Power on the unit.
  4. Access Terminal:

    • After the device boots, locate the terminal icon on the taskbar and open it.
  5. Create Autostart Entry:

    • To create a new autostart entry, type the following command in the terminal:

sudo nano /etc/xdg/autostart/display.desktop

If prompted, enter the password. This action will open an empty file for editing.
Lubuntu comes with the Firefox Browser pre-installed, which you'll use for this setup.

You will need to edit the content of the file to suit your needs. The content should resemble the following template, but you'll need to replace it with the IP address and port of your xpanel-touch server:

[Desktop Entry]
Name=Firefox
Exec=firefox  --kiosk http://192.168.11.5:7952

Save the changes and exit. That's all there is to it! When the panel restarts, Firefox will open in full-screen mode at the address specified in the configuration. If you need to change the IP address later, simply edit the file again.

sudo nano /etc/xdg/autostart/display.desktop

To prevent the browser from automatically starting up, you can follow these steps:

sudo rm /etc/xdg/autostart/display.desktop

Variant with embedded version of xpanel-touch

It's possible to run the xpanel-touch application directly on the Densitron panels with built-in computer. This entails:

Running the binary:

There are likely several methods to transfer the xpanel-touch binary from SKAARHOJ to your Densitron panel. One effective approach is using a USB stick via the USB port. We recommend copying the binary into the home directory of the densitron user, setting execute permissions, and running it from there. Below are examples with the copy command and changing permissions:

IMG_8761.JPG

After running it for the first time, two things will happen: 

IMG_8762.JPG

Configuration

You can use nano to edit the config file:

nano xpanel-touch.toml

This will lead you to an editor where you should modify at least the Ratio and Layout settings, for example to these values:

Ratio = "UReady 2U" Layout = "Stream Deck Adapt"

The layout can be other options known from the configuration of xpanel-touch.

WSPort set to 7950 would be standard and Port for raw panel is usually set to 9953

IMG_8766.JPG

Setting up Auto start:

It can be started by systemd creating a config file, rawpanel.service, in /etc/systemd/system/ with the following contents:

[Unit]
Description=Raw Panel Server

[Service]
ExecStart=/home/densitron/xpanel-touch.Linux-386
Restart=always
User=densitron
Group=densitron
WorkingDirectory=/home/densitron

[Install]
WantedBy=multi-user.target

After creating this file, you must reload systemd and set it to auto start on every boot:

sudo systemctl daemon-reload

sudo systemctl enable rawpanel.service

Restart if needed with this:

sudo systemctl restart rawpanel.service

Check status like this:

sudo systemctl status rawpanel.service

Changing the URL for Firefox

Finally, change the URL for Firefox to localhost on port 7950 by editing the file "/etc/xdg/autostart/display.desktop" as per above:

IMG_8768.JPG

Test

Reboot the panel. Upon booting, you should see the touch UI displayed, similar to the image below (note that in the image, a Raw Panel client is connected, populating the buttons with content).

IMG_8776.JPG

To test the connection, you can use a telnet client. For Mac users, you can use the command 'nc [IP address of panel] 9953' in the terminal. After connecting, type 'list', and you should see an output resembling this:

image.pngNote: During our tests, we observed that the Raw Panel server operating on the Densitron panel did not announce itself on the network via mDNS. The reason for this is unclear, but it may be addressed in future updates.

UReady 1U + Raspberry Pi 4/5 setup (Easy Setup, Recommended)

This guide will help you to set up an off-the-shelf Raspberry Pi 4 or 5 to drive the UReady 1U screen via USB

Prerequisites
Flashing

image.png

image.png

image.png

image.png

image.png

image.png

image.png

image.png

Preparing the Operating System to run the Densitron screen over USB

You should see it boot up on the HDMI monitor. It will automatically reboot a few times before it finally settles with a standard desktop. It's important to stay alert because on the final desktop you will see the DHCP provided IP address shown in the upper right corner. You need that in the next step.

Untitled-1.jpg

Untitled-2.jpg

image.png

curl -O https://raw.githubusercontent.com/SKAARHOJ/Support/master/Files/Densitron/patch.tar.gz
sudo tar -xzf ./patch.tar.gz
sudo chmod 777 ./install_all.sh
sudo sh ./install_all.sh

These steps will look like this:

image.png

image.png

As the Raspberry Pi reboots, you should experience that the Densitron screen is used as a monitor and that a web browser opens that tries to load page from the IP address and port you specified.

Changing the browser target URL

If you need to change the IP address and port entered during the setup, then follow these steps:

sudo nano /etc/xdg/autostart/display.desktop
[Desktop Entry]
Name=Chrome
Exec=chromium-browser --app=http://192.168.11.5:7952 --kiosk --app-shell-hosted

Variant with embedded version of xpanel-touch

The instructions below are mostly a repetition of the ones given for a Densitron screen with x86 inside above. You will need to request the ARM version of the binary from SKAARHOJ and there are some variations to the config files.

It's possible to run the xpanel-touch application directly on the Raspberry Pi driving your UReady 1U. This entails:

Running the binary:

There are likely several methods to transfer the xpanel-touch binary from SKAARHOJ to your Raspberry Pi. Since you have already used the terminal and SSH for setup, using SCP may be the easier one:

scp xpanel-touch scp://admin@192.168.1.240

IP address should be that of your Raspberry Pi.

After transfer:

After running it for the first time, two things will happen: 

Configuration

You can use nano to edit the config file:

nano xpanel-touch.toml

This will lead you to an editor where you should remove everything existing and substitute with this:

[[TouchApplications]]
  Active = true
  Name = "UReady #1"
  Description = ""
  Port = 9923
  ProtocolMode = ""
  MaxClients = 0
  LockToIPs = ""
  WSPort = 7950
  Layout = "Stream Deck Custom (RxC)"
  Ratio = "UReady 1U"
  ConfigFile = "RxC=1x7"
  Cursor = "Hidden"

The layout can be other options known from the configuration of xpanel-touch.

WSPort set to 7950 would be standard and Port for raw panel is usually set to 9923

Setting up Auto start:

It can be started by systemd creating a config file, rawpanel.service, in /etc/systemd/system/ with the following contents:

sudo nano /etc/systemd/system/rawpanel.service

[Unit]
Description=Raw Panel Server

[Service]
ExecStart=/home/admin/xpanel-touch.arm64
Restart=always
User=admin
Group=admin
WorkingDirectory=/home/admin

[Install]
WantedBy=multi-user.target

The above config assumes you named your user "admin" and keep the binary in the home directory.

After creating this file, you must reload systemd and set it to auto start on every boot:

sudo systemctl daemon-reload

sudo systemctl enable rawpanel.service

Restart if needed with this:

sudo systemctl restart rawpanel.service

Check status like this:

sudo systemctl status rawpanel.service

Follow log messages from the service like this:

journalctl -u rawpanel.service -f

Changing the URL for the browser

sudo nano /etc/xdg/autostart/display.desktop
[Desktop Entry]
Name=Chrome
Exec=chromium-browser --app=http://localhost:7950 --kiosk --app-shell-hosted

(--app-shell-hosted will avoid certain browser pop-ups you don't like in kiosk full screen mode)

Test

Reboot the panel. Upon booting, you should see the touch UI displayed.

To test the connection, you can use a telnet client. For Mac users, you can use the command 'nc [IP address of panel] 9923' in the terminal. After connecting, type 'list', and you should see an output resembling this:

[LEGACY] UReady 1U + Raspberry Pi 4/5 setup (Alternative Instructions)

The instructions in this section include additional details and reference an older version of Raspbian. They are provided for historical context and may offer useful insights.

image.png

Prerequisites

Extra Power for Densitron Screen

The Densitron UReady 1U screen requires additional 5V power. There are two recommended methods to provide this power:

  1. Using a MicroUSB Cable

    • Connect an additional microUSB cable from one of the two "USB Out" ports on the screen to another USB port on the Raspberry Pi or to an external power supply. This is probably the easiest.
  2. Using a 5V Power Plug:

    • Alternatively, you can use the 5V Power Plug, which is compatible with a Molex 43025-0200 and 43030 series crimp terminals.

Pasted Graphic 35.png

Operating System

*Apparently newer Raspberry Pi 4 revisions as well as new 5th generation are not supported by suggested version of Raspbian OS. Therefore some extra steps are needed to achieve the same with latest release Raspbian Bookworm 2023-12-05. Please download exactly this release as it is not guaranteed that proposed patch will work on others. Follow instructions from Easy Setup Method ( Raspbian Bookworm 2023-12-05)

Setting Up Your Touch Panel:

  1. Initial Setup:

    • Insert the pre-flashed SD card into the Raspberry Pi (RPI).
    • Connect a HDMI-compatible monitor and the USB keyboard and mouse.
    • Connect the Densitron screen to the RPI using a USB-A to microUSB cable (into either USB 2.0 or USB 3.0 port). Note: The Densitron screen won't display anything at this stage.
    • Power on the RPI.
  2. Complete Raspbian OS Installation:

    • Follow the onscreen instructions to complete the installation. This includes setting up the user, time zone, WiFi network, etc.
  3. Enable Remote Access:

    • To facilitate future adjustments without needing a keyboard and mouse, enable SSH and VNC servers on the RPI.
    • Click the raspberry icon in the upper left corner of the screen.
    • Navigate to Preferences -> Raspberry Pi Configuration.
    • In the 'Interfaces' tab, enable SSH and/or VNC.
    • Click 'OK' and reboot the RPI.

After rebooting, you should be able to remotely access the RPI via SSH or VNC.

image.png

Post-Setup Process

Now, our next steps are to activate the Densitron screen and configure the browser to automatically open at the required URL address. To simplify this process, we have created a small shell script that will automatically make the necessary modifications for you.

Easy Setup Method (Raspbian OS (Buster) version dated 2020-08-24)

  1. Open the Terminal application on your Raspberry Pi.
  2. Run the following command to download the script. (If your Raspberry Pi doesn't have internet access, download the file on another machine with internet access and transfer it to your Raspberry Pi using a USB flash drive. Then, continue from step 3.)
curl -O https://raw.githubusercontent.com/SKAARHOJ/Support/master/Files/Densitron/DensitronSetup1U.sh

     3. Next we need to give permissions to execute the file we have just downloaded. Execute following command:

sudo chmod 777 ./DensitronSetup1U.sh

      4. Now we are ready to execute the script. Execute following command:

sudo sh ./DensitronSetup1U.sh

When prompted, enter the IP address and port of your xpanel-touch web server (the Blue Pill device where it's installed) and then press ENTER.

image.png

       5. That is it, you can now power down your RPI, disconnect keyboard,mouse and HDMI screen. Next time you power it on the browser should open in full screen mode on the Densitron screen.

Easy Setup Method ( Raspbian Bookworm 2023-12-05)

Assuming you have installed that version of OS and configured everything you need. We have to proceed with patching the kernel procedure. To save time we provide a simple script to setup up what is needed.

  1. Open the Terminal application on your Raspberry Pi.
  2. Run the following command to download the script. (If your Raspberry Pi doesn't have internet access, download the file on another machine with internet access and transfer it to your Raspberry Pi using a USB flash drive. Then, continue from step 3.)
curl -O https://raw.githubusercontent.com/SKAARHOJ/Support/master/Files/Densitron/patch.tar.gz

     3. Next we need to extract to execute the file we have just downloaded. Execute following command:

sudo tar -xzf ./patch.tar.gz

You might need to provide permission to execute the script.

sudo chmod 777 ./install_all.sh

      4. Now we are ready to execute the script. Execute following command:

sudo sh ./install_all.sh

When prompted, enter the IP address and port of your xpanel-touch web server (the Blue Pill device where it's installed) and then press ENTER. You will also so be asked if you want to reboot now or later. Choose later.

   5. That is it, you can now power down your RPI, disconnect keyboard,mouse and HDMI screen. Next time you power it on the browser should open in full screen mode on the Densitron screen.

Advanced Setup Method

For advanced users interested in creating a custom setup, such as combining two Densitron screens or pairing a Densitron screen with an HDMI screen, detailed guidance is beyond the scope of this introductory tutorial. However, we will provide some basic hints to get you started:

@xset s off
@xset -dpms

If you don't apply the recommended modifications, you may encounter USB dropouts, where the device disconnects and then reconnects during screen saver activation or wake-up. This issue can result in a 'green' and unresponsive screen. The Light Display Manager doesn't automatically detect this problem. Therefore, you'll need to either manually restart the Light Display Manager or create a udev rule to restart the service automatically when this condition occurs.

***

If you are to do this on newer than Raspbian OS (Buster) version dated 2020-08-24 release without using our script, below are a few things you must know:


Revision #27
Created 9 November 2023 13:57:04 by Arturas
Updated 6 May 2024 19:53:44 by Kasper