def usb_test(): # print "Starting USB test" for x in range(1, 51): ip_to_ping = "192.168.0." + str(x + 100) if (check_connectivity(ip_to_ping) == True): mount_usb = "adb -s alt" + str( x ) + ":4321 shell mount -t vfat /dev/block/sda1 /mnt/sdcard > /dev/null" connect_alt = "adb connect alt" + str(x) + ":4321 > /dev/null" alt_root = "adb -s alt" + str(x) + ":4321 root > /dev/null" os.system(connect_alt) time.sleep(2) os.system(alt_root) time.sleep(2) os.system(connect_alt) time.sleep(2) os.system(mount_usb) time.sleep(2) mount_sp = subprocess.Popen([ 'adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'mount', '-t', 'vfat', '/dev/block/sda1', '/mnt/sdcard' ], stdout=subprocess.PIPE) output = mount_sp.communicate()[0] if not "busy" in output: print "Failed to mount USB drive on ALT%d at %s" % ( x, str(datetime.now())) thermal_chamber.status()
def temp_test(): # print "Starting Core Temp test" for x in range(1,51): ip_to_ping="192.168.0."+str(x+100) if(check_connectivity(ip_to_ping) == True): get_temp = subprocess.Popen(['adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'cat', '/sys/devices/platform/omap/omap_temp_sensor.0/temp1_input'], stdout=subprocess.PIPE) output = get_temp.communicate()[0] output = int(output) if output > 95000: print "Core temperature is %d on ALT%d at %s" % (output/1000, x, str(datetime.now())) thermal_chamber.status()
def wifi_test(): # print "Starting Wifi test" for x in range(1,51): ip_to_ping="192.168.0."+str(x+100) if(check_connectivity(ip_to_ping) == True): scan = "adb -s alt" + str(x) + ':4321 shell "wpa_cli scan" > /dev/null' os.system(scan) time.sleep(3) scan_res = subprocess.Popen(['adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'wpa_cli', 'scan_results'], stdout=subprocess.PIPE) output = scan_res.communicate()[0] # print output if not "GoogleGuest" in output: print "Wifi issues on ALT%d at %s" % (x, str(datetime.now())) thermal_chamber.status()
def temp_test(): # print "Starting Core Temp test" for x in range(1, 51): ip_to_ping = "192.168.0." + str(x + 100) if (check_connectivity(ip_to_ping) == True): get_temp = subprocess.Popen([ 'adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'cat', '/sys/devices/platform/omap/omap_temp_sensor.0/temp1_input' ], stdout=subprocess.PIPE) output = get_temp.communicate()[0] output = int(output) if output > 95000: print "Core temperature is %d on ALT%d at %s" % ( output / 1000, x, str(datetime.now())) thermal_chamber.status()
def wifi_test(): # print "Starting Wifi test" for x in range(1, 51): ip_to_ping = "192.168.0." + str(x + 100) if (check_connectivity(ip_to_ping) == True): scan = "adb -s alt" + str( x) + ':4321 shell "wpa_cli scan" > /dev/null' os.system(scan) time.sleep(3) scan_res = subprocess.Popen([ 'adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'wpa_cli', 'scan_results' ], stdout=subprocess.PIPE) output = scan_res.communicate()[0] # print output if not "GoogleGuest" in output: print "Wifi issues on ALT%d at %s" % (x, str(datetime.now())) thermal_chamber.status()
def usb_test(): # print "Starting USB test" for x in range(1,51): ip_to_ping="192.168.0."+str(x+100) if(check_connectivity(ip_to_ping) == True): mount_usb = "adb -s alt" + str(x) + ":4321 shell mount -t vfat /dev/block/sda1 /mnt/sdcard > /dev/null" connect_alt = "adb connect alt" + str(x) + ":4321 > /dev/null" alt_root = "adb -s alt" + str(x) + ":4321 root > /dev/null" os.system(connect_alt) time.sleep(2) os.system(alt_root) time.sleep(2) os.system(connect_alt) time.sleep(2) os.system(mount_usb) time.sleep(2) mount_sp = subprocess.Popen(['adb', '-s', 'alt' + str(x) + ':4321', 'shell', 'mount', '-t', 'vfat', '/dev/block/sda1', '/mnt/sdcard'], stdout=subprocess.PIPE) output = mount_sp.communicate()[0] if not "busy" in output: print "Failed to mount USB drive on ALT%d at %s" % (x, str(datetime.now())) thermal_chamber.status()
cycles = 4 #while True: for x in range(1, 4): # Start a timer so that we get an accurate loop time start = time.time() # Setup elapsed timer elapsed = 0 # Increment iteration count += 1 # Notify of iteration count print "Starting iteration %d at %s" % (count, str(datetime.now())) thermal_chamber.status() # Start power supply print "Units powered on at %s" % str(datetime.now()) wrly = urllib.urlopen(BASE_STATE_URL + "1") # Sleep for 2 minutes to let everyone come up time.sleep(120) # Start dhrystone on ALT units dhrystone_start() # Start HDMI tests #print "Starting HDMI test" hdmi_sw_matrix.hdmi_test()
cycles = 4 #while True: for x in range(1,4): # Start a timer so that we get an accurate loop time start = time.time() # Setup elapsed timer elapsed = 0 # Increment iteration count += 1 # Notify of iteration count print "Starting iteration %d at %s" % (count, str(datetime.now())) thermal_chamber.status() # Start power supply print "Units powered on at %s" % str(datetime.now()) wrly = urllib.urlopen(BASE_STATE_URL + "1") # Sleep for 2 minutes to let everyone come up time.sleep(120) # Start dhrystone on ALT units dhrystone_start() # Start HDMI tests #print "Starting HDMI test" hdmi_sw_matrix.hdmi_test()