jueves, 21 de octubre de 2010

ARGUS DC-1510 como webcam en Ubuntu

¡Al fin la solución! Encontrada en: http://ubuntuforums.org/showthread.php?t=435463&highlight=argus

If your webcam reports something similar to this:

Code:
$ lsusb
Bus 001 Device 005: ID 2770:9120 NHJ, Ltd Che-ez! Snap / iClick Tiny VGA Digital Camera
Then it is now fully supported by Ubuntu (version 10.04, Lucid Lynx).

Ubuntu has, however, a bug that needs a workaround:
Code:
$ sudo modprobe -rv gspca_sq905
$ sudo modprobe -v gspca_sq905
You have to do this after every reboot or after every time you connect the camera plug.

After this you can use XawTV or VLC to see video from your webcam:
XawTV must not need any configuration. Just install and run it.
With VLC, use the "Open Capture Device" (Ctrl+C) menu and point the "Video device name" to /dev/video or /dev/video0.
aMSN must also recognise the webcam without any issues.
See the mentioned bugreport for tips on making Skype work with it (I haven't tested it).


You may also be able to download still photos or record your own movies with xawtv. Notice that these procedures were not confirmed by me on the most recent versions of Ubuntu.
Recording movies with VLC should work without any issues.

jueves, 14 de octubre de 2010

Scroll con 2 dedos en Samsung N220+

For multitouch in touchpad, I created a script and added at startup (system-->preferences-->aplication at starup or similar, I'm using spanish version). It works fine for multitouch.
You can find more info in many forums about this script.
I think that you have to enable Visual Asistance for it works


#!/bin/bash
# enable multitouch
sleep 5
synclient VertTwoFingerScroll=1
synclient HorizTwoFingerScroll=1
synclient EmulateTwoFingerMinW=5
synclient EmulateTwoFingerMinZ=48 


Fuentes:
http://seaborne.blogspot.com/2010/07/ubuntu-on-samsung-n210.html
http://josthalen.wordpress.com/2010/07/03/linux-on-samsung-n210/

viernes, 8 de octubre de 2010

Aproximación de Padé en SciLab

function P = Pade(q,n)
  // Aproximacion de Pade de orden «n» para «exp(-q.s)»
  // Calculado como:
  //      $\textrm{e}^{-\Theta\,t}\approxeq\dfrac{\sum_{k=0}^{n}\,(-1)^{k}\, c_{k}\,(\theta s)^{k}}{\sum_{k=0}^{n}\, c_{k}\,(\theta s)^{k}}$
  // donde:
  //     $c_{k}=\dfrac{(2n-k)!\, n!}{2n!\, k!\,(n-k)!}$
  // para $k=1,2,\ldots,n$
  s=poly(0,'s');
  Num = 0; // Inicializo el numerador
  Den = 0; // Inicializo el denominador
  nn = prod(1:n); // nn = n!
  n2 = prod(1:(2*n)); // n2 = 2n!
  for k=0:n
    c = (prod(1:(2*n-k))*nn)/(n2*prod(1:k)*prod(1:(n-k)));
    Num = Num + ((-1)**k)*c*(q*s)**k;
    Den = Den + c*(q*s)**k;
  end;
  P = Num/Den;
endfunction

Ahora sí, corregido.

sábado, 2 de octubre de 2010

Habilitar la interface GNOME en Ubuntu Netbook Remix 10.04

Para netbooks con soporte para aceleración 3D (Ubuntu Netbook Edition):

sudo ln -s /etc/xdg/xdg-une/autostart/maximus-autostart.desktop /etc/xdg/autostart/ #this makes Maximus run at login
sudo ln -s /etc/xdg/xdg-une/autostart/netbook-launcher.desktop /etc/xdg/autostart/ #this launches the UNE interface at login
sudo ln -s /usr/share/gconf/une/default/20_une-gconf-default /usr/share/gconf/defaults/
sudo ln -s /usr/share/gconf/une/mandatory/20_une-gconf-mandatory /usr/share/gconf/defaults/
sudo update-gconf-defaults


Para netbooks sin soporte para aceleración 3D (Ubuntu Netbook Edition 2D):

sudo ln -s /etc/xdg/xdg-une/autostart/maximus-autostart.desktop /etc/xdg/autostart/ #this makes Maximus run at login
sudo ln -s /etc/xdg/xdg-une-efl/autostart/netbook-launcher-efl.desktop /etc/xdg/autostart/ #this launches the UNE interface at login
sudo ln -s /usr/share/gconf/une/default/20_une-gconf-default /usr/share/gconf/defaults/
sudo ln -s /usr/share/gconf/une/mandatory/20_une-gconf-mandatory /usr/share/gconf/defaults/
sudo update-gconf-defaults


Para elegir una interfase, desloguearse y en la pantalla de login elegir la deseada.

Fuente: http://www.webupd8.org/2010/06/how-to-get-most-out-of-ubuntu-netbook.html

Cambiar la política de consumo del CPU

Para conocer la política en uso:

cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

Para conocer las opciones de consumo del CPU:

cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors

Para Cambiar la política actual:

sudo echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

(Cambiar ondemand por la política deseada. Para Ubuntu 10.04 Netbook Remix en Samsung N220+ con CPU Intel Atom N450 puede ser: conservative, ondemand, userspace, powersave, performance).