Advertisement
ToinasMaker

Untitled

Oct 5th, 2018
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.79 KB | None | 0 0
  1. df_list = df_latest.values.tolist()
  2.  
  3. if len(df_list) >> 0:
  4.     for row in range(len(df_list)):
  5.         #print df_list[row]
  6.         if ('#IMEC18 spy' in str(df_list[row])):
  7.             imageToDisplay= Image_Setup("spy")
  8.             print ("show spy")
  9.         if ('#IMEC18 kaboom' in str(df_list[row])):
  10.             imageToDisplay= Image_Setup("kaboom")
  11.             print("show kaboom")
  12.         if ('#IMEC18 drop' in str(df_list[row])):
  13.             imageToDisplay= Image_Setup("dropin")
  14.             print("show dropin")
  15.         if ('#IMEC18 sneaky' in str(df_list[row])):
  16.             imageToDisplay= Image_Setup("sneaky")
  17.             print("show sneaky")
  18.  
  19. def Image_Setup(imageString):
  20.     """device = Adafruit_NeoPixel(256)     
  21.     device.setBrightness(0.01)"""
  22.     intel_blue=[0,0,255]
  23.     black=[0,0,0]
  24.     white=[255,255,255]
  25.     red=[255,0,0]
  26.    
  27.     image = Translate_Image(imageString)
  28.    
  29.     return image
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement