Then I executed this function before executing above “Set_wakeup_alarm_and_sleep(int Next_wakeup_in_seconds)” function hoping that I have successfully manage to assign an interrupt functions.
public static void set_wakeup_options()
{
InterruptPort usb_pwr_connector = new InterruptPort(G120.P0_27, true, Port.ResistorMode.PullDown,Port.InterruptMode.InterruptEdgeBoth);
InterruptPort bluethooth_pair_ok = new InterruptPort(G120.P0_28, true, Port.ResistorMode.PullDown, Port.InterruptMode.InterruptEdgeBoth);
usb_pwr_connector.OnInterrupt +=usb_pwr_connector_OnInterrupt;
bluethooth_pair_ok.OnInterrupt +=bluethooth_pair_ok_OnInterrupt;
}
The system still wake up from RTC alarm but not from the GPIO interrupt.
I know it’s a cold start every time when it wake up but I can manage that.
CAN any one help!
see the picture if any one interested in our design.
Sleep.Off does not work with interrupts currently. I’m not sure if this is a hardware or software limitation. If you haven’t already seen it you may be interested in this thread here where various sleep states were discussed and measured.
I have this installed but not sure how to test whether I am using this in my project or not.
[quote]NETMF 4.3 SDK
2014 R5
Released October 2014
Built with NETMF SDK 4.3 QFE1
EMX
Version
4.3.6.0 Firmware
4.3.4.0 Loader
Changes
None.
Issues
The loader cannot be updated on Windows 8.
G120
Version
4.3.6.0 Firmware
4.3.4.0 Loader
[/quote]
Can you also see my references are correct as well.
GHI.Pins= 4.3.6.0
GHI.Hardware= 4.3.6.0
Do I need to have these references in 4.3.6.0 as well?
Microsoft.SPOT.Graphics =4.3.1.0
Microsoft.SPOT.Hardware = 4.3.1.0
Microsoft.SPOT.Hardware.SerialPort=4.3.1.0
Microsoft.SPOT.IO=4.3.1.0
Microsoft.SPOT.Native=4.3.1.0
mscorlib=4.3.1.0
System.IO=4.3.1.0
Please note that the SD card,Threads, RTC, Coms are working fine.
PROJECT…(name of the project) properties…then see what version of NETMF you are using
Then on the right to find the specific versions go to
solution explorer…references…then find the Gadgeteer(click it)…then find the version in the properties box(tell us all the numbers)
Also do it for ghi.hardware…properties(tell us the versions)
I think this is what they want, or atleast will help them
So yes, you’re running the GHI 2014 R5 SDK. An equally important point is to confirm you have the right firmware on your device, fire up FezConfig and test (paste the results back in a reply here)
@ John -
@ John -
I tried with SleepLevel.Off, SleepLevel.Off, SleepLevel.Sleep and SleepLevel.DeepSleep same result.
What you are saying is when using RTC alarms interrupts the GPIO interrupts can not be used. Isn’t this implemented in software ISR.
I know that “LPC17x.” hardware supports this(from the data sheet UM10360 page 129 last paragraph) just not included in the .net porting.
I wish you put that in the module’s data sheet. I did expect such a basic and important function is not ported.
I am too far in to the development process and its not possible to turn back now.
Can you give me a workaround?
Is it possible to set to restart the G120 device when GPIO or any interrupts triggered? Do not need to execute an function.
Can I do this by accessing CPU registry?
I select this module for an low power field logger that need to sleep and it needs to wake up from pin interrupts. Sleep power consumption is some what acceptable for the performance and I know its the hardware limitation but the above problem is not an hardware limitation.
???
I think the supported low power states are:-
Sleep. - automatic when idle
DeepSleep. -
PowerDown. - not implimented.
DeepPowerDown - off . RTC wake only
You could use the register class or RLP to trigger the PowerDown mode and see what that does. There is an app note with some example C code on the nxp site.