def config(self): logging.info( '------deliver task configuration to runner config_file------') config = Getconfig(self.config_file) config.setValue('test_type', 'demo') config.setValue('app', self.casename) config.setValue('build_and_run', 'no') config.setValue('build', 'no') config.setValue('run', 'yes') config.setValue('platform', self.platform) config.setValue('IDE', self.compiler) config.setValue('debugger', self.debugger) config.setValue('target', self.target_mode) config.setValue(self.compiler, self.compiler_dir) config.setValue(self.software_debugger, self.software_debugger_dir) config.setValue('app_info', 'no') config.setValue('pre_configure', 'no') config.setValue('build_lib', 'no') config.setValue('psdk_demo_dir', self.repo_dir) config.setValue('binary', self.local_bin) config.setAttr(self.platform, 'serial_port', self.serial_port) config.setAttr(self.platform, 'device_type', self.device_type) config.setAttr(self.platform, 'debug_port', self.debug_port) try: config.setValue(self.debugger, self.hardware_debugger_dir) except Exception, e: pass
def config(self): logging.info('------1, Deliver Task Configuration to Builder Config_file------') try: config = Getconfig(self.config_file) config.setValue('test_type','usb') config.setValue('requestid',str(self.campaign_id)) config.setValue('app',self.casename) config.setValue('build','yes') config.setValue('run','no') config.setValue('build_and_run','no') config.setValue('platform',self.platform) config.setValue('IDE',self.compiler) config.setValue('target',self.target_mode) config.setValue(self.compiler,self.compiler_dir) config.setAttr(self.compiler,'version',self.compiler_version) # deliver mingw path by force(for use of gcc_arm) config.setValue('mingw',self.mingw_dir) config.setValue('psdk_demo_dir',self.repo_dir) # app_info/pre_configure/build_lib enable (app_info_done,pre_configure_done,build_lib_done)= GetEnvInfo_demo(self.tool_dir,self.campaign_id,self.platform,self.compiler,self.target_mode) if app_info_done: config.setValue('app_info','no') else: config.setValue('app_info','yes') if pre_configure_done: config.setValue('pre_configure','no') else: config.setValue('pre_configure','yes') if build_lib_done: config.setValue('build_lib','no') else: config.setValue('build_lib','yes') except Exception,e: return 1
def config(self): logging.info('------deliver task configuration to runner config_file------') config = Getconfig(self.config_file) config.setValue('test_type','unit_test') config.setValue('app',self.casename) config.setValue('build_and_run','no') config.setValue('build','no') config.setValue('run','yes') config.setValue('platform',self.platform) config.setValue('IDE',self.compiler) config.setValue('debugger',self.debugger) config.setValue('target',self.target_mode) config.setValue(self.compiler,self.compiler_dir) config.setValue(self.software_debugger,self.software_debugger_dir) config.setValue('app_info','no') config.setValue('pre_configure','no') config.setValue('build_lib','no') config.setValue('psdk_demo_dir',self.repo_dir) config.setValue('binary',self.local_bin) config.setAttr(self.platform,'serial_port',self.serial_port) config.setAttr(self.platform,'device_type',self.device_type) config.setAttr(self.platform,'debug_port',self.debug_port) try: config.setValue(self.debugger,self.hardware_debugger_dir) except Exception,e: pass
def config(self): logging.info( '------1, Deliver Task Configuration to Builder Config_file------') try: config = Getconfig(self.config_file) config.setValue('test_type', 'demo') config.setValue('requestid', str(self.campaign_id)) config.setValue('app', self.casename) config.setValue('build', 'yes') config.setValue('run', 'no') config.setValue('build_and_run', 'no') config.setValue('platform', self.platform) config.setValue('IDE', self.compiler) config.setValue('target', self.target_mode) config.setValue(self.compiler, self.compiler_dir) config.setAttr(self.compiler, 'version', self.compiler_version) # deliver mingw path by force(for use of gcc_arm) config.setValue('mingw', self.mingw_dir) config.setValue('psdk_demo_dir', self.repo_dir) # app_info/pre_configure/build_lib enable (app_info_done, pre_configure_done, build_lib_done) = GetEnvInfo_demo(self.tool_dir, self.campaign_id, self.platform, self.compiler, self.target_mode) if app_info_done: config.setValue('app_info', 'no') else: config.setValue('app_info', 'yes') if pre_configure_done: config.setValue('pre_configure', 'no') else: config.setValue('pre_configure', 'yes') if build_lib_done: config.setValue('build_lib', 'no') else: config.setValue('build_lib', 'yes') except Exception, e: return 1
config.setValue('pre_configure','no') config.setValue('app_info','yes') if demo!='': config.setValue('psdk_demo_dir',demo) if iar!='': config.setValue('iar',iar) if gcc_arm!='': config.setValue('gcc_arm',gcc_arm) try: if uv4!='': config.setValue('uv4',uv4) if cw10!='': config.setValue('cw10',cw10) except Exception,e: pass if platform!='' and device_type!='' and debug_port!='': config.setAttr(platform,'serial_port',serial) config.setAttr(platform,'device_type',device_type) config.setAttr(platform,'debug_port',debug_port) def senior_process(build_lib,build,build_and_run,run,app): config.setValue('build_lib',build_lib) config.setValue('build',build) config.setValue('build_and_run',build_and_run) config.setValue('run',run) config.setValue('app',app)