Sunday, February 26, 2012
Embarcadero Academy
Friday, February 24, 2012
Exceptions in Async
Pop quiz time! What would the user see if this code is executed in your application?
Parallel.Async(
procedure
begin
raise Exception.Create('Exception in Async'); end);
The answer may surprise you: Nothing! At least if you’re not using the latest SVN version.
Wednesday, February 22, 2012
Introduction to Debugging
Blaise Pascal Magazine #21 is out with with my introductory article on debugging. Two more advanced articles on the same topic are scheduled to follow.
Tuesday, February 21, 2012
Accelerometer Revisited
I wrote about handling accelerometer in iOS from the browser before (Detecting Device Movement, Accelerometer Demo) but I wasn’t happy enough with my code and I promised to return with the third part. Today I returned to the topic with advanced features – handling data smoothing and calibration.
Monday, February 20, 2012
Blaise Pascal Magazine: “Multithreading” series
In the last week I’ve republished all the articles about multithreading I’ve written for the Blaise Pascal Magazine. To simplify linking from other sites, I’m listing them all in this post.
Sunday, February 19, 2012
Blaise Pascal Magazine Rerun #9: High Level Multithreading
This article was originally written for the Blaise Pascal Magazine and was published in Issue #18.
Relevant Delphi code is available at http://17slon.com/blogs/gabr/BPM/HighLevel.zip.
Saturday, February 18, 2012
Blaise Pascal Magazine Rerun #8: Debugging Multithreaded Applications
This article was originally written for the Blaise Pascal Magazine and was published in Issue #14.
Friday, February 17, 2012
OmniThreadLibrary Documentation: Future
I have just finished a pretty long chapter on futures.
Any comments, corrections, ideas etc are welcome.
8 Simple Rules for Modifying Production Database
- Make sure you have a backup!
- And by that I mean a fresh backup, made just now, not an idea that there may exist a person who knows where a backup is stored!
- Make sure you can restore from the backup!
- And by that I mean that you have tested the restore procedure. On the backup that you have just created. And that you have tried accessing restored backup with the program that usually operates on it!
- Don’t type any SQL commands. Use only scripts/programs that were previously tested on a development/test database.
- And by that I mean tested by yourself, not by a fictitious somebody who may have tested a script three years before on a database used by a completely different program!
- Don’t modify production database!
- And by that I mean DON’T MODIFY PRODUCTION DATABASE!
Thursday, February 16, 2012
Blaise Pascal Magazine Rerun #7: Intraprocess Communication
This article was originally written for the Blaise Pascal Magazine and was published in Issue #12.
Relevant Delphi code is available at
http://17slon.com/blogs/gabr/BPM/Communication.zip.
Tuesday, February 14, 2012
Blaise Pascal Magazine Rerun #6: Synchronisation in Multithreaded Environment
This article was originally written for the Blaise Pascal Magazine and was published in Issue #11.
Relevant Delphi code is available at http://17slon.com/blogs/gabr/BPM/Synchronisation.zip.
Monday, February 13, 2012
Blaise Pascal Magazine Rerun #5: Four Ways to Create a Thread
Relevant Delphi code is available at http://17slon.com/blogs/gabr/BPM/FourWaysToCreateAThread.zip.
Blaise Pascal Magazine Rerun #4: Introduction to Multithreading
This article was originally written for the Blaise Pascal Magazine and was published in Issue #9.
Friday, February 10, 2012
Accelerometer Demo
My accelerometer blog ended rather abruptly, without a demo program so today I’m returning to the topic.
To test the accelerometer control I wrote a very simple program in which you can move a rectangle around the screen by tilting your iOS device. You can test it here.
This program builds heavily upon the source code I found on Alberto Sarullo’s blog. Thanks!
Wednesday, February 08, 2012
OmniThreadLibrary Documentation: Async
First small part of the forthcoming documentation is available in the wiki, Any comments, corrections, ideas etc are welcome.
Tuesday, February 07, 2012
Detecting Device Movement
For my next quest I decided to find out how accelerometer works in web applications. IOW, I wanted to control an object on my HTML page just by moving my iPad around.
I limited my quest to iOS because that’s my favorite toy. don’t know yet how to do it in Android – this StackOverflow post hinted that access from bare JavaScript may not be possible. PhoneGap somehow does that, but it’s quite possibly that they implement Java wrapper that exposes native accelerometer data to your JavaScript. But that’s just guessing.
Thursday, February 02, 2012
Wiki Editing
Do you have any recommendation? I'm sick of using Notepad2 for these purposes.
In case there's no such tool available - is there a young programmer that needs a pet project? Put together a TSynEdit (to bring in highlighting and printing) and a toolbar/ribbon and you'll be half done...