Thursday, December 24, 2015

Android - Debugging Lenovo A7-30 Tablet (A3300) on Linux

If you are using Windows, please read my article HERE on how to debugging using OEM driver from Lenovo Smart Assistant.

Lenovo A7-30 Tablet (A3300)

It has been a while since I wrote post about Android development, right? Today, I share with you how to add Lenovo A7-30 Tablet (A3300) as device for debugging with ADB on Linux operating system. Just like before, I did some research and keep trying until succesfully install and use this device. Oh, make sure you already enable developer mode on that Android table first before proceed to the #1 step.

Wednesday, December 23, 2015

Fixed - JDK >= 1.7.0 needed by astah_professional

Problem:
$ sudo dnf install astah-professional-7.0.0.846701-0.noarch.rpm 
Last metadata expiration check performed 0:26:51 ago on Wed Dec 23 07:38:28 2015.
Error: nothing provides jdk >= 1.7.0 needed by astah_professional-7.0.0.846701-0.noarch
(try to add '--allowerasing' to command line to replace conflicting packages)

Fixed :
$ sudo rpm -ivh --nodeps astah-professional-7.0.0.846701-0.noarch.rpm 
warning: astah-professional-7.0.0.846701-0.noarch.rpm: Header V3 DSA/SHA1 Signature, key ID c22bd678: NOKEY
Preparing...                          ################################# [100%]
Updating / installing...
1:astah_professional-7.0.0.846701-0   ################################# [100%]

Linux - Disk space

How to check free disk space on an linux machine ?
$ df -h
Filesystem               Size  Used Avail Use% Mounted on
devtmpfs                 3.9G     0  3.9G   0% /dev
tmpfs                    3.9G  1.9M  3.9G   1% /dev/shm
tmpfs                    3.9G  1.7M  3.9G   1% /run
tmpfs                    3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root   34G   12G   20G  38% /
tmpfs                    3.9G  992K  3.9G   1% /tmp
/dev/sdb2                477M  184M  265M  41% /boot
/dev/mapper/fedora-home   17G   11G  5.0G  68% /home
tmpfs                    785M  8.0K  785M   1% /run/user/42
tmpfs                    785M   40K  785M   1% /run/user/1000

Saturday, December 19, 2015

Fedora 23 - Installling KompoZer version 0.8 beta 3

Today I need to wrote HTML table very quick and I dont have time to play with matching tag. So I need WYSIWYG tool such KompoZer. I searched the package via DNF command but KompoZer are not available in Fedora repository. After google-fu, I found this website. I tried to install and boom! Success! Yeah
$ wget http://hbcom.info/kompozer/kompozer-0.8-0.4.b3.i386.rpm
$ sudo dnf install kompozer-0.8-0.4.b3.i386.rpm 

Last metadata expiration check performed 1:43:44 ago on Sat Dec 19 13:54:44 2015.
Dependencies resolved.
================================================================================
 Package                 Arch     Version                Repository        Size
================================================================================
Installing:
 GConf2                  i686     3.2.6-15.fc23          fedora           1.0 M
 ORBit2                  i686     2.14.19-14.fc23        fedora           178 k
 atk                     i686     2.18.0-1.fc23          fedora           259 k
 avahi-glib              i686     0.6.31-43.fc23         fedora            15 k
 avahi-libs              i686     0.6.31-43.fc23         fedora            61 k
 cairo                   i686     1.14.2-2.fc23          fedora           754 k
 cups-libs               i686     1:2.1.2-1.fc23         updates          402 k
 dbus-glib               i686     0.104-3.fc23           fedora           123 k
 gamin                   i686     0.1.10-18.fc23         fedora           133 k
 gdk-pixbuf2             i686     2.32.3-1.fc23          updates          447 k
 gdk-pixbuf2-modules     i686     2.32.3-1.fc23          updates           97 k
 glib2                   i686     2.46.2-1.fc23          updates          2.3 M
 gnome-vfs2              i686     2.24.4-19.fc23         fedora           388 k
 graphite2               i686     1.2.4-5.fc23           fedora            91 k
 gstreamer1              i686     1.6.2-1.fc23           updates          1.1 M
 gtk2                    i686     2.24.29-1.fc23         updates          3.4 M
 harfbuzz                i686     1.0.6-1.fc23           updates          182 k
 jasper-libs             i686     1.900.1-31.fc23        fedora           151 k
 keyutils-libs           i686     1.5.9-7.fc23           fedora            45 k
 kompozer                i386     1:0.8-0.4.b3           @commandline     9.7 M
 krb5-libs               i686     1.14-3.fc23            updates          856 k
 libIDL                  i686     0.8.14-10.fc23         fedora            89 k
 libXft                  i686     2.3.2-3.fc23           fedora            62 k
 libXt                   i686     1.1.5-2.fc23           fedora           174 k
 libart_lgpl             i686     2.3.21-13.fc23         fedora            72 k
 libbonobo               i686     2.32.1-8.fc22          fedora           432 k
 libbonoboui             i686     2.24.5-9.fc23          fedora           346 k
 libcanberra             i686     0.30-10.fc23           fedora            85 k
 libcom_err              i686     1.42.13-3.fc23         fedora            45 k
 libdatrie               i686     0.2.8-6.fc23           fedora            32 k
 libglade2               i686     2.6.4-13.fc23          fedora            68 k
 libgnome                i686     2.32.1-10.fc23         fedora           744 k
 libgnome-keyring        i686     3.12.0-5.fc23          fedora           114 k
 libgnomecanvas          i686     2.30.3-10.fc23         fedora           233 k
 libgnomeui              i686     2.24.5-11.fc23         fedora           790 k
 libtdb                  i686     1.3.8-1.fc23           updates           52 k
 libthai                 i686     0.1.21-2.fc23          fedora           193 k
 libverto                i686     0.2.6-5.fc23           fedora            21 k
 openssl-libs            i686     1:1.0.2e-3.fc23        updates          993 k
 pango                   i686     1.38.1-1.fc23          fedora           284 k
 pixman                  i686     0.33.4-1.fc23          updates          233 k
 polkit-libs             i686     0.113-4.fc23           fedora            70 k
 popt                    i686     1.16-6.fc23            fedora            60 k

Transaction Summary
================================================================================
Install  43 Packages

Total size: 27 M
Total download size: 17 M
Installed size: 94 M
Is this ok [y/N]: y

Checklist for Review of Use Case Specification

 Topic  Question  (Answer : Yes → Continue to next, No → add finding in review template)
Use case title
  1. Is the title an active phase (i.e 'verb'+'noun') expressing the goal of the primary actor?
  2. Can the goal be archived by the system?
Actors
  1. Is the use case triggered by at least one (primary) actor?
  2. Is the primary actor the first in the list of actor?
  3. Are all actors of the use case listed?
Precondition
  1. Is the precondition formulated as a condition that either true or false?
  2. Is the system able to check the precondition?
  3. Is it true that no checking of precondition is also done in the use case senario?
Post condition
  1. Is the post condition formulated as a condition that is either true or false?
  2. Is the system able to check the post condition?
  3. Can the post conditions always be met after a succesful development?
Primary path
  1. Is described with 3 to 9 steps?
  2. Do the steps describes a consistent scenario leading from trigger to archived post condition?
  3. Are branches and loops described as such?
  4. At condition in the flow: Is it defined what procedure shall be taken if the condition is not fulfilled?
For every step
  1. Can all steps be succesfully executed?
  2. Is it clear in all steps who is the acting actor?
  3. It is clear in all steps what the actor need to accomplish?
  4. Is none of the steps too complex?
  5. Is there no design description in all step (e.g description of UI)?
  6. Is it unambiguous, what information is processed in each step?
  7. Is each step described actively from the view of the acting actor or the system?
Alternative paths
  1. Are all alternative paths in the identical business context?
  2. For all alternative path perform the check check as described above the primary actor.
Overall view (Use case diagram)
  1. Are all the relevant use cases shown in the use case diagram?
  2. Do all actors have connection to at least one use case?
  3. Do all <<include>> and <<extend>> relationship make sense?
  4. Is the syntax of the UML diagram are correct (e.g. actor symbols, stereotypes <<actor>>, <<include>> and <<extend>>, labelling of the system and use case, lines for relationship, etc) ?

Wednesday, December 16, 2015

Fedora 23 - Hibernate

Peace be upon you..
By default, Fedora 23 have suspend function but I still prefer to use hibernate function with my laptop. We need to add resume parameter to the default grub parameter.

First thing, we need to get UUID of swap partition from our computer. Let use blkid command:

$ sudo blkid | grep swap
/dev/mapper/fedora-swap: UUID="bt81a351-8421-1337-96ca-r9ab3605ff7c" TYPE="swap"

Then copy UUID code from you output (Don't copy my swap UUID partition example), which we gonna need that in next step. Now lets edit the default GRUB2 file located at /etc/default/grub

Open that GRUB2 file and find GRUB_CMDLINE_LINUX then, put resume=UUID parameter inside the quote such like this :

GRUB_CMDLINE_LINUX="rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap rhgb quiet resume=UUID=bt81a351-8421-1337-96ca-r9ab3605ff7c"

Now we need to rebuild the GRUB2 config file. Just run sudo grub2-mkconfig -o /boot/grub2/grub.cfg or if you have EFI feature with you computer, please run sudo grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg command, make sure you know which command to execute.

Congratulation, now you have hibernate features enabled. If you are using Gnome desktop, I suggest you to install this wonderful, awesome and nice hibernate status button extension that adds a Hibernate button in status menu.

That all for now. Thanks :)

Monday, December 7, 2015

symbolic link / symlink - Reaver-wps-fork-t6x

# ln -s /usr/local/bin/reaver /usr/bin/reaver
# ln -s /usr/local/bin/wash /usr/bin/wash

Wednesday, December 2, 2015

Fedora / Redhat - Pixie fatal error: openssl/sha.h (FIXED)

I tried to compile PixieWPS, but openSSL library are missing
$ cd src
$ make
cc -std=c99 -O3 -Wno-deprecated-declarations -o pixiewps pixiewps.c random_r.c -lcrypto
In file included from pixiewps.c:51:0:
pixiewps.h:66:25: fatal error: openssl/sha.h: No such file or directory
compilation terminated.
Makefile:11: recipe for target 'all' failed
make: *** [all] Error 1

Debian family call this library package as libssl-dev, but in RHEL family side, it's called as openssl-devel.
$ sudo dnf install openssl-devel
Last metadata expiration check performed 2:52:30 ago on Wed Dec  2 14:43:05 2015.
Dependencies resolved.
========================================================================================================================================================================
 Package                                        Arch                              Version                                      Repository                          Size
========================================================================================================================================================================
Installing:
 keyutils-libs-devel                            x86_64                            1.5.9-7.fc23                                 fedora                              45 k
 krb5-devel                                     x86_64                            1.14-2.fc23                                  updates                            649 k
 libcom_err-devel                               x86_64                            1.42.13-3.fc23                               fedora                              35 k
 libselinux-devel                               x86_64                            2.4-4.fc23                                   fedora                             182 k
 libsepol-devel                                 x86_64                            2.4-1.fc23                                   fedora                              77 k
 libverto-devel                                 x86_64                            0.2.6-5.fc23                                 fedora                              16 k
 openssl-devel                                  x86_64                            1:1.0.2d-3.fc23                              updates                            1.5 M
 pcre-devel                                     x86_64                            8.38-2.fc23                                  updates                            540 k
 zlib-devel                                     x86_64                            1.2.8-9.fc23                                 fedora                              55 k
Upgrading:
 krb5-libs                                      x86_64                            1.14-2.fc23                                  updates                            839 k

Transaction Summary
========================================================================================================================================================================
Install  9 Packages
Upgrade  1 Package

Total download size: 3.9 M
Is this ok [y/N]: y

Now I can compile PixieWPS without error anymore :)

$ make
cc -std=c99 -O3 -Wno-deprecated-declarations -o pixiewps pixiewps.c random_r.c -lcrypto
$ sudo make install 
rm -f /usr/local/bin/pixiewps
install pixiewps /usr/bin/pixiewps
install -m 755 pixiewps /usr/bin