Difference between revisions of "What can I do with IGEP SMARC iMX6"
From IGEP - ISEE Wiki
Line 108: | Line 108: | ||
* Read EEPROM: | * Read EEPROM: | ||
<pre>cat /sys/devices/soc0/soc.0/2100000.aips-bus/21a8000.i2c/i2c-2/2-0050/eeprom</pre> | <pre>cat /sys/devices/soc0/soc.0/2100000.aips-bus/21a8000.i2c/i2c-2/2-0050/eeprom</pre> | ||
− | |||
== SPINOR == | == SPINOR == |
Revision as of 10:00, 20 May 2016
| |
| |||||||||
Overview
This is the 2/3 chapter of the Getting Started with IGEP SMARC iMX6 Tutorial Guide.
In this second chapter, we will learn some basics tasks. Upon completion, you will be ready to continue with chapter 3/3 that explains more advanced tasks.
Contents
[hide]
What can I do
You must logged in the board.
Handle the GPIO-LEDS
The board has two user bicolor (green/red) leds available that can be controlled. In its simplest form, you can control of LEDs from userspace. LEDs appear in /sys/class/leds/igep and you can turn on and off with following commands:
$ echo 1 > /sys/class/leds/igep\:red\:led1/brightness $ echo 1 > /sys/class/leds/igep\:red\:led0/brightness $ echo 0 > /sys/class/leds/igep\:red\:led1/brightness $ echo 0 > /sys/class/leds/igep\:red\:led0/brightness
$ echo 1 > /sys/class/leds/igep\:green\:led1/brightness $ echo 1 > /sys/class/leds/igep\:green\:led0/brightness $ echo 0 > /sys/class/leds/igep\:green\:led1/brightness $ echo 0 > /sys/class/leds/igep\:green\:led0/brightness
If you want to trigger the leds you can enable this mode and select the trigger source (none by default) to: mmc0, mmc1, timer, heartbeat and default-on.
To enable any of this modes you just have to change a parameter in the directory of the led you want to control. You can see all the possibilities using the instruction 'cat':
$ cat /sys/class/leds/igep\:red\:led0/trigger [none] mmc0 mmc1 timer heartbeat default-on
In the example above, we have checked the status of the trigger in led red\led0. Mode 'none' is selected.
To change it, for example, to the timer mode you can use 'echo':
echo timer > /sys/class/leds/igep\:red\:led0/trigger
In this case, we have set the trigger to the 'timer' mode. Now you can set the time for what the led is ON and the time it is OFF using:
echo 250 > /sys/class/leds/igep\:red\:led0/delay_on echo 750 > /sys/class/leds/igep\:red\:led0/delay_off
Now the selected led is configured with a timer consisting of 250 miliseconds ON and 750 miliseconds OFF.
The base has two user (red/blue) leds available that can be controlled. Can't use them in the same time. In its simplest form, you can control of LEDs from userspace. LEDs appear in /sys/class/leds/base and you can turn on and off with following commands:
$ echo 1 > /sys/class/leds/base\:blue\:led0/brightness $ echo 1 > /sys/class/leds/base\:red\:led0/brightness $ echo 0 > /sys/class/leds/base\:blue\:led0/brightness $ echo 0 > /sys/class/leds/base\:red\:led0/brightness
How to use UART (RS485)
under construction
CAN BUS
under construction
Audio
under construction
Boot SATA
under construction
Boot emmc
under construction
Install firmware emmc
under construction
How to use EEPROM
EEPROM can be read and write via /sys/devices/soc0/soc.0/2100000.aips-bus/21a8000.i2c/i2c-2/2-0050/eeprom:
- Write EEPROM:
echo "data" > /sys/devices/soc0/soc.0/2100000.aips-bus/21a8000.i2c/i2c-2/2-0050/eeprom
- Read EEPROM:
cat /sys/devices/soc0/soc.0/2100000.aips-bus/21a8000.i2c/i2c-2/2-0050/eeprom
SPINOR
under construction
IO expansion
under construction
wifi
under construction
HDMI resolution
under construction
modem USB
under construction
You have successfully completed this chapter of the guide.
| |
![]() |
If you have any question, don't ask to ask at the IGEP Community Forum or the IGEP Community Chat | ![]() |