Showing posts with label python. Show all posts
Showing posts with label python. Show all posts

Thursday, 13 October 2016

Easy steam scraping with BeautifulSoup


I wanted to make a sensor for my steam account to use for future projects. After some googling i found BeautifulSoup. I framework to search with in text/html and xml. After some fiddling i got it working. To get steam working you need a working public profile page.

Install BeautifulSoup

sudo apg-get update -y && sudo atp-get upgrade -y && sudo apt-get install python-bs4 -y

Steam scraper

Will return blank if Im not playing anything or the name of the game if im playing.

Referance
https://www.crummy.com/software/BeautifulSoup/bs4/doc/

Monday, 10 October 2016

Smartify a simple heater


I needed to make a controller for my cheap and simple heater. It don't have any termostat and the setting are really strange and I could not find the correct settings, either too hot or too cold. I connected a 433 sender to a raspberry pi and made a flask web API. I then added a switch in Home Assistant that run a curl command to the other pi.

Hardware

Parts

Wiring

  • VCC -> pin 1 3,3Volt
  • Gnd -> pin 6 Gnd
  • Date/Data/signdal -> GPIO 17 (pin11)

Software


Flask code

 

Homeassistant


Referances