Category Archives: Programming

No Weather On Your Taskbar?

Seems that NOAA.gov has shut down their weather data in the past few days. The weather applet on the Linux task bar used this resource.

Fear not, and be patient, as the developer of this wonderful desktop tool is working on sourcing a new data stream. As soon as it’s tested, I’m sure it will be pushed out to the repositories!

To read the ongoing work, CLICK HERE

Tweaking ownCloud’s Calendar

New goats are settling in, so let’s get back to some Linux fun!

We love ownCloud here on the farm, and have written several blog entries about it. One thing about this wonderful software that has always made me crazy, was that the calendar application used a colour to highlight the current day, that we just couldn’t see!

ownCloud Calendar

ownCloud Calendar

When my FLux software would cut in, the barely visible colour would not be visible.

Of course like any software, you can tweak it to your liking in just a few steps!

First open your file browser as an administrator and head to your /var/www/owncloud/apps/calendar/js directory and then open the Calendar.js file with your favorite text editor.

Caja as Superuser

Caja as Superuser

Then do a quick search for the current colour, in this case #FFC and change it to whatever you like! In the example below, I changed it to #f4e71d

Revised background colour

Revised background colour

Of course, it’s possible that if ownCloud does an update of that file, you will lose your fix, but it’s simple to change again!

I should note that really, the proper place to fix this problem is in the themes, changing the colour in the style sheet. I’d done that without success, which is why I went ahead and changed it in the javascript file instead…

 

Learning: Bash Scripting Is Your Friend

Linux is a very powerful operating system. and if you’re not using it, you really should be!

That said, once you get your new Linux machine up and running, consider learning how it actually runs!

By learning Bash, or shell scripting, you open up tons of new doors into your computer. You can use scripting to do all kinds of useful things. I use scripts to prune system logs, update multiple machines on my network at once, and lots more.

The best place to learn Bash, is the wonderful Internet source: Advanced Bash-Scripting Guide

You can use the web site above, or from your Package Manager, you can do a quick search for, and then install: abs-guide

Package Manager, installing abs-guide

Package Manager, installing abs-guide

The author of this great tutorial, assumes that you have no experience at all with shell scripting. The site or software will take you step by step in how to write simple, and later more complex shell scripts.

Go at your own pace, understand the current lesson, then click Next  at the bottom of each page and keep going! The site has dozens and dozens of Bash scripts, that you are free to use, modify, and enjoy.

 

Holiday Hardware: Playing With My Pi

Had a great Christmas and New Year with friends and family, but now it’s time to get back to Linux fun!

A piece of computer hardware I always wanted to experiment with, is the Raspberry Pi.

I most have been very good last year, because Santa got me  a Raspberry Pi for Christmas this year!  Of course I spent a lot of time  playing with it lately.

Raspberry Pi - Image courtesy Amazon.com

Raspberry Pi – Image courtesy Amazon.com

I was given the CanaKit package, that came complete with a WiFi dongle, SD card with the OS installed, a nice case, power supply, etc. Only thing I had to do was plug it into my HDMI television for a monitor and plug a USB keyboard and mouse into it.

After I played with it for a couple of days, getting the operating system, menus etc.  set up just the way I like it. I started thinking about a use for it!

Pondering the question for a couple of days, I decided that the Pi would work great as an automation system for my goat pen!

The idea, still in the design  and programming stages, is to use a series of Infrared motion detectors, to send a contact closure to the Raspberry Pi’s GPIO, which will then fire a terminal command to change the camera shot.

So, a goat walks into the feed area, the motion sensor would trip the Pi to send a command to turn on that camera! The programming should be pretty easy.

I use the Curl library to send commands to my 12 input video switcher. The Pi can easily send the same Curl command. In fact, Curl was the first software package I installed after I got my Pi booted up!

No real reason why it shouldn’t work, but it will take a lot of wiring of the motion sensor modules, from the different areas of the pen and then connect them to the Pi.

Should be a great and  useful project, and I’ll keep everyone up to date as I go!

 

One Fish, Two Fish, Bluefish!

If you take care of a web page of any kind, or wish to start dabbling in software programming, then  Bluefish is a tool you should have on your Linux computer.

Bluefixh editor

Bluefish editor

Installed from your Program Manager, just search for Bluefish.

More than a simple text editor, Bluefish has many handy tools to make your HTML5, PHP, SQL, and other languages much easier to deal with.

I’m a hardware guy, not a  programmer. However, using Bluefish, I can build a web page quickly and easily. Editing style pages for off the shelf templates is a breeze. Building pages from scratch, even with my limited abilities is straight forward.

Bluefish has a nice feature, which gives you wizards for many of the boring tasks in building a web page or writing code. As in the example above, a couple of mouse clicks runs you through the process of creating tables or iframes. The wizard gives you the syntax, and you just fill in the data!