Friday, April 4, 2014

Chess on Kindle 4 - open-source

Chess on Kindle 4

K3Chess - free open-source chess for Kindle

Do you belive or not but there is a very good graphical chess on Kindle 4 NT (non touch).
It is free!

Check this:
http://www.mobileread.com/forums/showthread.php?t=152815


Amazing program, a very good example of masterpieces of opensource world. :)

E-ink is good for eyes, while you nut-cracking.

The chess is strong, it always wins over me. :)


MC on Android
:)

https://play.google.com/store/apps/details?id=com.nativnux.installers.mc&hl=hu

Midnight Commander Installer - screenshot

Tuesday, February 25, 2014

Call Record on Fritz.Box

Call Record - Fritz.Box 



I want automatic calls record on Fritz.box. After few days of Goggling found a solution :)

a few options: 

  1. On new (7320) Fritz devices provides this feature out of box. But it has many limitations; 
  • it is only for 10 minutes.
  • Not automatic, each call records must be allowed with key presses during the calls.
     2. Asterix PBX + Freepbx.
  • needs compilation, configuration and massive PBX knowledge. Probably uses lots of resources on HW side and from human side too... :)
Solution is

     3. FritzCap.

http://www.ip-phone-forum.de/showthread.php?t=232682
This is the call record solution on server side.
  • Download Fritzcap 2.0.0 (or 2.1 depending on your firmware)
  • Extract it, and configure-only the password in fritzcap.conf 
  • pick up the fritzbox handset and dial #96 * 5 * 
  • python fritzcap.py -c -d -m
thats all! Your all calls are recorded automatically.

Make it permanent:

make a shell script in /etc/init.d directory.



#touch /etc/init.d/fritzcap

edit file and insert this
python /yourroute/fritzcap.py -c -d -m
Save file.

#chmod +x fritzcap
#update-rc.d fritzcap defaults
#sync
#reboot
check it is runing:
#ps ax | grep fritzcapHauskeeping script.

# ps ax | grep fritzcap
 1817 ?        S      0:00 /bin/sh /etc/init.d/fritzcap start
 1822 ?        Sl     0:08 python /usr/local/bin/fritzcap.py -c -d -m
 2171 pts/1    S+     0:00 grep fritzcap
Hauskeeping script.

Cap and Wav files are large, convert mixed wav to mp3 and delete all source files.
Convert to mp3 with CRON. for example in the night when system not loaded.

# crontab -l
to check present cron

Just edit crontab.
# crontab -e
30 2 * * * /usr/local/bin/wav2mp3.sh

# cat wav2mp3.sh                                                                                                      

#!/bin/sh
# wav to mp3
cd /usr/local/bin/captures
nice -19 find /usr/local/bin/captures -name '*mix*.wav' |
while read i
do
if [ ! -f ${i%.wav}.mp3 ]; then
    nice -19 lame -h -b 128 "$i" "${i%.wav}.mp3"
fi
done
cd /usr/local/bin/captures
nice -19 find /usr/local/bin/captures -name '*.mp3' |
while read i
do
FILESIZE=$(stat -c%s "$i")
if [ "$FILESIZE" -gt 1000 ]
then
    nice -19 rm -f ${i%_mix_0_1.mp3}*.wav
    nice -19 rm -f ${i%_mix_0_1.mp3}.cap
fi
done

#repair cap file:
#python /usr/local/bin/fritzcap.py -d /usr/local/bin/captures/2014-03-10/160627/capture_20140310160627.cap