Archive for the ‘Information Technologies’ Category

System choices for Home Automation

Friday, November 27th, 2009

I’m studying the hardware and software for my Home Automation project, namely for the server and clients of the SCADA system. I won’t use Windows for these systems, because I need something that I can trust (and immune to viruses/trojans/attacks), and in the end it gets expensive. MacOS X and Linux comply (better at least) with that, and it’s relatively easy to find good, cheaper systems they run on.

But I’m studying how I can include Amiga-based systems on my project. The reasons for choosing an alternative system are simple:

* Lower power consumption, good for the environment.
* Supports smaller, innovative companies, good for the economy.
* Really small, efficient and fast operating systems.
* Secure (different from mainstream OSs, unexploited).
* Virus immune.
* Usually cheaper than a Windows system (the OS is payed separately, and usually needs better, more expensive hardware to perform well).

I won’t deny that the Amiga had a big impact on my life, during my childhood… a lot of what I know now was learned on an Amiga, and the Amiga community surely influenced many of my (good) choices in life. Including it’s spirit in my project can only bring good things!

As of now, my options boil down to this:

AmigaOS 4
Expensive system (~700€).
Dedicated hardware (ACube‘s SAM440ep motherboard).
Hardware available commercially today.
Good performance.
Low power consumption.
Good operating system support of the hardware.
Has SDL.
Good future perspective.
Developer: Hyperion.

Reasonable system cost (~300€).
Dedicated hardware (Genesi stuff), with support for some obsolete PowerPC G4 Macs (MacMini).
Hardware not really available, as of now only runs on obsolete systems (Efika/Pegasos/Radeon). Will certainly support the new Genesi Smarttop and Smartbook.
Good performance.
Low power consumption.
Good operating system support of the hardware (on the Efika/Pegasos at least).
Has SDL.
Good future perspective.
Developer: the MorphOS team.

AROS (Icaros Desktop)
Cheaper system (iMica: ~250€).
Generic hardware.
Hardware available, but limited operating system support of the hardware (targets old x86 hardware), although the iMica is available, and can be used to give value to old computers with lower power consumption.
Good performance.
Low power consumption.
Has SDL.
Uncertain future perspective, since it is developed by the community, with no commercial company backup (although this sometimes means nothing).
Developer: AROS community.

Normal system cost (MacMini Intel: ~500€).
Dedicated hardware (Apple stuff).
Hardware available commercially today.
Best performance.
Low power consumption (30W).
Good operating system support of the hardware.
Has SDL.
Good future perspective.
Developer: Apple.

Linux (DSL, Ubuntu, PuppyLinux, …)
Cheaper system (~300€).
Generic hardware.
Hardware available commercially today, and can also be used to give value to old hardware.
Good/Best performance.
Low power consumption (40W).
Good operating system support of the hardware.
Has SDL.
Good future perspective.
Developer: the Linux community.

Preliminary observations
It’s not easy to choose the OS by reading these facts. I took a look at AROS, but I’m yet to see AmigaOS 4.1 or MorphOS running, and using the OS is an important part for me. Also, I have to make a bit of development on the three and see wich one feels better.

My emotional side tells me AmigaOS might be the way to go, but it seems to cost more than a Mac or Linux system. From this simple comparison AROS is the best value and MorphOS (assuming it will run on the MX Open Client “Smarttop” from Genesi) is as strong a candidate… I’m eager to try them out, and I’m sure testing sessions will be lots of fun! 😉

AmigaOS unchained

Friday, October 23rd, 2009

It has finally happened! It’s great news to see AmigaOS free from it’s legal disputes! Hyperion seem to now have full rights to develop it for whatever hardware platform they desire.

I hope they give the OS a clear roadmap, even if it is primarily targeted to a niche market (like the embedded one, where I think it could have some following). And I also hope they realize that their most probable early adopter userbase will be us Amigans. We nerds that had Amigas 10-15 years ago, and that now have twice that age at least. I think they need to target us first.

Like I’ve seen the honorable Zetr0 say on EAB, the boing ball is on their side now. Let’s see what they do with it!

A Calendar Bird’s Eye View

Wednesday, October 21st, 2009

I’ve been using my company’s paper calendar (the ones they distribute) to mark my project’s research, development schedules, deployment phases, support events, appointments, personal events, holidays, whatever. I like to have a view of the whole year; visualising the months ahead is great to preview stuff, but looking back at the past months is great to see where you’re at.

Amazingly, I can’t get this view in Apple’s iCal, the further it goes is one month view. This means I’ve nerver used it. I’ll be looking at other software alternatives (as soon as I can find the time to do so) and see if I can move away from paper… any sugestions?

Home, Smart Home

Sunday, May 24th, 2009

Although people are starting to take a better look at home automation (or domotics), there is still this idea that domotic are expensive, dispensable and a luxury. A mere toy, one that is quickly forgotten and seldomly used. And from what I’ve seen, they seem to be right.

Today, I’m starting to build my house. Being an electronics and telecommunications engineer it’s only natural that I’d like my home to have some kind of automation. I’ve asked around a bit, and from the proposals I saw, most people don’t get it. You should be building domotics from the users’ point of view, not from an engineer’s point of vue. It’s what’s really useful that should be implemented.

When we talk about home automation, most people think about automating lighting. Ok, so you can centrally (often through a kind of touch control on the wall) turn on/off every light in your house, or even dim them. What’s the *real* benefit in that? That’s something nice to have, but not amazing.

For me, a domotics system should be useful every day! By order of priority, it must:
* Protect me and my familly, and my belongings (by implementing a security system)
* Save money (by automatic energy saving)
* Save time (by doing things quicker, augmenting confort)

To comply with these requirements, these are some of the things the system should have, also by order of priority:

* A user-friendly, intuitive, distributed supervison and control system, based on touch screens with animated graphics.
* A data archiving system for energy and event analysis.
* A sofisticated alarm system. Several zones, several modes, motion detection, video recording.
* Automated window shutters.
* Automated entrance doors and gates.
* Climate control (temperature and forced ventilation).
* Energy monitoring (electric and thermic).
* Garden, Orchard, Horticulture and Greenhouse (hydroponics) irrigation and monitoring.
* House-wide speakers (for warnings and info).
* Daily-usage-appliances monitoring, to inform when long work cycles end (laundry, bread maker, oven, etc).
* Lighting control.

The order clearly shows it, lighting control really is the least important thing in my book. Unsurprisingly, the alarm system is the single most important thing in a smart home, and most people end up spending lots of money on (independent) security systems alone. So my ideia is to integrate all these into a very useful home automation system.

If you think about it, many pieces can be reused within the system. For example, the alarm’s motion sensors can be used to open doors and/or turn some lights on; the alarm lights and speakers can be used to warn about many other events; the alarm system can control the window shutters when securing the house; the climate control can also use the window shutters for efficiency, making the most of the Winter sun.

A system like this would be a natural part of my life, not a gimmick that quickly gets forgotten after the initial impact. But all this needs to be affordable, and most systems aren’t. 20000 Euro (that’s twenty thousand) for a system is NOT realistical these days. Things also need to be kept simple and standard. Proprietary buses and hardware is definitely not the way to go in my opinion (you simply get locked in). And finally, things need to be very dependable, and quickly amendable should a fault occur.

I’ll keep on searching for the perfect system. Meanwhile, I have my own ideias of how the basic system should be done… and some very advanced stuff too.

Stay tuned!

OPC – OLE (Open?!) Process Control

Monday, March 9th, 2009

In my industrial meanderings, I’ve been using some I/O modules for wich I write device drivers (for my data layer abstraction). One of these involves the OPC protocol (OLE for Process Control). It’s actually a pretty good ideia (badly implemented).

The ideia is that all data devices should be easily accessible by a standard communications protocol. There’s the ideia of an OPC server, an application that connects to the devices and exposes their data on the OPC protocol. Then, an OPC client connects to these servers and reads/writes on those devices. The problem is that they based OPC on a Microsoft-only (thus Windows-only) technology, DCOM. DCOM has a history of being difficult and picky to configure remote access and, because of this, almost nobody goes to the length (and risk) of configuring a system remotely (permissions problems, etc), and clients and servers are usually run on the same machine (defeating half the purpose).

Still, the ideia is too good to let go, and there are OPC servers for almost everything on the market. Getting OPC to work was one of my first projects at work, but since I write almost everything in Java (so that it runs on Windows, Mac and Linux) I had to find a way to get access to OPC from Java.

Back then, I developed a small TCP/IP proxy, socket-based, with a simple ASCII protocol, on Visual Basic (using the native OPC DLL). It not only brought along the lost OPC purpose (distributed access), but I could have access from just about anything (Java, Ruby…). Still, it was slow, configuration was local, and it did not implement all of the OPC protocol.

Later, I found almost exactly what I was looking for: a couple of companies were proposing JNI-based Java wrapper libraries, giving access to OPC. The problem: they cost as much as the OPC server (about 600 Euro) and, just like the server, I had to purchase one library license for each deployment.

I never understood this business model; I would hapilly buy the library once and deploy to my hearts content, as this would probably be cheaper than developing the library myself (I do this with JFreeChart, for example). But if I have to pay for every deployment this is simply not economical, since with the money of 2 or 3 deployments I was definitely able to develop the library from scratch. I was seriously thinking of developing the library myself and selling it with JFreeChart’s business model (I had no competition anyway), until I found JEasyOPC.

Antonin Fisher developed an OPC wrapper library based on JNI (and Delphi) and offered it with a LGPL license. I’m testing the library now and it seems to perform very well on Java 5. It crashes on Java 6 though (apparently due to multithreaded issues).

If Antonin ever gets around to fix this issue on Java 6, we’ll have a winner! 🙂

The Amiga: tool or toy?

Thursday, November 20th, 2008

These days, things tend to be dominated by the biggest powers; there is always one or two big names that usually dominate some market. And when there are smaller contenders that start to have dimension, the big guys usually just swallow the small ones whole (getting rid of competition and gaining valuable assets in the process; they were gaining market share after all).

In the computer world, things are very similar: There is one big giant, Microsoft, and then the alternative, Apple. Linux comes as a community effort, difficult to deal with for it’s nature, but then again it is not much in the way of competition. Although things have improved immensely lately (Ubuntu springs to mind), Linux distros tend to be geek-oriented, and some simple task require a lot of fiddling around for the general user (and, too often, terminal shenanigans).

In my youth, there was more in the mix: the PC was a horribly grey machine, with a clear target: business. Then there was OS/2 running on PCs, and a few less-known OSs. The Mac was expensive, elitist, forward-thinking, closed and incompatible. The Atari was a machine I never had much contact with, but was very popular too. Then there was the Amiga.

A very interesting machine, with a ground-breaking form-factor, innovative, dedicated and powerful hardware, lots of expansion options, and a reasonable price tag. The AmigaOS was elegant, small, fast, efficient, multitasking, and very advanced in many ways (some even today). It had everything to become The Platform, but it was not to be. Still, it had many years of prosperity (mainly as a games machine, before the Wolfenstein era, wich broke the “business” tags on PCs), before evolution simply froze and the platform was slowly abandoned until it became a small niche market.

Today, after years of effort (and also lots of destructive criticism) from the Amiga community, things seem to start shaping up again. Hyperion has held on to the AmigaOS and kept (slowly) developing; and finally, it seems we might actually have some (easily accessible) hardware to run it on, with ACube’s Sam440.

But is it really worth the bother, in these days of megacorporations? I think it is.

The Amiga might still have a future in dedicated, embedded, industrial, public, and mobile environments. Niche markets, I know, but I don’t see the Amiga getting up there, stealing market share from Microsoft or Apple anytime soon. So, what do we need to be sucessful in the short run?

First, Hyperion should make sure the OS is ready to fulfil integrators’ desires. It’s great to have an amazing desktop OS, but they should address the embedded needs too. We need Java (1.5 at least), we need a stable OS, we need a good set of drivers, we need easy networking, we need simple and secure remote access, etc. I would love using AmigaOS for my industrial and domotics projects!

Then, the motherboards should be priced lower quickly. I don’t mind being an early adopter, and pay 500 Euro for the board alone to play around and start development, but it must come down to at least 200 Euro before integrators can start considering it. Maybe the new Flex board will be within this price range.

Identity might not be a problem now, but in the future we should better define the Amiga computer. The boards should probably be sold with special enclosures, to give identity and soul to the machines.

For the long run, there is this problem that the Amiga does not have a single company behind it just now. Amiga Inc. today is a slim, modified shadow of it’s former self, and has nothing to do with the original Amiga vision. The vision has survived in the core of the community. Lots of great talents keep the spirit alive today. But I think we need more in the long run, we need a name and a brand, a sound strategy and a banner we can rise. Or maybe I’m just thinking “Apple” too much.

I hope Hyperion get to keep AmigaOS from the lawsuit. At least they are showing good work done, not vapourware, and probably deserve to reap the rewards of their work.  

Here’s hoping the Amiga can make a real comeback this time.

(Finally) Back for the Future (hopefully)

Tuesday, November 4th, 2008

It seems we may have a “new Amiga” in the market! Well, it’s a new motherboard, capable of running AmigaOS 4.1, and it’s called Sam440ep. It’s actually available to purchase on the Net!

I would have liked to see a trully new Amiga; I mean a full computer, with a name, and a distinctive case. More like a Mac than a PC. Relec have done something like that with The Red One.

If you know Amiga’s history, you won’t be asking why Amiga Inc. haven’t done that themselves. Still, I think this opens up a lot of space for Amigans to build their machines in special/custom/modded cases and brag about it!

I know it’s been years since news like these made a significant impact on the market, the Amiga today being mostly regarded as a very small niche market of people holding on to old hardware. But an Amigan is always an Amigan, and we have a reputation of being clever, inventive, innovative, rebel and fun geeks. The AmigaOS has always been a reflection of this status: a simple, out-of-the-ordinary, highly efficient, yet powerful operating system.

Hyperion seem to have done quite a remarkable job with the AmigaOS up until now (Ars Tecnica seems to think so too), and we finally have something to run it! Plus, we also have AROS running on the Sam, and some Linux flavours.

(Maybe Pedro Gordinho can give us his artistic vision of the new Amiga?! I’ll post it should he find the time to do it.)

I look forward to having an Amiga again! And Christmas is just around the corner…

Dá-se router Siemens

Monday, October 13th, 2008

Tenho uma Net nova. Ou melhor, estou finalmente a tirar partido da ligação que tinha, sem problemas.

Vi-me finalmente livre do meu router Siemens Gigaset, que fui obrigado a comprar aquando da instalação da minha linha da Cabovisão. Nunca tive problemas com a Cabovisão em termos de serviço, suporte, etc, mas a minha ligação era uma grande treta em termos de qualidade (desde há dois anos para cá). Ao princípio pensei que fosse culpa do ISP, e não liguei muito. Mas quando comecei a ter problemas apenas em uma ou duas máquinas na rede (e também em alguns protocolos específicos, tipo AFP), comecei a suspeitar da minha rede.

O facto do router simplesmente deixar de trabalhar e precisar de um power cycle quase uma vez por semana também me deu uma pista. O AFP do meu servidor era lentíssimo, o meu blog ficou quase parado, até o SSH era lento, enfim, nada funcionava como deve ser. Sempre pensei que nestas coisas era ON-OFF, ou funciona ou não. Mas a Siemens conseguiu fazer um router muito especial! 🙂

Há duas semanas, deixei simplesmente de conseguir aceder ao site do eBay. Nicles, niente, nada, kaput. Foi a gota de água. Então lá consegui arranjar uma horita (entre dar a sopa, trocar a fralda, e cantar mais uma música das Chiquititas à minha princesa) para mudar de router.

O suporte da Cabovisão portou-se muito bem (fui atendido quase instantaneamente por duas vezes) e rapidamente me deram os dados que me faltavam (DNS). Agora o meu Linksys está a trabalhar como um relógio, e tenho a minha Net de volta, mais rápida que nunca, upstream e downstream (é que entretanto houve uns poucos aumentos de velocidade de que nunca tirei partido)!

Alguém quer um router Siemens de borla?

Ribbit! Ribbit!

Monday, October 6th, 2008

Estou a planear ir à Sapo Codebits!

Um amigo disse-me que o ambiente é porreiro e parece-me uma boa oportunidade para aprender alguma coisa e divertir-me um bocado. Bom, isto se conseguir arranjar férias para ir… acho que marcar um evento destes maioritariamente à semana é… complicado para tipos como eu que têm uma vida preenchida (pessoal e profissionalmente).

Gostei muito das edições da Minho Campus Party a que fui, mas gostava de ver mais programação (jogos não faltavam). Acho que vou gostar muito da Codebits!

Breefly Uninterrupting the Power Supply

Wednesday, August 27th, 2008

Comprei aqui há um par de anos uma UPS fanhosa da Mustek (Office 650VA) para proteger o meu PowerMac G4 MDD Dual 867Mhz. Custou 55€ e até parecia “bon marché”. Hoje, não aguenta o meu novo MacPro Quad Xeon 2GHz. Mal falha a alimentação, ela arreia e entra em erro. Supostamente devia aguentar facilmente o MacPro, pelo menos por 3-5 minutos, mas nem 5 segundos trabalha.

O barato sai mesmo caro… um amigo meu (olá Marco!) viu a fonte de alimentação do seu PowerMac G5 e do seu Apple Cinema Display 20” irem com os pitos atrás de uma UPS Mustek. De quoi changer la miene!

Como o meu servidor ainda usava uma APC 400VA velhinha (15 anos), comprei-lhe uma nova UPS: uma MGE NOVA AVR 1100VA. Como o meu fornecedor não me conseguia arranjar uma versão com ligação USB, tive de me contentar com uma versão com porta série RS-232 (que liguei ao Mac com um adaptador USB-série, chipset Prolific PL2303, e as Network UPS Tools que compilei em Tiger).

Primeira constatação: a UPS faz muito barulho! Tem uma ventoínha pequena mas barulhenta, que está sempre ligada. No entanto a UPS é potente, tem AVR (booster+fader, ou seja, compensa a tensão de saída se a de entrada oscilar um pouquinho), e cold-start (arranca mesmo independente, sem alimentação). Testei-a no meu MacPro e lo and behold, reporta 16% de carga (o MacPro puxa cerca de 120Watt) e aguenta a besta a trabalhar durante mais de 10 minutos (idle). Not bad at all.

Mas era impossível de aguentar o barulho da ventoínha, principalmente perto do MacPro que é virtualmente silencioso (tanto que às vezes até assusta). Assim, resolvi fazer um mod à UPS. Objectivo: silenciar o bicho! Método: trocar a ventoínha original (uma Sunon 50mm 12V) por uma maior, com regulação de RPM (uma 80mm CoolerMaster). O fluxo de ar é pensado para arrefecer o transformador que faz boost/fade, e os transístores de potência da board, mas não me parece ter grande trabalho mesmo sobre carga durante 10 minutos. Por isso não tive medo de fazer a modificação.

Resultou muito bem, depois do meu sogro me ajudar a fazer o novo buraco para a nova ventoínha, e depois de ter de mudar o local dos furos por causa da posição de um relé que não antecipei. A UPS agora quase não faz barulho, mas se precisar dela sobre carga durante muito tempo é só aumentar o RPM da ventoínha!

Estou curioso de ver a carga que ela reporta com o iMac G4…