Tell us about yourself!

Complete Your Profile
  • EnriqueH7 made the instructable Raspberry Pi Internet Weather Station9 months ago
    Raspberry Pi Internet Weather Station

    Here the result, traducido al español ^^

    View Instructable »
  • EnriqueH7 commented on jimk3038's instructable Raspberry Pi Internet Weather Station9 months ago
    Raspberry Pi Internet Weather Station

    Hello. I made the necessary modifications to the "weather.py" file to translate it into spanish language, search fthis lines...self.day[0] = w[f][0]['day_of_week']self.day[1] = w[f][1]['day_of_week']self.day[2] = w[f][2]['day_of_week']self.day[3] = w[f][3]['day_of_week']put this following, it will translate day of the week into spanish...if ( self.day[0] == 'Monday' ): self.day[0] = 'Lunes' self.day[1] = 'Martes' self.day[2] = 'Miercoles' self.day[3] = 'Jueves' else: if ( self.day[0] == 'Tuesday' ): self.day[...

    see more »

    Hello. I made the necessary modifications to the "weather.py" file to translate it into spanish language, search fthis lines...self.day[0] = w[f][0]['day_of_week']self.day[1] = w[f][1]['day_of_week']self.day[2] = w[f][2]['day_of_week']self.day[3] = w[f][3]['day_of_week']put this following, it will translate day of the week into spanish...if ( self.day[0] == 'Monday' ): self.day[0] = 'Lunes' self.day[1] = 'Martes' self.day[2] = 'Miercoles' self.day[3] = 'Jueves' else: if ( self.day[0] == 'Tuesday' ): self.day[0] = 'Martes' self.day[1] = 'Miercoles' self.day[2] = 'Jueves' self.day[3] = 'Viernes' else: if ( self.day[0] == 'Wednesday' ): self.day[0] = 'Miercoles' self.day[1] = 'Jueves' self.day[2] = 'Viernes' self.day[3] = 'Sabado' else: if ( self.day[0] == 'Thursday' ): self.day[0] = 'Jueves' self.day[1] = 'Viernes' self.day[2] = 'Sabado' self.day[3] = 'Domingo' else: if ( self.day[0] == 'Friday' ): self.day[0] = 'Viernes' self.day[1] = 'Sabado' self.day[2] = 'Domingo' self.day[3] = 'Lunes' else: if ( self.day[0] == 'Saturday' ): self.day[0] = 'Sabado' self.day[1] = 'Domingo' self.day[2] = 'Lunes' self.day[3] = 'Martes' else: if ( self.day[0] == 'Sunday' ): self.day[0] = 'Domingo' self.day[1] = 'Lunes' self.day[2] = 'Martes' self.day[3] = 'Miercoles'self.sunrise = w[f][0]['sunrise']now with the month, search this line...sfont = pygame.font.SysFont( fn, int(ymax*sh), bold=1 )# Small Font for Secondsput this following....tm1 = time.strftime( " %I:%M", time.localtime() )# 1st parttm2 = time.strftime( "%S", time.localtime() )# 2ndtm3 = time.strftime( " %P", time.localtime() )# if (time.strftime( "%b" ) == 'Dec'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Dic'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Jan'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Ene'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Feb'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Feb'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Mar'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Mar'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Apr'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Abr'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'May'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' May'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Jun'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Jun'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Jul'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Jul'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Aug'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Ago'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Sep'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Sep'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Oct'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Oct'+tm1, True, lc ) else: if (time.strftime( "%b" ) == 'Nov'): rtm1 = font.render( self.day[0][0:3]+time.strftime( " ,%d" )+' Nov'+tm1, True, lc )(tx1,ty1) = rtm1.get_size()

    View Instructable »