How to use Ethernet IOT Card on MangOH green?

Hi all, I’m using the mangoh green with ethernet IOT card. In my project the ethernet card must be connected to slot 1. Are there any configurations to be made such as enabling the pins etc? Or just follow the script used in the following guide Setting up MangOH Red as Router to Cellular Gateway ?

Thanks in advance.

probably you need to type the following to have the eth1.

echo 2 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio2/direction
echo 1 > /sys/class/gpio/gpio2/value

Thank you jyijyi.
If i want to use slot 2, I have to execute the same commands? or do I have to change something, like the number of gpio ?

maybe you try the slot 1 and see it the eth1 can be seen first

I have this problem ? how can i fix it ?

you need to check AT+wiocfg? and see if GPIO2 can be used in the linux console

i have this answer when i use the command.

Previously, however, I used slot 1 for the can and I used the following script without having errors:


you should type this in “microcom /dev/ttyAT”

Sorry jyijyi for my lack of practicality with linux, I’m a beginner.
I follow your tips and this is the response:

I don’t see such issue:

root@swi-mdm9x28-wp:~# microcom /dev/ttyAT
+WIOCFG: 2,16,0,0,1,0,0
+WIOCFG: 4,3,0,0,1,0,0
+WIOCFG: 6,8,0,0,1,0,0
+WIOCFG: 7,16,0,0,1,0,0
+WIOCFG: 8,16,0,0,1,0,0
+WIOCFG: 13,16,0,0,1,0,0
+WIOCFG: 21,16,0,0,1,0,0
+WIOCFG: 22,16,0,0,1,0,0
+WIOCFG: 23,16,0,0,1,0,0
+WIOCFG: 24,16,0,0,1,0,0
+WIOCFG: 25,16,0,0,1,0,0
+WIOCFG: 28,16,0,0,1,0,0
+WIOCFG: 29,16,0,0,1,0,0
+WIOCFG: 30,16,0,0,1,0,0
+WIOCFG: 31,16,0,0,1,0,0
+WIOCFG: 32,16,0,0,1,0,0
+WIOCFG: 33,16,0,0,1,0,0
+WIOCFG: 35,16,0,0,1,0,0
+WIOCFG: 42,16,0,0,1,0,0

root@swi-mdm9x28-wp:~# echo 2 > /sys/class/gpio/export
root@swi-mdm9x28-wp:~# echo out > /sys/class/gpio/gpio2/direction
root@swi-mdm9x28-wp:~# echo 1 > /sys/class/gpio/gpio2/value

I still have the same problem : “sh: write error: Device or resource busy” .
However, I noticed that in the CAN script I don’t have echo 2 but echo7, with also a route and a reset of SPI. Why are there these differences?

It is controlling different gpio

Gpio2 vs gpio7

Maybe you load the official fw and stop running the CAN script