Wednesday, November 21, 2012

Endianness

How to memorize what the Big-endian is and what the Little-endian is?
(The decision to use that meaningless names only in favor of J. Swift talent was quite stupid in the first place.)

So, here's a "simple" rule:
Let's say that the "end" is the starting byte of the memory word (lowest address).
Then "Little" will mean the less-significant, i.e. little part of the number is located at that first byte end.
In contrary, "Big" will mean the most-significant, i.e. biggest part of the number is located at the end  (the first byte).

How to memorize which architecture uses which notation?
The PC which costs a little is based on the x86 architecture which is Little-endian.
Workstations, like SPARC, SGI cost big money, and also they are Big-endian.

Crypted Jelly Bean fix

Android v4.2 changed default provider for SecureRandom. Because of that the Cipher throws this exception on v4.2: BadPaddingException: pad block corrupted.

The solution is quite simple. Just add explicitly specified provider as the second parameter of the SecureRandom.getInstance() method:

 SecureRandom sr = SecureRandom.getInstance( "SHA1PRNG", "Crypto" );

Read more here

Tuesday, November 20, 2012

Depricate an IP address

Say, a server has a number of IP addresses, but we don't want some addresses to be used as outbound.

ipconfig /all   gives us which address is preferred:

 Autoconfiguration Enabled . . . . : Yes
 IPv4 Address. . . . . . . . . . . : 2.68.18.2(Preferred)
 Subnet Mask . . . . . . . . . . . : 255.255.255.248
 IPv4 Address. . . . . . . . . . . : 2.68.18.3(Preferred)
 Subnet Mask . . . . . . . . . . . : 255.255.255.248


To make an address not preferred, remove it from the interface and recreate it again using the netsh:
 
interface ipv4 add address LAN 2.68.18.2 mask=255.255.255.248 preferredlifetime=0


keyboard switching utility

Updated the language switching utility
This utility assigns mostly unused the right "windows" key to switch between the system's languages.

Friday, October 26, 2012

Android application I recommend

RealCalc Scientific Calc - very good calculator (does RPN too)

QuickPic - picture viewer

Bookmark Tree Manager - organizes the browser's bookmarks in to a hierarchy

 ColorDict Dictionary  - offline dictionary

Cool Reader - very good e-books reader

Google Goggles - scans pictures, labels, QR codes, BAR-codes, texts and gives the digital result or links

Google Translate - online translator (input text can be spoken or drawn)

StopWatch & Timer - it is

Radar Now!  - shows the weather radar. Good way to know will be there rain or it will pass by

TuneIn Radio Pro - radio - music and talks from all over the world

Wikipedia - it is

andLess - good music player - plays physical folders, not stupid libraries

Greed  - RSS reader. All favorite news and digests in one place

2X Client RDP - remote desktop client. Works very well

My-Cast Weather - best weather application I've found

Libra - Weight Manager  - just record your everyday weight change

Ghost Commander File Manager - file manager (copy move organize files (music, book, pictures, etc.)). FTP client

SMB plugin for Ghost Commander - a plugin to the above to connect to windows network shares

FTPServer - FTP server. Lets you connect from your PC to the phone to transfer files

KeePassDroid - stores your passwords and other sensitive data (SSN, etc.) encrypted

 Mileage - records the car fueling and shows the mileage charts

Photo Slides (Photo Frame) photo slide show. (If you practice a martial art or similar you can have a set of photos of positions and then exercise by following the pictures the app shows in sequence)

Wifi Analyzer - show how strong the WiFi networks nearby. May be it's a good idea to change the freq. channel for your own network?

 Screen Filter - makes the display even more dimmer

Pedometer ***NEW*** - counts your steps while you're running or walking

Quick System Info PRO - shows comprehensive information about your phone, processes, services, applications and network connections

TV Listings for Android TV24 - browse the current TV schedule



Thursday, October 11, 2012

Icons batch processing

To  convert images to a bigger canvas size preserving the transparency and keeping the content centered:

convert $f -background transparent -compose Copy -gravity center -extent 64x64 out/$f

Friday, October 5, 2012

PB new version

PlayBook has been updated to OS v2.1 ! Now all the Android apps are launched in each own separate windows. That's a great achievement, no doubts. PB is so picky and does not want to be charged via a data cable, but it seems it does charge via a "not-data" cable. I don't understand, what's the difference between cables? Apparently, there are tow charging modes. When the battery icon has a power plug on it and when it has a lightning bolt. I think in the second case it charges faster.