├── PCB ├── IMG_0475.jpg ├── IMG_0503.JPG ├── VINDRIKTNING_board.png ├── pcb_VINDRIKTNING.fzz ├── pcb_VINDRIKTNING_bb.pdf └── pcb_VINDRIKTNING_bb.png ├── README.md ├── Vindriktning schematic_Foto 19-08-21, 14 46 02.jpg ├── datasheets ├── ES7P001_8pin.png ├── ES7P001_Datasheet_C V1.5.pdf └── PM1006_LED_PARTICLE_SENSOR_MODULE_SPECIFICATIONS.pdf ├── ikea_particulate_matter_sensor.yaml ├── studyroomaq.bin └── user info.png /PCB/IMG_0475.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/IMG_0475.jpg -------------------------------------------------------------------------------- /PCB/IMG_0503.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/IMG_0503.JPG -------------------------------------------------------------------------------- /PCB/VINDRIKTNING_board.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/VINDRIKTNING_board.png -------------------------------------------------------------------------------- /PCB/pcb_VINDRIKTNING.fzz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/pcb_VINDRIKTNING.fzz -------------------------------------------------------------------------------- /PCB/pcb_VINDRIKTNING_bb.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/pcb_VINDRIKTNING_bb.pdf -------------------------------------------------------------------------------- /PCB/pcb_VINDRIKTNING_bb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/PCB/pcb_VINDRIKTNING_bb.png -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Ikea Hack: Making the air quality sensor VINDRIKTNING smart sensor 2 | 3 | > Do you want to know more about the air you breath in your home? Check the air quality based on particles (PM2.5) with this stylish and easy-to-use sensor. 4 | > 5 | > This sensor checks the air quality by detecting particles (PM2.5) in your home.Use your own power cord and adapter to easily turn on and use the sensor. You just need to connect it to a USB-C cable and wait a few seconds.A light indicates three levels of air quality – green (good), yellow (ok), and red (not good).Recommended to combine with FÖRNUFTIG air purifier. When the air quality is not good in your home, turn on FÖRNUFTIG air purifier to enjoy a good level of indoor air quality.Place it in the living room, bedroom, or other rooms where you spend a lot of time. With its small size, you can easily move it from room to room so you can rest assured that the air quality is good.Works just as well in small and large rooms, since the air quality is usually similar throughout a room.Its small and slim design makes the sensor blend in well with your decor.USB-C cable and USB power adapter are sold separately. 6 | > Ikea Website, Article Number: 605.159.11 7 | 8 | Now you have two paths… go simple and just passively sniff sensor values and send over Wi-Fi or get a full control of device and be able to control the fan, control the led separately and make all automations like night mode or light effects. 9 | 10 | If you choose the second path you will get complete control over the device. 11 | 12 | ![Final product](/PCB/IMG_0503.JPG) 13 | 14 | More info here: [www.fabiosoft.com ](https://www.fabiosoft.com/2021/12/02/ikea-hack-making-the-air-quality-sensor-vindriktning-smart-sensor/) 15 | -------------------------------------------------------------------------------- /Vindriktning schematic_Foto 19-08-21, 14 46 02.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/Vindriktning schematic_Foto 19-08-21, 14 46 02.jpg -------------------------------------------------------------------------------- /datasheets/ES7P001_8pin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/datasheets/ES7P001_8pin.png -------------------------------------------------------------------------------- /datasheets/ES7P001_Datasheet_C V1.5.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/datasheets/ES7P001_Datasheet_C V1.5.pdf -------------------------------------------------------------------------------- /datasheets/PM1006_LED_PARTICLE_SENSOR_MODULE_SPECIFICATIONS.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/datasheets/PM1006_LED_PARTICLE_SENSOR_MODULE_SPECIFICATIONS.pdf -------------------------------------------------------------------------------- /ikea_particulate_matter_sensor.yaml: -------------------------------------------------------------------------------- 1 | # Connected it all up as listed below. 2 | # IKEA Vindriktning D1 ESP MCU pin Note 3 | # PCB +5V pad 5V 4 | # PCB GND pad GND 5 | # PCB REST pad D2 UART TX from PM1006 sensor 6 | # Fan +5V (red wire) 3V3 (DC stepdown) Fan will run constantly and quietly 7 | # Fan GND (black wire) GND 8 | # Led_G pad D5 Green LED 9 | # R3 (left side) D7 Red LED 10 | # R4 (left side) D6 Orange LED 11 | # LED_R_1 pad A0 light-sensing element (not used yet) 12 | 13 | 14 | 15 | substitutions: 16 | friendly_name: "Vindriktning AQ Sensor" 17 | webserver_port: "80" 18 | 19 | globals: 20 | - id: daytime_start_hour 21 | type: int 22 | restore_value: no 23 | initial_value: "8" 24 | - id: daytime_end_hour 25 | type: int 26 | restore_value: no 27 | initial_value: "22" 28 | - id: show_good_status # if true: show only on orange and red not green 29 | type: bool 30 | restore_value: true 31 | initial_value: "true" 32 | - id: night_mode_enabled # if true: turn off all leds during from 22 to 8h 33 | type: bool 34 | restore_value: true 35 | initial_value: "true" 36 | 37 | 38 | esphome: 39 | name: studyroomaq 40 | platform: ESP8266 41 | board: d1_mini 42 | on_boot: 43 | priority: 600 #600: This is where most sensors are set up. 30 44 | then: 45 | - light.turn_on: 46 | id: lightgreen 47 | brightness: 100% 48 | - delay: 3s 49 | - light.turn_off: 50 | id: lightgreen 51 | - light.turn_on: 52 | id: lightorange 53 | brightness: 100% 54 | - delay: 3s 55 | - light.turn_off: 56 | id: lightorange 57 | - light.turn_on: 58 | id: lightred 59 | brightness: 100% 60 | - delay: 3s 61 | - light.turn_off: 62 | id: lightred 63 | 64 | logger: 65 | api: 66 | ota: 67 | wifi: 68 | ssid: !secret wifi_ssid 69 | password: !secret wifi_password 70 | ap: {} 71 | captive_portal: 72 | time: 73 | - platform: homeassistant 74 | id: homeassistant_time 75 | 76 | #web_server: 77 | # port: $webserver_port 78 | 79 | # MQTT 80 | # mqtt: 81 | # broker: !secret mqtt_broker 82 | # discovery: false 83 | # topic_prefix: "esphome/livingroom_particulate_matter" 84 | 85 | uart: 86 | id: uart_pm1006 87 | tx_pin: D1 88 | rx_pin: D2 89 | baud_rate: 9600 90 | 91 | light: 92 | - platform: monochromatic 93 | id: lightgreen 94 | name: "Led Green" 95 | output: ledgreen 96 | - platform: monochromatic 97 | id: lightorange 98 | name: "Led Orange" 99 | output: ledorange 100 | - platform: monochromatic 101 | id: lightred 102 | name: "Led Red" 103 | output: ledred 104 | 105 | output: 106 | - platform: esp8266_pwm 107 | id: ledgreen 108 | pin: 109 | number: D5 110 | inverted: true 111 | - platform: esp8266_pwm 112 | id: ledorange 113 | pin: 114 | number: D6 115 | inverted: false 116 | - platform: esp8266_pwm 117 | id: ledred 118 | pin: 119 | number: D7 120 | inverted: true 121 | 122 | switch: 123 | - platform: restart 124 | name: "$friendly_name Restart" 125 | icon: "mdi:restart" 126 | - platform: template 127 | id: goodmode_switch # id(nightmode_switch).publish_state(false); 128 | name: "$friendly_name Good Mode" 129 | icon: "mdi:weather-night" 130 | lambda: |- 131 | return id(show_good_status); 132 | turn_on_action: 133 | then: 134 | - lambda: |- 135 | id(show_good_status) = true; 136 | turn_off_action: 137 | then: 138 | - lambda: |- 139 | id(show_good_status) = false; 140 | auto lightgreen_call = id(lightgreen).turn_off(); 141 | lightgreen_call.perform(); 142 | - platform: template 143 | id: nightmode_switch 144 | name: "$friendly_name Night Mode" 145 | icon: "mdi:weather-night" 146 | lambda: |- 147 | return id(night_mode_enabled); 148 | turn_on_action: 149 | then: 150 | - lambda: |- 151 | id(night_mode_enabled) = true; 152 | auto lightgreen_call = id(lightgreen).turn_off(); 153 | auto lightorange_call = id(lightorange).turn_off(); 154 | auto lightred_call = id(lightred).turn_off(); 155 | lightgreen_call.perform(); 156 | lightorange_call.perform(); 157 | lightred_call.perform(); 158 | turn_off_action: 159 | then: 160 | - lambda: |- 161 | id(night_mode_enabled) = false; 162 | 163 | sensor: 164 | #- platform: adc 165 | # pin: A0 166 | # name: "A0" 167 | # unit_of_measurement: lux 168 | # update_interval: 30s 169 | # filters: 170 | # - lambda: |- 171 | # return (x * 3.3 / 10000.0) * 2000000.0; 172 | 173 | - platform: pm1006 174 | uart_id: uart_pm1006 175 | update_interval: 20s 176 | pm_2_5: 177 | id: pm1006_sensor 178 | name: "$friendly_name PM1006" 179 | accuracy_decimals: 2 180 | filters: 181 | - sliding_window_moving_average: 182 | window_size: 50 183 | send_every: 10 184 | send_first_at: 1 185 | on_value: 186 | lambda: !lambda |- 187 | auto sensor_value = id(pm1006_sensor).state; // 90 188 | auto ha_time = id(homeassistant_time).now(); 189 | if (ha_time.is_valid() && (id(night_mode_enabled) || (ha_time.hour < id(daytime_start_hour) && ha_time.hour > id(daytime_start_hour))) ){ 190 | // NIGHT MODE - ALL OFF and never turn on even on red/orange 191 | auto lightgreen_call = id(lightgreen).turn_off(); 192 | auto lightorange_call = id(lightorange).turn_off(); 193 | auto lightred_call = id(lightred).turn_off(); 194 | lightgreen_call.perform(); 195 | lightorange_call.perform(); 196 | lightred_call.perform(); 197 | return; 198 | } 199 | if (sensor_value >= 0 && sensor_value <= 35 && id(show_good_status)) { 200 | //Green ON 201 | auto lightgreen_call = id(lightgreen).turn_on(); 202 | auto lightorange_call = id(lightorange).turn_off(); 203 | auto lightred_call = id(lightred).turn_off(); 204 | lightgreen_call.perform(); 205 | lightorange_call.perform(); 206 | lightred_call.perform(); 207 | } 208 | if (sensor_value >= 36 && sensor_value <= 85){ 209 | //Orange ON 210 | auto lightgreen_call = id(lightgreen).turn_off(); 211 | auto lightorange_call = id(lightorange).turn_on(); 212 | auto lightred_call = id(lightred).turn_off(); 213 | lightgreen_call.perform(); 214 | lightorange_call.perform(); 215 | lightred_call.perform(); 216 | } 217 | if (sensor_value >= 86){ 218 | //Red ON 219 | auto lightgreen_call = id(lightgreen).turn_off(); 220 | auto lightorange_call = id(lightorange).turn_off(); 221 | auto lightred_call = id(lightred).turn_on(); 222 | lightgreen_call.perform(); 223 | lightorange_call.perform(); 224 | lightred_call.perform(); 225 | } 226 | 227 | # enables the Vindriktning to be shown properly in the HA Energy Monitoring 228 | - platform: template 229 | name: "$friendly_name - Power Usage" 230 | id: power_consumption 231 | device_class: power 232 | state_class: measurement 233 | unit_of_measurement: W 234 | accuracy_decimals: 2 235 | filters: 236 | - heartbeat: 60s 237 | - platform: integration 238 | name: "$friendly_name - Consumed Energy" 239 | sensor: power_consumption 240 | time_unit: 'h' 241 | device_class: energy 242 | state_class: total_increasing 243 | unit_of_measurement: 'Wh' 244 | restore: false 245 | integration_method: left 246 | accuracy_decimals: 2 247 | 248 | interval: 249 | - interval: 1min 250 | then: 251 | - sensor.template.publish: 252 | id: power_consumption 253 | state: 0.5696 -------------------------------------------------------------------------------- /studyroomaq.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/studyroomaq.bin -------------------------------------------------------------------------------- /user info.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fabiosoft/esp8266_ikea_vindriktning/9eadd940d988e4302409f977143571db09df6e88/user info.png --------------------------------------------------------------------------------