Useful Keys

If you had asked me ten years ago, whether I find the keys we are going to talk about in this post any useful, I would have said NO. But ironically, I use them quite a lot these days and I cannot live without them as well.

Home and End Keys

If you program or do document editing a lot you will understand the importance of Home and End. There is no quicker way to get to the start and end of a line.

Ctrl + (Shift) + Left/Right Arrow

Ctrl + the arrow keys, can be used to move over words rather than characters. Can be really useful for programming and document editing. I cannot live without this. Just makes navigation faster and easier.

Using Shift along with this combination helps you select words rather than selecting characters as is the case with Shift + Arrow Keys

Page Up/Down

Again, for people who handle many lines of code on text editors and huge documents, there are no better friends than Page Up/Down. Scrolling can be the most annoying thing sometimes on the mouse and these keys work like a charm in these situations.

F2 Key

F2 is one of those keys you cannot live without whether you are browsing files in a file explorer or working in an excel. F2 can be used to rename a file or edit a cell swiftly. It is very handy.

Ctrl + Shift + T

This combination is extremely useful on browsers. They reopen closed tabs. The function may prompt you to ask if this is really that useful, but once you start managing tabs in the order of 10 to 15 or more, you will start realizing the need for it.

 

Those would be my top five. Of course the obvious ones like Ctrl + S for save; Alt + Tab for window switching; Super + L for locking the pc and just the Super key for entering into the search menu on Ubuntu are really important too. There are a lot of shortcuts that pertain to specific software and are really useful, but I wanted this list to be as generic as possible.

 

Advertisements

Stop Sound – Matlab

clear sound will stop a sound that is playing on matlab.

The sound command on Matlab (sound(some_variable,sampling_rate)) plays a sound based on the values in a variable and a sampling rate. But it almost seems like there is no way to stop it. You can, though, if you clear all the variables by typing in clear all. But that can be problematic as it will wipe out all the variables you are working with. The best thing to do instead, is to type in clear sound.

Listing absolute paths with `ls`

Normally when you list the files in your directory/sub-directory with the ls command you would get the paths to those files with respect to the current directory.

But what if you wanted to save this list and you wanted the absolute paths rather than the relative paths. Well it doesn’t strike you first but then when you know it, its like, “Oh its that obvious!”

So you do

ls -d $PWD/what_ever_you_are_trying_to_list

The $PWD gets filled with the path to the current directory.

Example:
ls work/*.md

might have yielded

work/this.md
work/that.md
work/something.md
work/someotherthing.md

But,
ls -d $PWD/work/*.md

would yield something like

/home/username/work/this.md
/home/username/work/that.md
/home/username/work/something.md
/home/username/work/someotherthing.md

Crossfade – The Smooth Operator

Do you have your crossfade on in your music player? If not, you should turn it on now. You are missing out some really good stuff.

Smooth Transitions from Song to Song. Crossfades create a really smooth transition from one song to another. That means that your brain also transitions much smoother, if you are sensitive to that sort of thing. Usually music producers add a crossfade between songs, themselves, in the mastering stage or during arrangement itself. But still, there are times when this maybe a good thing to have in your music player when you navigate to the next track maybe?.

Smooth Transitions between Pausing and Playing. Abrupt pause and playback can be annoying. You would understand what you were missing so far when you turn on Crossfade. When you pause and play a song without a crossfade, it can get glitchy as well.

But where this makes a huge difference is subconsciously in your brain. Have you tried suddenly halting from running? How did your body feel. So how do you stop running usually? If it was possible to go from 0 to 10 km/hr in an instant, would it be a pleasant experience? But that’s what happens in your brain when pause and play randomly without a crossfade on if you are actively listening to a song.

Easier to handle interruptions. A lot of us don’t like to be interrupted when we are listening to music. We soak ourself in the immense joy of tingling our basilar membranes with a spectrum of frequencies being activated in rhythmic fashion. That is a lot to turn off suddenly, to divert our attention to a pesky request from a friend asking for ten bucks, right? 😛

Well it can get a lot easier if you had your crossfade on. Trust me. It will definitely ease your irritation.

So, switch it on, and let me know how it went for you. 🙂

My Experience With Laptop Batteries

I have been using laptops for about 8 years now. Just like everyone else, I have always wanted to make my battery last for a really long time. Not in terms of back up time, but in terms of how long it keeps working until I have to replace it. When I say working, I mean decently, with a backup time of at least about 20 minutes. But how many of us have had trouble with this. I would say most.

There are so many blog posts around, with so many ways to go about it. Some say, its better that you keep charging and discharging it. Some say, keep charging and discharging only between 40 to 80 percent. That would be around 3 to 7 times a day for someone who works on his laptop all day, depending on the laptop and the battery. How would that work out? I am not sure. Some say that it is better to just work without the battery when ever you can. So what is good and what is bad. Over the years, I have tried a lot to keep my batteries running the best way possible. So I wanted to list out some of the things that I do at the moment and why I do it. Maybe it could help you out. But if you don’t agree with any of it, let me know why. Maybe I can adopt your logic. But please talk only out of experience, and not based on things you have read. The reality is really different from the theory.

I work with my power supply connected all the time. I work on my laptop for about 10 to 15 hours a day. Typically, my battery lasts for about 2.5 hours. That would mean that I would have around 2 to 4 charge-discharge cycles a day assuming 2.5 hours to discharge and 1.5 hours to charge back up again. This would mean that my battery would last for only a year if I go around charging and discharging it. I did some investigation as to how my power supply works. I visited my laptop manufacturer’s forum and I found out that once the batteries are full, the supply gets directed away from the battery so I will not be overcharging it. I think this has helped me a lot.

I sometimes work without the battery as well. When ever possible. But there is a lot of fuss associated with that, so I don’t do that much these days. When you are done working and you want to pack up, you have to shut it down before you connect your battery. I don’t think it is a good idea to plug in the battery when the laptop is on. I don’t think I want to face the electrical mess that may happen. Most of the time, I like to have my laptop on standby, to continue working from home. I don’t like the trouble of booting up all my tools again. I don’t shut it down.

Standby’s are perfectly Ok. Some always shut down their laptops thinking giving it a rest would be a good idea. But when your laptop is on standby, only your RAM is being used. So its not really a big deal, unless you are thinking that you are straining your RAM. We leave our phone ON all the time, but we apply a different logic when it comes to the laptop. But also consider this, there is a theory that when you reboot your system, it actually puts more pressure on the electronic components than just being On all the time, because of the temperature changes that they go through. I shut it down once in three or four days probably. I work on linux and I have come to realize that going to a standby state and coming back up again does a few things specific to my hardware. So when I sense some hic ups, I reboot it. But coming back to the battery! Being on stand by consumes ~1 percent per hour on my laptop that lasts 2.5 hours normally when it is up and running. So if I leave my laptop on stand by over night, I would probably only lose about 10 percent..

If I discharge it, I discharge it. What I mean is that, once I let my battery discharge even a little, I count it as one discharge cycle, and I let it fully discharge. I wait for it to reach 25% and I start charging it back again, and continue using it with the power supply plugged in until I vacate the place. The reason behind this is the theory that the life of a battery is based on the number of charge-discharge cycles. Although some people refute that, I assume it is an active theory and just do it, and it works for me.

I saved the most important one for last. If you read any blog any where, you would see one aspect that is common to all of it. It is that Heat Kills your Battery. It is its worst enemy. So no matter what precaution you take and what you do, if your battery is unnecessarily heating up, you would definitely see some degradation in its health. The best way to prevent it would be to get a good cooling pad. “Oh, come on man. The laptop already has a fan inside. You think the makers of the laptop, who took into consideration all those design aspects would have forgotten this one?”. Eh, well I think, for a number of good solid reasons, that they do compromise on this (looks, weight,..). So I think we better do something about it ourself. Especially if you are from a hot city, which naturally provides a good environment for your batteries to heat up. 90% of the time, I run my laptop only on a cooling pad, and I think I am seeing a lot of difference. I think a good cooling pad has a lot of uses, the batteries are just one of it.

How do you treat your batteries? Let me know.

 

Good Uses for Old Phones

We live in a day and age where mobile phones are as common as shirts and pants. There is a good possibility that a lot of good phones that are lying around in your house which can be put to good use. Here I list a few ways in no particular order. Some of these functions can only be performed by a smart phone, some by ordinary phones as well.

  1. Download Manager – If you have a slow wifi connection at home, your downloads might take a really long time to complete. If you have an old android phone lying around, you can install a torrent downloader on that and any sort of download manager that you need and start downloading. You might have some old memory card lying around as well. If that is the case, then well and good. You are all set for your download journeys. This is less power consuming as opposed to leaving your desktop on all the time as well.
  2. Timer – Timers come of good use in a lot of places. For example, in the kitchen; when you want to time your game time, tv time and so on. There is one good technique called the pomodoro technique that works based on the principle of concentrating for 20 minutes and then relaxing for five. Repeating this set three times and then taking a long break for 15 mins at the end of those three cycles. It can help you be more productive. I have tried it and it works. Use your old phones for that, you will save yourselves from the distractions of all the notifications from your current phone.
  3. Music Player – Your current phone may have a lot of space, but I am sure you would want more. Why not push all the music to your old phone and just have the hits on your phone. This works well if you don’t own an iPod and you probably don’t need to. An old phone works really well for this.
  4. GPS Device – How many times have you been frustrated with maps and GPS consuming your battery like crazy. Why not use an old phone for that. You don’t have to worry about your phone going out of battery at the end of the journey. Sure you can use your car charger but isn’t it less fussy to just forget about having to charge your phone all the time.
  5. E-Reader – If your old phone has a good screen you can use it as an e-Reader and save battery on your current phone.
  6. Backup Phone – When you have your old phone lying around for any use mentioned above. You will have it charged. This will come in handy when your current phone dies and you don’t have a power bank with you.
  7. Fitness Tracker – Install a fitness tracker that requires just your accelerometer and your GPS. You will again not have to worry about your battery draining in such activities.
  8. Donate It – Last but not least. Rather than just keeping in a shelf and letting it die, give it to someone who really needs it. You will have earned their love.