Send Email using Python…

Send Mail Through Gmail with Python by MARK SANBORN on June 30, 2009 Python is a great scripting language for Linux and it is often used to automate tasks or check on overall system health. Discover how to send emails through Gmail with Python. Good system admins get to know scripting languages well and sometimes use them for all kinds of purposes, from scripts that do backups to complex automated tasks. Often times it would be nice to get an email notification

MPlayer, Manual

http://www.mplayerhq.hu/DOCS/man/en/mplayer.1.html MPlayer NAME SYNOPSIS DESCRIPTION INTERACTIVE CONTROL USAGE CONFIGURATION FILES PROFILES GENERAL OPTIONS PLAYER OPTIONS (MPLAYER ONLY) DEMUXER/STREAM OPTIONS OSD/SUBTITLE OPTIONS AUDIO OUTPUT OPTIONS (MPLAYER ONLY) AUDIO OUTPUT DRIVERS (MPLAYER ONLY) VIDEO OUTPUT OPTIONS (MPLAYER ONLY) VIDEO OUTPUT DRIVERS (MPLAYER ONLY) DECODING/FILTERING OPTIONS AUDIO FILTERS VIDEO FILTERS GENERAL ENCODING OPTIONS (MENCODER ONLY) CODEC SPECIFIC ENCODING OPTIONS (MENCODER ONLY) ENVIRONMENT VARIABLES FILES EXAMPLES OF MPLAYER USAGE EXAMPLES OF MENCODER USAGE BUGS AUTHORS NAME mplayer − movie player mencoder − movie encoder

How to quickly make a (sorted) playlist for mplayer

http://zuttobenkyou.wordpress.com/2009/01/17/how-to-quickly-make-a-playlist-for-mplayer/ How to quickly make a (sorted) playlist for mplayer January 17, 2009 by Shinobu See my update on July 10, 2010, below (making use of the neat “-iregex” option)! Mplayer uses a simple kind of playlist: a text file with the path and name of each file to be played. The path to the new file is relative to the location of the playlist file itself. So, you can do: 1 find -maxdepth 1 -type f -name \*.\* | sort > playlist

Getting Up and Running with MySQL for Python

http://www.packtpub.com/article/getting-up-running-mysql-python   Getting Up and Running with MySQL for Python   by Albert Lukaszewski, PhD |December 2010 | MySQL Open Source There are, several ways to get MySQL for Python in a place such that your local Python installation can use it. Which one you use will depend as much on your familiarity with your operating system and with Python itself, as it will on which operating system and version of Python you are running. In this article, by Albert Lukaszewski, PhD,

Installing the RasClock – Raspberry Pi Real Time Clock

https://www.modmypi.com/blog/installing-the-rasclock-raspberry-pi-real-time-clock Installing the RasClock – Raspberry Pi Real Time Clock Module Introduction The Raspberry Pi is an ultra-small and ultra-low cost computer. In order to achieve this size and price, several non-essential items usually found on a computer had to be omitted. Laptops and computers keep time when the power is off by using a pre-installed, battery powered ‘Real Time Clock’ (RTC). However, this Real Time Clock module is not included with the Raspberry Pi. To keep time, the Raspberry

Remove Raspberry Pi Logo on startup

Remove Raspberry Pi Logo on startup http://ananddrs.com/2013/09/18/remove-rpi-logo-startup/ The Raspberry Pi logo that shows during startup can be easily removed by adding logo.nologo to the file /boot/cmdline.txt The following command can be used to edit /boot/cmdline.txt sudo nano /boot/cmdline.txt The source of this post came from http://www.raspberrypi.org/phpBB3/viewtopic.php?t=11642&p=417828

Raspberry Pi – hiding boot messages on screen

http://ananddrs.com/2013/09/18/rpi-hide-boot-msg/ Raspberry Pi – hiding boot messages on screen There may be a time when one would want to hide boot messages that show up on the screen (or monitor or TV). The trick is to edit /boot/cmdline.txt file. One may use the following command sudo nano /boot/cmdline.txt Then make the following changes to the file: – Replace “console=tty1″ by “console=tty3″ to redirect boot messages to the third console. – Add “loglevel=3″ to disable non-critical kernel log messages. After changing,

Raspberry Pi On-Screen Keyboard

http://ananddrs.com/2013/09/25/rpi-onscreen-keyboard/ One may need to use on screen keyboard on Raspberyy Pi. One can accomplish this by using matchbox-keyboard. You can download by using the following command: sudo apt-get install matchbox-keyboard You can start by the matchbox-keyboard by using command matchbox-keyboard or sudo matchbox-keyboard

Send Commands or Data to Other Terminals

http://ananddrs.com/2013/09/25/send-commands-to-other-terminals/ Send Commands or Data to Other Terminals Somehow I need to send commands from one terminal to another. Luckily I found this postwhich saves my time. Here is a set of steps that one need to follow: Copy the code below to a C file (e.g. ttyecho.c) #include <stdio.h> #include <stdlib.h> #include <fcntl.h> #include <sys/stat.h> #include <sys/ioctl.h> #include <string.h> #include <unistd.h> void print_help(char *prog_name) { printf(“Usage: %s [-n] DEVNAME COMMAND\n”, prog_name); printf(“Usage: ‘-n’ is an optional argument if you want

Create your own boot logo

http://www.arm9board.net/wiki/index.php?title=Create_your_own_boot_logo Create your own boot logo In this tutorial there will be explained how to show your own image on the LCD display while your Linux system is booting. Contents [hide] 1 Preparations 2 Developping the boot logo 2.1 Converting the image 2.2 Going to a 224 color image 3 Put it inside the Kernel image 3.1 Editing the necessary files 3.1.1 Edit the Makefile 3.1.2 Edit the logo.c file 3.1.3 Edit the Kconfig file 3.2 Editing the header file 3.2.1 For the 2.6.28 kernel version 3.2.2 For the 2.6.36 kernel version

RPi Debian Auto Login

http://elinux.org/RPi_Debian_Auto_Login RPi Debian Auto Login This guide will show you how to login to a Debian image and start LXDE by simply powering the Pi on. Auto Login: In Terminal: sudo nano /etc/inittab Scroll down to: 1:2345:respawn:/sbin/getty 115200 tty1 and change to #1:2345:respawn:/sbin/getty 115200 tty1 Under that line add: 1:2345:respawn:/bin/login -f pi tty1 </dev/tty1 >/dev/tty1 2>&1 Ctrl+X to exit, Y to save followed by enter twice Auto StartX (Run LXDE) In Terminal: sudo nano /etc/rc.local Scroll to the bottom and

Getting a Python script to run in the background (as a service) on boot

http://blog.scphillips.com/2013/07/getting-a-python-script-to-run-in-the-background-as-a-service-on-boot/ Getting a Python script to run in the background (as a service) on boot 16 Replies Share on facebookShare on twitterShare on emailShare on pinterest_shareMore Sharing Services10 For some of my projects I write a simple service in Python and need it to start running in the background when the Raspberry Pi boots. Different Linux distributions use different ways of starting and stopping services (some now use Upstart, some systemd). I am using the “Wheezy” Debian distribution on my Raspberry Pi,

How to use interrupts with Python on the Raspberry Pi and RPi.GPIO

http://raspi.tv/2013/how-to-use-interrupts-with-python-on-the-raspberry-pi-and-rpi-gpio How to use interrupts with Python on the Raspberry Pi and RPi.GPIO  Input and Output, interfacing, python programming, raspberry pi Add comments Mar172013   The latest big news in the world of Raspberry Pi Python GPIO programming is that Ben Croston has released an update for RPi.GPIO. Why is that a big deal? Because this version has interrupts. “What’s an interrupt?” I hear you say. It’s a way of waiting for something to happen without checking constantly whether or not it’s happening. Imagine that

How to use interrupts with Python on the Raspberry Pi and RPi.GPIO – part 2

http://raspi.tv/2013/how-to-use-interrupts-with-python-on-the-raspberry-pi-and-rpi-gpio-part-2 How to use interrupts with Python on the Raspberry Pi and RPi.GPIO – part 2  Input and Output, interfacing, python programming, raspberry pi Add comments Mar202013   Interrupts are an efficient way for a program to be able to respond immediately to a specific event. In the previous article I explained the basics of using interrupts in RPi.GPIO and gave an example of a simple “wait for an event” interrupt program. In this second article I will introduce “threaded callback” which opens up a lot

How to use interrupts with Python on the Raspberry Pi and RPi.GPIO – part 3

http://raspi.tv/2013/how-to-use-interrupts-with-python-on-the-raspberry-pi-and-rpi-gpio-part-3 Multiple threaded callback interrupts in Python We’ve been learning about interrupts this week because of the brand new interrupt capabilities of RPi.GPIO. We covered a simple “wait for” interrupt in part 1, threaded callback interrupt and button debouncing in part 2 and today we’re getting sophisticated with multiple threaded callbacks. “WoooooooooOOOOOOOOOOOOOOOooooooooooo”, I hear you say. Well actually, we’re not doing much that’s very different from last time, except, now there’s more of it. We’ll add another button and another threaded callback function

« Older Entries Recent Entries »