コード例 #1
0
class WeatherStation():

	def __init__(self):
		self.camera = CameraFeatures()

	def check_camera_motion(self):
		# return self.camera.detect_motion()
		return self.camera.detect_face()

	def get_weather_conditions(self):
		if self.check_camera_motion():
			weather = WeatherApi()
			response = weather.return_formatted_weather(5, HOURLY)

			print response
コード例 #2
0
	def __init__(self):
		self.camera = CameraFeatures()