Connecting to a mangOH Green board through Ethernet cable and having it powered only of the power supply will not be enough to have a sustainable connection. In many cases, it will appear that the Ethernet port will not get enough power to stay on, but don’t worry, your board is not defective! The board was actually programmed to automatically go into power saving mode if the host decides to suspend the USB connection (in our case, we did not have an upstream machine connected to our USB hub). The simple solution to this obstacle would be to disable the auto sleep feature. There are two ways to do this:
##1) Disabling auto sleep feature manually:
a. Open a console or ssh connection to the desired mangOH board and log in
b. Edit enable_autosleep.sh file using vi text editor tool vi /etc/init.d/enable_autosleep.sh
c. Scroll down the file (using the down arrow key) until you reach the following function # Enable the autosleep feature if [ -f /sys/power/autosleep ] then echo mem > /sys/power/autosleep true fi ;;
d. Once you have reached this function, you can now press the i key (this will place you into insert mode)
e. Edit the text so it looks like the following # Enable the autosleep feature if [ -f /sys/power/autosleep ] then # stop autosleep #echo mem > /sys/power/autosleep echo "Disable Autosleep" echo off > /sys/power/autosleep true fi ;;
f. Press ESC key and then type :wq! (this will save and then quit the file)
The next time you reboot the manhOH board, the auto sleep on USB suspend function will be disabled.
##2) Disabling auto sleep feature using an automated script:
a. Download DisableUsbSleep.sh.gz
b. Unpack the script (using gunzip on Linux or 7zip on Windows)
c. Copy the DisavleUsbSleep.sh script to your mangOH board (scp on Linux, WinSCP on Windows)
d. Open a console or ssh connection to the desired mangOH board and log in
e. Run the script ./DisableUsbSleep.sh
This will modify /etc/init.d/enable_autosleep.sh to disable the auto-sleep feature. Next time the mangOH board will be rebooted, the auto sleep on USB suspend functionality will be disabled.
Is there a way to “disable” this from being built included in Legato-Dist ? as with the custom image build it appears to be included and running by default after a new flash, while im at it the mentioned below are apps also included that we dont need
The system definition file (.sdef) defines which apps are in the Legato system that is built. Legato’s Makefile has a variable named SDEF_TO_USE which controls which SDEF it uses. Within the primary Makefile you can see that it is set like this SDEF_TO_USE ?= default.sdef. This actually has no effect in the case of the WP modules because of another line earlier in the Makefile. That line is include $(wildcard modules/*/moduleDefs. That line causes modules/WiFi/moduleDefs to be included which setsSDEF_TO_USEif it's not already set tomodules/WiFi/wifi.sdef`.
I’m not sure exactly what it is that you do want in your SDEF. You can define your own and then pass SDEF_TO_USE=path/to/your/system.sdef if you are building with the Legato Makefile. Or if you’re just using mksys, then you just pass your sdef as the one to build.