Thursday, March 17, 2016

Random Notes LIRC

Random Notes on LIRC

irrecord -list namespace

These are the names you can give the buttons on your remote.


KEY_0
KEY_102ND
KEY_10CHANNELSDOWN
KEY_10CHANNELSUP
KEY_1
KEY_2
KEY_3
KEY_4
KEY_5
KEY_6
KEY_7
KEY_8
KEY_9
KEY_A
KEY_AB
KEY_ADDRESSBOOK
KEY_AGAIN
KEY_ALTERASE
KEY_ANGLE
KEY_APOSTROPHE
KEY_ARCHIVE
KEY_AUDIO
KEY_AUX
KEY_B
KEY_BACK
KEY_BACKSLASH
KEY_BACKSPACE
KEY_BASSBOOST
KEY_BATTERY
KEY_BLUE
KEY_BLUETOOTH
KEY_BOOKMARKS
KEY_BREAK
KEY_BRIGHTNESS_CYCLE
KEY_BRIGHTNESSDOWN
KEY_BRIGHTNESSUP
KEY_BRIGHTNESS_ZERO
KEY_BRL_DOT10
KEY_BRL_DOT1
KEY_BRL_DOT2
KEY_BRL_DOT3
KEY_BRL_DOT4


..

killall lircd
you may need to delete /storage/.config/lircd.conf if you want to add new rewote
irrecord /storage/.config/lircd.conf



 Lircmap.xml:


lircd.conf->lircmap.xml->remote.xml


 /usr/share/kodi/system/Lircmap.xml
Lircmap.xml

   
       KEY_PAUSE
       KEY_INFO
       KEY_NUMERIC_STAR
       KEY_PVR
       KEY_TV
       KEY_ANGLE
       KEY_EPG
   


remote.xml

 
   
      ContextMenu
      AspectRatio
   
 




Tuesday, March 1, 2016

Typical 4-Port ATA ( SLIC , DSP ,FXS ,FXO) 



Ajax Login to Disable Browser Prompt












 
   
 
 
 
 


Creating CVS Server in windows in 5 mins

If tou want a local CVS Server on Windows ,this would be probably simplest Tutorial find on internet.


Steps:-
  1. Download Tortoise CVS (Contains both client and server component (cvsnt).
(~15mb)
  1. Full Install it.
  2. Restart PC
  3. Goto Control Panel->CVSNT Server




5.See the entries as below




-If you want server to access locally use 127.0.0.1
-Cvstemp is a temp directory needed by cvs ,u could name it anything
-alok is anonymous user which allows to alok to access without password


6.

Asdfas



Click OK this will create
This create CVSROOT Folder inside mycvsrepo needed by cvs server.


One it done it will added in list,again click add to folder of module or project (could be empty or already contain cvs files)






Now check CVS Server and CVS Lock server both are running



Enter Repository folder
D:/CVSREPO and protocol as locally mointed


Then fetch list will show module


Select LCD4liux and click ok



Create A folder and cvs checkout it



Fieldset - New HTML Tag for Grouping






Asterisk Failover Solution (IP Failover Solution)
Simplest way to setup a redundant asterisk system is by using UCARP application
If creates a vitual IP that will be assigned for the external world to use.


Here is my setup ,I have two machines on which asterisk is installed.


Master 192.168.0.201
Slave 192.168.0.202


Now I will create Virtual IP 192.168.0.250


Steps :
1.First thing is to install a ucarp packages to both machines this needs
Dependency : needs libpcap and libpcap-devel
Yum install libpcap libpcap-devel


This was the error when I tried to installed ucarp with installing libpcap libraries.


This shows pcap.h is missing i.e pcap library not installed.

2.Install UCARP on both machine
tar xvf  ucarp-1.5.1.tar.gz
cd ucarp-1.5.1


./configure
make install-strip


Once installed on both the servers ucarp should be available in /usr/local/sbin/ucarp

3.Now Make Two scripts on both machine that will run whenever a UCARP Detects that other is not available so it should takeover.


/etc/vip-up.sh


#!/bin/bash
/sbin/ip addr add 192.168.0.250/24 dev eth0
arping -U –c 3 -I eth0 192.168.0.250


/etc/vip-down.sh


#!/bin/bash
/sbin/ip addr del 192.168.0.200/24 dev eth0


Note :
1.#!/sbin/bash is necessary otherwise it will show exec format error
2.Since Router or pc caches the arp ,they might have old mac address of virtual ip ,so gratuitous arp has to be send to clear arp tables.so added arping on up screen.


4.Make them executable
Chmod +x /etc/vip-up.sh
Chmod +x /etc/vip-down.sh


5.
Now from Server1 (let it be Master)
/usr/local/sbin/ucarp -v 42 -P -p somepasswd -a  192.168.0.250 –s  192.168.0.201 –-upscript=/etc/vip-up.sh -–downscript=/etc/vip-down.sh  &

& From Server 2 run this command


References






Featured Post

XDP - Getting Started with XDP (Linux)