Skip to content

Commit

Permalink
fx
Browse files Browse the repository at this point in the history
  • Loading branch information
openshwprojects committed Jan 7, 2025
1 parent 17c91f8 commit 728c0c5
Showing 1 changed file with 30 additions and 30 deletions.
60 changes: 30 additions & 30 deletions src/hal/bk7231/hal_main_bk7231.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,36 +173,36 @@ void BUTTON_TriggerRead_quick(){

void user_main(void)
{
// OSStatus err;
//Main_Init();


// err = rtos_init_timer(&g_main_timer_1s,
// 1 * 1000,
// Main_OnEverySecond,
// (void *)0);
// ASSERT(kNoErr == err);

// err = rtos_start_timer(&g_main_timer_1s);
// ASSERT(kNoErr == err);
//ADDLOGF_DEBUG("started timer\r\n");

// // initialise a one-shot timer, triggered by MQTT_TriggerRead() and others
// err = rtos_init_oneshot_timer(&g_timer_oneshot,
// 1,
// process_oneshot_timer,
// (void *)0,
// (void *)0);
// ASSERT(kNoErr == err);

// err = rtos_init_oneshot_timer(&g_quick_timer_oneshot,
// QUICK_TMR_DURATION,
// process_quick_oneshot_timer,
// (void *)0,
// (void *)0);
// ASSERT(kNoErr == err);

//ADDLOGF_DEBUG("initialised oneshot timers");
OSStatus err;
Main_Init();


err = rtos_init_timer(&g_main_timer_1s,
1 * 1000,
Main_OnEverySecond,
(void *)0);
ASSERT(kNoErr == err);

err = rtos_start_timer(&g_main_timer_1s);
ASSERT(kNoErr == err);
ADDLOGF_DEBUG("started timer\r\n");

// initialise a one-shot timer, triggered by MQTT_TriggerRead() and others
err = rtos_init_oneshot_timer(&g_timer_oneshot,
1,
process_oneshot_timer,
(void *)0,
(void *)0);
ASSERT(kNoErr == err);

err = rtos_init_oneshot_timer(&g_quick_timer_oneshot,
QUICK_TMR_DURATION,
process_quick_oneshot_timer,
(void *)0,
(void *)0);
ASSERT(kNoErr == err);

ADDLOGF_DEBUG("initialised oneshot timers");
}

#if PLATFORM_BK7231N
Expand Down

0 comments on commit 728c0c5

Please sign in to comment.