Make screenshot in Raspberry Pi

Last Updated: 2016-12-24T08:23:28Z
Install scrot
sudo apt-get install scrot -y
Make instant screenshot
scrot
Make screenshot after 5 seconds
scrot -d 5
All screenshots by default goes to your home directory.

wget jre, jdk

Last Updated: 2017-01-04T19:26:53Z
The key is to use
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie"
and replace all url start http://download.oracle.com/otn/java-pub/.. with
http://download.oracle.com/otn-pub/java/..
Se example:
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/7u51-b13/jre-7u51-windows-i586.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/7u51-b13/jre-7u51-windows-x64.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8-b132/jre-8-windows-i586.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8-b132/jre-8-windows-x64.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u5-b13/jre-8u5-windows-i586.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u5-b13/jre-8u5-windows-x64.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/6u45-b06/jre-6u45-windows-i586.exe
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/6u45-b06/jre-6u45-windows-x64.exe
or more beautiful to create a batch file with array:
for %%a in (7u51-b13/jre-7u51-windows-i586.exe ^
7u51-b13/jre-7u51-windows-x64.exe ^
8-b132/jre-8-windows-i586.exe ^
8-b132/jre-8-windows-x64.exe ^
8u5-b13/jre-8u5-windows-i586.exe ^
8u5-b13/jre-8u5-windows-x64.exe ^
6u45-b06/jre-6u45-windows-i586.exe ^
6u45-b06/jre-6u45-windows-x64.exe) do (
"%~dp0wget.exe" --no-cookies ^
--no-check-certificate ^
--header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" ^
http://download.oracle.com/otn-pub/java/jdk/%%a
)
http://catonrug.googlecode.com/files/wget.exe
With auto file name rename
for %%a in (7u51-b13/jre-7u51-windows-i586.exe ^
7u51-b13/jre-7u51-windows-x64.exe ^
8-b132/jre-8-windows-i586.exe ^
8-b132/jre-8-windows-x64.exe ^
8u5-b13/jre-8u5-windows-i586.exe ^
8u5-b13/jre-8u5-windows-x64.exe ^
6u45-b06/jre-6u45-windows-i586.exe ^
6u45-b06/jre-6u45-windows-x64.exe) do (
for /f "tokens=7 delims=/" %%b in ('echo http://download.oracle.com/otn-pub/java/jdk/%%a') do (
"%~dp0wget.exe" --no-cookies ^
--no-check-certificate ^
--header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" ^
-O %%b ^
http://download.oracle.com/otn-pub/java/jdk/%%a
)
)
jre-7u51-windows-i586.exe
1af9e2aa8264b023404a76d3fb6751fe
72aa32f97a0ddd306d436ac3f13fabb841b94a76

jre-7u51-windows-x64.exe
b0f3a9c0f4c2c66127223ba3644b54f6
0d3346f4c249d9443237205cc1c0dde1ef534874

jre-8-windows-i586.exe
df4ab2ac812c932d2d4572ff29f469ba
519b9537330e0dc0536b08c54a87bde0a4ea80f6

jre-8-windows-x64.exe
be0d3cabd4ffb9425c5e82a9471450f5
ce523eb8524d624d0399baadd4b508847f190e64

jre-8u5-windows-i586.exe
b211f62dd50509086940ed09e9d868f5
ca48401f6f71ad360b3c0882393e2c93c35f80de

jre-8u5-windows-x64.exe
fb50b5035f206dfaf35761947b5707ba
ca656e8a722c068939665ad23760b8b072281594

jre-6u45-windows-i586.exe
f2f6bb7753edca2175b39090477fa602
5100b8eafaa7ed73ed6dab5469ba3faff38a9ae9

jre-6u45-windows-x64.exe
dd8b0e566a0cae1a330a456dd73afc5f
210c9527dcc0122ca90d22c2f5b96c03d5bb7b48

Jave 6 archive:
http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase6-419409.html

Java 7 archive:
http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase7-521261.html

Java 8 archive:
http://www.oracle.com/technetwork/java/javase/downloads/java-archive-javase8-2177648.html

On bicycle

Last Updated: 2017-01-15T15:59:41Z

Extract rar archive in Wheezy Raspbian

Download precompiled non-free version:
wget -O unrar_4.1.4-1_armhf.deb goo.gl/Vxyu0Y
Install:
sudo dpkg -i unrar_4.1.4-1_armhf.deb
Extract all files with full path:
unrar-nonfree x wrar531.exe -y
Extract all files in archive to subdirecotry:
mkdir subdirecotry
unrar-nonfree x wrar531.exe -y subdirecotry
Extract all files in archive:
unrar-nonfree e wrar531.exe -y

Out of The Box experience for Raspberry Pi

Last Updated: 2016-12-24T08:24:23Z
Let me introduce you to NOOBS.
NOOBS stand for New Out of The Box Software.
This will copy a whole bunch of operating systems to your SD card.
When the first time you boot from SD card it will let you choose (only once) which operating system you really want to install and use.
If suddenly want to use another operating system then you have reformat your SD card and copy whole NOOBS pack again and boot again.

To install this New Out of The Box experience to Raspberry Pi you have download
https://googledrive.com/host/0B_esWdErYKaLQkZuM0VXRUNyVEk/NOOBS_v1_3_4.zip
14ff9a6170d1c3aacce2f71d69a401a3
96b7a28e7b3bc7d73c93ff2207ede0582fe29525
and extract all content to SD cards root. SD card must be in Fat32 file system. No need to worry about boot partition and/or boot sectors! The raspberry will understand the content of flash drive automatically while the fat file system is used.

If can not create a Fat32 file system then use
https://googledrive.com/host/0B_esWdErYKaLQkZuM0VXRUNyVEk/SDFormatterv4.zip
73dfcbcd9f970bb4e57c7dce84463f38
83e49cbe2dd1dac8f0b802dde0f4612d167383e7

If you have multiple hidden partitions then use Partition Wizard to create a single one.

Record desktop with mouse pointer, VLC

Last Updated: 2016-12-14T05:29:32Z
Save this image as mouse-pointer.png in directory where vlc.exe is having a good time.

Open VLC shortcut for editing

On 64-bit windows replace "C:\Program Files (x86)\VideoLAN\VLC\vlc.exe" with
"C:\Program Files (x86)\VideoLAN\VLC\vlc.exe" --screen-mouse-image="mouse-pointer.png"
On 32-bit windows replace "C:\Program Files\VideoLAN\VLC\vlc.exe" with
"C:\Program Files\VideoLAN\VLC\vlc.exe" --screen-mouse-image="mouse-pointer.png"
To capture video go for Media -> Open Capture Device

Switch capture mode to Desktop, set frame rate to 30.00 f/s and set video for Convert on live play

Set the output container to Video - H.264 + MP3 (TS), set the destination for file and then click Start

Recording time starts to increase. You are on live! You can minimize this window and do your tutorial.

After you end recording you cat stop the recording and wait a few seconds to vlc proceed the last seconds.

The hardest way to create windows [version 6.x] USB installation media

Last Updated: 2015-07-14T07:01:47Z
This tutorial works for windows seven and windows eight and windows eights point one for booth 32-bit and 64-bit versions ;)
Advantage for this method is that you can copy another files to flash disk which is larger than 4 gigabytes.
Who will need future like this? :o - Only the Matroska king :D

Plug the flash drive
Launch Command Prompt in "Run as administrator" mode

Launch diskpart utility
diskpart
choose the flash device
list disk
SELECT THE RIGHT DISK!
select disk 2
Write down commands
clean
create partition primary
select partition 1
active
format fs=ntfs quick
assign
exit
Move to cd directory
l:
cd boot
bootsect.exe /nt60 f:
All together looks like:


Finally extract all content of ISO file to USB drive root ;)

Limit dd image size based on partition area


This is how to clone flash drive if the first partition is less than 2,8 gigabytes
dd if=/dev/sdb of=/home/user/win81x86enterprise90days.img bs=1M count=2800

And if the first partition is 3,71 GB big use
dd if=/dev/sdb of=/home/user/win81x64enterprise90days.img bs=1M count=3750
To restore the image use
dd if=/home/user/win81x64enterprise90days.img of=/dev/sdb
Later on windows can use Win32DiskImager to write the image:
https://googledrive.com/host/0B_esWdErYKaLQkZuM0VXRUNyVEk/Win32DiskImager-0.9.5-install.exe
0080b7125d628819922314074c7e164a
f7ca6ffdd3b70dbb4723f33471df3f7dcc225ca4

x64 B1Jzi5/goo.gl
x86 oEDf2L/goo.gl

Related:
http://www.cyberciti.biz/faq/howto-create-lage-files-with-dd-command/

List directory sizes in linux, du including hidden files

Last Updated: 2017-01-11T19:32:32Z
Move to home directory
cd ~
List folders and files size and show the greater directories at the last lines
du -sk * | sort -n
List folders, hidden folders, files and hidden files and show the biggest at the bottom
du -sch .[!.]* * | sort -h

Happy Raspy

Last Updated: 2017-01-15T15:59:58Z

Enable ssh at first boot, Wheezy Raspbian, Raspberry Pi

Last Updated: 2016-12-31T11:39:01Z
You have created fresh Wheezy Raspbian and you want to enable ssh so you not need additional keyboard for Pi.
To solve this situation save this file as boot_enable_ssh.rc in boot partition:
https://googledrive.com/host/0B_esWdErYKaLUjBPb0RrYzJXLTA

Create an IP address reservation at your router so you will have always the same IP address to connect ;)

An this is totally the first boot!

Related:
https://raspberrypi.stackexchange.com/questions/4444/enabling-ssh-on-rpi-without-screen-keystrokes-for-raspi-config

TightVNC server via router, port forwarding

Last Updated: 2015-07-14T07:02:37Z
VNC by default uses TCP ports 5900 through 5906, each port corresponding to a separate screen (:0 to :6)
Here is how to implement port forwarding: