## Beamer: making hand outs for your presentations

It’s often handy to create hand-outs for your presentations. (I need them for my master’s assessments at the moment). It’s really simple to make hand-outs. What we do is first create a presentation, like we normally do. Then, since the presentation generally contains overlays (the \pause command and more), we make another version where these commands are ignored. That’s the most of it. I go ahead another step and create another TeX file to print multiple slides in a single page.

As you’ll notice, between the presentation, and it’s hand out version, the only change is in the \documentclass options, where you add a “handout” option in the latter. Instead of copy pasting and keeping these two files in sync, a smart thing to do is to write everything other than the \documentclass line in another text file and then simply include it using an \input command in two files for the two versions.

So, the files you have are:

1. mypresentation-src.tex: the file that contains your entire presentation, other than the \documentclass line
2. mypresentation.tex: this file will contain the \documentclass line for your presentation
3. mypresentation-hand-out.tex: this file contains another \documentclass line for your presentation’s hand-out version where overlays are ignored
4. mypresentation-hand-out-print-multiple.tex: this file will generate a pdf file with multiple slides on a single page

This is what your mypresentation-src.tex file looks like (Observe the lack of a document class definition):

\usepackage{color}

\usepackage{hyperref}

% graphics
\usepackage{graphicx}

% algorithm
\usepackage{algorithmic}

\usepackage{textcomp}

% beamer theme
% use defaults for theme
\usetheme{Berlin}
\usecolortheme[RGB={41,65,114}]{structure}
\logo{\includegraphics[width=2.5cm,angle=0]{uts-logo.jpg}}

%% title %%
\title{Week review: October 2 2012}
\author[Ankur Sinha]{Ankur Sinha\\UTS ID: 11484312}
\institute{University of Technology, Sydney}
\date{October 2 2012}

%% document begins %%
\begin{document}

%% title frame %%
\begin{frame}
\titlepage

\end{frame}

.....
..
..
...
\end{document}

This is how your mypresentation.tex file looks like:

\documentclass[usenames,dvipsnames,10pt]{beamer}
\input{mypresentation-src.tex}

This is how your mypresentation-hand-out.tex file looks like (Observe that the only addition is the “handout” option):

\documentclass[usenames,dvipsnames,10pt,handout]{beamer}
\input{mypresentation-src.tex}

This is how your mypresentation-hand-out-print.tex file looks like:

\documentclass[a4paper]{article}
\usepackage{pdfpages}

\begin{document}
\includepdf[pages=1-last,nup=2x2,landscape=false,frame=true,
noautoscale=true,scale=0.6,delta=5mm 5mm]{mypresentation-hand-out.pdf}
\end{document}

You need to compile the 3 TeX files (not the mypresentation-src.tex file). Note that the -hand-out-print.tex file should be compiled last, since it requires the hand-out.pdf file. It’s pretty simple. I ran in to all of this via Google of course. I just thought it’d be nice to have it all in one place. Hope it helps. Cheers!

## Compiling the cp210x module for use with the NAO

I’ve been recently working on trying to get a NavChip to work with the NAO. (The NAO is very cool btw!) To start with, I was delighted to see that the NAO uses a Linux OS on it’s Geode processor. (The newer NAOs are using an Atom processor though) The issue was that this kernel that Aldebaran (the manufacturer) uses is customized. Specifically, it lacks the cp210x driver that the NavChip requires. I’ve been trying to build/compile this driver for the past week, and the one before. I’m really not a kernel developer. In fact, this is the first time I’ve come close to touching the kernel sources and well, running make!

Anyway, as a note to self (yes, another!), and as some documentation for folks who’d try to use the NAO with more hardware, here’s what I’ve done so far. I haven’t tested the final module yet, but it looks okay. I’ll only know tomorrow when I try it out on the robot if I were successful.

Get the kernel configuration from the Nao. It should be /boot/config on the file system. Copy this to your downloaded kernel source tree as .config (DOT config).

Run:

make oldconfig ARCH=i386 #My system is an x86_64, so the ARCH argument is needed

The Nao’s kernel is 2.6, so you need to use the Makefile26 file in the cp210x directory. Run configure. It’ll create a defaults.mk file. Modify this file to correct the KVER etcetera variables (You can also modify the configure script instead. Whatever you prefer):

# Makefile.config
# Automatically generated
KVER=2.6.29.6-rt24
KVER1=2
KVER2=6
KVER3=29.6-rt24
EXT=.ko
KOFILE=cp210x.ko
KDIR=/home/ankur/Documents/work/code/NAO/OS/linux-aldebaran
MODFILE=cp2101.ko
MODDIR=/home/ankur/Documents/work/code/NAO/OS/linux-aldebaran
PWD=/home/ankur/Documents/work/code/NAO/OS/linux-aldebaran/cp210x-3.1.0/cp210x

In the Makefile, under “default:”, I added ARCH=i386 (again, since my host is an x86_64). Now, just run

make

That should be it. Check if your module is okay using “file” and “modinfo”. It looks okay. I’ve got to try it on the Nao tomorrow though to confirm.

## Using SURFmex with Octave

This isn’t so much as for others as it’s a “note to self”.

I’ve recently begun actual work at my research course. Obviously, I prefer to use Octave to Matlab. Here’s how to use the SURFmex toolkit for Matlab with Octave:
Download the source and unzip it someplace. You can get rid of the mexw{32,64} directories, since they’re binaries for Windoz.
Create a folder called mex, just to keep all our output mex files together.
Install the opencv-devel package. On fedora:
$su -c 'yum install opencv-devel' Then, compile the cpp files into mex files: $ mkoctfile-3.6.2 --mex -v pkg-config --libs --cflags opencv surfpoints.cpp
$mkoctfile-3.6.2 --mex -v pkg-config --libs --cflags opencv surfmatch.cpp # Move them to your mex folder: $ mv *.mex mex/ -v
You should now have two mex files generated:
[ankur@ankur SURFmex-v2(master *%)]$cd mex/ [ankur@ankur mex(master *%)]$ ll
total 484
rwxrwxr-x. 1 ankur ankur 219400 Aug 22 11:20 surfmatch.mex
rwxrwxr-x. 1 ankur ankur 273339 Aug 22 11:20 surfpoints.mex
That’s pretty much it. All the hints were in the make.m file really.
To run one of the examples:
Copy an image to the examples folder and name it peppers.png. This appears to be one of the default images that matlab provides.
$cd examples/ octave octave> octave> addpath ../mex % add the mex files to path octave> addpath ../common % add the common functions to the path octave> path % check your path octave> small_example Your screenshot won’t look like this. I’ve modified the example a little to use different images. ## What have I been upto? Quite a bit actually! I’ve recently moved to Sydney to pursue a Masters of engineering (research) course. It’s a two year course, which will probably be followed by a Ph.D. I guess I’m in this for the long haul now. I’ve been thinking of blogging since I got here. All the work and running around has sucked up all my time though. Today, when I finally decided to finish this task, I’ve forgotten everything that I wanted to write! ### Firstly, Fedora related: I was shortly away from Fedora. The entire period was weird, because I’m so used to working on random Fedora stuff, even if it’s just hanging out on #fedora. I’ve worked and finished up my backlogs: all my FTBFS bugs have been squashed. I’m reviewing libfreenect which is a great package for folks interested in using the kinect to do cool stuff. I haven’t been able to attend any of the APAC Ambassador meetings yet. The time zone makes them on Saturday afternoons. I’m either out or sleeping at the time. I’m looking to get back into marketing a little. Ruth is working to bring back marketing meetings, which is GREAT (Come join in!). I’m going to try to bring back the Fedora pamphlet which we’ve missed for previous releases. ### Sydney related: It’s a huge change from India. I mean, as I mentioned to bochecha earlier over the IRC, the streets are almost empty at times. That’s a rare sight in India. The place is a little expensive in comparison. (I’m still in the habit of converting my prices to INR. I’ll lose it in a while as I get settled.) The university has taken great pains to help us international students get settled too, so it’s all been smooth sailing really. The people here are really friendly, always ready to help :). Accomodation is generally a hassle, but I was brainy enough to get my hands on university housing as soon as I heard of it. I’ve just only begun working on my thesis subject. It’s related to robot navigation. I still need to review literature in the field and find a gap I want to plug. I’m working on it. I get weird ideas all the time. It takes a while to follow them up and see if they’re feasible though (None of them have been feasible yet). I’m also helping with some research my supervisor’s other students have taken up related to intertial navigation systems. I need to use a sensor for this purpose. I really haven’t any background in electronics, but I’m learning quickly. The fedora electronics lab mailing list has been helpful too (Thanks!). Tomorrow I’m supposed to work with the NAO. It’s really great to be able to work with all this hardware. The one thing that bugs me is that most of this is properitory software/hardware. You need to purchase everything, from drivers, simulators, you name it. NAO is going to be open sourced according to this press release, but that’s the last I’ve heard about it. All the software and hardware specifications is still properitory and requires an NDA. (Interestingly, the NAO uses linux as it’s OS). They do support Linux, but the support is really limited compared to their support for Windows. Maybe we need to focus on research tools a little more? A majority of the researchers seem to use Windows with Matlab installs. (That’s irritating too). I’m trying to port all the existing Matlab code to C/C++ just so I can continue using my Fedora system. I’ve fortunately found football and beer people, so I do have some recreation. There are music clubs etcetera that I could join too. I haven’t join any though, not knowing how much time I’ll have research in the future. I’m still scouting the area for cheap pubs that play rock though. I guess it’ll take me some time to find those. My darling sister cooks and gives me tiffins every week, so I pretty much don’t have to cook or spend extra on eating out. Perks of having an elder sibling 😉 Ok. I can’t think of anything else at the moment! The post is random enough! Have fun! I’ll see you folks around Fedora! Cheers! ## Unavailable till the end of July I’m due to join university to start my masters course later this month. I’m currently busy readying everything to move to Sydney, and will be busy with orientation and getting settled once I get there. I will therefore be unavailable till the end of July. Please e-mail me at my fedoraproject id if something urgent comes up. I should be back in early August 🙂 ## Migrating your contacts from your Blackberry to Android using Linux I got my father an Android today: an HTC Explorer. (The Blackberry 3G plans here in India are too expensive). Of course, he had years of contacts built up in his Blackberry and I needed to migrate them. Here’s how I did it: 1. Install barry # yum install barry 2. Connect the Blackberry and run the command: btool -V -d "Address Book" > dadcontacts.vcf #dump contacts in vcard format 3. I then imported these on to his Google contacts, merged and deleted dups, and synced his phone. Of course, you can also copy the vcf to your memory card and import it if you don’t want to go via Google. That’s all. Have fun! ## Integrating byobu/screen’s copy buffer with X/Gnome clipboard I use byobu with a screen backend on xterm. I’ve been trying to find an easy way of copying stuff from the terminal to my X/GNOME clipboard. The one way that I came across was: echo "paste buffer here" | xsel #for X clipboard or echo "paste buffer here" | parcellite #for GNOME Clipboard I even tried a script to make this a little better. However, this isn’t convenient enough. I looked around a little and found a way to integrate the screen and X clipboards. However, since I use byobu, which uses it’s own buffer (I think, since, there is no /tmp/screen-exchange file on my system), this didn’t work for me. I dug up a little and found byobu’s buffer file instead. It’s kept at$BYOBU_RUN_DIR/printscreen. Therefore, a tiny change in the screen method works for byobu:
# Add cool line to make copying to x clipboard possible.
# This binds C-a b to copy screen's copy buffer to the system clipboard.
bind b eval writebuf 'exec /bin/sh -c "parcellite < $BYOBU_RUN_DIR/printscreen && xsel -i <$BYOBU_RUN_DIR/printscreen "'
Now, after you’ve put something into the screen copy buffer, press Ctrl a b (ctrl, then a, then b), and this buffer will be put into the X and GNOME clipboards!
It’s a hack. It works 😉

## Announcing: Fedora Join SIG!

We’ve all run into people who are interested in contributing. Quite a few times, these folks are completely new to F/LOSS: the environment, the workflow, the mailing lists. To make it a little easier for folks looking to contribute, we’ve set up dedicated channels where they can talk to the community. I hope that we’ll be able to make it easier for users to turn into contributors via this SIG.

We now have an IRC channel in place: #fedora-join on Freenode. If you have some time to spare, please hang out here.
We also have a mailing list in place: https://admin.fedoraproject.org/mailman/listinfo/fedora-join
If you run into folks who’d like to contribute, please direct them to these channels 🙂

## Fedora Join SIG: what do you think?

Hello folks!
We’ve been recently looking to reduce the learning gradient that new folks need to hike up when they look to contribute to Fedora. Users looking to give back to the community is amazing. I feel we need to go out and give them as much help as we can. The importance here is that most of them will be new to the workflows, SIGS, teams and processes that Fedora community uses. Quite a few of them will be new to Linux even. For these novices, learning all that is required to become contributors is a daunting task. However, what is important is that all of them have the *potential* to make awesome contributors!
At the moment, this is how folks go about it:
1. Look at the join-fedora page[1]
2. Select what they want to do, or randomly pick one that looks familiar
3. Join the various mailing lists
4. Ask how they can help
5. Start working, and learn while they work
Even though this works, there are a few issues here IMO:
1. Quite a few folks aren’t sure what they want to do. The join fedora page is confusing for them at times. They don’t know first hand what each role is about, so they aren’t sure if they should join up SIG A or SIG B.
2. The various mailing lists: devel, mktg, infra are work oriented. While we do guide newcomers that ask for help on the lists, these newcomers are usually scared to ask questions. They feel they’ll make fools of themselves if they ask simple questions in front of established contributors.
Basically, the working mailing lists aren’t exactly the best environment for new comers. They are task oriented. They aren’t dedicated to aiding new comers. We also don’t want lots of introductions etc. on the work mailing lists either. We want them to be dedicated to *work*.
I therefore suggest setting up communication channels dedicated to aid newcomers. I’ve already run into a “Welcome SIG”[2] initiative. The “welcome SIG” was intended to be more broad. It was intended for users too. If we set up “welcome SIG”, I’m afraid it’ll turn into another troubleshooting channel. We already have #fedora, the users mailing list[3], askfedora[3] for troubleshooting. I’d like to set up a channel dedicated to prospective contributors: something like a “Join Fedora SIG”(proposal on the wiki here[4]). Gnome already has something on these lines: the Gnome Love[5] project. It works. I’m on the mailing list. People ask for help, they get their guidance. Slowly, they turn into contributors. I’d like to again stress that the current mailing lists, while already present and open to the public are not *dedicated* to this purpose of guiding newbies. I suggest:
1. #fedora-join on Freenode
2. fedora-join mailing list
The goals of these are:
1. Set up a communication channel between the existing contributors and prospective contributors. Speaking to current team members is always encouraging. We could even set up a system to send “easyfix” tasks to this mailing list giving folks a chance to work on them and learn in the process.
2. Guide/aid prospective contributors to turn into solid contributors. Rather than just pointing them to join.fp.o, talk to them, see what issues they face, help them decide where they want to get started.
3. Via these channels, form better mentor-mentee relationships. Here, I mean “mentor” in the real sense of the word. Rahul, for instance, brought me into Fedora almost 6 years back via a font packaging IRC work shop. He’s still my mentor and I still email him when I get stuck in a situation. Such relationships improve the community, both work wise and fun wise.
4. Give prospective contributors a communication channel to converse amongst themselves. This is very important. Take the gsoc mailing list for instance. It is set up specifically so that the candidates can talk to each other. Since they’re all in the same boat, they feel more comfortable discussing certain issues amongst themselves. They’ll also be aware of what different people are upto which will give them a better idea of what they can do.
I’m looking to set up this channel. Whatever I’ve written above is mostly what *my* neurons could think up. I initially thought that extending the classroom SIG to also function as the Join Fedora SIG would work, but Kevin suggested we keep them separate. (The function of the classroom SIG is for the community to teach each other). Basically, I’d like to look for potential, not polish. We can help them gain the polish that established contributors have.
What are your views on this folks? Here, I’d request folks to follow “plussing”: please criticize this as much as you want, find issues, but only if you have a “plus” to give as a solution. (I ran into it in a book I recently read. I think it’s a great way to go. No harm giving it a try 🙂 )
Steps:
1. File ticket at infra to set up fedora-join mailing list
2. Set up IRC channel #fedora-join
3. File ticket with websites SIG to make tiny changes to join.fp.o to list Fedora-Join IRC and mailing list channels.
4. Get started!

## Open source creative applications

I’ve been meaning to write this post for quite a while now. Ever since I attended the session that Victor(Ting Chong Victor Yap) took at FUDCon KL 2012. It was a most interesting session. I really wanted to attend it, because the number of questions I get about creative apps that are open source is too damn high! The session gave me a huge list of applications to try out. I’m still going over them, but I thought I’d share the presentation here with the rest of the community.

This is Victor’s presentation. I suggest everyone take a look!