meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
groups:mg:temperature_pressure_and_humidity_monitoring [2024/03/20 09:35] – Admin: Syntax-Update (Migration from deprecated "fontcolor" plugin to "color" plugin) klausgroups:mg:temperature_pressure_and_humidity_monitoring [2024/03/20 09:37] (current) – Admin: Syntax-Update (Migration from deprecated "fontcolor" plugin to "color" plugin) klaus
Line 57: Line 57:
  
 <blockquote> <blockquote>
-<color #008000>//#!/usr/bin/python3//</fc>+<color #008000>//#!/usr/bin/python3//</color>
  
-**<color #008000>import</fc> <color #6495ed>board</fc> \\ +**<color #008000>import</color> <color #6495ed>board</color> \\ 
-<color #008000>import</fc> <color #6495ed>busio</fc> \\ +<color #008000>import</color> <color #6495ed>busio</color> \\ 
-<color #008000>import</fc><color #6495ed> adafruit_bmp280</fc>**+<color #008000>import</color><color #6495ed> adafruit_bmp280</color>**
  
 i2c = busio.I2C(board.SCL, board.SDA)\\ i2c = busio.I2C(board.SCL, board.SDA)\\
 bmp280 = adafruit_bmp280.Adafruit_BMP280_I2C(i2c, address=0x76) bmp280 = adafruit_bmp280.Adafruit_BMP280_I2C(i2c, address=0x76)
  
-<color #008000>print</fc>(<color #ff0000>"Temperature: %0.1f C"</fc> % bmp280.temperature)\\ +<color #008000>print</color>(<color #ff0000>"Temperature: %0.1f C"</color> % bmp280.temperature)\\ 
-<color #008000>print</fc>(<color #ff0000>"Pressure: %0.1f hPa"</fc> % bmp280.pressure)+<color #008000>print</color>(<color #ff0000>"Pressure: %0.1f hPa"</color> % bmp280.pressure)
 </blockquote> </blockquote>