mirror of https://github.com/ARMmbed/mbed-os.git
				
				
				
			Prevent detect_targets.py tool script from crashing on known targets
As mut['mcu'] can be "None" on unknown targets, the detect_targets script crashes when one of these boards is connected. This happens when "mbed-cli detect -vv" is ran when a STEVAL-3DP001V1 board is connected. Which does not provide a html file with a target_id, and thus cannot be looked up in the mbedls platform database. http://www.st.com/en/evaluation-tools/steval-3dp001v1.htmlpull/6000/head
							parent
							
								
									b8d218038b
								
							
						
					
					
						commit
						e7839f1cb6
					
				| 
						 | 
				
			
			@ -79,7 +79,7 @@ def main():
 | 
			
		|||
 | 
			
		||||
        count = 0
 | 
			
		||||
        for mut in muts.values():
 | 
			
		||||
            if re.match(mcu_filter, mut['mcu']):
 | 
			
		||||
            if re.match(mcu_filter, mut['mcu'] or "Unknown"):
 | 
			
		||||
                interface_version = get_interface_version(mut['disk'])
 | 
			
		||||
                print ""
 | 
			
		||||
                print "[mbed] Detected %s, port %s, mounted %s, interface version %s:" % \
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue