accessory:display:odroid-show:examples

ODROID-SHOW examples

Download ODROID-SHOW source code first.
Then connect microUSB cable to the Host PC with ODROID-SHOW.
Finally check the serial port number and run bash shell script file.

The DTR reset jumper should not be connected to ODROID-SHOW Except in case of writing a firmware.

show2_boarddetail.jpg

Tutorials

This guide is tested on Ubuntu 16.04(ARM and x86)

both
$ sudo apt-get install git
$ git clone https://github.com/hardkernel/ODROID-SHOW

This tutorial is compatible firmware version 2.0 so if it isn't 2.0, update your firmware on ODROID-SHOW

...
int serialSetup(void)
{
        ...
}
 
void writeData(int fd, char *str)
{
        ...
}
 
int main(int argc, char **argv)
{
        ...
 
        writeData(usbdev, "Hello ODROID-SHOW");
 
        return 0;
}

The DTR reset jumper should not be connected to ODROID-SHOW when the examples run

This linux c source code show the ODROID’s stats and clock.

Check your serial port.

both
$ ls /dev/ttyUSB*

To run this program, you need to compile.

both
$ gcc -o status status.c
$ sudo ./status

This bash script can display 2 text strings with different color and different font size.
Open the “/dev/ttyUSBn” port and sending VT100/ANSI commands with a couple of strings.
It also changes the color of strings.

This tutorial is compatible firmware version 2.0 so if it isn't 2.0, update your firmware on ODROID-SHOW

#!/bin/bash
...
function programExit()
{
        ...
}
 
...
 
writeData()
{
        ...
}
 
writeData "\ec"
writeData "Hello ODROID-SHOW"
 
...

The DTR reset jumper should not be connected to ODROID-SHOW when the examples run

check your serial port

both
$ ls /dev/ttyUSB*

Modify the serial port path “/dev/ttyUSB0” or “/dev/ttyUSBn”

both
$ cd ODROID-SHOW/example/linux
$ vi ODROID.sh

Run

both
$ sudo ./ODROID.sh

The DTR reset jumper should not be connected to ODROID-SHOW when the examples run

You can display a graphic image on the ODROID-SHOW.
It supports only raw RGB-565 format.

We used ffmpeg to convert a normal PNG file to raw RGB file. Note that you must resize the PNG file first.

both
$ sudo apt-get install ffmpeg

You can convert it with this command. If the conversion is success, you will have the penguin.raw file.

both
$ ffmpeg -vcodec png -i penguin.png -vcodec rawvideo -f rawvideo -pix_fmt rgb565 penguin.raw

You can set the image load mode with the pixel coordination parameters.

Check your serial port

both
$ ls /dev/ttyUSB*

Modify the serial port “/dev/ttyUSB0” or “/dev/ttyUSBn”

both
$ cd ODROID-SHOW/example/linux
$ vi images.sh

Run

both
$ sudo ./images.sh

  • accessory/display/odroid-show/examples.txt
  • Last modified: 2017/08/01 16:55
  • by luke.go