Archive for category Geekiness
Recursion
Posted by Andrew Flanagan in Geekiness, Somewhat Random on January 20, 2010
So what happens when your can of WD-40 is left out too long and the trigger gets stuck and won’t stop spraying? Spray it with some WD-40?
Did you know that WD-40 stands for “Water Displacement – 40th Attempt”? Thanks Wikipedia!
Price Tracking
Posted by Andrew Flanagan in Actual Events, Geekiness on January 19, 2010
Price tracking can be confusing online. Retailers like Amazon and Newegg (two that I buy from frequently) seem to sometimes change their prices daily. One expects prices to drop over time but this doesn’t always happen. I was surprised to find that prices for Solid-State Hard Drives have actually been rising recently (although the real deals appear to have been back in October/November). Thankfully there are some tools that can help. One of them is the Camelizer — a Firefox plugin. Alternatively, you can access the same data at the website camelcamelcamel.com (for Amazon) and camelegg (for Newegg). The same group also tracks prices at BackCountry, Best Buy, OverStock.com, and Zzounds,
Here’s an example of one of the SSD’s that I’m interested in:
In this digital age it’s nice to have something that keeps some history around. It’s easy to get information these days but it’s always easy to change information (which is why I’m also a big fan of the WayBackMachine — check out the original Google page!) We don’t keep coupons, flyers, or catalogs anymore, we just remember the website.
Anyone experience this sort of problem?
Happy New Year
Posted by Andrew Flanagan in Geekiness on January 1, 2010
It’s 2010 everyone! It’s ridiculuous how fast 2009 went by. I have high hopes for the year. We’ll see how things go…
Office Setup
Posted by Andrew Flanagan in Actual Events, Geekiness on December 31, 2009
I seem to remember talking about this already but I’ve further upgraded my man-cave to new levels of geekiness. I know have two 26″ screens that I’ve wall mounted just above my desk (keeps them in the same position regardless of all the clutter on my desk.)
Currently I’m running OS X on my right screen and Windows 7 on the left. I use Synergy to share mouse/keyboard commands so it feels like one continuous background. I’m mostly using OS X still but the new machine has 6GB of RAM which gives a lot of breathing space if the Mac gets bogged down.
What I’d like to do is switch out my aging Logitech system with two simple monitor speakers — I still haven’t decided what make/model to get but they have good stuff for pretty cheap. I’ll plan on mounting these on a small shelf along with all the hard drives and accessories that I have. If that all works, I could simply get rid of the desk and bring the leather chair from downstairs. Should be a nice setup.
I have visions of punching a hole behind the monitors and making an in-wall rack that I can use to store my rather large 4U case. The wall there backs into the garage rafters and there’s quite a bit of room. Ventilation and cooling would be an issue but I’m sure I can come up with something that works well.
What’s your work/play area set up like? I’ll post any pictures I receive…
Graphs
Posted by Andrew Flanagan in Geekiness, Somewhat Random on December 29, 2009
Google Public DNS
Posted by Andrew Flanagan in Actual Events, Geekiness on December 3, 2009
Google today announced that they’re providing a high-performance public DNS server. This sounds like a great idea from a performance perspective … I’ve not had too many complaints with my DNS servers provided by Comcast but I’ve definitely had some issues at my work with slow/non-responsive DNS servers.
However, I suppose this is just one more thing that can go wrong. Now there’s one BIG target to attack and if someone happens to poison the cache, we’re all in a world of hurt.
I do plan on updating my home router though to start using this. I’ll post a follow-up with my review.
From: Official Google Blog: Introducing Google Public DNS.
Update: They’re definitely taking security very seriously. Some more info can be found here that’s quite helpful.
Scuttle Firefox extension
Posted by Andrew Flanagan in Geekiness on October 23, 2009
I use Scuttle on my server (for storing bookmarks). The beauty of the solution is that I have a centralized repository of bookmarks (which isn’t too special considering that many services provide this feature) but in addition, it’s very nicely set up to server as Live Bookmark lists in Firefox. So for example, I can have a single Live Bookmark drop-down for all work-related links, or all my “daily” websites or whatever and automatically add and remove from them as I see fit. The Live Bookmarks mean that all I need to do to reorganize links is retag them and it’s instantly working on all the computers I have.
It’s handy. But there’s a problem. The Firefox extension for Scuttle isn’t really being maintained. It’s pretty simple but needed a new “max firefox version supported” string in the configuration. I’ve updated this and am now posting the unofficial 0.4.2 release of the Firefox Scuttle plugin with support for Firefox 3.5+.
Unicorns?
Posted by Andrew Flanagan in Geekiness on May 17, 2009
I don’t know how many people reading this may know, but you can use Google as a calculator. Doing a search for “4 * pi” will in fact return a special “first result” that is the calculation. This is handy as it also does unit conversions like in order to convert 22 km to furlongs. There are some easter eggs though, and this is definitely the best: number of horns on a unicorn. Maybe it’s just me, but this is incredibly funny to me.
I’ve been playing with the very impressive WolframAlpha and wondered if they had done anything similar. Sure enough “number of horns on a unicorn” return the expected result. Even more amusingly, my second guess, number of horns on a horse shows that they really having some fun:
C++ from Python
Posted by Andrew Flanagan in Actual Events, Geekiness on March 30, 2009
I was impressed today to see how easy it was to call a C++ DLL from Python. I got the following information from another site:
1. Create a file called dlltest.cpp and write a function that sums two numbers and returns the result:
//dlltest.cpp #define DLLEXPORT extern "C" __declspec(dllexport) DLLEXPORT int sum(int a, int b) { return a + b; }The extern “C” construct tells the compiler that the function is a C function. It also removes the decorations from the functions names in the DLL.
__declspec(dllexport) adds the export directive to the object file so you do not need to use a .def file.
2. Include the header of the function in dlltest.h:
//dlltest.h int sum(int, int);3. Create a new Dinamic-Link Library project and include the two files, compile, and create the DLL.
4. You can now use Dependency Walker to see the list of the exported functions. You should see here the sum function.
5. Move the DLL in the Python folder or use
>>> import sys >>> sys.path.append(r"C:\path\of\dll")to include the DLL folder in the list of Python folders.
6. Use the ctypes module to access the DLL:
>>> from ctypes import * >>>mydll = cdll.dlltest >>> mydllNote: ctype module is already included from Python 2.5. If you are using an older version you can download ctypes here.
7. Now call the function:
>>> sum = mydll.sum >>> sum <_FuncPtr object at 0x0097DBE8> >>> sum(5, 3) 8
Reposted from here… (Thanks!)
I need to get into Python more — I’ve used Ruby a bit but have tended to ignore Python simply because I’ve not seen it is needed. Evidently, I need more side projects.