Project

General

Profile

Included Examples and Scripts

LED Driver

The MitySOM-5CSX module features a tri-color (red, green and blue) LED that can be controlled by a user application or script. We have provided an example script that interfaces with the LED driver. Note that for development kits that included "pre-production" silicon you should reference the "leds" script and for newer module/development kits use the "lp5562" script.

80-000640 and 80-000639 Development Kit LED script

Uses an LED driver, instead of I2C write commands, to change the color of the LED in a pattern.

root@mitysom-5csx:~# ./scripts/lp5562
BLUE ON
RED ON
GREEN ON
GREEN1 ON

lp5562 Script Content (cycles through each LED/color)

#!/bin/sh
echo 100 > /sys/class/leds/B/brightness
echo "BLUE ON" 
sleep 1
echo 0 > /sys/class/leds/B/brightness
echo 100 > /sys/class/leds/R/brightness
echo "RED ON" 
sleep 1
echo 0 > /sys/class/leds/R/brightness
echo 100 > /sys/class/leds/G/brightness
echo "GREEN ON" 
sleep 1
echo 0 > /sys/class/leds/G/brightness
echo 100 > /sys/class/leds/G1/brightness
echo "GREEN1 ON" 
sleep 1
echo 0 > /sys/class/leds/G1/brightness

Depreciated - 80-000615 Development Kit LED script

./leds

I2C Power/Current monitor (IC located on baseboard)

The MitySOM-5CSX Development Kit Baseboard features a LTC2945 current monitor IC which monitors the current drawn by the modules +5V supply. This allows users to obtain an good approximation of module power consumption instantaneously.

root@mitysom-5csx:~# ./scripts/pwr
power = 2613 mW

"enable_usb"

This script will configure the MitySOM-5CSX as a 5MB "mass storage" device that can be seen with a PC.

  • From the serial port of the MitySOM-5CSX dev board run the enable_usb script from /home/root/scripts
root@mitysom-5csx:~# ./scripts/enable_usb
g_mass_storage gadget: Mass Storage Function, version: 2009/09/11
g_mass_storage gadget: Number of LUNs=1
 lun0: LUN: removable file: /home/root/scripts/backing_file
g_mass_storage gadget: Mass Storage Gadget, version: 2009/09/11
g_mass_storage gadget: userspace failed to provide iSerialNumber
g_mass_storage gadget: g_mass_storage ready
s3c-hsotg ffb40000.usb: bound driver g_mass_storage
root@mitysom-5csx:~# s3c-hsotg ffb40000.usb: GINTSTS_USBSusp
s3c-hsotg ffb40000.usb: s3c_hsotg_irq: USBRst
s3c-hsotg ffb40000.usb: new device is high-speed
s3c-hsotg ffb40000.usb: s3c_hsotg_irq: USBRst
s3c-hsotg ffb40000.usb: new device is high-speed
s3c-hsotg ffb40000.usb: new address 4
g_mass_storage gadget: high-speed config #1: Linux File-Backed Storage
  • Plug a Mini-USB from the USB-OTG interface (J401) into a PC
  • The PC should install drivers and show a new mass storage device 5MB in size
  • On your MitySOM mount the backing file to a mount point
  • You can now access any files that are placed in the backing directory

"hw_version"

This script will retrieve the HW version and display it.

  • From the serial port of the MitySOM-5CSX dev board run the hw_version script from /home/root/scripts
root@mitysom-5csx:~# ./scripts/hw_version
HW VERION: 1100000000
EXPECTED : 1100000000
CORRECT VERSION

SoM Thermocouple "tc74"

The MitySOM-5CSX module features an on-module thermocouple that can read the current temperature from that location. It is located on the "bottom" side of the module. Unlike the examples above the thermocouple is read by an application that is included on the development kit SD card file system.

For the latest details about using the temperature sensor please visit https://support.criticallink.com/redmine/projects/mityarm-5cs/wiki/SoM_Temperature_Sensor

FPGA DDR Memory Test

As a part of the included/pre-built FPGA image that is loaded automatically on startup of the module there is also a test application that writes and reads from the FPGA DDR memory. To execute this test perfrom the following command from the serial port:

root@mitysom-5csx:~# fpgaddrtest
Writing counting pattern to FPGA DDR
Writing done

Reading and validating counting pattern from FPGA DDR
Read done
Correct: 16777216, Miss Match: 0

Go to top
Add picture from clipboard (Maximum size: 1 GB)