Blog Moved

March 11, 2010

My Blog has moved to http://chryseus8086.co.uk
This blog will no longer be updated.


Inkscape

January 29, 2010

Well it has been quite a while since I last posted. I’ve been quite busy doing various things so it is about time I updated this blog.
Anyways for my first post of the year I’m going to review Inkscape, an extremely good tool that is quickly becoming my favourite.

Inkscape is a vector graphics editor similar to Adobe Illustrator it is completely free to use and modify, also it works perfectly under Windows, Linux and Mac.

It is quite easy to use and learn and there are many tutorials available online so it is quite easy to make professional looking graphics.

Inkscape has a nice clear interface which for the most part is very easy to work with, I have hower had some issues with the snap to grid feature which does not always work quite as well as I would like.

There is not much bad I can say about Inkscape, its implementation of the SVG file format is not quite complete and it does sometimes crash (on windows) but other than that it is a very good program to have.

Pros

  • Easy to use
  • A good number of tutorials available
  • Under active development
  • Works on Windows, Linux and Mac
  • Completely free

Cons

  • Can get a bit slow when working with complex graphics
  • Snap to grid could be improved
  • Incomplete implementation of SVG

Installing Qucs on Ubuntu

December 16, 2009

Qucs is a free circuit simulator for Windows, Linux and Mac. It comes complete with a schematic editor, project manager and other useful tools.
Qucs is very easy to use and support the standard DC, AC, Parameter Sweep, Transient, digital and other simulations, it also includes a selection of popular component models.
Qucs can display the simulation data in a number of ways such as Cartesian Plot, Polar, Tabular, Smith Chart, Timing Diagram and Truth Table.

Installing

First open the terminal and type the following:

cd ~
wget -t5 http://downloads.sourceforge.net/project/qucs/qucs/0.0.15/qucs-0.0.15.tar.gz?use_mirror=kent

This is download the latest version of Qucs, once that is done you will need to extract it:

tar -xvzf qucs-0.0.15.tar.gz

If you want to delete the Qucs source archive you can do so by using this, if not skip this next command.

rm qucs-0.0.15.tar.gz

Now you need to move the folder to where you want to compile it, if you don’t mind it being in your home folder skip this:

sudo mv qucs-0.0.15 /usr/src
cd /usr/src/qucs-0.0.15

Next move into the folder and download the dependencies required to compile Qucs:

cd qucs-0.0.15
sudo apt-get install libqt3-headers

Finally you can compile Qucs:

./configure
make
sudo make install

Once this is done (hopefully without any errors) you can run Qucs simply by typing:

qucs

That’s all, although I’d suggest adding a shortcut to your menu.


Semiconductors Explained

December 10, 2009

A semiconductor is a material that has an electrical resistance between that of a conductor and an insulator. Semiconductor materials also contain 4 electrons in their outer electron shell (valence shell).

Most group 14 elements in the periodic table can be semiconductors, these are carbon, silicon and germanium, most modern semiconductor components are made from silicon that has been grown into a cubic crystal structure.

The arrangement of atoms in the semiconductor is very important, semiconductors must have a cubic crystal structure to function properly, pure silicon or germanium is never used to manufacture working semiconductor components as its resistance cannot be controlled very well, it is only effected by changes in temperature.
In a pure semiconductor all the high energy outer electrons are used up maintaining the tight crystal structure save for those dislodged thermally.

P and N type Semiconductors
Two different types of semiconductor can be made by adding tiny amounts of impurities to the semiconductor material in a process known a doping, one type of semiconductor is the P type which is made by adding a small amount of boron.

Boron (B) is a group 13 element, it had 3 electrons in its outer shell, so when it is added to the crystal structure it leaves a gap known as a ‘hole’, because of this it is known as an acceptor impurity because the hole can accept an electron.

The other type is the N type semiconductor which is doped with phosphorus (P) which is a group 15 element that has 5 electrons it its outer shell, when added to the crystal structure it leave a free electron, thus it is known as a donor impurity.

A hole is an empty space in the crystal lattice that can accept an electron to fill the gap, holes cannot move as such, however they may appear to do so as electrons in the semiconductor move around.
P type semiconductors have many holes and few electrons, thus holes are the majority charge carrier with electrons being the minority.
The reverse is true with N type semiconductors, electrons are the majority charge carrier with holes as the minority.

Placing a piece of N and P type semiconductor results in diffusion, where some of the electrons in the N material jump over to fill some holes in the P material, this results a small region forming in each type.

In the P type semiconductor a small N type area is formed where the materials touch.
In the N type semiconductor a small P type area is formed where the materials touch.

Depletion Region
This results in a very small region forming in the semiconductor known as the depletion region, this region is very important in the manufacture of useful semiconductor components as they are all made up of both P and N type material.
The simplest electronic device made from semiconductors is the diode which is made of one P type and one N type semiconductor material sandwiched together, this results in a depletion region forming a P-N junction.

I will add more information on how diodes work in my next post.


Ohm’s Law

December 3, 2009

Ohm’s Law is a simple mathematical law that shows how voltage, current and resistance are related.
It was discovered by Georg Simon Ohm in 1827, the three main equations given by Ohm’s Law are:

V = IR
I = V / R
R = V / I

Using Ohm’s Law it is possible to find the voltage, current and resistance in any circuit.

For example, a simple circuit containing one 9V battery and a resistor of 1kΩ it is possible to find the current through the resistor by using Ohm’s Law.
V = 9V
R = 1000Ω
I = 9V / 1000Ω = 9mA

It can also be used to find the resistance of the resistor or any other component.
V = 9V
I = 9mA
R = 9V / 9mA = 1000Ω

And the voltage drop over the resistor.
I = 9mA
R = 1000Ω
V = 9mA * 1000Ω = 9V


Installing EDuke32

November 24, 2009

Install requirements

GNU C++ Compiler (g++)
libSDL runtime & development files
NASM (Assembler)
GTK+ 2.0 runtime & development files
libVorbis development files

Subversion (SVN) – to download the latest EDuke32 source
Timidity – software MIDI player

First check you have the build tools installed by running

gcc –version

You should be given the version, if you get something like ‘command not found’ you will need to install the build tools.
If the version is below 4.0 you should upgrade your build tools to version 4.3 or greater.

If you using Ubuntu you can use the following command to install the build tools.

sudo apt-get install build-essential

If you not using Ubuntu you should search your distributions package manager for the build tools.

All the required development files can be installed on Ubuntu using the following, again check your package manager if you are using a different distribution.

sudo apt-get install subversion timidity libsdl1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev nasm libgtk2.0-dev libvorbis-dev

Getting EDuke32

Now you need to get the latest version of EDuke32.

cd ~
svn co https://eduke32.svn.sourceforge.net/svnroot/eduke32 eduke32

I assume your going to build in your home directory, if not I suggest you use /usr/src

Building EDuke32

Once EDuke32 is downloaded you can build it.

cd eduke32/polymer/eduke32
make

If the build completes without errors you should find two executables in your current directory.
Next you need to make the directory where you will place EDuke32 and Duke Nukem 3D.

mkdir ~/duke3d
mv eduke32 ~/duke3d
mv mapster32 ~/duke3d
cd ~/duke3d

Using EDuke32

Alternatively you may install EDuke32 globally, (I.E in /usr/bin) for information on doing this read the EDuke32 wiki.
Now simply get your version of Duke Nukem 3D and look for the file called DUKE3D.GRP. Move this file to where the EDuke32 executable is located. (I.E ~/duke3d)
Once that is done simply run EDuke32 with:

./eduke32

Important Note: ensure that the DUKE3D.GRP file is LOWER CASE, such as duke3d.grp or EDuke32 will not be able to read it, hopefully this will be fixed in future.
I will show you how to use multiplayer in my next post.

Update
There are APT repositories for Debian and Ubuntu for easy installation.

http://wiki.eduke32.com/wiki/APT_repository


Installing Morrowind on Linux

November 19, 2009

This article will show you step by step how to install The Elder Scrolls: Morrowind, Tribunal and Bloodmoon under Linux for running with WINE.
I have tested this with Ubuntu 9.04 and WINE-1.1.33.

This process is much more involved than normal as newer versions of WINE have broken MP3 playback support, so you will need to recompile WINE.

Cleaning up

First you will need to remove any old versions of WINE and libmpg123, how you go about doing this depends on what package management tool you use, I will be giving the below instruction specifically for Ubuntu Linux 9.04, but may also work on other Debian based distributions.

  • Open the terminal

  • Type ‘sudo apt-get remove wine mpg123 libmpg123-0 libmpg123-dev’

Getting the needed stuff

You will be needing quite a bit of stuff before you can begin compiling, first you need the latest WINE source and libmpg123.

  • Get WINE from here

  • Get the latest version of libmpg123 from here

Also get the needed compiler tools, this is ‘build-essential’ on Ubuntu. There may be other packages you will need but you will find out what they are when you get to configuring WINE.

Compiling and installing libmpg123

This step should be pretty simple to manage and it should not require anything besides the compile tools.

  • Extract the source of mpg123 you downloaded and stick it in a folder

  • ‘cd’ to that folder and type ./configure –enable-static –prefix=’/usr/’
  • If configure went well type the following
  • ‘make’
  • ‘sudo make install’

libmpg123 should now be installed.

Compiling and installing WINE

  • Extract WINE into a folder and cd to it.

  • run ./configure –with-mpg123 –prefix=’/usr/’
  • Configure will warn you about any missing libraries, you should install these using your systems package manager unless you do not need the features they provide.
  • If your happy type ‘make depend’ then ‘make’
  • Wait for WINE to compile, this will take about half an hour on a average system
  • Once the compile is complete type ‘sudo make install’
  • Now test out wine !

Installing Morrowind, Tribunal and Bloodmoon

  • Insert the disk or mount the disk image for Morrowind

  • Go to the disk directory and type ‘wine Setup.exe’
  • Install Morrowind
  • Repeat this same process for Tribunal then Bloodmoon, do not do in any other order.
  • Get the latest Bloodmoon patch here
  • Mount the Morrowind image or disk and play

Ruby Sockets

November 3, 2009

For the last few days I’ve been writing a simple IRC bot in Ruby. I have noticed however that the documentation for Ruby Sockets is quite poor, so I thought I’d post a bit about using Ruby Sockets here.

RubySocket
These are all the main classes that deal with sockets, with the exception of IO.

BasicSocket
This is the base socket class which defines a few simple methods, pretty useless on its own.

Socket
This class contains everything you need to work with sockets, however if you intend to use a TCP, UDP, SOCKS or UNIX socket you will probably be better off using one of the other classes.
http://en.wikipedia.org/wiki/Internet_socket

UNIXSocket & UNIXServer
These two classes make it easy to quickly work with UNIX sockets.
http://en.wikipedia.org/wiki/Unix_socket

IPSocket
This is the base class for working with IPv4 and IPv6 addresses.
http://en.wikipedia.org/wiki/Internet_Protocol

UDPSocket
As the name suggests this provides everything you need to work with UDP.
http://en.wikipedia.org/wiki/User_Datagram_Protocol

TCPSocket & TCPServer
Everything you need to deal with TCP is in these two classes as TCP is the most common internet protocol, this will probably be the class you will most use.
http://en.wikipedia.org/wiki/Transmission_Control_Protocol

SOCKSSocket
http://en.wikipedia.org/wiki/SOCKS

For the most part you will only ever make use of TCPSocket, TCPServer and UDPSocket. In my next post I’ll show some examples of using these and Socket.


Minecraft

October 31, 2009

Minecraft is a multiplayer cooperative building game. In Minecraft you can build anything you want by adding and removing blocks of which there are a number of different styles, currently the game is in active development so there will be many changes coming in the future including additional game modes.

Minecraft Blocks
- Some of the blocks you can use in Minecraft.

Minecraft is free to play however by paying for it (~£10) you get access to a few other features such as custom skins, survival mode and probably much more in future. Overall MC is a pretty good game that still needs some work done to it.

The Good

  • Easy to play and fun
  • Java based so you can play it anywhere
  • Good community

The Bad

  • Still being worked on
  • Low resolution graphics and no full screen support
  • Limited music and SFX

My Rating: 75 / 100


Haven & Hearth

October 21, 2009

Haven & Hearth or HnH is a free online RPG that allows you to build your own farm and craft items which you can trade with other players for items you need, you can also claim your own plot of land in the game world, hunt animals, or a variety of other things.

Building a farm in HnH is pretty simple, you start off in the game with a few basic skills that allow you construct simple objects suck as baskets, constructing these or doing a number of other things earns you Learning Points (LP) which you can use to buy skills or improve your stats.

The Good

  • Decent graphics
  • Excellent gameplay
  • No pointless leveling system
  • Free

The Bad

  • Some bugs
  • Not many players (about 40 average)
  • Very little in the way of music and limited sfx

Here is a nice video of some of the gameplay:


Follow

Get every new post delivered to your Inbox.