Skip to content

Commit

Permalink
Guide de l'étudiant de l'objectif 4
Browse files Browse the repository at this point in the history
  • Loading branch information
pthebaul committed May 29, 2020
1 parent 39fc3c2 commit 829c33e
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 26 deletions.
47 changes: 22 additions & 25 deletions Project.uvoptx
Original file line number Diff line number Diff line change
Expand Up @@ -153,32 +153,29 @@
<Name>-U066CFF574857847167074929 -O2254 -S0 -C0 -A0 -N00("ARM CoreSight SW-DP") -D00(1BA01477) -L00(0) -TO18 -TC10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -FO7 -FD20000000 -FC800 -FN1 -FF0STM32F10x_128.FLM -FS08000000 -FL020000 -FP0($$Device:STM32F103RB$Flash\STM32F10x_128.FLM)</Name>
</SetRegEntry>
</TargetDriverDllRegistry>
<Breakpoint/>
<Breakpoint>
<Bp>
<Number>0</Number>
<Type>0</Type>
<LineNumber>87</LineNumber>
<EnabledFlag>1</EnabledFlag>
<Address>134221994</Address>
<ByteObject>0</ByteObject>
<HtxType>0</HtxType>
<ManyObjects>0</ManyObjects>
<SizeOfObject>0</SizeOfObject>
<BreakByAccess>0</BreakByAccess>
<BreakIfRCount>1</BreakIfRCount>
<Filename>.\Src\principal.c</Filename>
<ExecCommand></ExecCommand>
<Expression>\\CHTI\Src/principal.c\87</Expression>
</Bp>
</Breakpoint>
<WatchWindow1>
<Ww>
<count>0</count>
<WinNumber>1</WinNumber>
<ItemText>module</ItemText>
</Ww>
<Ww>
<count>1</count>
<WinNumber>1</WinNumber>
<ItemText>tab</ItemText>
</Ww>
<Ww>
<count>2</count>
<WinNumber>1</WinNumber>
<ItemText>k</ItemText>
</Ww>
<Ww>
<count>3</count>
<WinNumber>1</WinNumber>
<ItemText>global</ItemText>
</Ww>
<Ww>
<count>4</count>
<WinNumber>1</WinNumber>
<ItemText>global.scores[i]</ItemText>
<ItemText>global.scores</ItemText>
</Ww>
</WatchWindow1>
<MemoryWindow1>
Expand Down Expand Up @@ -235,17 +232,17 @@
<Wi>
<IntNumber>0</IntNumber>
<FirstString>((portb &amp; 0x00000002) &gt;&gt; 1 &amp; 0x2) &gt;&gt; 1</FirstString>
<SecondString>FF0000000000000000000000000000000000F03F0100000000000000000000000000000028706F7274622026203078303030303030303229203E3E2031000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000001000000565555555555D53F1400000000000000000000000000000000000000AE0E0008</SecondString>
<SecondString>FF0000000000000000000000000000000000F03F0100000000000000000000000000000028706F7274622026203078303030303030303229203E3E2031000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000001000000565555555555D53F1500000000000000000000000000000000000000AE0E0008</SecondString>
</Wi>
<Wi>
<IntNumber>1</IntNumber>
<FirstString>((portb &amp; 0x00004000) &gt;&gt; 14 &amp; 0x4000) &gt;&gt; 14</FirstString>
<SecondString>00800000000000000000000000000000E0FFEF400100000000000000000000000000000028706F7274622026203078303030303430303029203E3E2031340000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000002000000565555555555D53F1400000000000000000000000000000000000000AE0E0008</SecondString>
<SecondString>00800000000000000000000000000000E0FFEF400100000000000000000000000000000028706F7274622026203078303030303430303029203E3E2031340000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000002000000565555555555D53F1500000000000000000000000000000000000000AE0E0008</SecondString>
</Wi>
<Wi>
<IntNumber>2</IntNumber>
<FirstString>`TIM3_CCR3</FirstString>
<SecondString>00008000000000000000000000000000007084400000000000000000000000000000000054494D335F4343523300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000003000000555555555555D53F1400000000000000000000000000000000000000FE0E0008</SecondString>
<SecondString>00008000000000000000000000000000007084400000000000000000000000000000000054494D335F4343523300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000003000000555555555555D53F1500000000000000000000000000000000000000FE0E0008</SecondString>
</Wi>
</LogicAnalyzers>
<DebugDescription>
Expand Down
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,28 @@ Votre dernier objectif sera de réunir tout votre travail en un seul projet qui

### Guide de l'étudiant

#### Le point d'arrêt
Placer un point d'arrêt à la ligne 87 (`etat.position = 0;`) permet de s'arrêter juste après l'ajout d'un point à un joueur.

#### Observation des scores
Ajouter la variable `global.scores` à une *Watch Window* pour visualiser les scores au fil de l’exécution.

#### Afficher le son dans le débugueur :

1. Ouvrir le Logic Analyzer
2. Cliquer sur Setup
3. Ajouter un nouveau signal *TIM3_CCR3* en mode analogique.
4. Lancer l'exécution.

Et si le son n'est pas entièrement visible :

5. Dans *Zoom*, cliquer sur *All*
6. Dans *Min/Max*, cliquer sur *Auto*

#### Visualisations optionnelles
Deux bits du *GPIOB* sont utilisés lors de l’exécution. Il est possible de les observer avec le *Logic Analyser* :
* Le `portb.1` qui est à 1 lors de l'exécution de la fonction `sys_callback`
* Le `portb.14` qui est mis brièvement à 1 à chaque modification des scores

### À propos

Expand Down
2 changes: 1 addition & 1 deletion Src/principal.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ void sys_callback(void) {
if (global.compteur[i] == NOMBRE_FENETRES_VALIDATION) {
global.isValid = 1;
global.scores[i]++;
etat.position = 0;
etat.position = 0; // Point d'arrêt sur cette ligne :D
}
}
GPIO_Clear(GPIOB, 1);
Expand Down

0 comments on commit 829c33e

Please sign in to comment.