Testcases now run through prelude

geofence_dev
Richard Meadows 2015-03-13 19:42:01 +00:00
rodzic 9049df90f9
commit 372af471d3
3 zmienionych plików z 33 dodań i 11 usunięć

Wyświetl plik

@ -264,10 +264,10 @@ void output_telemetry_string(enum telemetry_t type)
}
/**
* MAIN
* Internal initialisation
* =============================================================================
*/
int main(void)
void init(void)
{
/**
* Internal initialisation
@ -306,21 +306,26 @@ int main(void)
//wdt_init();
//wdt_reset_count();
xosc_init();
led_init();
gps_init();
/* Initialise Si4060 interface */
si_trx_init();
}
xosc_init();
/**
* MAIN
* =============================================================================
*/
int main(void)
{
init();
measure_xosc(XOSC_MEASURE_TIMEPULSE);
while (1) {
system_sleep();
}

Wyświetl plik

@ -37,6 +37,7 @@
/***************************** test cases *******************************/
#include "times_two.h"
#include "osc8m_calib.h"
/******************************* tc_main ********************************/
@ -60,3 +61,18 @@ __verification__ void tc_main(void) {
tc_run();
}
}
/* This is in the real main.c */
void init(void);
/**
* Prelude to main loop
*/
__verification__ void tc_prelude(void) {
/* Initialise the board */
init();
/* Proceed to main loop */
tc_main();
}

Wyświetl plik

@ -86,7 +86,8 @@ class Tests():
self.print_fail(name, time)
self.print_header("")
#### GDB
#### GDB
def __init__(self):
self.inferior = gdb.selected_inferior()
@ -99,10 +100,10 @@ class Tests():
gdb.execute("load")
gdb.execute("b main")
gdb.execute("run")
# Stopped at the top of main. Go to tc_main
# Stopped at the top of main. Go to tc_main via tc_prelude
gdb.execute("del 1")
gdb.execute("b tc_main")
gdb.execute("set $pc=tc_main")
gdb.execute("set $pc=tc_prelude")
gdb.execute("c")
def __del__(self):