Category: computers

Linux, 2017!

First of all, please do not read this post as a complain. Just as an analysis. I am a Linux user for decades. I remember using Linux in my first year of University, somewhere about 1996. I never stopped using Linux, in the server, but during some years, somewhere between 2002 and 2017 I was a Mac user for the desktop (one PPC Mac Book, two Intel Mac Book Pro). Back to the beginning of 2017 I needed an update, and decided to go back to Linux. Mostly because of the price of a decent Mac Book Pro when compared with a generic laptop. I decided on a Dell, and without a lot of thinking, decided on a Dell with a 4K display. Well, I had a hard time trying to install a distribution. Tried Mint, Debian and Ubuntu. Curiously, all gave trouble with UEFI boot, but the one that ended up installing a working Linux was Mint Given it is Debian based, I can keep up with the Debian updates, and install most packages available only for Ubuntu.

While I see some applications getting better, from 2002 to 2017, it seems Linux community continues rewriting the wheel. I can’t see any big difference from what I am experiencing today in the desktop with what I was experiencing earlier with Gnome 1. Yes, the code was changed. It might be more stable, faster, support a couple of new things. But it seems we continue rewriting and rewriting the same old applications.

Then there is the issue with a 4K display. Even if GTK3 has support for High DPI screens, a lot of  applications are not written for this toolkit. And I am not sure, at all, that this is something that need to be managed by the graphical toolkit. I still think it is a Xorg issue, where we should be able to define DPIs for each screen, and have the basic low-level tools scale everything. As this is how I see things, I decided today to look to the blog of Xorg. And it doesn’t have news since 2013. As I could read, now most work is done as independent libraries. Nevertheless, it is strange no changes were needed to be done in 4 years.

Also curious that a bunch of applications using node.js are being working great. Examples are GitKraken, Code, Atom, Franz… and even Sublime is working great on 4K (even if it has some other issues). Unfortunately Unity3d is not working properly in 4K, but that looks more like an issue with their own GUI system, than anything else (but then, if Xorg took care of things, maybe it would work great, just like it works acceptably under Windows). But other things, like old Gtk, Xlib, QT or even Java applications still look like needing a microscope to be read.

So, here I am, with a shiny new laptop, deciding to keep Linux, or getting back to.. huh.. windows! Yeah, I do dual boot, but I like Linux for most things. But some aren’t possible As a teacher, I know I will have problems when trying to use a beamer. When connecting an external display, everything will look monstrous. Or I can change the resolution on the built-in screen, go searching the HiDPI switch, turn it of, restart the session for it to be correctly applied, and then use the laptop. Shame.

And yes, I know a lot of this is my fault. If I did not change to Mac, and if like me other hundred of developers didn’t do the same, probably we would have a lot more Linux users, writing and patching these applications. Or we would just end up with a lot of more distributions, a lot more window manager, but with the same main issues.

At last, but not less important, I would like to thank you to everyone that is still working on Linux making it better. I know this is not a paid job. I know you (and I) do what we want, and what makes us happy. That is why this is not a complain text. Just looking to what I see, without pointing any fingers.

 

 

MonoGame: From Windows to Linux

The traditional way to have a C# MonoGame Project compile both under Linux and Windows is to use a tool named Protobuild. With the last version (3.6), the MonoGame OpenGL template for a cross platform game includes references to the libraries in the three main formats: DLL for windows, DyLib for mac, and so for Linux. This seemed like a good chance for making things work.

And it mostly did. Change to the path where the .csproj file resides, and run xbuild. The bin folder should be created, and inside there, a path accordingly with your project configuration. For example, bin/DesktopGL/AnyCPU/Debug. Then, go there, and just run your game with
mono Project.exe.

(future work: check how to make things work outside the output dir)

Euclidea – Geometric Construction Game

Euclidea

Euclidea

Euclidea is a very interesting game. Something new, a different game, educational, fun, difficult, challenging. A great game. If you like geometry, if you loved how to build geometric constructions on paper, but always made them blur, you will love this game.

Getting back to Linux: Part #1

Debian_Logo_02After the last Apple keynote, the news on Mac Book Pro, and the exorbitant price, I took part of this Sunday to look back to Linux as a Desktop. Although I work usually on a 2011 Mac, that runs perfectly (just some bumps), I have a Lenovo laptop. So, I decided to install the Linux distribution I have been using lately for my servers: debian.

First I downloaded the netinstall image. It complained of missing drivers for wi-fi and ethernet. Then, I downloaded the non-free netinstall image. Same behavior.

Well, decided to keep it, and use a USB stick to install the missing packages. After going from/to my mac to download missing packages and dependencies, I got something. The card is detected, the correct (at least it seems) module is loaded, ifconfig shows the device, but ifup fails to bring it up.

After googling and fighting with wpa (first I was thinking this was the problem), I found out that Linux was just deciding that it couldn’t load the interface, and mentioned something about rfkill, that I am not sure what it is.

Googled a little more and found articles saying that my Lenovo has some other wireless card than the one listed by lspci. Strange.

In any case, the day is almost over, and I need to get back to my job. My conclusion so far is a quote from an old teacher, now a friend: Linux is still a Cowboys operating system.

Not sure about all Linux distributions, but debian for sure.

 

Slitherlink

Slitherlink

Slitherlink

Usually I do not play much on my Android phone. But when waiting for someone or something, to have a good puzzle is worth it.

Slitherlink, as you can look up in the Internet, is not an idea of this app author. It is a known puzzle, and if you look up in Google Play, you will notice a few implementations.

I can’t say that this one is the best, as I did not test any other. But it installed correctly, runs smoothly, and seems to have some good diversity of modes and difficulty levels. Therefore, I am quite happy with it, happy enough to consider buying the ad-free version, with extra levels. Truth be said, the free version includes a good mount of levels, and ads are not intrusive. So, kudos for that.

About the game, it is up to you to read about it and test it. It can be seen as some sort of minesweeper, with some reasoning mechanisms also used in sudoku.

eXist-db: Installing XQuery functx module

existdbUsing the blog as a notepad, I will start posting here some notes on things I discover and are not very clear in the documentation (or I just did not find it at first).

In the last times I have been hacking in eXist-db, and writing XQuery. I noticed a website with a lot of interesting functions with the functx prefix. The eXist-db website help reference returns hits for this module. But it is not installed by default (or at least, it can happen on not being installed by default).

To install it, just run this XQuery command:

repo:install-and-deploy(“http://www.functx.com”, “1.0”,
“http://exist-db.org/exist/apps/public-repo/public/functx-1.0.xar”)

After installation the functx module can be loaded with

import module namespace functx = “http://www.functx.com” at “/db/system/repo/functx-1.0/functx/functx.xql”;

Also, for reference, I found the list of eXist packages here.

IGI Global: the clown of scientific publishing?

I am not sure how I agreed to write a chapter for a book to be published in IGI Global. Probably, being edited by a friend that invited me personally to send a proposal made the difference.

I have my contribution ready, but starting to think on just forgetting it. Why? Because IGI Global is, surely, kidding with me. They have a set of rules for their contributions, and somewhere in the middle, they say, and I quote:

 

LaTex. LaTex files are NOT accepted because they are not compatible with IGI Global’s typesetting program. As an alternative, we require that you use MathType (see “Equations” below).

First, dear IGI, when not possible to use the fancy form of LaTeX, the latest X should be in uppercase. Second, if hey are not compatible with your typesetting program, that is probably because you are using the wrong typesetting program. And, no, LaTeX is not useful only for math. Please learn what LaTeX is, try to use it, then evaluate how it can be useful or not for your editorial requirements.

Third (or fourth, I think I will stop counting), look to other publishing houses. Who are your adversaries? Springer, probably. Do you know they use LaTeX? Yeah, they do! And they create good quality document. Of course they do, they use LaTeX. And no, I have an IGI book, and no, your books does not have typesetting quality. I am sorry.

Finally, because I have some hours to lose formatting the chapter, if you want us to use Microsoft Word, please create a template in Word. Do you know what that is? You know how it can be useful? Do you? I am sure you don’t.

 

BaseQi

Usually I do not advertise on this blog. In fact, this is not properly advertisement, but a review. But given I am happy with the product, yeah, it can be seen as advertisement.

I will talk about BaseQi, the Ninja Stealth Drive. Basically, it allows you to pop-in a MicroSD card into your MacBook keeping it all inside. I know this sounds a little pornographic. But if you have a small SSD drive, like me, you will be happy to duplicate this easy its space. There are some similar products with the SD card built-in, but then, you can’t replace it later if, for example, it gets non working. Also, there are some similar products with this same mechanism. For those, I can’t talk, as I did not try them.

To explain the idea, follows a set of pictures. Of course you have similar pictures in their webpage, but having pictures from an user can make you a little more confident.

First, the Samsung 128GB drive being added to BaseQI.

DSCN0983

Note how tight it fits…

DSCN0984

Now, put it on your Mac SD Card reader…

DSCN0985

And push it all in… just clean!

DSCN0986

Any.Do – The best task tracking system ATM

Any.DO-Logo-+-NameFor a long time I have been trying different ways to track my stack of tasks. I tried different approaches, from using paper (it is fun!), Calendar Mac App, Wunderlist, and recently Any.Do.

Paper is probably the best, as you can write freely, draw, scratch, rip, and other physical activities that are quite fun. But, unless you get a small notebook, it gets hard to be with you all the time. You could also scratch on a smart phone device, like Samsung S Note app. But when I am working in my laptop, I do not like to have to take the phone to add or remove entries. So, next natural step is to use a tool that syncs tasks between devices.

Wunderlist is cool. Cool enough for me to use it for some time. It has the fun fact that it keeps finished tasks scratched, just like you might do in paper. Nevertheless, the app is (or was, when I tried it) quite limited. You could have different todo lists, but it was hard to see them all at once. You could add some manual tags to tasks (I did that for some time), but it got boring. And it wasn’t easy to sort tasks. You needed to, somehow, change its date.

I tried for some time Evernote for that. It allows to add tick boxes to your notes. But again, not easy to see all tasks in one screen, unless you add them all in the same sheet. And if you do, it gets complicated to manage the order, and the categories, with lots of cut, copy and paste.

So, recently I am using Any.DO. It is also available for Mac, Web, and Android, so easy to sync around. And it has three main ways to see your tickets: per category, per time, or per importance. And in each of these three views, you can sort easily your tasks just by moving them around. I am very satisfied (for now, at least) with it. But I still wonder how much more fun and efficient it might get with the paid version. But a monthly (or yearly) subscription is not exactly what I want right now. Nevertheless, if I could buy the app (and not a service) I might be buying it soon.

The Joy of Logic (2013)

Socrates syllogism

Socrates syllogism

For something completely different, today I talk (erm, write) about a BBC documentary on Logic. It starts with Socrates Syllogisms up to Boole algebra. Then a quick visit on Mathematics nightmare of trying to prove Mathematics logically (yeah, Maths aren’t logic!), introducing first order logic. Then, we get back to Boole algebra and Alan Turing, and understand how it changed the world, and how you, my friend, are using Boole algebra in your computer, at levels you might not think of.

This should be a required documentary for every computer science student (or researcher). It is really worth to “lose” a class to show this to our students.