Eval » Historie » Version 1
Redmine Admin, 05.10.2021 15:55
| 1 | 1 | Redmine Admin | h1. Eval |
|---|---|---|---|
| 2 | |||
| 3 | h2. Writing to board |
||
| 4 | |||
| 5 | Writing HWInfo via bringup-software is bad. Boards will be switched and wron serial number is on board. |
||
| 6 | An dedicated application should flash it. -Read serial number via UART.- with the help of gdb |
||
| 7 | <pre><code class="shell"> |
||
| 8 | gdb qhello -ex "br loop" -ex "run" -ex "call (flash)(10,\"mmm\")" -ex "clear loop" -ex "c" --batch |
||
| 9 | </code></pre> |
||
| 10 | |||
| 11 | The information can be read even without serial insterface. |
||
| 12 | <pre><code class="shell"> |
||
| 13 | print myStruct |
||
| 14 | |||
| 15 | info symbol 0x4010 |
||
| 16 | info address myStruct |
||
| 17 | </code></pre> |
||
| 18 | An unstripped elf file is needed of course. |
||
| 19 | |||
| 20 | set var $new = (SMyStruct *)malloc(sizeof(struct SMyStruct)) |
||
| 21 | set var $new.version = 111 |
||
| 22 | print $new.version |
||
| 23 | set var $new.name="MAX" |