Clone of official tools
settings.py@35:da9c89f8be7d, 2017-02-15 (annotated)
- Committer:
- The Other Jimmy
- Date:
- Wed Feb 15 13:53:18 2017 -0600
- Revision:
- 35:da9c89f8be7d
- Parent:
- 31:8ea194f6145b
- Child:
- 40:7d3fa6b99b2b
Update tools to mbed-os 5.3.5
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
screamer | 0:66f3b5499f7f | 1 | """ |
screamer | 0:66f3b5499f7f | 2 | mbed SDK |
screamer | 13:ab47a20b66f0 | 3 | Copyright (c) 2016 ARM Limited |
screamer | 13:ab47a20b66f0 | 4 | |
screamer | 0:66f3b5499f7f | 5 | Licensed under the Apache License, Version 2.0 (the "License"); |
screamer | 0:66f3b5499f7f | 6 | you may not use this file except in compliance with the License. |
screamer | 0:66f3b5499f7f | 7 | You may obtain a copy of the License at |
screamer | 13:ab47a20b66f0 | 8 | |
screamer | 13:ab47a20b66f0 | 9 | http://www.apache.org/licenses/LICENSE-2.0 |
screamer | 13:ab47a20b66f0 | 10 | |
screamer | 0:66f3b5499f7f | 11 | Unless required by applicable law or agreed to in writing, software |
screamer | 0:66f3b5499f7f | 12 | distributed under the License is distributed on an "AS IS" BASIS, |
screamer | 0:66f3b5499f7f | 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
screamer | 0:66f3b5499f7f | 14 | See the License for the specific language governing permissions and |
screamer | 0:66f3b5499f7f | 15 | limitations under the License. |
screamer | 0:66f3b5499f7f | 16 | """ |
screamer | 0:66f3b5499f7f | 17 | |
screamer | 13:ab47a20b66f0 | 18 | from os import getenv |
screamer | 13:ab47a20b66f0 | 19 | from os.path import join, abspath, dirname, exists |
screamer | 0:66f3b5499f7f | 20 | import logging |
screamer | 0:66f3b5499f7f | 21 | |
screamer | 0:66f3b5499f7f | 22 | ROOT = abspath(join(dirname(__file__), "..")) |
screamer | 0:66f3b5499f7f | 23 | |
screamer | 0:66f3b5499f7f | 24 | |
screamer | 0:66f3b5499f7f | 25 | ############################################################################## |
screamer | 13:ab47a20b66f0 | 26 | # Toolchains and Build System Settings |
screamer | 0:66f3b5499f7f | 27 | ############################################################################## |
The Other Jimmy |
31:8ea194f6145b | 28 | BUILD_DIR = abspath(join(ROOT, "BUILD")) |
screamer | 0:66f3b5499f7f | 29 | |
screamer | 13:ab47a20b66f0 | 30 | # ARM Compiler 5 |
The Other Jimmy |
35:da9c89f8be7d | 31 | ARM_PATH = "" |
screamer | 0:66f3b5499f7f | 32 | |
screamer | 0:66f3b5499f7f | 33 | # GCC ARM |
screamer | 0:66f3b5499f7f | 34 | GCC_ARM_PATH = "" |
screamer | 0:66f3b5499f7f | 35 | |
screamer | 0:66f3b5499f7f | 36 | # GCC CodeRed |
The Other Jimmy |
35:da9c89f8be7d | 37 | GCC_CR_PATH = "" |
screamer | 0:66f3b5499f7f | 38 | |
screamer | 0:66f3b5499f7f | 39 | # IAR |
The Other Jimmy |
35:da9c89f8be7d | 40 | IAR_PATH = "" |
screamer | 0:66f3b5499f7f | 41 | |
screamer | 13:ab47a20b66f0 | 42 | # Goanna static analyser. Please overload it in mbed_settings.py |
The Other Jimmy |
35:da9c89f8be7d | 43 | GOANNA_PATH = "" |
screamer | 0:66f3b5499f7f | 44 | |
screamer | 0:66f3b5499f7f | 45 | # cppcheck path (command) and output message format |
screamer | 0:66f3b5499f7f | 46 | CPPCHECK_CMD = ["cppcheck", "--enable=all"] |
screamer | 0:66f3b5499f7f | 47 | CPPCHECK_MSG_FORMAT = ["--template=[{severity}] {file}@{line}: {id}:{message}"] |
screamer | 0:66f3b5499f7f | 48 | |
screamer | 0:66f3b5499f7f | 49 | BUILD_OPTIONS = [] |
screamer | 0:66f3b5499f7f | 50 | |
screamer | 0:66f3b5499f7f | 51 | # mbed.org username |
screamer | 0:66f3b5499f7f | 52 | MBED_ORG_USER = "" |
screamer | 0:66f3b5499f7f | 53 | |
screamer | 22:9e85236d8716 | 54 | CLI_COLOR_MAP = { |
screamer | 22:9e85236d8716 | 55 | "warning": "yellow", |
screamer | 22:9e85236d8716 | 56 | "error" : "red" |
screamer | 22:9e85236d8716 | 57 | } |
screamer | 13:ab47a20b66f0 | 58 | |
screamer | 13:ab47a20b66f0 | 59 | ############################################################################## |
screamer | 13:ab47a20b66f0 | 60 | # User Settings (file) |
screamer | 13:ab47a20b66f0 | 61 | ############################################################################## |
screamer | 13:ab47a20b66f0 | 62 | try: |
screamer | 13:ab47a20b66f0 | 63 | # Allow to overwrite the default settings without the need to edit the |
screamer | 13:ab47a20b66f0 | 64 | # settings file stored in the repository |
screamer | 13:ab47a20b66f0 | 65 | from mbed_settings import * |
screamer | 13:ab47a20b66f0 | 66 | except ImportError: |
screamer | 13:ab47a20b66f0 | 67 | pass |
screamer | 13:ab47a20b66f0 | 68 | |
screamer | 13:ab47a20b66f0 | 69 | |
screamer | 13:ab47a20b66f0 | 70 | ############################################################################## |
screamer | 13:ab47a20b66f0 | 71 | # User Settings (env vars) |
screamer | 13:ab47a20b66f0 | 72 | ############################################################################## |
screamer | 13:ab47a20b66f0 | 73 | _ENV_PATHS = ['ARM_PATH', 'GCC_ARM_PATH', 'GCC_CR_PATH', 'IAR_PATH'] |
screamer | 13:ab47a20b66f0 | 74 | |
screamer | 13:ab47a20b66f0 | 75 | for _n in _ENV_PATHS: |
screamer | 13:ab47a20b66f0 | 76 | if getenv('MBED_'+_n): |
screamer | 13:ab47a20b66f0 | 77 | if exists(getenv('MBED_'+_n)): |
screamer | 13:ab47a20b66f0 | 78 | globals()[_n] = getenv('MBED_'+_n) |
screamer | 13:ab47a20b66f0 | 79 | else: |
screamer | 13:ab47a20b66f0 | 80 | print "WARNING: MBED_%s set as environment variable but doesn't exist" % _n |
screamer | 13:ab47a20b66f0 | 81 | |
screamer | 13:ab47a20b66f0 | 82 | |
screamer | 13:ab47a20b66f0 | 83 | ############################################################################## |
screamer | 0:66f3b5499f7f | 84 | # Test System Settings |
screamer | 0:66f3b5499f7f | 85 | ############################################################################## |
screamer | 0:66f3b5499f7f | 86 | SERVER_PORT = 59432 |
screamer | 0:66f3b5499f7f | 87 | SERVER_ADDRESS = "10.2.200.94" |
screamer | 0:66f3b5499f7f | 88 | LOCALHOST = "10.2.200.94" |
screamer | 0:66f3b5499f7f | 89 | |
screamer | 0:66f3b5499f7f | 90 | MUTs = { |
screamer | 0:66f3b5499f7f | 91 | "1" : {"mcu": "LPC1768", |
screamer | 0:66f3b5499f7f | 92 | "port":"COM41", "disk":'E:\\', |
screamer | 0:66f3b5499f7f | 93 | "peripherals": ["TMP102", "digital_loop", "port_loop", "analog_loop", "SD"] |
screamer | 0:66f3b5499f7f | 94 | }, |
screamer | 0:66f3b5499f7f | 95 | "2": {"mcu": "LPC11U24", |
screamer | 0:66f3b5499f7f | 96 | "port":"COM42", "disk":'F:\\', |
screamer | 0:66f3b5499f7f | 97 | "peripherals": ["TMP102", "digital_loop", "port_loop", "SD"] |
screamer | 0:66f3b5499f7f | 98 | }, |
screamer | 0:66f3b5499f7f | 99 | "3" : {"mcu": "KL25Z", |
screamer | 0:66f3b5499f7f | 100 | "port":"COM43", "disk":'G:\\', |
screamer | 0:66f3b5499f7f | 101 | "peripherals": ["TMP102", "digital_loop", "port_loop", "analog_loop", "SD"] |
screamer | 0:66f3b5499f7f | 102 | }, |
screamer | 0:66f3b5499f7f | 103 | } |