05 Dec

UPDATE TO: USB Automount Script for Raspberry Pi

Here an update to USB Automount Script for Raspberry Pi after some tests and some comments. The script now supports multiple partitions and those without labels.

You can download it here mount_manager (438 downloads) or checkout the code below. I also updated the original post.

regex='(/dev/sd[a-z][0-9]): (LABEL=\"([A-Za-z0-9_\-]+)\")?.*UUID=\"([a-zA-Z0-9\-]+)\".*TYPE=\"([a-zA-Z0-9]+)\"'
while IFS= read -r line; do
        if [[ $line =~ $regex ]];then
                name="${BASH_REMATCH[1]}"
                label="${BASH_REMATCH[3]}"
                uuid="${BASH_REMATCH[4]}"
                type="${BASH_REMATCH[5]}"
                if [ -z "${label}" ];then
                        label=${uuid}
                fi
                arr_plugged_in_path+=($name)
                arr_plugged_in_label+=($label)
                arr_plugged_in_type+=($type)
        fi
done < <(blkid)

Thanks to all who wrote me and enjoy!

17 Apr

Java Android application to send http commands via htaccess for remote control

This is a quick one.  In our recent post Remote Control Raspberry via Apache2 Web Server we explained how to receive a command on an apache2 web server. And in JavaScript function to send http commands via htaccess for remote control we demonstrated how to send such a control command via JavaScrip. Now here is the minimal Java Android application to send http commands via htaccess for remote control e.g. your raspberry pi. So when you push a button on you android phone, your raspbery pi at home does whatever you want him to do.… read more.

17 Apr

JavaScript function to send http commands via htaccess for remote control

In our recent post Remote Control Raspberry via Apache2 Web Server we explained how to receive a command on an apache2 web server. If we want to send this command e.g. via an android app, we need some code to accomplish this task without any browser. Thus, we show how to write a JavaScript function to send http commands via htaccess for remote control a raspberry pi or any other web accessible http(s) server.

You might think you find a typo and it should say Java instead of JavaScript. But we are aware of that. If you want to use Java, we will present a guide on that soon. This post applies JavaScript, because you can use the same come … read more.

27 Mar

Remote Control Raspberry via Apache2 Web Server

Control your raspberry pi and its GPIOs via apache2 Web Server from android app or web browser. Including SSL and htaccess security.

remote control your raspberry pi

Remote Control Raspberry via apache2 Web Server: This post guides you to remote control your raspberry pi via https (self-signed SSL certificate) from wherever you want. We show you how to add htaccess security and add commands via php.

Introduction

Let’s say you have some fancy Raspberry Pi setup at home which  does some home automation (e.g. via GPIOs) or other tasks for you. But how do you remote control your tasks if necessary? My suggestion is a web interface or a simple android smart phone or tablet app (these devices are usually at hand, so there is no need to access you pi directly).… read more.

24 Mar

USB Automount Script for Raspberry Pi

RaspberryUSBWhen working with a raspberry pi, you might need some USB storage to carry your data. I for example use a raspberry as a quite powerful seafile cloud server, which will probably be presented in a later post. As I was working with usb storage on raspberry pis, I became pretty bored on mounting devices manually and unmount it later aswell. The installable ‘automount’ program didn’t suit my flavor by adding unlabeled usb* folders to /media/*. I want to see the correct device name like on a regular desktop computer. So, I wrote a handy USB Automount Script for Raspberry Pis with the according udev rule to execute it when required.

The main script can be downloaded here:

[Download not… read more.
03 Feb

Hello world!

Welcome to SolvedForHome.com.

 

With this site we started a longterm project for home electronic solutions like we built it.

In a first step we write posts about code and scripts we created. While this stuff might only be applicable to those of you, who have some programming knowledge, we plan on doing more. We are currently building first hardware and software products for home use.

During the creation process we will keep you posted and maxbe start some diskussions on product details.

We are planing on selling those products for a fair price, but (if possible) also release some instructions, so the crafty once of you can built the devices on your own.… read more.