Open main menu

DAVE Developer's Wiki β

Changes

DESK-MP1-L/Peripherals/GPIOs

460 bytes removed, 8 January
no edit summary
!colspan="4" style="width:100%; text-align:left"; border-bottom:solid 2px #ededed"|History
|-
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|ID#
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Issue Date
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Notes
|-
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|{{oldid|1877|18177}}|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|022023/08/202302
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|DESK-MP1-L-1.0.0 release
|-
==Peripheral GPIOs ==
In [[ETRA_SOM | ETRA SOM]] there is an I2C I/O Expander driven via i2c: in this way, with this ETRA can handle external several pins in many different ways and most of them can be configured as GPIOs, these . These GPIOs are present available in the J11 connector.
There is no driver to configure and use these GPIOs, to To configure and write/read the GPIOs you need to interact with configure the I/O expander with i2c via I2C commands.
=== Accessing the peripheral ===
==== Usage with i2c I2C command ====
Set all GPIO on output mode, all pin pins low:
<pre class="workstation-terminal">
</pre>
set Set all pin to high, one by one:
<pre class="workstation-terminal">
</pre>
set Set all pin to high and set all to low one by one: 
<pre class="workstation-terminal">
root@desk-mp1:~# i2cset -y 1 0x34 0x2a 0xff
</pre>
set gpio Set GPIO input mode, disable debounce:
<pre class="workstation-terminal">
</pre>
Read input value:
<pre class="workstation-terminal">
8,286
edits