Completed http://webmaster.buildproject.dk/index.php/projects/completed Sat, 21 Dec 2024 16:53:23 +0000 Joomla! - Open Source Content Management en-gb Setting up Asterisk for Raspberry Pi with Cisco 7940 phones and 3g modem http://webmaster.buildproject.dk/index.php/projects/completed/24-setting-up-asterisk-for-raspberry-pi-with-cisco-7940-phones-and-a-3g-modem http://webmaster.buildproject.dk/index.php/projects/completed/24-setting-up-asterisk-for-raspberry-pi-with-cisco-7940-phones-and-a-3g-modem

4 phone Cisco/Asterix setup4 phone Cisco/Asterix setupThe place where I work, decided to change IP phones. Therefore they changed all their old Cisco 7940/7960 phones in favor of Microsoft Lync. This ment the container was full of really nice phones, and I decided to put them to use - while keeping costs as low as possible.

These days, VoIp service is fairly costly if you do not need 25+phones connected. On the other hand,mobile plans being cheap and almost flatrate (at least in Denmark). Therefore I decided to connect a 3g modem as connon phone-trunk for the Cisco Phones.

]]>
bo@visfeldt.dk (Super User) Completed Fri, 21 Nov 2014 16:09:40 +0000
Rooting a cheap chinese tablet (Denver TAD-70111) http://webmaster.buildproject.dk/index.php/projects/completed/23-rooting-a-cheap-chinese-tablet-denver-tad-70111 http://webmaster.buildproject.dk/index.php/projects/completed/23-rooting-a-cheap-chinese-tablet-denver-tad-70111

denver TAD_70111Denver TAD_70111A few days ago i bought a cheap android tablet. It was a "Denver TAD 70111". It sported 4gb of hdd, 512mb RAM as well as a 7 inch screen and Wifi connection. All for the price of DKK300 (aprox $50).

I bought one and tested it. I was quite impressed with the amount of tablet you got for the money. Only problem was that I could not get the adb-link to function properly.
Therefore I could not install homebrew software or even gain root.

Denver (which is a Danish company) does not have any hardware development themselves, so the tablet was likely a cheap rebranded chinese version. In any case Denver was not inclined to help me troubleshoot the adb link.

So I began trying...

]]>
bo@visfeldt.dk (Super User) Completed Thu, 20 Nov 2014 16:31:58 +0000
Build Trafficlight http://webmaster.buildproject.dk/index.php/projects/completed/21-build-trafficlight http://webmaster.buildproject.dk/index.php/projects/completed/21-build-trafficlight

Background

At my work, we are trying to accomplish something approaching "Continious Delivery". There is a long way to go, but we have gotten our Git server to function alongside Gerrit and the TeamCity buildserver.

In order to visualize our builds I made a small trafficlight, that continiously polls the state of the TeamCity server. The state of the current project is then visualized as Green (build passed), yellow (build in progress) or red (build failed).

Hardware

I am using a small elderly thin client, running a tiny Debian distribution. As the thin client does not have enough internal space, i have installed the distro on a 4GB usb key, using it to boot from.

In addition, i am using a tiny trafficlight designed for industrial machines (aliexpress.com), which state i am changing through a Denkovi relay module. The relaymodule is connected to the thin client using an usb cable.

Now, many people would say that I could just use a Raspberry Pi to do this, avoiding the need for a usb-controlled relay module. True... but I happened to 

The relay module.

I am using a relay module from Denkovi to switch the state of the trafficlight. 

Basics

The build trafficlight is build around a small linux server and a Denkovi Relayboard. Countless 

]]>
bo@visfeldt.dk (Super User) Completed Tue, 17 Jun 2014 11:45:38 +0000
Configuring a TK-102 GPS tracker to work online http://webmaster.buildproject.dk/index.php/projects/completed/17-configuring-a-tk102-gps-tracker-to-work-online http://webmaster.buildproject.dk/index.php/projects/completed/17-configuring-a-tk102-gps-tracker-to-work-online

The TK-102 online gps tracker

Personal-GPS-Tracker-TK102-4Personal-GPS-Tracker-TK102-2A few months ago i purchased a cheap TK-102 GPS tracker.

The idea was that if my motorbike got stolen, I would be able to track it online. Seemed nice.

It did, however, take me weeks if not months to configure it correctly. It is not that it is difficult, there are just a lot of confusion about standards, clones - and the manuals tend to be in english autotranslated from chinese. Also there is some protocol differences you might not be aware of.

This tutorial is mainly for my own sake, and will not mention the simple stuff the tracker can to, so read your own manual :)

Different models:


tk102 abThe first pitfall is that there are several clones of the original Xexun TK-102. You cannot easily tell them apart, and their communication protocols are different. For instance, some models require a response-key from the server when connecting while others just dumps their data in a package.

I tried two different clones of the TK-102, but only managed to get one of them working with an online service. The only noticably difference is that the one i *did* get to work, is charged with a microusb and the one i did *not*, was had a mini-usb plug. Other than that they looked identical.

Also, there is as of now two official different versions: TK-102 and TK-102-2. The difference is supposedly that the latter has a micro-sd slot under the sim-card and can record tracking data. The two also has different communication protocols. 

... however.... Mine DOES have the micro-sd slot, and should therefore be at TK-102-2, still though, it used the TK-102 protocol. In the product pages it is described as TK-102, rev B.

Configuration

Now, most of the devices and clones are configured in pretty much the same fashion. Also they all have the standard password of "123456" untill you change it.

Wialon ID testWialon ID testGps Orange tracking serviceGps Orange tracking service

  1. Send the command begin123456 to the tracker. It will then initialize the device and begin tracking. It should reply begin ok.
  2. Physically call the device 10 times. It will respond with two beeps. Calling 10 times may seem a little excessive, but at the 10'th time, your number is stored permanently in the memory (also on powerout) , in a "positive list". In the future you can just call the device and it will send you an sms with its location.
  3. You need to obtain the IMEI number, which is how most devices identify themselves. I did, however, read that some clones use some other kind of serial numbers. It is should be stamped on a sticker inside the device, but confirm that it is consistent by sending the command imei123456. You should get the imei back. Write this down, as this is how you identify the device in the online service you will be using to track it.
  4. Some defices allows you to set the time zone. send time zone123456 x where x is the number of hours you are + or - from GMT (you can use negative numbers by prefixing a minus)
  5. Unless you are setting up your own tracking service, i recommend trying GPS Trace OrangeIt is commercial tracker software, but you can have one GPS registered for free. Note, that if your device does not send data to them for a month, your account will be deleted. Even if you do not want to use their service, try their test service to make sure you have a hole through from the device to the net..
    1. Set your device to use the Wialon GPS Device Unique ID Checker. Send adminip123456 193.193.165.167 20157 The first part is the IP address, the last the port. Each different GPS device has a seperat port, including the TK-102 (port 20157) and TK-102-2 (port 20668). While it seems odd that there are different ports, remember that they have different protocols - and this is how the know how to decode the telegrams. The tracker replies to the command with Adminip OK
    2. Set up your APN for the tele communications provider you have chosen. Most companies in denmark does not have password or usernames but simply the apn "internet". In that case send Apn123456 internet. Be aware that, if you do need user/password for your provider they are set differently according to clonemodel. Also be aware that each time you change change the recieving ip address you need to set the APN again!!! This is due to the whole internal communication registry is cleared each time you do so. Still it was not mentioned in my manuals. It will reply Apn OK
    3. Switch from SMS to GPRS mode: Gprs123456. It should reply Gprs OK.
    4. Now check that there is a connection: Send Check123456. You should get stats for the battery (in%), if the GPS is on, If the GSM is on and if the GPRS is on. Be aware that it will take a few minutes for the GPRS to become active.
    5. Set the tracker to send a new package every 30 seconds. There are different commands for different clones, but the two I have come across are t030s***n123456 or fix030s***n123456. These commands are a little annoying as they do not reply with an ok. I surgest you consult your manual or try both.
    6. Go to Id.wialon.Net. Here you should be able to identify your device if you have a connection all the way through.
  6. When you know everything functions, register an account at GPS Trace Orange. Thereafter you should change your IP to 193.193.165.166 using the same method as before. remember to repeat the APN and GPRS steps as well!!
  7. Now go and play with your new GPS tracker.
  8. Open Gps TrackerIf you need cooler stuff, make your own server using open source: Open Gps Tracking System. It works well, is simple to set up and does not require posh hardware.

Data usage

As data is rarely free, you should do some calculations on how much data traffic you need to cover your needs.

The telegram sent by different GPS trackers are of different size, so check for the model you are using. Also different clones of the TK-102 may have different size telegrams from the original. I have not bothered to check the exact size of mine, but if you have your own server, this should be simple using a network analyzer.

Anyway. The forums i checked states that it is around 130-180 bytes long... so if you add some TCP overhead... My bid is, definately less than 300 bytes a telegram.

Now check how many updates you want a day. I personally want as many as possible, but the TK-102 specification states (without any explanation),  that the unit should not send position more often than every 20 secs. I guess that is how often the GPS chip is polled for location.

24 hours is  86400 Seconds. This gives us 4320 updates a day with a 20 second interval.
4320 * 300 bytes = 129600 bytes = 1.3 Megabyte datausage a day.
1.3 Megasbyte *31 days = 96.1 Megabyte a month.

Update 2014-04-05! - FREE tracking!

Currently the scandinavian company "Telenor" is bragging about having the best network coverage in Denmark. Therefore they are giving away SIM cards with 200 Mb/month away for FREE in the hope that people like it so mutch that they will buy more traffic. These cards are PERFECT for gps-tracking. Especially since they will not charge you extra if you overdo the 200 mb, just cut the connection and tend you an sms with details on how you can get more data. (the TK-102 will just discard this message). This should allow you to set the interval to 5 secs without overdoing the datalimit (but check yourself. Dont blame me if you go over)

Using this offer there is only one pitfall. You are not told what the SMS number is for the SIM card you are getting, so using this card it is hard to configure the device. Well, not to worry - just use another simcard for configuration and then switch cards. (Almost all carriers in Denmark uses "internet" as apn)... I actually just swapped my cards and it worked.


Quickly! Get it here: 
http://www.telenor.dk/privat/mobilt_bredbaand/gratis-sim/ 

]]>
bo@visfeldt.dk (Super User) Completed Wed, 25 Dec 2013 22:07:39 +0000
SmsServer help http://webmaster.buildproject.dk/index.php/projects/completed/16-sms-server-help http://webmaster.buildproject.dk/index.php/projects/completed/16-sms-server-help

The SMS server is a project build for Ad-hoc communications between people coupled in a loose pyramidal structure. It has existed nearly two years, and is nearly complete. It is, however, still undergoing expansion and continious innovation

System Layout

 

]]>
bo@visfeldt.dk (Super User) Completed Wed, 11 Sep 2013 17:48:18 +0000
Child Crying Control http://webmaster.buildproject.dk/index.php/projects/completed/13-childcryingcontrol2012 http://webmaster.buildproject.dk/index.php/projects/completed/13-childcryingcontrol2012

Child Crying Control using open source tools.

nocry

How to get your neighbors annoying constantly crying child to shup up using simple automation.

(disclaimer, I have actually not used this system as I am way too nice a person.
The whole text is written in dispair as my neighbors child has a nasty habbit of crying furiously through most of the night, and the parents fails to control it.
I have tested the technical aspects of the system described below and they seem to work well.
Still, hower, this is rather drastic measures and  talking the matter over with the parents will surely give better results. After all. Even parents must acknowledge that other people exists outside their baby-bubble)

In this experiment I will be using open source tools. I do not like using Window$ very much and has hence found some programs that runs on Debian Linux. You can surely find similar for Window$.

Anyway... Lets get started....

Facts:

  • Smaller Children and babies are crying at a frequency at 1000-5000 Hz, centered at 3500 Hz. This is also the frequency at which adults are the most sensitive, making it even more annoying.
  • Babies and small children has much better hearing in the higher frequencies than adults. Ideal hearing goes up above 20kHz, but degrades aldready from the the 8th living year. As a result, most children and a few adults can still hear tones aproaching/surpassing the 20kHz
  • Most small children learns well by repetition.

Theory

shock collarShock Collar for Dogs

In dog training it is possible to get electric collars in order to give the dog a gentle zap whenever
it oversteps its bounds. After a short while the dog will learn not to enact in a specific activity.
It is quite likely that this theory can be used on humans as well.
As we cannot very well zap the children, we can nudge them in the right direction using a high annoying sound
every time they overstep their bounds.

In short: Detect crying and respond with a powerfull blast of sound in a frequency area that only they can hear.


The tools

  1. A computer running Debian, Ubuntu, Xubuntu or another derivative - or windows if you do not mind searching for other
    audio triggerConfiguring Audiotrigger
    programs that will run under this OS.
  2. Audacity. An open source tool to manipulate sound. It has an buildin tone generator and can generate a tone high enough that only small children will be able to hear it. Get the program HERE. (Also exists for windows)
  3. AudioTrigger. An open source tool designed to detect sounds within specific parameters and run a program as response. While it is not perfect and does detect a "loud high pitched sound" instead of "crying", it is good enough for prototyping If you need better control, do some MatLab ccripting instead. Get AudioTrigger HERE (The program is made for Debian and distributed in .deb format. If you use an alternative OS, you can probably find something else.
  4. Mpg123, A command line player that can play mp3 files. Install it by typing "sudo apt-get install mpg123". It is run with the command mpg123 fairness.mp3. If you were on Windows, you could use Windows Media Player that is part of Windows. It can be run from command line like this "c:\wmplayer.exe fairness.mp3"
  5. A highend amplifier. Most amplifiers does not do well in the edge of the audible spectrum. You might need a highend amplifier to reach 20KHz
  6. A pair of good speakers. As with amplifiers, cheaper speakers are centered around the frequencies that are used the most. Speakers designed for Jazz or Classical music will do fine.
  7. A Microphone. Luckily you do not need an expencive one. Childrens crying are smack in the middle of the recordable spectrum, and you can probably detect it even from the buildin mic on a laptop.

The doing

Well, from here it is fairly straight forward:

speakerwallYou will need plenty of amplification
  • Use Audacity to create a highpitched sound only the children can hear. Personally I have quite good hearing, so I had to go way over the normal 20kHz. The specific frequency is, however, not that important just make sure that it is just above what your own hearing accepts.
  • Setup AudioTrigger to play the sound whenever it detects crying
  • Make sure the amplifier is turned well up. Higher frequencies do not penetrate walls well.


Conclusion

While this should work, it is utter bullshit and should not be nessesary. It is the kind of thing you would only ever do if your sanity was in threatened (which repeated sleepless nights will do).
Parents should take care of their kids - They chosed to have them, not the peaceloving neighbor.
If parents cannot themselves take care of the kids, they should seek help.

]]>
bo@visfeldt.dk (Super User) Completed Thu, 10 May 2012 07:49:14 +0000
Unbricking a (Soft) bricked Euro Samsung Galaxy Tab GP-P1000 http://webmaster.buildproject.dk/index.php/projects/completed/12-unbricking-p1000-2012 http://webmaster.buildproject.dk/index.php/projects/completed/12-unbricking-p1000-2012

Why this tiny guide?

GT-P1000 bricked

This small guide tried to help people that has bricked their P1000 while trying to install ClockWorkMod - or by other means.

There are a number of forums telling you how to do this, but I have written this as i could not find anywhere that told me how to recover from bricking by CWM... later i found out that either your device is soft-bricked, else it is not. The recovery process is the same. Anyway, it might help some other poor sods...

Now, there are two ways you can brick your tablet, hard and soft.

  • Hard means that the device is dead. Game over.
  • Soft means that you can still get it download mode by pressing power+volume down when it is off.

This guide will help you if the latter is the case.

]]>
bo@visfeldt.dk (Super User) Completed Fri, 20 Apr 2012 09:27:06 +0000
Extending the range for a router/repeater http://webmaster.buildproject.dk/index.php/projects/completed/11-extendedrangerouterrepeater2012 http://webmaster.buildproject.dk/index.php/projects/completed/11-extendedrangerouterrepeater2012

Why extend the range of the routers?

Hacked D-LINK
extended range router repeater 2012 030  rs

I am building the infrastructure of a network at a scoutcentre in Jutland.
It might sound like a trivial task, but money is severely limited and demand is high.
There are usually around 30 clients on the wireless net and around 60 when in peak periods.
This number will certainly rise as most young people are carrying smartphones at alle times.

The network so far consists of a wired backbone and a bunch of smaller wireless
repeater-islands for places where wired net is not feasible. These repeater-stations are, however placed where wireless does not have a direct line of sight, and the off-the-shelf routers cannot cope. New antennas with better rx-tx was needed.

]]>
bo@visfeldt.dk (Super User) Completed Sun, 15 Jan 2012 19:46:47 +0000
User experience prototypes for mobile devices http://webmaster.buildproject.dk/index.php/projects/completed/10-user-experience-prototypes-for-mobile-devices http://webmaster.buildproject.dk/index.php/projects/completed/10-user-experience-prototypes-for-mobile-devices

User experience design for mobile devices

Fitbit Golf trainerFitbit Golf trainer

In the spring of 2012 I took the course 02266 - User Experience Engineering as a part of the program for my Masters at the Technical University of Denmark (DTU).
Though it was an university course i decided to post it anyway as it was quite entertaining (and a whole lot of hard work).
The main objective of the course was to teach the students how to create a nice user experience on an array of different devices. Assignments was mostly given along the lines "Design an interface for use with this project/idea - how can you explot the possibilities in that?"

Most of the prototypes was for mobile devices and made in a trial of Axure 6.0 from www.axure.com

Below is a few of the prototypes we made (I must stress that i did not make this alone and that we were 4 in the group - Sune Andersen, Johan Flod, Allan Munck and Me - credit where it is due ;)

]]>
bo@visfeldt.dk (Super User) Completed Thu, 12 Jan 2012 21:27:55 +0000
Raft from a waxed groundsheet http://webmaster.buildproject.dk/index.php/projects/completed/9-raftfromgroundsheet http://webmaster.buildproject.dk/index.php/projects/completed/9-raftfromgroundsheet

Why build this stuff??

Sailing merrilySailing merrily

 Every year scouts from all over Denmark compete in building and sailing homemade rafts 10 km on the Mill River. The event is called "Mill River Rafting" (dk:Mølleåsejladsen), and scouts are supposed to build their raft in two hours.

They are only allowed to use a tarp, hand tools, rope and whatever they can find in the forrest. Normally scouts use factory made industrial grade tarps that is cut to a special shape. This, year (2011), however, it was Mill River's 50 year aniversory, so a few of us figured that we would compete in same fashion our grandparrents did back then.

]]>
bo@visfeldt.dk (Super User) Completed Sun, 09 Oct 2011 12:10:33 +0000