Dan Allen
/
ramp_blink
a program to ramp the blink frequency of an analog out pin for Nucleo L432KC
README.md@0:95d8db6b6e4d, 2019-01-27 (annotated)
- Committer:
- laserdad
- Date:
- Sun Jan 27 15:48:36 2019 +0000
- Revision:
- 0:95d8db6b6e4d
ramping version full range
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
laserdad | 0:95d8db6b6e4d | 1 | # Getting started with Blinky on mbed OS |
laserdad | 0:95d8db6b6e4d | 2 | |
laserdad | 0:95d8db6b6e4d | 3 | This guide reviews the steps required to get Blinky working on an mbed OS platform. |
laserdad | 0:95d8db6b6e4d | 4 | |
laserdad | 0:95d8db6b6e4d | 5 | Please install [mbed CLI](https://github.com/ARMmbed/mbed-cli#installing-mbed-cli). |
laserdad | 0:95d8db6b6e4d | 6 | |
laserdad | 0:95d8db6b6e4d | 7 | ## Import the example application |
laserdad | 0:95d8db6b6e4d | 8 | |
laserdad | 0:95d8db6b6e4d | 9 | From the command-line, import the example: |
laserdad | 0:95d8db6b6e4d | 10 | |
laserdad | 0:95d8db6b6e4d | 11 | ``` |
laserdad | 0:95d8db6b6e4d | 12 | mbed import mbed-os-example-blinky |
laserdad | 0:95d8db6b6e4d | 13 | cd mbed-os-example-blinky |
laserdad | 0:95d8db6b6e4d | 14 | ``` |
laserdad | 0:95d8db6b6e4d | 15 | |
laserdad | 0:95d8db6b6e4d | 16 | ### Now compile |
laserdad | 0:95d8db6b6e4d | 17 | |
laserdad | 0:95d8db6b6e4d | 18 | Invoke `mbed compile`, and specify the name of your platform and your favorite toolchain (`GCC_ARM`, `ARM`, `IAR`). For example, for the ARM Compiler 5: |
laserdad | 0:95d8db6b6e4d | 19 | |
laserdad | 0:95d8db6b6e4d | 20 | ``` |
laserdad | 0:95d8db6b6e4d | 21 | mbed compile -m K64F -t ARM |
laserdad | 0:95d8db6b6e4d | 22 | ``` |
laserdad | 0:95d8db6b6e4d | 23 | |
laserdad | 0:95d8db6b6e4d | 24 | Your PC may take a few minutes to compile your code. At the end, you see the following result: |
laserdad | 0:95d8db6b6e4d | 25 | |
laserdad | 0:95d8db6b6e4d | 26 | ``` |
laserdad | 0:95d8db6b6e4d | 27 | [snip] |
laserdad | 0:95d8db6b6e4d | 28 | +----------------------------+-------+-------+------+ |
laserdad | 0:95d8db6b6e4d | 29 | | Module | .text | .data | .bss | |
laserdad | 0:95d8db6b6e4d | 30 | +----------------------------+-------+-------+------+ |
laserdad | 0:95d8db6b6e4d | 31 | | Misc | 13939 | 24 | 1372 | |
laserdad | 0:95d8db6b6e4d | 32 | | core/hal | 16993 | 96 | 296 | |
laserdad | 0:95d8db6b6e4d | 33 | | core/rtos | 7384 | 92 | 4204 | |
laserdad | 0:95d8db6b6e4d | 34 | | features/FEATURE_IPV4 | 80 | 0 | 176 | |
laserdad | 0:95d8db6b6e4d | 35 | | frameworks/greentea-client | 1830 | 60 | 44 | |
laserdad | 0:95d8db6b6e4d | 36 | | frameworks/utest | 2392 | 512 | 292 | |
laserdad | 0:95d8db6b6e4d | 37 | | Subtotals | 42618 | 784 | 6384 | |
laserdad | 0:95d8db6b6e4d | 38 | +----------------------------+-------+-------+------+ |
laserdad | 0:95d8db6b6e4d | 39 | Allocated Heap: unknown |
laserdad | 0:95d8db6b6e4d | 40 | Allocated Stack: unknown |
laserdad | 0:95d8db6b6e4d | 41 | Total Static RAM memory (data + bss): 7168 bytes |
laserdad | 0:95d8db6b6e4d | 42 | Total RAM memory (data + bss + heap + stack): 7168 bytes |
laserdad | 0:95d8db6b6e4d | 43 | Total Flash memory (text + data + misc): 43402 bytes |
laserdad | 0:95d8db6b6e4d | 44 | Image: .\.build\K64F\ARM\mbed-os-example-blinky.bin |
laserdad | 0:95d8db6b6e4d | 45 | ``` |
laserdad | 0:95d8db6b6e4d | 46 | |
laserdad | 0:95d8db6b6e4d | 47 | ### Program your board |
laserdad | 0:95d8db6b6e4d | 48 | |
laserdad | 0:95d8db6b6e4d | 49 | 1. Connect your mbed device to the computer over USB. |
laserdad | 0:95d8db6b6e4d | 50 | 1. Copy the binary file to the mbed device. |
laserdad | 0:95d8db6b6e4d | 51 | 1. Press the reset button to start the program. |
laserdad | 0:95d8db6b6e4d | 52 | |
laserdad | 0:95d8db6b6e4d | 53 | The LED on your platform turns on and off. |
laserdad | 0:95d8db6b6e4d | 54 | |
laserdad | 0:95d8db6b6e4d | 55 | ## Troubleshooting |
laserdad | 0:95d8db6b6e4d | 56 | |
laserdad | 0:95d8db6b6e4d | 57 | If you have problems, you can review the [documentation](https://os.mbed.com/docs/latest/tutorials/debugging.html) for suggestions on what could be wrong and how to fix it. |