- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What is there function like a "delay" in WICED Smart SDK?
I am a Japanese student.
I would like to blink LED to use like a "delay" function.
But I couldn't find it.
Please tell me.
Solved! Go to Solution.
- Labels:
-
GPIO
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello hoshiken
There is in fact a delay function(delay in microseconds):
extern void bleapputils_delayUs(UINT32 delay);
*delaying more than 2 seconds will cause system reboot
However, this isn't necessary to blink an LED. To blink and LED you can utilize the "timeout" in any of the sample apps. This function is called once per second. With a simple if/then statement, you can utilize this function to toggle the state of the LED pin high and low.
Likewise, you can carry out the same function with the "fine_timeout" function. This function does the same thing as the regular timeout, but it's period can be configured in the configuration array at the top of every function:
const BLE_PROFILE_CFG spi_comm_slave_cfg =
{
/*.fine_timer_interval =*/ 20, // ms
}
Jacob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello hoshiken
There is in fact a delay function(delay in microseconds):
extern void bleapputils_delayUs(UINT32 delay);
*delaying more than 2 seconds will cause system reboot
However, this isn't necessary to blink an LED. To blink and LED you can utilize the "timeout" in any of the sample apps. This function is called once per second. With a simple if/then statement, you can utilize this function to toggle the state of the LED pin high and low.
Likewise, you can carry out the same function with the "fine_timeout" function. This function does the same thing as the regular timeout, but it's period can be configured in the configuration array at the top of every function:
const BLE_PROFILE_CFG spi_comm_slave_cfg =
{
/*.fine_timer_interval =*/ 20, // ms
}
Jacob