Archive for the ‘TKJ Electronics’ Category

Face Recognition using Eigenfaces and Fisherfaces

July 10th, 2017 No comments

In this project I developed an Android application with Jonathan Wang at UIUC demonstation face recognition using Eigenfaces and Fisherfaces.

I will not go into details on the theory about Eigenfaces and Fisherfaces in this blog post. Instead the reader should refer to the two reports written as part of the project: Eigenfaces for Recognition and Near-Real-Time Facial Recognition on an Android Tablet Using Fisherfaces. I would also recommend reading the original papers: Eigenfaces for Recognition and Eigenfaces vs. Fisherfaces: Recognition Using Class Specific Linear Projection.

The library is written in C++ where all the matrix operations are performed using Eigen. One of the advantages of using Eigen is that it can be used on any hardware platform (even microcontrollers), as it got no library dependencies. This allowed us to easily test the code on our laptops and then afterwards use it directly in the Android application by using the Android NDK toolset. As usual the code is available on Github: FaceRecognitionLib.

A few screenshots of the Android application can be seen below:

Google Play

The application is available on Google Play and the source code is provided at the following link.

If you have any questions leave them below or open up an issue on Github.

Categories: TKJ Electronics Tags:

Universal Robots vision-based LEGO DUPLO stacker

June 7th, 2017 No comments

As part of the Robot Vision course at the Institute of Electronic Systems at Aalborg University we had to develop a vision-based LEGO DUPLO stacker using a Universal Robots UR5 robot, a webcam and MATLAB. Equipped with a robot cell as shown below, the task was to develop a system capable of stacking randomly placed LEGO DUPLO bricks in a certain order.

A detailed description of the project and the development of both the image processing and robot control software, is contained within the project report available here: Universal Robots vision-based LEGO stacker.pdf

Conceptual robot cell layout

Using several image processing techniques, including color segmentation, thresholding, BLOB analysis, feature extraction etc. the system is capable extracting the color, location and orientation of the DUPLO bricks currently present in the camera image. This allows an Universal Robots UR5 robot arm to pick up the brick and stack them in an color-ordered scheme of: red, green, blue, yellow, orange.

The webcam is mounted on the robot arm to avoid having to fixate it anywhere else and to link it up to the tool position. This allows easy calibration between the robot tool frame and the camera frame by using the free-drive mode of the Universal Robots arms, allowing the user to grab the robot arm and move it manually to a calibration spot.

A video demonstration of the project including the calibration procedures is shown below.

The project is Open Source and all resources, including both MATLAB code and the URScript, are available online in the GitHub repository:

Read more…

Categories: TKJ Electronics Tags:

Painting with drones

December 27th, 2016 No comments

The purpose of this project was to come up with an interactive demonstration for the Pygmalion Festival 2016 at UIUC. The end result was a demo where an Android device was given to the visitors, each visitor could then draw any continuous path on the Android device. The x,y-coordinates would then be uploaded to the cloud and a trajectory based on Bézier curves would be generated using a Python script. Finally ROS was used to control a small drone. Camera software was then used to highlight the brightest light in the scene, in this case a LED on the drone. This resulted in the path being visualised in 3D-space.

An overview of the project can be seen in figure below. The Android application is used as a simply user interface. The path drawn is then uploaded to Dropbox and a trajectory is generated using a Python script.

Project overview

Project overview

Finally the drone flies the trajectory. A short video of the project can be seen below:

Read more…

Software Defined Radio with USRP N200 and LabVIEW (GUIDE)

March 6th, 2016 1 comment

As a part of my electronic engineering degree I have decided to look into the world of Software Defined Radios, a complicated but very powerful tool.

Software Defined Radios, SDR in short, is in short a software-based radio platform, making it possible to program the RF transmissions schemes and updating them on the fly if necessary, a bit similar to what we in the digital world know as FPGA’s. This allows end-products to redefine their radio needs, such as when sending a satellite into orbit where it would be impossible to update the RF hardware platform to support other radio protocol and schemes.

USRP N200 module

USRP N200 module

To get familiar with the SDR’s I decided to work with a basic USRP N200 module which is supported by LabVIEW and other tools, eg. GNU Radio, and write a detailed report about my progress and discoveries (see the bottom of the post for a link to the report).
The N200 module is controlled over an Ethernet interface, which is also used to exchange (transmit and receive) the so called IQ samples when they have been converted by the analog RF frontend.

In the video below I demonstrate the use of a Software-Defined radio setup with two USRP N200 modules programmed in LabVIEW programmed with an AM modulation and demodulation scheme.
The modules are programmed and tested thru LabVIEW where a graphical interface allows me to transmit a single tone signals or an audio-file from one SDR unit to another for.

Read more…

IoT Arduino Vending Machine

February 7th, 2015 6 comments

In this blog post I will describe a IoT (Internet of Things) Vending Machine that I built quite some time ago with a friend of mine Sigurd Jervelund Hansen.
At Sigurd’s dorm room they got hold of an old vending machine free of charge, as it did not work. We quickly decided that we wanted to get it working and give it a overhaul as well. In the end we enabled it to take both RFID/NFC cards and coins and make funny twitter updates about it.

The video below gives a short overview on how it works.

As mentioned we reused some shift registers, relays and voltage regulators on the original mainboard. One Arduino Pro Mini is connected to the mainboard and takes care of reading and lighting up the buttons (lights up if the relevant slot is not empty), controls the 7-segment LED display, reading the output from the coin validator and returning money if the user requests it by pressing a dedicated button.

Read more…

Categories: Arduino, Raspberry Pi, TKJ Electronics Tags:

LaunchPad Flight Controller

January 23rd, 2015 8 comments

As some of you might know I have been studying in San Francisco the last semester at San Francisco State University. For that reason I have not done as much as development as I usually do, due to all my equipment being back in Denmark and also because I prioritised being social and not just sit behind my desk coding all night 😉

Anyway I did not fully stop working. I actually started working on my own flight controller written from scratch in one of by courses. Below is the result so far:

Read more…

Full size DIY Balancing Robot

July 6th, 2014 120 comments

It has been quite a while since my last blog post, but I am finally ready to reveal what I have been working on the last months. Ever since I made my first balancing robot: and the Balanduino I wanted to build myself a full size version which I would be able to ride just like a regular Segway.

Finally I decided to make one together with a good friend of mine Mads Friis Bornebusch in a course at my university DTU (Danish Technical University/Technical University of Denmark).

Video demonstration

Mechanical construction
The main frame is an aluminium checker plate that is 500x360x7mm which the motors are bolted onto. This width was chosen, so it would be able to go through a normal door opening. The motors used are two MY1020Z 500W, 24V, 12.6Nm brushed DC motors.

I ordered them from Germany, as I needed them right away, but you should be able to get them much cheaper by ordering them directly from China.

Below is an image of the aluminium checker plate after we have drilled the holes for the 8mm steel bolts. Note that these are countersunk, so they are flush with the surface. I would recommend using lock nuts to ensure that the bolts will stay in place – you can also use Loctite instead.

Aluminium checker plate - ready to mount the motors

Aluminium checker plate – ready to mount the motors

Motor with hub

Motor with hub

Read more…

New contributor at TKJ Electronics – Diego

January 30th, 2014 4 comments

We are happy to announce a new contributor and hopefully soon consultant at TKJ Electronics, Diego Ayala.
I have been in touch with Diego for quite a while and we have been talking about his experience with the STM32 family and other ARM M0, M1 and M4 cores together with the Keil and CooCox IDE’s. So an experience like his is really usefull for ARM embedded projects.

To display some of his work we decided to go thru one of his recent projects, a color tracking device running on the STM32F103. A project that really displays what the ARM Cortex-M3 device is capable of doing, as long as you optimize well enough.

Read more…

Categories: ARM, TKJ Electronics Tags:

Year 2013 for Thomas

January 25th, 2014 7 comments

thomasIt has been quite a while ago since my last post here at the Blog which is due to a lot of new things and changes that happened in the past year. So with the following post I would like to tell a bit about myself and why I haven’t been writing post so frequently.

“Who am I?”

Most of you probably don’t know a lot about either me or Kristian, but I thought it would be the right time now to give a better introduction about me and myself. I have mainly been keeping these details about myself private, due to my age and the difficulty in freelance work and consultancy when being a newly started company and now with an age of only 20 years.

“My name is Thomas Kølbæk Jespersen. I’m 20 years old and a keen electronics enthusiast, entrepreneur, R&D ‘engineer’ and now being a student at Aalborg University studying Electronics Engineering.”

A lot of things happened for me and my company TKJ Electronics in the past year, which are but not limited to:

  1. Gap year
  2. Sales manager for solar panels
  3. Balanduino project
  4. Travel adventure
  5. Moving to Aalborg
  6. Aalborg University
  7. Employment at Create It Real
  8. General TKJ Electronics consultancy

Read more…

PS4 controller now supported by the USB Host library

January 12th, 2014 132 comments

I am very pleased to announce that I have now added support for the PS4 controller via Bluetooth. This will allow you to read all the buttons and joysticks with the same API as all the other libraries I have written for the USB Host library.

PS4 controller

To get started you should look at the provided example. It shows how to read the different buttons and joysticks. I still haven’t figured out how to control the light, rumble and read the accelerometer, gyroscope and touchpad, but hopefully I will figure that out soon.
Read more…

Categories: Arduino, Bluetooth, TKJ Electronics, USB Tags: