예제 #1
0
		hostname = find_ip_addr('eth0')
		set_tamper_trigger(tamper_flag)
##############INIT END##############
		get_log_cm().info('Start FCC Test')
		get_log_cm().info('Test :\n UART, Ethernet, USB, SmartCard')

		while run:
			#Total Test Cycles
			#get_log_cm().info( "\n")
			total_count+=1
			get_log_cm().debug( "Total Test Cycles = %d", total_count)

			#Ethernet Test:###########################################################
			###Find HCR-4 IP Address####
			if hostname != -1:
				ret = can_addr_ping(hostname)
				if ret == True:
					ethernet_count+=1

			get_log_cm().info( "Ethernet Count = \t\t%d of %d", ethernet_count, total_count)
			#Ethernet Test end:#######################################################

			#UART:####################################################################
			ret = uart_self_test()
			if ret == False:
				uart_count += 1
			get_log_cm().info( "UART Count = \t\t\t%d of %d", uart_count, total_count)
			#UART end:################################################################

			#USB:####################################################################
예제 #2
0
        hostname = find_ip_addr('eth0')
        set_tamper_trigger(tamper_flag)
        ##############INIT END##############
        get_log_cm().info('Start FCC Test')
        get_log_cm().info('Test :\n UART, Ethernet, USB, SmartCard')

        while run:
            #Total Test Cycles
            #get_log_cm().info( "\n")
            total_count += 1
            get_log_cm().debug("Total Test Cycles = %d", total_count)

            #Ethernet Test:###########################################################
            ###Find HCR-4 IP Address####
            if hostname != -1:
                ret = can_addr_ping(hostname)
                if ret == True:
                    ethernet_count += 1

            get_log_cm().info("Ethernet Count = \t\t%d of %d", ethernet_count,
                              total_count)
            #Ethernet Test end:#######################################################

            #UART:####################################################################
            ret = uart_self_test()
            if ret == False:
                uart_count += 1
            get_log_cm().info("UART Count = \t\t\t%d of %d", uart_count,
                              total_count)
            #UART end:################################################################