Add README.md
This commit is contained in:
@@ -109,20 +109,21 @@ void system_time_init(void)
|
||||
|
||||
int IPC_DO_SERVE_FUNC(Ipc_delay_us)(uint32_t* usecs)
|
||||
{
|
||||
// uint32_t instance = g_system_timer_port;
|
||||
// if (*usecs == 0) {
|
||||
// return 0;
|
||||
// }
|
||||
uint32_t instance = g_system_timer_port;
|
||||
if (*usecs == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// /* enable the counter first */
|
||||
// epit_counter_enable(instance, *usecs, POLLING_MODE);
|
||||
/* enable the counter first */
|
||||
epit_counter_enable(instance, *usecs, POLLING_MODE);
|
||||
|
||||
// /* wait for the compare event */
|
||||
// while (!epit_get_compare_event(instance))
|
||||
// ;
|
||||
/* wait for the compare event */
|
||||
while (!epit_get_compare_event(instance)) {
|
||||
yield(SYS_TASK_YIELD_NO_REASON);
|
||||
}
|
||||
|
||||
// /* disable the counter to save power */
|
||||
// epit_counter_disable(instance);
|
||||
/* disable the counter to save power */
|
||||
epit_counter_disable(instance);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -145,7 +145,6 @@ void print_hw_enet(const hw_enet_t* enet)
|
||||
*/
|
||||
int enet_test()
|
||||
{
|
||||
|
||||
imx_enet_priv_t* dev0 = &enet0;
|
||||
int pkt_len_send = 0, pkt_len_recv = 0, ret = 0, i;
|
||||
unsigned int enet_events = 0;
|
||||
|
||||
Reference in New Issue
Block a user