adb not running

The more common this problem, the solution is as follows:

1, Enter CMD into the DOS interface, enter the android-sdk-windows\platform-tools directory, execute the following command

Start ADB start-server
The following error occurred
* daemon not running. starting it now on port 5037 *
ADB server didn’t ACK
* failed to start daemon *

2, Execute the following command
adb nodaemon server
The following error occurred
cannot bind ‘tcp:5037’
The original ADB server port binding failed 

3, Enter the following command query which using port 5037
netstat -ano | findstr “5037”
The following information

4, Open the task manager kill 1616 out of the process

5. Taskkill -pid 1616

adb not running

Enabling Remote Access to MySql

Hello Temans Temans…. this will remind me.. hehe

by default remote access to the MySQL database server is disabled for security reasons.
However, some time you need to provide remote access to database server from home or a web server.
This post will explain how to setup a user account and access mysql server remotely.

case-nya :

1. gw punya server di yang ada mysql-server database-nya

english: I have a mysql-server on

2. nah gw punya client tapi IP-nya dinamics, di pakenya di android, iOS dll

english: and the clients have dinamics IP-Address, that run on Android, iOS or Desktop App

3. gw mau akses / Query dari manapun. untuk menambah atau menghapus atau apapun pada record-nya

english: I wanna access that database or query from anywhere, for adding, remove record etc.

after, 5 minutes googling and confusing and make my head start to blow, I finally found a simple way to do this.

lets start!!!

Login to your Machine

assume that your machine is a *nix machine, you can do this from any-platform, from windows you can

access remotely by using putty ssh, from linux you can directly using ssh.

$ ssh

Edit The “my.cnf” mysql Configuration File

you have to edit this file and add your public-IP on the following line :

# vim /etc/mysql/my.cnf

add this :

bind-address    =

and the rest of configuration file, should be look like this :

user = mysql
pid-file = /var/run/mysqld/
socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
language = /usr/share/mysql/English
bind-address =

Save and Close The File

you have to restart the mysql service

# /etc/init.d/mysql restart

Grant Access to Any Remote IP Address

example parameter :

Database  : myDatabase

User           : root

Password : password

remoteIP : ANY


connect and login to database :

# mysql -u root -p

enter this command :

# mysql> GRANT ALL ON myDatabase.* TO root@’%’ IDENTIFIED BY ‘password’;

logout from mysql

# mysql> exit

ok, now you can try to access and remotely query or add or whatever you want to your database.


Thanks for Reading


Tommy Agustianto

Enabling Remote Access to MySql

current loop


I’d like to explain about current loop which usually used in instrument and process control systems, remember… CURRENT LOOP not CURRENT LOVE, hahahahaha…stt… dont curcol on the blog please. hihi.


1. what do you know about 4-20mA?

2. why we transmits a current not voltage?

3. how to measure a current loop?

4. how to generate a simple current loop from a microcontroller?

5. how its use? 4-wire? 2-wire?

6. what systems that applicable for this?


lets study one by one, I’m  not smart, but maybe I’m one step ahead from you.


4-20mA :

First appearing in the 1950’s with the advent of electricaland electronic controls, the 4-20mA signal standard reigns
as one of the most popular mediums for signal transmission and electronic control in industrial environments nearly
60 years later, at that year Indonesia still playing sharp bamboo.

Prior to the widespread adoption of electrical and electronic controls, buildings often used pneumatic control
systems. Large and powerful compressors drove 3psi to 15psi pneumatic signals throughout a plant and these
pneumatic lines connected to pneumatically controlled valves and pneumatically controlling valves in order to drive
proportional controls and actuators throughout the building, all powered from compressed air. Air pressure at 3psi
served as the “live-zero” and 15psi represented 100%. In this way, the more modern 4-20mA signal standard
emulated the earlier 3-15psi pneumatic controls. Any pressure below 3psi was considered “dead zero” and an alarm
condition. Some installations still use pneumatic control today. Modern I/P converters (current-to-pressure
transducers) are available to convert the 4-20mA control loops to common pneumatic ranges, such as 3-15psi, 1-18psi, 3-27psi, and 6-30 psi.

now, lets see this triangle | relation between R.I.V R(Resistance)/I(Current)/V(Voltage).

Current Loop

From the triangle, I can quickly identify the three common components of a current loop, how they are wired together,
and even the direction of current flow. For my mental model, each side of the triangle represents a component of the
current loop. The vertices of the triangle represent a wired connection between these components. For reference, I
also place a positive/plus sign on the “peak” of the triangle. I will also use the first three letters of “TRIangle” to
identify the principle components. Accepting the convention that current flow will move from the supply positive to
and return to the supply negative, I see that current moves counter-clockwise in my symbolic current loop.

Thats enough for phase one, I’ll continue later…


current loop

Using Serial Port /dev/ttyAMA0 on Raspberry Pi

hello and Happy Fasting All

I’d like to share about Serial Port on Rpi, kebetulan gw lagi working on Holux GPS GR-89 n mau connect to Rpi UART.note for you all, RPi UART Level itu 3.3volt and GPS gw 5v yang di take from Rpi Pins. on the out world(beuh bahasanya) maksudnya di luaran banyak yang bilang level itu must be converted, but trust me, you dont have to do that thing, just connect lah. it works!! secara umum the Raspberry Pi’s serial port is configured to be used for console input/output. Whilst this is useful if you want to login using the serial port, it means you can’t use the Serial Port in your programs, to be able to use the serial port to connect and talk to other devices (e.g. Arduino/BT-Module), the serial port console login needs to be disabled. Needless to say you will need some other way to login to the Raspberry Pi, and we suggest doing this over the network using an SSH connection, you can do this with putty(jangan jorok ye) terminal.

Just follow these instruction ya, hehe..

Disable Serial Port Login

To enable the serial port for your own use you need to disable login on the port. There are two files that need to be edited The first and main one is


This file has the command to enable the login prompt and this needs to be disabled.

Edit the file and move to the end of the file.

You will see a line similar to

T0:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100

Disable it by adding a # character to the beginning.

Save the file.

#T0:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100

Disable Bootup Info

When the Raspberry Pi boots up, all the bootup information is sent to the serial port. Disabling this bootup information is optional and you may want to leave this enabled as it is sometimes useful to see what is happening at bootup. If you have a device connected (i.e. Arduino) at bootup, it will receive this information over the serial port, so it is up to you to decide whether this is a problem or not.

You can disable it by editing the file


The contents of the file look like this

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait

Remove all references to ttyAMA0 (which is the name of the serial port). The file will now look like this

dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait


In order you enable the changes you have made, you will need to reboot the Raspberry Pi

# sudo shutdown -r now

Test the Serial Port A great way to test out the serial port is to use the minicom program.

If you dont have this installed run

# sudo apt-get install minicom

Connect your PC to the Raspberry Pi serial port using an appropriate serial port adapter and wiring, then open Putty or a similar serial terminal program on PC side. Setup a connection using the serial port at 9600 baud. Now run up minicom on the Raspberry Pi using :

# minicom -b 9600 -o -D /dev/ttyAMA0

What you type into the minicom terminal screen should appear on the serial PC terminal n sebaliknya,

this is contoh tampilan minicom lewat Putty SSH Terminal in my Win 7, I do this bcoz this is the simple way to access the Rpi.hehe..

NMEA data berhasil gw dapetin, ksananya its up to me dongs.

NMEA Burst on Rpi
NMEA Burst on Rpi — Raspberry Pi + Holux GPS GR-89

hehe.. ok, selamat mencoba kawan. ayo bobok jam stengah 4 nanti kita sahur 🙂

great things begin from the small things -tommy-

Using Serial Port /dev/ttyAMA0 on Raspberry Pi

USB tethering from Android to Raspberry Pi

USB tethering will not work with initial default config of usb port in rasp pi, this is one of many way to connect your RPi through your android internet connection using usb tethering


1. Boot your Raspberry Pi

2. Edit the network interface configuration file

# sudo nano /etc/network/interfaces

3. Add this following line “iface usb0 inet dhcp”

auto eth0
iface eth0 inet dhcp
iface usb0 inet dhcp

4. Save the file. Ctrl-o and exit Ctrl-x

5. Run the new configuration

# sudo ifup usb0

6. Reboot your RPi

# sudo reboot

I have try this way and succed

– RPi model B
– raspbian os
– HTC Legend with CyanogenMod

USB tethering from Android to Raspberry Pi

Karman Filter Calculation


after review the rest of my blog, I just realized that so many post that explaining about IT/UNIX hehehe…

one thing that you should know, I’m electro engineer..wkwwkwkwk

this time, I’ll post about Karman Filter, ok..lets start

Whats The Karman Filter?

first of all, you have to know about LDS( Linear Dynamical System) a partially observed stochastic process with linear dynamics and linear observations, both subject to Gaussian noise. It can be defined as follows, where X(t) is the hidden state at time t, and Y(t) is the observation.

here's the equation :
x(t+1) = F*x(t) + w(t),  w ~ N(0, Q),  x(0) ~ N(X(0), V(0))
y(t)   = H*x(t) + v(t),  v ~ N(0, R)

The Kalman filter is an algorithm for performing filtering on this model, i.e., computing P(X(t) | Y(1), …, Y(t)).
The Rauch-Tung-Striebel (RTS) algorithm performs fixed-interval offline smoothing, i.e., computing P(X(t) | Y(1), …, Y(T)), for t <= T.

The Example of Karman Filter :
Here is a simple example. Consider a particle moving in the plane at constant velocity subject to random perturbations in its trajectory. The new position (x1, x2) is the old position plus the velocity (dx1, dx2) plus noise w.

[ x1(t)  ] =  [1 0 1 0] [ x1(t-1)  ] + [ wx1  ]
[ x2(t)  ]    [0 1 0 1] [ x2(t-1)  ]   [ wx2  ]
[ dx1(t) ]    [0 0 1 0] [ dx1(t-1) ]   [ wdx1 ]
[ dx2(t) ]    [0 0 0 1] [ dx2(t-1) ]   [ wdx2 ]

We assume we only observe the position of the particle.

[ y1(t) ] =  [1 0 0 0] [ x1(t)  ] + [ vx1 ]
[ y2(t) ]    [0 1 0 0] [ x2(t)  ]   [ vx2 ]
                       [ dx1(t) ] 
                       [ dx2(t) ]

Suppose we start out at position (10,10) moving to the right with velocity (1,0). We sampled a random trajectory of length 15. Below we show the filtered and smoothed trajectories.

aima_filtered Smoothed Trajector

The mean squared error of the filtered estimate is 4.9; for the smoothed estimate it is 3.2. Not only is the smoothed estimate better, but we know that it is better, as illustrated by the smaller uncertainty ellipses; this can help in e.g., data association problems. Note how the smoothed ellipses are larger at the ends, because these points have seen less data. Also, note how rapidly the filtered ellipses reach their steady-state (Ricatti) values.

here’s the code to generate the Graphs :


% X(t+1) = F X(t) + noise(Q)
% Y(t) = H X(t) + noise(R)

ss = 4; % state size
os = 2; % observation size
F = [1 0 1 0; 0 1 0 1; 0 0 1 0; 0 0 0 1];
H = [1 0 0 0; 0 1 0 0];
Q = 0.1*eye(ss);
R = 1*eye(os);
initx = [10 10 1 0]’;
initV = 10*eye(ss);

seed = 9;
rand(‘state’, seed);
randn(‘state’, seed);
T = 15;
[x,y] = sample_lds(F, H, Q, R, initx, T);

[xfilt, Vfilt, VVfilt, loglik] = kalman_filter(y, F, H, Q, R, initx, initV);
[xsmooth, Vsmooth] = kalman_smoother(y, F, H, Q, R, initx, initV);

dfilt = x([1 2],:) – xfilt([1 2],:);
mse_filt = sqrt(sum(sum(dfilt.^2)))

dsmooth = x([1 2],:) – xsmooth([1 2],:);
mse_smooth = sqrt(sum(sum(dsmooth.^2)))

hold on
plot(x(1,:), x(2,:), ‘ks-‘);
plot(y(1,:), y(2,:), ‘g*’);
plot(xfilt(1,:), xfilt(2,:), ‘rx:’);
for t=1:T, plotgauss2d(xfilt(1:2,t), Vfilt(1:2, 1:2, t), 1); end
hold off
legend(‘true’, ‘observed’, ‘filtered’, 0)

hold on
plot(x(1,:), x(2,:), ‘ks-‘);
plot(y(1,:), y(2,:), ‘g*’);
plot(xsmooth(1,:), xsmooth(2,:), ‘rx:’);
for t=1:T, plotgauss2d(xsmooth(1:2,t), Vsmooth(1:2, 1:2, t), 1); end
hold off
legend(‘true’, ‘observed’, ‘smoothed’, 0)


on the next post, I’ll show you how to implement this Algorithm into Simple Manipulator Robot.

Thank’s for, thank you for reading maksudnya. wkwkwk
see you, keep on rock

Karman Filter Calculation