Skip navigation

I found Raph Levien’s GTK+ Hello World page, typed in the code, and attempted to compile it. Unfortunately, while the code itself is functional, the suggested Makefile is definitely not. These days, we use the pkg-config program to generate flags for libraries like GTK+ to the compiler and linker, rather than hard-coding them. Also, some of the directory-finding stuff for libraries and headers is unnecessary today.

Thus, while you can use his “helloworld.c” program, you’ll probably want to use my Makefile instead, which follows.

CC = gcc
CFLAGS = -O2 -pipe
CFLAGS += $(shell pkg-config --cflags glib-2.0)
CFLAGS += $(shell pkg-config --cflags gtk+-2.0)
LIBS = $(shell pkg-config --libs gtk+-2.0)
LIBS += $(shell pkg-config --libs glib-2.0)
#LDFLAGS = $(LIBS) -lgtk -lgdk -lglib -lX11 -lXext -lm

OBJS = gtk_helloworld.o

helloworld:     $(OBJS)
        $(CC) $(OBJS) -o gtk_helloworld $(LDFLAGS)

        rm -f *.o *~ gtk_helloworld

Don’t follow the recipe on the box. It’s not ideal. I take 1 cup “old fashioned pancake and waffle mix” as a base, toss in an egg, a liberal amount of sugar, cinnamon, real vanilla extract, and perhaps some chocolate powder (like Nesquik; don’t use “healthier” chocolate drink mixes like Ovaltine because they taste like crap.) Once you’ve mixed these base ingredients that won’t change, add milk and beat the mix with a fork until the mix is reasonably thin. When you pull out the fork, it should appear to be the thickness of the fake “pancake syrup” that’s really just corn syrup with magic chemicals. Too thick and the pancake will essentially be an actual cake. Too thin and the damned thing won’t flip over, it’ll just become a pancake taco. (If you like crepes, this might be desirable, now that I think of it…)

Mix the batter violently with a regular fork. This is really important because it’s why my pancakes are so much better than yours. The conventional wisdom about cooking pancakes is “don’t over mix pancake batter, just mix until the big lumps are gone. Mixing the batter too much will make a tough pancake.” This is completely wrong by my own experimentation; beating pancake batter until it is absolutely full of tiny bubbles makes for an amazing fluffy pancake full of air pockets that make it absorb all the unhealthy crap that tastes so good and make it feel more like “cake” and less like “pan.”

DO NOT follow the other conventional wisdom about how hot a pan should be to cook a pancake. The “if a drop of water dances across the surface” measure is too hot and the reason your pancakes suck is that you’re burning them up too quickly. Use a small, non-stick pan on a small burner, set to medium heat but no higher, and give the thing a reasonable amount of time to cook properly. If it looks slightly burnt, that’s the sugar carmelizing and becoming over 9000 times more delicious so don’t worry about a little “charring.” That’s just the awesomeness sealing itself in.

When you flip it over to cook the other side, go ahead and apply a lot of thin pieces of real salted butter from a real stick of real butter and spread it with the fork you’ll probably decide to eat it with. If you don’t feel your arteries hardening as you apply the butter, you need a lot more butter. Margarine is garbage and very bad for you anyway so don’t use it.

Real maple syrup is the best syrup. It’s runny and tasty and my clearly superior pancakes absorb it readily, even through the shield of real butter you’ve applied.

If you did this correctly, you just enjoyed the best pancakes ever. If you don’t agree that they’re the best pancakes ever, I can guarantee you with absolute certainty that you did it wrong. I won’t let your taste buds get in the way of my ego…or my delicious unhealthy satisfying breakfast. Now, if you’ll excuse me, I have to make some of my clearly superior scrambled eggs that I’m not telling you how to make.

Happy cake-frying, kids!

I recently had the chance to work with an Asus Vivobook X202E ultrabook (the S200E and Q200E are very similar models with only slight feature differences). I’d like to state upfront that these tiny laptops seem like pretty awesome machines. They can be had for less than $500, are quite thin and fairly light, constructed with plenty of metal instead of cheap easy-to-damage plastic, and pack a pretty scary amount of power under the hood. The Core i3-3217U CPU it uses is faster than most Athlon II X3 desktop processors, yet is designed for low-power applications where a standard laptop CPU can’t go. If this was a review, I’d go into more detail, but for now I would like to talk about one single aspect of these laptops.

The Asus Vivobook CPU constantly overheats and goes into thermal throttling at full load.


Tritech Service System burn-in temperature display; originally hit 89 and throttled.

What is thermal throttling? When a modern CPU reaches a certain temperature near the maximum operating temperature it’s designed to handle, the CPU will slow down the clock that keeps everything inside working at the same speed. For example, a 1200 MHz chip might throw its clock down to 400 MHz, reducing the heat it produces to a little over 1/3 what it was at 1200 MHz. This is both good and bad; the CPU is keeping itself from crashing by overheating, but performance drops severely until the temperature drops low enough. When it happens, you usually notice “stuttering” in the video or sound due to the sudden drop in performance, and nothing is more annoying than watching a TV show that jerks and has choppy audio for no apparent reason.

For many owners of the Vivobook 200 series, this doesn’t matter. It’s rare that streaming Netflix or watching a 720p video on YouTube (the LCD is effectively a 720p screen) will spike both cores–or all four threads if you prefer–to their maximum load. Even if it did trigger thermal throttling, the Vivobook doesn’t do it unless the 100% CPU usage is sustained for a minute or more based on my experiments, and most tasks that spike the CPU don’t do it for more than a few seconds.

Unfortunately, this thermal throttling also means that the Vivobook 200 series can’t run the CPU at full blast without random performance losses. I’d like to share with you how I fixed an Asus Vivobook’s overheating/thermal throttling problem completely.

Disclaimer: This is done entirely at your own risk, but you know that already, don’t you?

You will need:

  • Heavy duty aluminum foil
  • Lots of little thermal pads OR a cut-to-fit thermal pad sheet


Remove the entire bottom from the laptop. With the motherboard facing up and the back facing you, look for the black square with the yellow warranty label stuck to the right-hand side.


This square is what you need to cool off. Note that you will only be working with the square area to the right of where it “ramps” away to a small square indentation and the cooling fan assembly.

Cover the square (including the part that covers the RAM and also some of the “ramping” part) with thermal pads or a cut-to-fit thermal sheet.


Cut (and remove any pointy bits remaining after cutting) a sheet of heavy duty aluminum foil that is exactly the size of the area you covered with thermal padding doubled horizontally so it can be folded over itself.


Lay half of the foil sheet over the thermal pads. Apply the exact same pattern of thermal padding on top of the existing padding and foil.


Fold the foil over into a “sandwich” over those pads.


Apply one last layer of thermal pads except where the vents on the bottom will be. This will be the top 1/3 of the square you’re trying to cool; you can look through the vents at the thermal pads you’ve placed to see if you need to remove or relocate them.


When the unit is closed, these pads will make contact with a foil layer that is part of the bottom panel. Close the unit carefully, checking the “give” of the back panel against where the CPU sits! I cannot stress this enough, because thermal padding often varies in thickness and you might have to remove a layer of padding and foil to safely reassemble everything. If you have doubts, take the computer to a professional that knows what they’re doing!

After doing this modification, a burn-in test on the Vivobook maxed out at 85 degrees C with no thermal throttling, where previously it would float at 89-91 degrees C and repeatedly throttle itself.


Idle CPU temperature in TSS after the fix. It was in the 50s before!

The only minor disadvantage is that the Vivobook’s bottom gets warmer in the back because the CPU is now making thermal contact with it, but this shouldn’t be a problem and the improvement in performance under load and overall reliability should be worth it.

Open Hardware Monitor readings taken during three days of non-stop use.

Open Hardware Monitor readings during/after 3 days of use, two months after applying the cooling fix and still running cool!

Please leave any questions in the comments and I will try to answer them quickly.


Get every new post delivered to your Inbox.

Join 62 other followers

%d bloggers like this: