Fork of the espurna firmware for `mhsw` switches
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

463 lines
12 KiB

  1. [platformio]
  2. env_default = d1-debug
  3. src_dir = espurna
  4. data_dir = espurna/data
  5. [common]
  6. build_flags = -g -DDEBUG_PORT=Serial -DMQTT_MAX_PACKET_SIZE=400
  7. build_flags_512k = ${common.build_flags} -Wl,-Tesp8266.flash.512k0.ld
  8. build_flags_1m = ${common.build_flags} -Wl,-Tesp8266.flash.1m0.ld
  9. lib_deps =
  10. DHT sensor library
  11. Adafruit Unified Sensor
  12. https://github.com/xoseperez/Time
  13. ArduinoJson
  14. https://github.com/me-no-dev/ESPAsyncTCP#991f855
  15. https://github.com/me-no-dev/ESPAsyncWebServer#a94265d
  16. https://github.com/marvinroger/async-mqtt-client#v0.8.1
  17. PubSubClient
  18. Embedis
  19. NtpClientLib
  20. OneWire
  21. DallasTemperature
  22. Brzo I2C
  23. https://bitbucket.org/xoseperez/justwifi.git#1.1.3
  24. https://bitbucket.org/xoseperez/hlw8012.git#1.0.1
  25. https://bitbucket.org/xoseperez/fauxmoesp.git#2.1.0
  26. https://bitbucket.org/xoseperez/nofuss.git#0.2.2
  27. https://bitbucket.org/xoseperez/emonliteesp.git#0.1.2
  28. https://bitbucket.org/xoseperez/debounceevent.git#2.0.1
  29. https://github.com/xoseperez/my9291#1.0.0
  30. https://github.com/xoseperez/RemoteSwitch-arduino-library.git
  31. lib_ignore =
  32. # ------------------------------------------------------------------------------
  33. [env:d1-analog]
  34. platform = espressif8266
  35. framework = arduino
  36. board = d1_mini
  37. lib_deps = ${common.lib_deps}
  38. lib_ignore = ${common.lib_ignore}
  39. build_flags = ${common.build_flags} -DD1_MINI -DENABLE_DS18B20=1 -DDS_PIN=14 -DENABLE_ADC_VCC=0 -DMQTT_USE_ASYNC=0 -DENABLE_ANALOG=1 -DNOWSAUTH
  40. [env:d1-debug]
  41. platform = espressif8266
  42. framework = arduino
  43. board = d1_mini
  44. lib_deps = ${common.lib_deps}
  45. lib_ignore = ${common.lib_ignore}
  46. build_flags = ${common.build_flags} -DD1_RELAYSHIELD -DDEBUG_FAUXMO=Serial -DNOWSAUTH
  47. [env:d1-debug-ota]
  48. platform = espressif8266
  49. framework = arduino
  50. board = d1_mini
  51. lib_deps = ${common.lib_deps}
  52. lib_ignore = ${common.lib_ignore}
  53. build_flags = ${common.build_flags} -DD1_RELAYSHIELD -DDEBUG_FAUXMO=Serial -DNOWSAUTH
  54. upload_speed = 115200
  55. upload_port = "192.168.4.1"
  56. upload_flags = --auth=fibonacci --port 8266
  57. [env:node-debug]
  58. platform = espressif8266
  59. framework = arduino
  60. board = nodemcuv2
  61. lib_deps = ${common.lib_deps}
  62. lib_ignore = ${common.lib_ignore}
  63. build_flags = ${common.build_flags} -DNODEMCUV2 -DDEBUG_FAUXMO=Serial -DNOWSAUTH
  64. [env:node-debug-ota]
  65. platform = espressif8266
  66. framework = arduino
  67. board = nodemcuv2
  68. lib_deps = ${common.lib_deps}
  69. lib_ignore = ${common.lib_ignore}
  70. build_flags = ${common.build_flags} -DNODEMCUV2 -DDEBUG_FAUXMO=Serial -DNOWSAUTH
  71. upload_speed = 115200
  72. upload_port = "192.168.4.1"
  73. upload_flags = --auth=fibonacci --port 8266
  74. [env:espurna-debug]
  75. platform = espressif8266
  76. framework = arduino
  77. board = esp12e
  78. lib_deps = ${common.lib_deps}
  79. lib_ignore = ${common.lib_ignore}
  80. build_flags = ${common.build_flags} -DESPURNA_H
  81. [env:espurna-debug-ota]
  82. platform = espressif8266
  83. framework = arduino
  84. board = esp12e
  85. lib_deps = ${common.lib_deps}
  86. lib_ignore = ${common.lib_ignore}
  87. build_flags = ${common.build_flags} -DESPURNA_H
  88. upload_speed = 115200
  89. upload_port = "192.168.4.1"
  90. upload_flags = --auth=fibonacci --port 8266
  91. [env:sonoff-debug]
  92. platform = espressif8266
  93. framework = arduino
  94. board = esp01_1m
  95. board_flash_mode = dout
  96. lib_deps = ${common.lib_deps}
  97. lib_ignore = ${common.lib_ignore}
  98. build_flags = ${common.build_flags_1m} -DSONOFF
  99. [env:sonoff-debug-ota]
  100. platform = espressif8266
  101. framework = arduino
  102. board = esp01_1m
  103. board_flash_mode = dout
  104. lib_deps = ${common.lib_deps}
  105. lib_ignore = ${common.lib_ignore}
  106. build_flags = ${common.build_flags_1m} -DSONOFF
  107. upload_speed = 115200
  108. upload_port = "192.168.4.1"
  109. upload_flags = --auth=fibonacci --port 8266
  110. [env:sonoff-dht22-debug]
  111. platform = espressif8266
  112. framework = arduino
  113. board = esp01_1m
  114. board_flash_mode = dout
  115. lib_deps = ${common.lib_deps}
  116. lib_ignore = ${common.lib_ignore}
  117. build_flags = ${common.build_flags_1m} -DSONOFF -DENABLE_DHT=1
  118. [env:sonoff-ds18b20-debug]
  119. platform = espressif8266
  120. framework = arduino
  121. board = esp01_1m
  122. board_flash_mode = dout
  123. lib_deps = ${common.lib_deps}
  124. lib_ignore = ${common.lib_ignore}
  125. build_flags = ${common.build_flags_1m} -DSONOFF -DENABLE_DS18B20=1
  126. [env:sonoff-pow-debug]
  127. platform = espressif8266
  128. framework = arduino
  129. board = esp01_1m
  130. board_flash_mode = dout
  131. lib_deps = ${common.lib_deps}
  132. lib_ignore = ${common.lib_ignore}
  133. build_flags = ${common.build_flags_1m} -DSONOFF_POW
  134. [env:sonoff-pow-debug-ota]
  135. platform = espressif8266
  136. framework = arduino
  137. board = esp01_1m
  138. board_flash_mode = dout
  139. lib_deps = ${common.lib_deps}
  140. lib_ignore = ${common.lib_ignore}
  141. build_flags = ${common.build_flags_1m} -DSONOFF_POW
  142. upload_speed = 115200
  143. upload_port = "192.168.4.1"
  144. upload_flags = --auth=fibonacci --port 8266
  145. [env:sonoff-dual-debug]
  146. platform = espressif8266
  147. framework = arduino
  148. board = esp01_1m
  149. board_flash_mode = dout
  150. lib_deps = ${common.lib_deps}
  151. lib_ignore = ${common.lib_ignore}
  152. build_flags = ${common.build_flags_1m} -DSONOFF_DUAL
  153. [env:sonoff-dual-debug-ota]
  154. platform = espressif8266
  155. framework = arduino
  156. board = esp01_1m
  157. board_flash_mode = dout
  158. lib_deps = ${common.lib_deps}
  159. lib_ignore = ${common.lib_ignore}
  160. build_flags = ${common.build_flags_1m} -DSONOFF_DUAL
  161. upload_speed = 115200
  162. upload_port = "192.168.4.1"
  163. upload_flags = --auth=fibonacci --port 8266
  164. [env:sonoff-4ch-debug]
  165. platform = espressif8266
  166. framework = arduino
  167. board = esp8285
  168. board_flash_mode = dout
  169. lib_deps = ${common.lib_deps}
  170. lib_ignore = ${common.lib_ignore}
  171. build_flags = ${common.build_flags_1m} -DSONOFF_4CH
  172. [env:sonoff-4ch-debug-ota]
  173. platform = espressif8266
  174. framework = arduino
  175. board = esp8285
  176. board_flash_mode = dout
  177. lib_deps = ${common.lib_deps}
  178. lib_ignore = ${common.lib_ignore}
  179. build_flags = ${common.build_flags_1m} -DSONOFF_4CH
  180. upload_speed = 115200
  181. upload_port = "192.168.4.1"
  182. upload_flags = --auth=fibonacci --port 8266
  183. [env:sonoff-touch-debug]
  184. platform = espressif8266
  185. framework = arduino
  186. board = esp8285
  187. board_flash_mode = dout
  188. lib_deps = ${common.lib_deps}
  189. lib_ignore = ${common.lib_ignore}
  190. build_flags = ${common.build_flags_1m} -DSONOFF_TOUCH
  191. [env:sonoff-touch-debug-ota]
  192. platform = espressif8266
  193. framework = arduino
  194. board = esp8285
  195. board_flash_mode = dout
  196. lib_deps = ${common.lib_deps}
  197. lib_ignore = ${common.lib_ignore}
  198. build_flags = ${common.build_flags_1m} -DSONOFF_TOUCH
  199. upload_speed = 115200
  200. upload_port = "192.168.4.1"
  201. upload_flags = --auth=fibonacci --port 8266
  202. [env:slampher-debug]
  203. platform = espressif8266
  204. framework = arduino
  205. board = esp01_1m
  206. board_flash_mode = dout
  207. lib_deps = ${common.lib_deps}
  208. lib_ignore = ${common.lib_ignore}
  209. build_flags = ${common.build_flags_1m} -DSLAMPHER
  210. [env:slampher-debug-ota]
  211. platform = espressif8266
  212. framework = arduino
  213. board = esp01_1m
  214. board_flash_mode = dout
  215. lib_deps = ${common.lib_deps}
  216. lib_ignore = ${common.lib_ignore}
  217. build_flags = ${common.build_flags_1m} -DSLAMPHER
  218. upload_speed = 115200
  219. upload_port = "192.168.4.1"
  220. upload_flags = --auth=fibonacci --port 8266
  221. [env:s20-debug]
  222. platform = espressif8266
  223. framework = arduino
  224. board = esp01_1m
  225. board_flash_mode = dout
  226. lib_deps = ${common.lib_deps}
  227. lib_ignore = ${common.lib_ignore}
  228. build_flags = ${common.build_flags_1m} -DS20
  229. [env:s20-debug-ota]
  230. platform = espressif8266
  231. framework = arduino
  232. board = esp01_1m
  233. board_flash_mode = dout
  234. lib_deps = ${common.lib_deps}
  235. lib_ignore = ${common.lib_ignore}
  236. build_flags = ${common.build_flags_1m} -DS20
  237. upload_speed = 115200
  238. upload_port = "192.168.4.1"
  239. upload_flags = --auth=fibonacci --port 8266
  240. [env:1ch-inching-debug]
  241. platform = espressif8266
  242. framework = arduino
  243. board = esp01_1m
  244. board_flash_mode = dout
  245. lib_deps = ${common.lib_deps}
  246. lib_ignore = ${common.lib_ignore}
  247. build_flags = ${common.build_flags_1m} -DITEAD_1CH_INCHING
  248. [env:1ch-inching-debug-ota]
  249. platform = espressif8266
  250. framework = arduino
  251. board = esp01_1m
  252. board_flash_mode = dout
  253. lib_deps = ${common.lib_deps}
  254. lib_ignore = ${common.lib_ignore}
  255. build_flags = ${common.build_flags_1m} -DITEAD_1CH_INCHING
  256. upload_speed = 115200
  257. upload_port = "192.168.4.1"
  258. upload_flags = --auth=fibonacci --port 8266
  259. [env:motor-debug]
  260. platform = espressif8266
  261. framework = arduino
  262. board = esp01_1m
  263. board_flash_mode = dout
  264. lib_deps = ${common.lib_deps}
  265. lib_ignore = ${common.lib_ignore}
  266. build_flags = ${common.build_flags_1m} -DITEAD_MOTOR
  267. [env:motor-debug-ota]
  268. platform = espressif8266
  269. framework = arduino
  270. board = esp01_1m
  271. board_flash_mode = dout
  272. lib_deps = ${common.lib_deps}
  273. lib_ignore = ${common.lib_ignore}
  274. build_flags = ${common.build_flags_1m} -DITEAD_MOTOR
  275. upload_speed = 115200
  276. upload_port = "192.168.4.1"
  277. upload_flags = --auth=fibonacci --port 8266
  278. [env:electrodragon-debug]
  279. platform = espressif8266
  280. framework = arduino
  281. board = esp12e
  282. lib_deps = ${common.lib_deps}
  283. lib_ignore = ${common.lib_ignore}
  284. build_flags = ${common.build_flags} -DESP_RELAY_BOARD -DENABLE_DHT=1
  285. [env:electrodragon-debug-ota]
  286. platform = espressif8266
  287. framework = arduino
  288. board = esp12e
  289. lib_deps = ${common.lib_deps}
  290. lib_ignore = ${common.lib_ignore}
  291. build_flags = ${common.build_flags} -DESP_RELAY_BOARD -DENABLE_DHT=1
  292. upload_speed = 115200
  293. upload_port = "192.168.4.1"
  294. upload_flags = --auth=fibonacci --port 8266
  295. [env:ecoplug-debug]
  296. platform = espressif8266
  297. framework = arduino
  298. board = esp01_1m
  299. board_flash_mode = dout
  300. lib_deps = ${common.lib_deps}
  301. lib_ignore = ${common.lib_ignore}
  302. build_flags = ${common.build_flags_1m} -DECOPLUG
  303. [env:ecoplug-debug-ota]
  304. platform = espressif8266
  305. framework = arduino
  306. board = esp01_1m
  307. board_flash_mode = dout
  308. lib_deps = ${common.lib_deps}
  309. lib_ignore = ${common.lib_ignore}
  310. build_flags = ${common.build_flags_1m} -DECOPLUG
  311. upload_speed = 115200
  312. upload_port = "192.168.4.1"
  313. upload_flags = --auth=fibonacci --port 8266
  314. [env:jangoe-debug]
  315. platform = espressif8266
  316. framework = arduino
  317. board = esp12e
  318. lib_deps = ${common.lib_deps}
  319. lib_ignore = ${common.lib_ignore}
  320. build_flags = ${common.build_flags} -DWIFI_RELAY_NC
  321. [env:jangoe-debug-ota]
  322. platform = espressif8266
  323. framework = arduino
  324. board = esp12e
  325. lib_deps = ${common.lib_deps}
  326. lib_ignore = ${common.lib_ignore}
  327. build_flags = ${common.build_flags} -DWIFI_RELAY_NC
  328. upload_speed = 115200
  329. upload_port = "192.168.4.1"
  330. upload_flags = --auth=fibonacci --port 8266
  331. [env:mqtt-relay-debug]
  332. platform = espressif8266
  333. framework = arduino
  334. board = esp_wroom_02
  335. lib_deps = ${common.lib_deps}
  336. lib_ignore = ${common.lib_ignore}
  337. build_flags = ${common.build_flags} -DMQTT_RELAY -DENABLE_DS18B20=1
  338. [env:mqtt-relay-debug-ota]
  339. platform = espressif8266
  340. framework = arduino
  341. board = esp_wroom_02
  342. lib_deps = ${common.lib_deps}
  343. lib_ignore = ${common.lib_ignore}
  344. build_flags = ${common.build_flags} -DMQTT_RELAY -DENABLE_DS18B20=1
  345. upload_speed = 115200
  346. upload_port = "192.168.4.1"
  347. upload_flags = --auth=fibonacci --port 8266
  348. [env:wifi-relays-debug]
  349. platform = espressif8266
  350. framework = arduino
  351. board = esp01_1m
  352. lib_deps = ${common.lib_deps}
  353. lib_ignore = ${common.lib_ignore}
  354. build_flags = ${common.build_flags_1m} -DWIFI_RELAYS_BOARD_KIT
  355. [env:wifi-relays-debug-ota]
  356. platform = espressif8266
  357. framework = arduino
  358. board = esp01_1m
  359. lib_deps = ${common.lib_deps}
  360. lib_ignore = ${common.lib_ignore}
  361. build_flags = ${common.build_flags_1m} -DWIFI_RELAYS_BOARD_KIT
  362. upload_speed = 115200
  363. upload_port = "192.168.4.1"
  364. upload_flags = --auth=fibonacci --port 8266
  365. [env:ai-light-debug]
  366. platform = espressif8266
  367. framework = arduino
  368. board = esp01_1m
  369. board_flash_mode = dout
  370. lib_deps = ${common.lib_deps}
  371. lib_ignore = ${common.lib_ignore}
  372. build_flags = ${common.build_flags_1m} -DAI_LIGHT
  373. [env:ai-light-debug-ota]
  374. platform = espressif8266
  375. framework = arduino
  376. board = esp01_1m
  377. board_flash_mode = dout
  378. lib_deps = ${common.lib_deps}
  379. lib_ignore = ${common.lib_ignore}
  380. build_flags = ${common.build_flags_1m} -DAI_LIGHT
  381. upload_speed = 115200
  382. upload_port = "192.168.4.1"
  383. upload_flags = --auth=fibonacci --port 8266
  384. [env:led-controller-debug]
  385. platform = espressif8266
  386. framework = arduino
  387. board = esp01_1m
  388. lib_deps = ${common.lib_deps}
  389. lib_ignore = ${common.lib_ignore}
  390. build_flags = ${common.build_flags_1m} -DLED_CONTROLLER
  391. [env:led-controller-debug-ota]
  392. platform = espressif8266
  393. framework = arduino
  394. board = esp01_1m
  395. lib_deps = ${common.lib_deps}
  396. lib_ignore = ${common.lib_ignore}
  397. build_flags = ${common.build_flags_1m} -DLED_CONTROLLER
  398. upload_speed = 115200
  399. upload_port = "192.168.4.1"
  400. upload_flags = --auth=fibonacci --port 8266
  401. [env:h801-debug]
  402. platform = espressif8266
  403. framework = arduino
  404. board = esp01_1m
  405. board_flash_mode = dout
  406. lib_deps = ${common.lib_deps}
  407. lib_ignore = ${common.lib_ignore}
  408. build_flags = -g -Wl,-Tesp8266.flash.1m0.ld -DH801_LED_CONTROLLER -DDEBUG_PORT=Serial1
  409. [env:h801-debug-ota]
  410. platform = espressif8266
  411. framework = arduino
  412. board = esp01_1m
  413. board_flash_mode = dout
  414. lib_deps = ${common.lib_deps}
  415. lib_ignore = ${common.lib_ignore}
  416. build_flags = -g -Wl,-Tesp8266.flash.1m0.ld -DH801_LED_CONTROLLER -DDEBUG_PORT=Serial1
  417. upload_speed = 115200
  418. upload_port = "192.168.4.1"
  419. upload_flags = --auth=fibonacci --port 8266