Example – basic media player

Another basic example of an SBC-based embedded system is a media player. This can involve both audio and audio-visual (AV) media formats. The difference between an SBC-based system being used to play back media with regular keyboard and mouse input, and an embedded SBC-based media player, is that in the latter's case the system can only ever be used for that purpose, with the software and user interface (physical- and software-wise) both optimized for media player use.

To this end, a software-based frontend has to be developed, along with a physical interface peripheral, using which the media player can be controlled. This could be something as simple as a series of switches connected to the GPIO pins, with a regular HDMI display for output. Alternatively, one could use a touch screen, although this would require a more complex driver setup.

Since our media player system stores media files locally, we want to use an SBC that supports external storage beyond the SD card. Some SBCs come with a SATA connection, allowing us to connect a hard disk drive (HDD) of capacities far exceeding those of SD cards. Even if we stick to compact 2.5" HDDs, which are roughly the same size as many popular SBCs, we can easily and fairly cheaply get multiple terabytes worth of storage.

Beyond the storage requirement, we also need to have a digital video output, and we want to either use the GPIO or the USB side for the user interface buttons.

A very suitable board for this purpose is the LeMaker Banana Pro, which comes with the H3 ARM SoC, hardware SATA, and Gigabit Ethernet support, as well as a full-sized HDMI output with 4k video decoding support:

After going through the basics of installing Armbian or similar OSes on the SBC, we can set up a media player application on the system, having it start together with the OS and configuring it to both load a playlist and to listen to events on a number of GPIO pins. These GPIO pins would be connected to a number of control switches, allowing us to scroll through the playlist and start, pause, and stop playlist items.

Other interaction methods are possible, such as an infrared or radio-based remote control, each of which come with their own advantages and disadvantages.

We will be working through the creation of this media player system and turning it into an infotainment system in the following chapters:

  • Chapter 6, Testing OS-Based Applications
  • Chapter 8, Example - Linux-Based Infotainment System
  • Chapter 11, Developing Embedded Systems with Qt

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.221.53.209