Adding MGE UPS support to SME server

MGE UPS support

Enable the monitor service

  • config set nut service status enabled
  • config setprop nut Model mge-shut
  • config setprop nut Device /dev/ttyS0
  • signal-event post-upgrade
  • /etc/init.d/ups start

Verify if the UPS was detected

  • upsc ups@localhost | grep mfr

should show something like

ups.mfr: MGE UPS SYSTEMS

Continue reading Adding MGE UPS support to SME server

Installing RRDtool with perl bindings on the NSLU

RRDtool is a nifty database mechanism that is widely used for monitoring parameters of routers, switches, weather stations, solar installations, …

I use it to monitor various parameters of our home. Since this is a 24/7 task, I run it on a low-power devic: the NSLU2. This article describes how to install the RRDtools on the NSLU2 (running Unslung).

Continue reading Installing RRDtool with perl bindings on the NSLU

Adding the smartd service to SME server

It is interesting to monitor the hard drives of your Linux server for possible problems.

The smartd package allows you to monitor the SMART parameters of any drive attached to your system. In case things are going wrong, smartd will warn you by email and chances are that you will be able to gracefully shut down the system.

Enabling the smartd service on SME Server (tested on 7.0pre3) is easy, since the package is already installed by default.

You only need to configure it, and to add it to the list of known services.

Continue reading Adding the smartd service to SME server

DCF controlled time switch

I needed a way to automatically control the main heating of my parents house. The basic idea is to start the heating at a certain time in the morning, and to switch it off at night. The switching points are different on various weekdays.

Of course, I could have bought a time switch. However, those things alway tend to have too much or too little switching points, an inaccurate clock, or they are just too complicated to be programmed (ok, this is relative, but you’ll agree with me that time switches with an RS232 port for programming are not really common ;-).

One of the first things I planned to make once I learned working with microcontrollers was a DCF77 time decoder. I never found the time to actually start building one, so this was the perfect excuse. I decided to make a PIC-controlled time switch that gets its time updated through the DCF77 radio signal.
Continue reading DCF controlled time switch

WRT54G and the Dynamic IP services of BNamed.net

BNamed.net offers a dynamic IP service as a part of their domain name registration services.

They offer client software for updating your IP address, but the provided script requires some changes in order to work on your WRT54G(S).

Below, you can a modified script for the Linksys WRT54G that updates your registered IP address when it has changed.

Continue reading WRT54G and the Dynamic IP services of BNamed.net

File decimater

A simple script that allows to strip a certain file by retaining only a subset of the lines of the original file.

Usage:

 dcmate <inputfile> <lines_to_skip>

There is also a trivial graphical interface to the tool, called ‘dcmatex’. Put the file in the same folder as the ‘dcmate’ script. It requires the Perl::Tk module.

Download: dcmate

Download: dcmatex

Outlook calendar event generator

This script will generate a list of events that can be imported in your Outlook calendar. Comes in handy if you work in shifts that are not week-aligned.

You can enter the events quickly in a graphical representation of the days of a specific month. The idea is that you first select a ‘shift’ and that you then click on the days that should be assigned the selected shift. The buttons in the calendar view will change color to reflect the new shift.

Once all events are entered, the Outlook import file can be generated by clicking the ‘generate’ button.

The GUI looks like this:

Download: caltool

Continue reading Outlook calendar event generator

Creating gerber output files from Eagle PCB

A short description on creating gerber files from Eagle PCB  for the processing of your PCB.

1. Design the PCB, obviously… Run both ERC and DRC with parameters as defined by your manufacturer.

2. Create the drill rack using ‘File’ -> ‘run’ -> ‘drillcfg.ulp’. Select ‘mm’ for the dimensions and click OK.

3. Create the Excellon drill data files. Open the ‘CAM processor’
window and select the Excellon job. Click the ‘process job’ button.

4. Open the ‘gerb274X.cam’ job in the ‘CAM processor’. Verify that the
correct layers are selected for output. The ‘mirror’
option should be deselected on all layers! Click ‘process job’.

5. Verify the generated files using a gerber file viewer, e.g. gc-prevue or gerbv. The output formats are

*.drl = drill list, import this first in gc-prevue (file type will be unrecognised, select ‘drill rack’)
*.drd = drill data, location of the drill holes
*.cmp = component side metal
*.sol = solder side metal
*.stc = mask stop for component side
*.sts = mask stop for solder side
*.plc = silkscreen for component side.

That’s it.
Continue reading Creating gerber output files from Eagle PCB