Setting Up the Development Environment

This section provides step-by-step instructions for setting up your development environment for MConn development. Please follow each section carefully.

Prerequisites

Before proceeding, ensure that your system meets the following requirements.

System Requirements

Component Requirement
Operating System Virtual machine capable of running Windows or a modern Linux distribution (e.g., Ubuntu 22.04)
Processor Dual-core
Memory 8 GB of RAM
Disk Space 20 GB of free disk space

Hardware Requirements

The following hardware components are required for development:

Component Purpose Link
MConn Display Main embedded platform for development Link
Programming Cable Used to power the MConn Display and for CAN communication, flashing, or programming the device
RJ45 Ethernet Cable Software/Application deployment and debugging Link
12V Power Supply (min 2A) Powering the MConn unit
AMPSEAL 776164 Connector (optional) Mating connector for Power, GPIOs, and CAN bus Link
AMPSEAL 776273 Connector (optional) Mating connector for Analog Cameras, Audio Out, and Mic In Link

Desktop Environment Setup for Cross-Compilation

You can either set up the environment yourself or use a pre-configured virtual machine provided by MRS Electronic.

Important
This document focuses on development on a Linux host. However, it can also be set up on a Windows host. For more details, contact MRS Electronic.
There are multiple virtualization techniques, but this document focuses on setting up an Ubuntu development environment using VirtualBox.

Download the latest version of VirtualBox according to your device’s architecture.

Pre-Configured Machine

If you are using a pre-configured virtual machine from MRS, simply install it and proceed to the Setting Up MConn section. The virtual machine is already set up for development and cross-compiling.

Additionally, in the VM at ~/QT_SETUP/ you will find Qt 5.12.9 for desktop development. You can install this on your host machine as well. This allows you to view the UI on your host machine and, when satisfied, flash it to the MConn display.

Manual Configuration

If you are working with native Linux, you need to configure your machine manually. Proceed with the installation steps below:

Required Permissions

Note: You require admin (sudo) privileges to perform the installation steps.

Installing Dependencies Using Provided Script

To simplify the installation of required packages, you can use the provided install_dependencies script. Download it from here (relative to the project root) and run the following commands in your terminal (from the project root directory):

$ chmod +x install_dependencies
$ sudo ./install_dependencies

This script will automatically install all necessary dependencies for development.

Software Requirements

Software Type Ubuntu 22.04
Build Essential Tools build-essential
Qt 5.12.9 Dependencies libxcb1 libxcb1-dev libxcb-keysyms1-dev libxcb-image0 libxcb-image0-dev
Development Libraries libgl1-mesa-dev libglu1-mesa-dev libxrender-dev libfontconfig1-dev
Other Useful Tools pkg-config git cmake

Installation Steps

  1. Install the latest version of Ubuntu.
  2. Follow this tutorial to configure your machine.
  3. Setup Qt development environment by downloading the latest version of Qt. At the time of writing this document, the MRS Display has Qt 5.12.9 installed. Navigate to this link to find the steps to install Qt5 in Ubuntu.
Important
Depending on your deployment strategy, you can either purchase Qt Commercial or begin development using the Open-source version of Qt, which is free. Consult your legal team regarding the suitable version for your application.
  1. Run the installer to begin the installation process.
Information
To obtain the steps to set up a cross-compile toolchain for Qt to allow deployment of applications to the Display, contact MRS Electronic.

Troubleshooting & Tips

  • If you encounter permission errors, ensure you are running commands with sudo where required.
  • If a package is missing, check your .pro file. Remove the dependency if the package is not needed. If the package is important and missing, please contact MRS Electronic for assistance.
  • For Windows users, contact MRS Electronic for specific setup instructions.

Setup Checklist

  • [ ] System meets hardware and software requirements
  • [ ] Required hardware is available and connected
  • [ ] Virtual machine or native Linux is ready
  • [ ] All dependencies installed (via script or manually)
  • [ ] Qt development environment installed
  • [ ] Able to build and deploy a sample application

If you have completed all the above steps, your development environment is ready!