Page 138 - ARM Based Microcontroller Projects Using MBED
P. 138

124                       7. USING THE Mbed WITH SIMPLE PROJECTS

                 TABLE 7.1 Number to be Displayed ad PORT C Value
                 Number     PC_7    PC_6    PC_5     PC_4    PC_3     PC_2    PC_1    PC_0     Hex
                 0          0       0       1        1       1        1       1       1        0x3F
                 1          0       0       0        0       0        1       1       0        0x06
                 2          0       1       0        1       1        0       1       1        0x5B
                 3          0       1       0        0       1        1       1       1        0x4F
                 4          0       1       1        0       0        1       1       0        0x66
                 5          0       1       1        0       1        1       0       1        0x6D
                 6          0       1       1        1       1        1       0       1        0x7D
                 7          0       0       0        0       0        1       1       1        0x07
                 8          0       1       1        1       1        1       1       1        0x7F
                 9          0       1       1        0       1        1       1       1        0x6F



                                          Number              PORT C Value
                                          0                   0x3F
                                          1                   0x06
                                          2                   0x5B
                                          3                   0x4F
                                          4                   0x66
                                          5                   0x6D
                                          6                   0x7D
                                          7                   0x07
                                          8                   0x7F
                                          9                   0x6F

                   As we can see from Table 7.1, the following hexadecimal number must be sent to the lower
                 byte of PORT C in order to display a number:


                 7.16.5 The Construction
                   Fig. 7.70 shows the project built on a breadboard.



                 7.16.6 The PDL

                   Fig. 7.71 shows the program PDL.
   133   134   135   136   137   138   139   140   141   142   143