FreeCalypso > hg > freecalypso-sw
comparison loadtools/ltmain.c @ 380:5e0e9bb26060
fc-loadtool: compalstage support hooked in
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Mon, 09 Jun 2014 21:20:10 +0000 |
parents | ccc5161848c7 |
children | 833e8fa93330 |
comparison
equal
deleted
inserted
replaced
379:7b3fd0e2a352 | 380:5e0e9bb26060 |
---|---|
22 extern char *optarg; | 22 extern char *optarg; |
23 extern int optind; | 23 extern int optind; |
24 int c; | 24 int c; |
25 char command[512]; | 25 char command[512]; |
26 | 26 |
27 while ((c = getopt(argc, argv, "a:b:h:H:i:n")) != EOF) | 27 while ((c = getopt(argc, argv, "a:b:c:C:h:H:i:n")) != EOF) |
28 switch (c) { | 28 switch (c) { |
29 case 'a': | 29 case 'a': |
30 iramimage.filename = optarg; | 30 iramimage.filename = optarg; |
31 continue; | 31 continue; |
32 case 'b': | 32 case 'b': |
33 set_romload_baudrate(optarg); | 33 set_romload_baudrate(optarg); |
34 continue; | |
35 case 'c': | |
36 set_compalstage_short(optarg); | |
37 continue; | |
38 case 'C': | |
39 set_compalstage_fullpath(optarg); | |
34 continue; | 40 continue; |
35 case 'h': | 41 case 'h': |
36 read_hwparam_file_shortname(optarg); | 42 read_hwparam_file_shortname(optarg); |
37 continue; | 43 continue; |
38 case 'H': | 44 case 'H': |
55 target_ttydev = argv[optind]; | 61 target_ttydev = argv[optind]; |
56 if (!iramimage.filename) | 62 if (!iramimage.filename) |
57 iramimage.filename = default_loadagent_image; | 63 iramimage.filename = default_loadagent_image; |
58 | 64 |
59 open_target_serial(); | 65 open_target_serial(); |
66 perform_compal_stage(1); | |
60 perform_romload(); | 67 perform_romload(); |
61 putchar('\n'); | 68 putchar('\n'); |
62 if (tpinterf_pass_output(1) < 0) | 69 if (tpinterf_pass_output(1) < 0) |
63 exit(1); | 70 exit(1); |
64 putchar('\n'); | 71 putchar('\n'); |