Category Archives: Raspberry Pi

Burnt VPN Pi (VPN Hotspot on Raspberry Pi)

Warning: I found this in my drafts and I think it was mostly done.  Enough where I can follow it again.  You might have issues following it word for word though until I can recheck and remove this warning.

Purpose

The purpose of this project is to create an environment where we can use two Raspberry Pi’s to create a temporary VPN tunnel, where the client Pi also has an AP hotspot that routes all traffic through the VPN tunnel.  This is good for those people who are going to countries that have different policies than your current country.  Some of the uses I’ve used it for:

  • Watching Netflix while in another country so that I can view my home countries content
  • Getting around country firewalls that block applications such as Facebook, twitter, Instagram, etc
  • Connecting back to a trusted network when I am in a spot where the network is known to be monitored and trying to steal data.

Install the Required Software

Install the following packages:

apt-get update
apt-get upgrade
rpi-update
apt-get install openvpn hostapd resolvconf dnsmasq cryptsetup libnet-ifconfig-wrapper-perl cryptsetup

Now disable some of the software from starting up, as we will be having these pieces start up triggered by future events such as eth0 up and openvpn up:

update-rc.d openvpn disable
update-rc.d hostapd disable
update-rc.d dnsmasq disable

Load modules

Read more »

Controlling a RGB LED attached to a Raspberry Pi through Android

This was a bit of a project that I used to learn some new technology.  Note: I am not an EE and I am just learning how to do this.  Proceed with caution if you want to repeat.

Project Description

I need to be able to control turning on and off an RGB LED utilizing the Raspberry Pi.  I also should be able to turn it on and off using an Android device.

Design

The design is made up to utilize three different components: Raspberry Pi / LED Hardware, Web Service, and Android device.

Raspberry Pi

All the gear that was used was:

  • Raspberry Pi – Model B
  • 5mm High Brightness Full-Color LED
  • Breadboard
  • Resistors
  • 3 x Transistors – 2N3904

Some of the constraints I also have to work with are:

  • Each of the 3.3V GPIO pins can handle a maximum current of 16mA.  They might be able to do more, but from what I read, it would not be for long.
  • The Pi takes about 700mA of the total power without anything plugged in (USB, HDMI, etc), so depending on the power adapter used, there might not be enough power.  In this case, I used a 2A plug.
  • Since each color will require more than 16mA of power to turn on, I need to utilize transistors and the 5V pin from the Pi.  I will use the GPIO to handle closing the circuit on an NPN transistor.  I believe I need to use NPN due to the fact that the LED has a common anode.

Read more »