lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | #include <stdio.h> |
2 | #include <stdlib.h> | ||||
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 3 | #include "zxic_fota_ab_upgrade.h" |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 4 | |
5 | int main(int argc, char *argv[]) | ||||
6 | { | ||||
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 7 | int ret = zxic_dual_get_current_system(); |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 8 | |
9 | switch (ret) | ||||
10 | { | ||||
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 11 | case Z_DUAL_SYSTEM: |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 12 | printf("ab_bootinfo:ab_a\n"); |
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 13 | ret = 1; |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 14 | break; |
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 15 | case Z_DUAL_SYSTEM2: |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 16 | printf("ab_bootinfo:ab_b\n"); |
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 17 | ret = 2; |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 18 | break; |
19 | default: | ||||
20 | printf("[error]ab_bootinfo:%d\n", ret); | ||||
lh | 758261d | 2023-07-13 05:52:04 -0700 | [diff] [blame^] | 21 | ret = 1; |
lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 22 | break; |
23 | } | ||||
24 | return ret; | ||||
25 | } |