This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# ---------------------------------------------------------------------------- | |
# BoatMonitor Version 1.0 May 2017 | |
# This is a Python 2.7.9 script for sending data from | |
# from a Raspberry Pi 3 and an interface board. | |
# It reports on various parameters | |
# on a boat under these conditions which are checked every 5min: | |
# 1. if shore power is off | |
# 2. if batteries are below 12vdc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <WiFi.h> | |
#include <HTTPClient.h> | |
#include "DHT.h" | |
#define DHTPIN 4 // Digital pin connected to the DHT sensor | |
#define DHTTYPE DHT22 | |
DHT dht(DHTPIN, DHTTYPE); | |
//-------- User Settings ----------- | |
const char* ssid = "SSID"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import board | |
import busio | |
import adafruit_bme280 | |
from ISStreamer.Streamer import Streamer | |
# Create library object using our Bus I2C port | |
i2c = busio.I2C(board.SCL, board.SDA) | |
bme280 = adafruit_bme280.Adafruit_BME280_I2C(i2c) | |
NewerOlder