5.2.1 - Updated I2C files
Dependents: mbed-TFT-example-NCS36510 mbed-Accelerometer-example-NCS36510 mbed-Accelerometer-example-NCS36510
cmsis/TOOLCHAIN_IAR/cmain.S@1:f30bdcd2b33b, 2017-02-27 (annotated)
- Committer:
- jacobjohnson
- Date:
- Mon Feb 27 17:45:05 2017 +0000
- Revision:
- 1:f30bdcd2b33b
- Parent:
- 0:098463de4c5d
changed the inputscale from 1 to 7 in analogin_api.c. This will need to be changed later, and accessed from the main level, but for now this allows the adc to read a value from 0 to 3.7V, instead of just up to 1V.;
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
group-onsemi | 0:098463de4c5d | 1 | /************************************************** |
group-onsemi | 0:098463de4c5d | 2 | * |
group-onsemi | 0:098463de4c5d | 3 | * Part two of the system initialization code, contains C-level |
group-onsemi | 0:098463de4c5d | 4 | * initialization, thumb-2 only variant. |
group-onsemi | 0:098463de4c5d | 5 | * |
group-onsemi | 0:098463de4c5d | 6 | * Copyright 2006 IAR Systems. All rights reserved. |
group-onsemi | 0:098463de4c5d | 7 | * |
group-onsemi | 0:098463de4c5d | 8 | * $Revision: 59783 $ |
group-onsemi | 0:098463de4c5d | 9 | * |
group-onsemi | 0:098463de4c5d | 10 | **************************************************/ |
group-onsemi | 0:098463de4c5d | 11 | |
group-onsemi | 0:098463de4c5d | 12 | |
group-onsemi | 0:098463de4c5d | 13 | ; -------------------------------------------------- |
group-onsemi | 0:098463de4c5d | 14 | ; Module ?cmain, C-level initialization. |
group-onsemi | 0:098463de4c5d | 15 | ; |
group-onsemi | 0:098463de4c5d | 16 | |
group-onsemi | 0:098463de4c5d | 17 | |
group-onsemi | 0:098463de4c5d | 18 | SECTION SHT$$PREINIT_ARRAY:CONST:NOROOT(2) |
group-onsemi | 0:098463de4c5d | 19 | SECTION SHT$$INIT_ARRAY:CONST:NOROOT(2) |
group-onsemi | 0:098463de4c5d | 20 | |
group-onsemi | 0:098463de4c5d | 21 | SECTION .text:CODE:NOROOT(2) |
group-onsemi | 0:098463de4c5d | 22 | |
group-onsemi | 0:098463de4c5d | 23 | PUBLIC __cmain |
group-onsemi | 0:098463de4c5d | 24 | ;; Keep ?main for legacy reasons, it is accessed in countless instances of cstartup.s around the world... |
group-onsemi | 0:098463de4c5d | 25 | PUBLIC ?main |
group-onsemi | 0:098463de4c5d | 26 | EXTWEAK __iar_data_init3 |
group-onsemi | 0:098463de4c5d | 27 | EXTWEAK __iar_argc_argv |
group-onsemi | 0:098463de4c5d | 28 | EXTERN __low_level_init |
group-onsemi | 0:098463de4c5d | 29 | EXTERN __call_ctors |
group-onsemi | 0:098463de4c5d | 30 | EXTERN main |
group-onsemi | 0:098463de4c5d | 31 | EXTERN exit |
group-onsemi | 0:098463de4c5d | 32 | EXTERN __iar_dynamic_initialization |
group-onsemi | 0:098463de4c5d | 33 | EXTERN mbed_sdk_init |
group-onsemi | 0:098463de4c5d | 34 | EXTERN SystemInit |
group-onsemi | 0:098463de4c5d | 35 | |
group-onsemi | 0:098463de4c5d | 36 | THUMB |
group-onsemi | 0:098463de4c5d | 37 | __cmain: |
group-onsemi | 0:098463de4c5d | 38 | ?main: |
group-onsemi | 0:098463de4c5d | 39 | |
group-onsemi | 0:098463de4c5d | 40 | ; Initialize segments. |
group-onsemi | 0:098463de4c5d | 41 | ; __segment_init and __low_level_init are assumed to use the same |
group-onsemi | 0:098463de4c5d | 42 | ; instruction set and to be reachable by BL from the ICODE segment |
group-onsemi | 0:098463de4c5d | 43 | ; (it is safest to link them in segment ICODE). |
group-onsemi | 0:098463de4c5d | 44 | |
group-onsemi | 0:098463de4c5d | 45 | FUNCALL __cmain, __low_level_init |
group-onsemi | 0:098463de4c5d | 46 | bl __low_level_init |
group-onsemi | 0:098463de4c5d | 47 | cmp r0,#0 |
group-onsemi | 0:098463de4c5d | 48 | beq ?l1 |
group-onsemi | 0:098463de4c5d | 49 | FUNCALL __cmain, __iar_data_init3 |
group-onsemi | 0:098463de4c5d | 50 | bl __iar_data_init3 |
group-onsemi | 0:098463de4c5d | 51 | MOVS r0,#0 ; No parameters |
group-onsemi | 0:098463de4c5d | 52 | FUNCALL __cmain, mbed_sdk_init |
group-onsemi | 0:098463de4c5d | 53 | BL mbed_sdk_init |
group-onsemi | 0:098463de4c5d | 54 | MOVS r0,#0 ; No parameters |
group-onsemi | 0:098463de4c5d | 55 | FUNCALL __cmain, __iar_dynamic_initialization |
group-onsemi | 0:098463de4c5d | 56 | BL __iar_dynamic_initialization ; C++ dynamic initialization |
group-onsemi | 0:098463de4c5d | 57 | |
group-onsemi | 0:098463de4c5d | 58 | ?l1: |
group-onsemi | 0:098463de4c5d | 59 | REQUIRE ?l3 |
group-onsemi | 0:098463de4c5d | 60 | |
group-onsemi | 0:098463de4c5d | 61 | SECTION .text:CODE:NOROOT(2) |
group-onsemi | 0:098463de4c5d | 62 | |
group-onsemi | 0:098463de4c5d | 63 | PUBLIC _main |
group-onsemi | 0:098463de4c5d | 64 | PUBLIC _call_main |
group-onsemi | 0:098463de4c5d | 65 | THUMB |
group-onsemi | 0:098463de4c5d | 66 | |
group-onsemi | 0:098463de4c5d | 67 | __iar_init$$done: ; Copy initialization is done |
group-onsemi | 0:098463de4c5d | 68 | |
group-onsemi | 0:098463de4c5d | 69 | ?l3: |
group-onsemi | 0:098463de4c5d | 70 | _call_main: |
group-onsemi | 0:098463de4c5d | 71 | MOVS r0,#0 ; No parameters |
group-onsemi | 0:098463de4c5d | 72 | FUNCALL __cmain, __iar_argc_argv |
group-onsemi | 0:098463de4c5d | 73 | BL __iar_argc_argv ; Maybe setup command line |
group-onsemi | 0:098463de4c5d | 74 | |
group-onsemi | 0:098463de4c5d | 75 | FUNCALL __cmain, main |
group-onsemi | 0:098463de4c5d | 76 | BL main |
group-onsemi | 0:098463de4c5d | 77 | _main: |
group-onsemi | 0:098463de4c5d | 78 | FUNCALL __cmain, exit |
group-onsemi | 0:098463de4c5d | 79 | BL exit |
group-onsemi | 0:098463de4c5d | 80 | |
group-onsemi | 0:098463de4c5d | 81 | END |