From 84da2a4dcc0a00ee02a83870990a3a27e5c1c344 Mon Sep 17 00:00:00 2001 From: Bernard Xiong Date: Mon, 3 Jun 2013 06:37:54 +0800 Subject: [PATCH] Keep flash setting when generate Keil MDK project. --- tools/keil.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/keil.py b/tools/keil.py index 723ab81c5..ef0dece3f 100644 --- a/tools/keil.py +++ b/tools/keil.py @@ -169,6 +169,11 @@ def MDK4Project(target, script): out.write(etree.tostring(root, encoding='utf-8')) out.close() + # copy uvopt file + if os.path.exists('template.uvopt'): + import shutil + shutil.copy2('template.uvopt', 'project.uvopt') + def MDKProject(target, script): template = file('template.Uv2', "rb") lines = template.readlines()