2020-09-30 23:05:04 +00:00
|
|
|
#ifndef TARGET_H
|
|
|
|
#define TARGET_H
|
|
|
|
|
2021-05-18 13:57:39 +00:00
|
|
|
/**
|
2020-09-30 23:05:04 +00:00
|
|
|
* Initialize hardware
|
|
|
|
*/
|
|
|
|
void target_init();
|
|
|
|
|
2021-05-18 13:57:39 +00:00
|
|
|
/**
|
2020-09-30 23:05:04 +00:00
|
|
|
* Check if dfu mode requested
|
|
|
|
* @return 1 if dfu mode requested, 0 if not
|
2021-05-18 13:57:39 +00:00
|
|
|
*/
|
2020-09-30 23:05:04 +00:00
|
|
|
int target_is_dfu_requested();
|
|
|
|
|
2021-05-18 13:57:39 +00:00
|
|
|
/**
|
2020-09-30 23:05:04 +00:00
|
|
|
* Switch to dfu mode
|
2021-05-18 13:57:39 +00:00
|
|
|
*/
|
2020-09-30 23:05:04 +00:00
|
|
|
void target_switch2dfu();
|
|
|
|
|
2021-05-18 13:57:39 +00:00
|
|
|
/**
|
2020-09-30 23:05:04 +00:00
|
|
|
* Switch to OS
|
2021-05-18 13:57:39 +00:00
|
|
|
*/
|
2020-09-30 23:05:04 +00:00
|
|
|
void target_switch2os();
|
|
|
|
|
|
|
|
#endif
|