ADSL sucks and NBN is available but proving to be a hassle with unit body corporate and being a renter.
Optus offer 5G wireless home broadband but only 1 Access Point is available and it locks down bridge mode.
4G wireless speeds are still fantastic compared to ADSL and comparable with NBN.
A certified device for Optus 4G is the netgear AC800S. You can pick these up for cheap on ebay and purchase a BYOD wireless plan and Optus will send you the SIM.
The challenge is to
A) Get pfSense to recognise the modem as an ethernet device, cos it won't by default.
B) Persist the Modem as an Ethernet device across reboots. If the interface isn't properly recognised pfSense will force an interface assignment configuration upon reboot. You'll be wondering why your router never reboots properly until you connect a monitor cable and look at the console.
After much messing around, here is what worked for me.
access the admin page of the AC800S device, set it to bridge mode
edit the pfSense /boot/loader.conf.local and insert: hw.usb.quirk.0="0x0846 0x68e1 0 0xffff UQ_CFG_INDEX_1"
reboot pfSense
change your WAN interface assignment to UE0
change the WAN interface to DHCP
edit the gateway (system-routing-gateways), go advanced, set 'use non local gateway'
done!
other results from google talked about putting:
Usbconfig -d 0.2 set_config 1
Sleep 60
into an earlyshellcmd, but I found this didn't work for me
This creates a 3 second timeout for WMI, which is very handy when querying hundreds of systems
This works fine in the ISE, but when using it in a scheduled task I get no result
There are lots of ways to output script errors. One way I like is to add a line to output the error object to a powershell xml file into my scheduled script.
My google-fu doesn't reveal much information about this on the interwebs.
Turns out you need to run the scheduled task with highest privilages. Then it is happy
Turning old kindles into internet data weather displays.
Using RF temperature sensors on a Raspberry Pi and displaying the data on a Pi served web page or simple LCD display.
Combining these two projects seemed like a great project idea to learn about the Pi and electronics. I haven't seen this particular combination published on the web yet.
To explain what the kindle display shows:
'House Temperature Sensor' Section:
Inside temperature as measured by a DHT22 sensor attached to the Pi
Outside temperature as measured by a remote RF temperature sensor.
'Local Weather Forecast' - API call to weatherunderground.com to show 7 day descriptive forecast and graphs of local temperature, wind, cloud cover, and rain chance.
Or to put it in a more visio kinda way:
Full tutorials take a lot of time to write, plus it's no fun following cut and paste steps. The real fun of tinkering is reading stuff, trying stuff and adapting it to your own needs. So here are some basic tips and pointers for anyone interested.
Hardware
1) Raspberry Pi.
I got a version 3. There is a slight hack to get the Uart pins working the same way as the Pi2 as the slice of radio expects.
sudo nano /boot/config.txt
and add
# Change device tree to enable slice of radio
dtoverlay=pi3-miniuart-bt
(Thanks goes to this site )
2) RF receiver (Slice of Radio) and remote temperature sensor
Any local temperature sensor would work. I got a Adafruit DHT22 but lots of others would do the same thing. You could also buy another RF remote sensor and just use that indoors too.
SQLite database
There's tons of tutorials and info and how to create databases and use insert and select statements.
The only things I would add is
1)
use 'detect_types=sqlite3.PARSE_DECLTYPES' in your sqlite3.connect command. This makes python convert the millisecond values directly into python datetime objects.
e.g. "conn = sqlite3.connect('/home/pi/yourDB.sqlite',detect_types=sqlite3.PARSE_DECLTYPES)"
2)
install iceweasel on your pi (which is firefox) and add the addon SQLiteManager. Managing your DB just got a whole lot easier.
Saving sensor data to a SQLite database
The adafruit local sensor comes with its own library and examples. Create a cronjob for every 5 minutes to poll the sensor and insert it into the database.
The Slice of Radio works differently in that a bash script needs to be running all the time to capture incoming serial messages. Again use the example code provided with it and modify it to insert the data into the DB.
Setting up the Apache webserver and CGI scripts
This website is a great resource for CGI scripts, SQLite and Apache.
He also has a excellent full tutorial on reading temperature sensors and displaying this via a google charts webpage. I ended up using flot charts in my project as they have the shading capability which I use to denote night times.
Flot charts
This site is a great tutorial on logging temperature sensors to a Pi database and then displaying this via a webpage using flot charts. Especially useful is his code to create shaded areas on the graph to denote weekends, I adapted this code to denote nightime areas on my graphs.
Converting the webpage to PNG
The kindle needs a small PNG file to display, it can't show a webpage.
wkhtmltoimage with a javascript delay of 2000ms will create your PNG file
pngcrush will compress the file to a size agreeable with the kindle.
Kindle
This site will give you all you need to know about hacking the kindle.
Jailbreak
Install KUAL - this give you a nice menu where you can disable your screensaver and turn on usbnet
Install USBnet - this allows you to access the kindle over putty. Your read about some kindles not needing this but do it anyway, my kindle technically didn't need it but I had problems running cron without connecting via usbnet.
setup a cron job to call your bash script every 5 minutes (more on this script below)
Some tutorials out there setup much more (e.g. functionality for enabling/disabling the cron job) but I didn't bother with that.
Weather display script
This site is one of the first internet resources on create a kindle weather display using internet forecast data.
I used his display-weather.sh bash script. This is the file that is executed by the cron job on the kindle. The commands fetches the PNG file served from the Pi and display it on the kindle.
Internet Weather Forecast
Weather Underground provide free access to weather forecast via API calls and JSON responses.
Using a slice of radio RF transmitter will take over the GPIO pins on your raspberry pi.
Sometimes you want your leftover GPIO pins back so you can use them for other things. (e.g. a DHT22 temperature sensor in this picture below)
A slice of radio only needs Tx, Rx, 3+ and GND.
You can cobble your slice of radio on a 26 pin cobbler and then put this on a breadboard.
I had the unfortunate surprise that the breadboard for my 40 pin cobbler and the 28 pin cobbler are slightly different dot alignment for the power and ground rails. So I had to daisy chain them together with one on top of the other