Wednesday, December 26, 2012

LEDShoot - Electronic LED Shooting Game

LEDShoot is a simple electronic shooting game which we developed in a year end vacation period. This is a single player electronic game with following game play logic:

There are two fighting groups are exists in this game world. RED group is an enemy group and GREENs are friendly parties. Player’s job is to shoot the RED group(s) when they appear on the stage. Player gets limited time to shoot and misfires are treated as negative points. When player get 100 points game get end with winning message.

This electronic game system is mainly based on ATmega32 MCU and firmware is developed using GCC C (with Atmel Studio 6.0). This system is design to work with 5V - 1.5A power supply unit.

We developed this system as a hobby project and we construct it on a couple of breadboards, at the moment we don’t have any PCB design for this project.

When assembling the circuit make sure to use some heavy-duty push button for (SL2) control key. For (SL1) use 8Ω - 1W (60mm) speaker. LED19 indicate the "audio-mute" status of the system and player can toggle it by pressing the S2 push button.

This project is release as an open hardware project and all the source codes, schematic diagrams and compiled binaries are available to download at google drive. All the project source codes are released under the terms of GNU General Public License 3.0. Project schematic diagrams and EAGLE project files are released under the terms of Creative Commons Attribution 3.0 Unported license.

Saturday, December 22, 2012

PalindromicGen - Search for Palindromic numbers

PalindromicGen is a lightweight configurable tool to perform reverse-and-add operations to obtain Palindromic numbers. The main purpose of this application is to examine the existence of Lychrel numbers in a series of natural numbers.

Sample execution of PalindromicGen from 10 to 1000 base numbers

This tool is developed using Free Pascal compiler and its design to work with many platforms with minor adjustments. We test this tool in several Windows and Linux distributions. PalindromicGen is design to work with Pentium 4 (or compatible) instruction sets (under the default compiler configuration) and its performance is heavily depends on its settings and system configuration.

Under the theoretical limits this application can manipulate up to 231 digit numbers and at the development phase we test this system with maximum of 501 digits (to obtain the palindromic number of 1186060307891929990).

PalindromicGen is an open source software project and it is release under the terms of MIT License. The latest project source code is available at PalindromicGen GitHub repository and compiled binaries are available for both Linux and Windows platforms.

Wednesday, November 28, 2012

DIY Surround Sound Dock for Apple iPods and iPhones

This is a "quick design" to make surround sound dock for Apple iPod, iPhone and iPad devices. This audio docking module contains analog surround sound processor, bass booster and electronic mode switch.

Main components of this surround sound dock are LA2610 - analog surround sound processor and ATTiny13 - 8bit MCU. This unit is design to work with 9V external DC power supply and it can deliver maximum of 2 × 1W audio output power.

Printed Circuit Board Design of Surround Sound Dock

In prototyping stage we test this system with couple of Apple iPod and iPad devices with 4inch full range 8Ω speakers. This system can also drive professional headphone through its "Ext. Output" connector. This system need 160mm × 100mm double side PCB and it is specifically design for vertical docking chassis.

This project is an open source hardware project and its design and other related materials are distributed under the terms of Creative Commons - Attribution 3.0 Unported license. Project Firmware source code is distributed under the terms of GNU General Public License 3.0. All the schematics, PCB design and firmware files of this project are available to download at google drive.

Sunday, November 11, 2012

LASER Based Gate Keeper

These days many verities of alarm systems are available in the market. Some of them get triggered through touch and some type where a wire needs to broken to get triggered.  Both of these types of alarms have some limitations and problems. Wire based alarms are easily avoidable, noticeable and need some regular maintenance. Touch type alarms often pickup RF waves and get activated (because of that it need some controlled environment to function properly).

In this project we design and develop LASER based burglar alarm system. Instead of wire(s) this system use LASER light wave and it can effective for more than 50m. Core features of this alarm system are:

  • High audio output power (Max. 3W PMPO)
  • Master light override switch
  • Inbuilt alarm test functionality
  • Memorized power state
  • Quick response time (aprox. 10ms ~ 30ms)
  • Support for wide input voltage range (15V – 25V DC)
  • Easy to build and calibrate
  • Compact size (aprox. 130 × 200 × 60mm)
This alarm system is specifically design for outdoor use and it is recommended for garages, warehouses, to cover wide range of landscapes, etc.

LASER Based Gate Keeper - final assembly

The core part of this system is ATMega8 MCU and it handles all the functionality of this system. TDA7267A is a power amplifier and NE555 is used as a secondary audio oscillator. TLC393 is used as a sensor driver and it handle both "master LDR" and "environmental sensor LDR". 

This system use high voltage and handle it with extreme care. Do not touch U1’s (BTA12-600) heatsink or associated parts when the power is ON. Make sure to use proper heatsinks for U1 (BTA12-600), IC1 (L7805) and IC2 (L7812) and for IC6 (TDA7267A). The circuit board should be placed in a suitable container and it does not need any maintenance.

This system is distributed as an open hardware project. All the project schematics, firmware files (including source codes) are available to download at google drive. This project is covered under the terms of Creative Commons Attribution 3.0 Unported License and firmware source code is release under the terms of GNU GPL 3.0 License. 

Friday, September 21, 2012

Project Profile Post - Project Description Suite

Project Profile Post (3P) is an open source XML base project description suite. It it helps authors to provide project descriptions and specifications to online sources in a standard way. 3P project description system is not limited for software projects, it can also applicable for any online project work which include electronic projects, arts, multimedia content, etc.

3PEd - Cross platform tool to edit 3P files

3P files can created through 3PEd. It is a GUI application and available for both Windows and Linux operating systems. 3P files can be open (view) through "3P Viewer". 3P Viewer is a GUI application and it is also available for both  Windows and Linux operating systems.

Initially we create this file format and tools to manage our in-house digital contents and later we plan to release it to general public as a free and open source software product(s). 3P tools are available to download at 3P project page at and it is distribute under the terms of MIT licenses.

In this general public release we add additional component to 3P tool chain and it is known as 3P API. 3P API is a software library to access 3P files. This library is available for both Windows (as DLL) and Linux (as SO) operating systems and it can be access through any programming/scripting language which support dynamically loadable libraries (e.g: C++, Delphi, C#,, etc.). 

Sunday, September 2, 2012

Shopping with and Aptinex

Last weekend I got chance to visit to Aptinex (Pvt.) Ltd.  Aptinex is a Sri Lankan startup company and they are mainly do Electronic circuit designing, PCB prototyping, mass-production of PCBs, selling electronic components, development kits, etc. In my last visit I order some dsPICs, Atmel ATmega MCUs and some SMD passive parts from them. They have good collection of development kits and programmers which include Arduino, MSP430 base kits, ARM development boards, Altera FPGA kits, etc.

Another interesting thing they have is electro-mechanical parts. They have various kinds of actuator modules, servo mechanisms, gear systems and controllers. I think this is good news to Sri Lankan DIY electronic community, because right now it is bit difficult to get these items in local electronic shops.

According to Aptinex, is there market place. operates in both real and virtual nature. Anyone can order Aptinex products through this site and they have nice and quick delivery system. One interesting feature in this site is “suggest an item” page. As per my discussion with them they don't have minimum order quantity and customers can order “special/rare” parts through them for prototyping purposes also.

I believe this is an excellent opportunity to Sri Lankan DIY electronic community and like to rate there effort with a clear 5 out of 5!

Contact details of and Aptinex are as follows:

LankaTronics Trading (Pvt) Ltd.
34/1, Old Kesbewa Road,
Sri Lanka.

Phone: +94 112 545470
Web: and

Tuesday, August 21, 2012

Offline High Voltage AC Power Supply

This is a high voltage, low current, offline, AC adjustable power supply for electronic/electrical experiments. This power supply is mainly design for switch mode power supply (SMPS) experiments and to drive basic high voltage electrical circuits. Thanks to the isolated step-up transformer this power supply breaks the ground loop and provides shock free – safer high voltage output. This offline (or isolation) feature preventing accidental current from reaching ground through a person's body.

This unit generates 50Hz or 60Hz (selectable at runtime) square wave AC output, and it is capable of generating output voltage between 150V – 290V AC (on no-load state).

Prototype version of offline high voltage AC power supply

As stated above this power supply unit is mainly design for SMPS experiments. This is not work well with liner power supplies because transformers in linear power supplies are get overheating from square wave inputs generated through this unit.

This is a high voltage project. Make sure to insulate all the connections, and install this unit in a "high voltage safe" enclosure. Before applying power make sure to check all your connections and external wirings.

This is an open hardware project. All the project schematics, wiring diagrams and PCB designs are available to download at here.

Please note that this power supply is design for low current – high voltage experiments. Do not attempt to drive your refrigerator or electric drill through this unit.

Sunday, July 29, 2012

TENMA 72-9390 Pen Style Multimeter

TENMA 72-9390 meter is a cool pen style multimeter. It feels right in the hand and incredibly simple to use, and accurate as professional multimeter.

The meter is 181mm long, and comes with a single (negative) test lead, 3V Li-MnO2 button cell, and instruction leaflet.

TENMA 72-9390 Pen Style Multimeter

TENMA 72-9390 is 3000 counts, true RMS, pen style multimeter with following core features:

  • Check continuity, AC/DC voltages (up to 300V), resistance (up to 30 MΩ), diode and capacitance (between 0.001nF to 3mF).
  • Sleep mode
  • Digital mode selection with audible feedback
  • Automatic ranging
  • Data hold, Max/Min mode selection
  • Sharp display backlight and test lead LED (for input terminal) to work in poorly lit areas
  • CATIII 300V safety rated
This meter keeps the digital display is in your hand and eyesight. This makes for easy reading of the display and one handed access to the function keys. The function key layout of this meter is simple and solid. Because of that you can easily familiarize with this meter within a short amount of time. 

I test this meter reading with Sanwa PC20 multimeter and GW-Instek GDM8034 bench multimeter, and it gives exact readings as above professional multimeters.

As a summery this is a very impressive pen style multimeter. It is easy to use, lightweight (90.2g with battery) and higher quality than its rated price. I like to highly recommended TENMA 72-9390 (especially) for electronic troubleshooting works.

This multimeter is available at element14 (formerly Farnell) and I got it from element14 Singapore within 1½ days. Complete technical specifications of this multimeter are available in here.

Friday, July 20, 2012

LiteASM - Light Weight & Customizable Assembly Compiler & Virtual Machine

LiteASM is a Light weight and reconfigurable Assembly language compiler and Virtual Machine.
It is design to fulfill the following core requirements:
  • As a scripting interface for embedded systems.
  • As a cross platform scripting interface.
  • As a experimental tool for compiler construction.
LiteASM compiler is design with minimum static instruction set. Its dynamic instruction set can be easily extend using compilers configuration files. LiteASM compiler generate fixed length binary output file and it can execute on LiteASM Virtual Machine Simulator (litevm) or on top of platform specific virtual machine. Virtually LiteASM Virtual Machines can execute on any 8bit to 64bit CPU/MCU/DSP platform.

8bit version of Fibonacci series demo on LiteASM Virtual Machine Simulator

LiteASM compiler and Virtual Machine simulator are distribute as a free and open source software (under the terms of GNU GPL version 3.0) and available for both Windows and Linux operating systems. This LiteASM project is still in development and research stages and anyone can contibute to it through

Latest version of LiteASM compiler,  virtual machines, simulators and source codes are available to download at LiteASM – home page.

Saturday, June 16, 2012

Precision Event Logger

This is an easy to construct precision electronic event logger and using this we may be able to measure time differences in two events in range between 0.02 seconds to 6.8 seconds.

This system is mainly design around PIC16F73 microcontroller and 4040 binary ripple counters. The main counter clock (reference counter) is oscillated around 2MHz. Most of the counter related components of this system are based on CMOS family of ICs. If you need more precious lower limit it is recommended to replace all these CMOS family of ICs with TTL equivalents (e.g: 4027 by 74HS73 with slight changes and 4040 by 74HC4040). The clock frequency of the existing counter can also increase up to 6.0MHz.

The counter gets activate and deactivate in positive edge of the input signal. Thanks to the wider operating voltage of the CMOS ICs this counter may be able to handle +5V to +15V of input signal. At the end of the counter session system release total tick count to the RS232 interface and it can receive through any serial terminal software. When applying the inputs it is recommended to maintain minimum of 100ms of interval between each session.

This event logger is useful for physics and electronic experiments, sports events, assembly line monitoring, etc. The input mechanism (e.g: sensor type, logic leveling, etc.) of this system is depends on its application.

The theoretical limit of input interval of this system is wider than above specified values, but we test our prototype in above range and values generated through out-of-range inputs are not guaranteed.

This system is release as an open source hardware project and license under the terms of Creative Commons Attribution 3.0 Unported License. All the project source files, compiled binaries and schematics are available to download at google drive.

Sunday, May 6, 2012

5V 5A Bench Power Supply

This is a high current 5V bench power supply for digital (and analog) electronic experiments. This power supply is based around National Semiconductor's LM338K positive voltage regulator. Virtually this is an indestructible power supply unit with short-circuit protection and thermal overload protection.

5V 5A Power Supply in ATX Power Supply Casing

In our prototype we assemble entire power supply (including step-down transformer) in an ATX power supply casing. When assembling this power supply take extra care about wirings and mountings. LM338K need proper heat-sink and make sure to mount it closer to the main PCB. While assembling makes sure that all the wirings are in correct order. Improper wiring and/or shot-circuits may leads to critical component failures (including voltage regulator IC and step-down transformer). 

Schematic diagram of this power supply unit is available to download at google drive

Monday, April 16, 2012

Simple 8bit digital data logger using PIC16F887

This is an example application for our "Extend PIC Microcontroller‘s RAM by without using EMI" blog post. In this system PIC16F887 microcontroller is interface with four units of UM61512AK – 64K × 8 CMOS SRAMs. Monitoring signal is supplied to the MCU through “PORT A” and all the communications are performing through RS232 interface.

In my previous post most of the readers ask me about pure C language routine(s) for memory access. To fulfill that request I rewrite both memory read and write operations using C programming language. Compared with the previous Assembly language routines, only performance glitch in this implementation is 16bit address decoding part (which consume some CPU cycles than assembly language implementation)

With this given firmware user can operate this system by without installing any driver software in the host side. All the data capturing and reporting operating are done by MCU itself.

Originally I design this data logger to do some photometric data logging. To generalize and to simplify I remove photo-detection and low voltage amplifier from this design.

This is an open hardware project. All the firmware source codes are released under the terms of GNU Lesser General Public License (LGPL) 3.0 and all the documents and other resources are released under the terms of Creative Commons Attribution-ShareAlike 3.0 Unported License. Downloadable content of this article are available at google drive.

Saturday, March 10, 2012

Extend PIC Microcontroller‘s RAM by without using EMI

Virtually all PIC microcontrollers have some banking mechanism to extend addressing to additional memory space. But this external data memory is not directly addressable (except in some high versions of PIC18 devices, which include PIC18F8520, PIC18F6620, etc.).

In this post we describe easy to implement external memory interface for PIC microcontrollers. Theoretically most of the PIC microcontrollers can use this setup to extend its RAM space. At the prototyping stage we test this system with PIC16F877, PIC16F887, PIC18F4550 and PIC18F4620 microcontrollers.

With current setup user may be able to address RAM space up to 192KB. But this can be extended up to 448KB by adding more SRAM modules to the system. In this given schematic we use W24512 – 64K x 8 CMOS SRAMs as a memory modules. 74HC373 latch is used as 8bit to 16bit address extender and 74HC138 demultiplexer is used as memory bank selector.

All the files (including source codes, EAGLE schematic files, etc.) of this system are available to download at google drive.

Monday, February 27, 2012

AT89S2051 base 8bit Bus Monitor

This is an AT89S2051 base 8bit bus monitoring utility. This module indicates bus values using hexadecimal numbering format and notify value changes by the beep. This utility is design to work with any 5V compatible TTL/CMOS - data/address buses.

This 8bit bus monitor requires 5V external power supply. In the idle mode this unit draws 15mA of current and in working mode (when inputs get change) this may raise up to 20mA – 30mA. Due to this low power profile, this system can also attach into the PSU of the "testing system".

This module is release as an open hardware project and it is covered with Creative Commons Attribution-ShareAlike 3.0 license. All the project related resources are available at Open Hardware Hub.

Tuesday, February 21, 2012

Kidogo : 8 channel USB Digital Signal Injector

Kidogo is 8 channel USB self powered digital signal injector. Kidogo system consists with Signal Editor and USB interface module. Kidogo Player is the Signal Editor of the Kidogo system and it can support up to 512 time slots (each range between 1ms to 1s) with 8 channels.

USB interface of the Kidogo system is based around Microchip’s PIC18F2550 microcontroller and generate 5V CMOS and TTL compatible outputs. Dimensions of current version of Kidogo USB interface is 53mm x 40mm (using standard through-hole components) and this can be reduce into more by using PCB layout based on SMD components.

Kidogo Player is design to work under the Microsoft Windows operating systems and it has following general features:

  • Save waveforms and settings as binary file (KDF file) or export waveform as a text file
  • Playback controls such as “Play to segment”, “Play from segment”, “Step back”, “Step next” and “Clear”
  • Shifting and rotating waveforms
  • Invert, Reset, Clocking and Binary Generator functions
  • Copy and Paste waveforms
  • Mute function to each individual channel
  • Launch without any installation or configuration (design to work as portable Windows application)

Kidogo is an open hardware project. All the project files (including PCB designs, source codes, etc.) are released under the Common Development and Distribution License (CDDL). Latest versions of Kidogo project content are available to download at Kidogo GitHub repository.

Wednesday, February 15, 2012

Yet another PIC development board

This is another configurable PIC microcontroller development board with E2PROM base storage and RS232 interface. Purpose of this development board is to emulate simple computation platform with storage, processing unit and control terminal.

This development board contain LM2576-ADJ base 3A switching voltage regulator (with external power terminals), E2PROM base storage (AT24C04) with 512words × 8bit space and standard RS232 serial interface.

All the peripherals of this development board can be isolated using onboard jumpers which include crystal oscillator, MCU reset line, E2PROM I2C interface and UART interface.

This development board supports most of the 40pin 5V PIC microcontrollers which include PIC18F4550, PIC18F452, PIC18F4620, PIC16F877, PIC16F887, etc.

Schematic diagram of this development board is available in Circuitbee with Creative Commons Attribution-ShareAlike 3.0 license.Link

Wednesday, February 1, 2012

Microscopic view of EEPROM IC

This is a Microscopic view of Fairchild Semiconductor's MBM27C64 E2PROM IC and ST Microelectronics M27C512 E2PROM IC.



Thursday, January 5, 2012

Homemade 2.1 Audio Power Amplifier System

This post show completed view of digitally controlled audio power amplifier with virtual surround (which we described in previous post). All the speaker enclosures, power amplifier casing and electronic system are design and developed by us. Configuration of this given step is as follows:

System Components: Power Amplifier, 2 main speaker units, 1 sub-woofer and 18V (5A) SMPS.

Speaker System: Main speaker system consist with 8Ω (45W) 6½ inch Woofer, 8Ω (50W) 3 inch Tweeter with passive crossover.

Subwoofer System: 3Ω (200W) 8 inch Bass Woofer.

All the speaker enclosures are mad out of 9mm MDF (medium density fiberboards) and power amplifier casing is made using 2mm acrylic sheets.

More views of this audio system are available in here.