Arduino: String and Float January 23rd, 2012
Arduino has a nice convenience Class: String.
Although it wraps nicely Chars in Arduino, it misses one really important aspect, it can’t handle Float. I really don’t get it why they didn’t add this, it is so essential in handling strings and it is really a pain in the ass to cover it for yourself since the AVR methods for converting Floats need buffer variables.
So i patched the class for myself, which was much more easy than I thought. Without any deep knowledge in C or C++ I added float and double functionality to the class and I do not understand why it wasn’t done until now. I can now do String to Float and Float to String conversions without any hassle.
If you want to use it, follow these steps:
- Download this Zip.
- Backup your “WString.h” and “WString.cpp” files from the folder \Arduino\hardware\arduino\cores\arduino\
- Unzip the downloaded file to your \Arduino\hardware\arduino\cores\arduino\ folder overwriting the old files
- Restart your Arduino IDE
Please note: Changing a core class is a BAD idea. Why? Because every time you update the IDE you WILL loose the patch you added. Also future changes in the Class could break the compatibility to your patch. So please consider not using my patch. I know it sounds silly. ;o)
Here are some examples for the new abilities of the String Class:
String example1 = String(1.852); // Equals: "1.852000" String example1 = String(1.852, 2); // Equals: "1.85" String example2 = String(example1.toFloat() * 1.784561, 4); // Equals: "3.3014" String example1 = example2 + 1.58356; // Equals: "3.30141.583560", since the example2 variable is of type String the number gets converted into String and concatinated.
The default precision i chose is 6 decimal places, but you can specify any number of decimal places as a second parameter in String(num, decimalPlaces).
I hope the guys behind Arduino fix this soon.
Posted in Programming | No Comments »
TimeWasters LCD Framework for HD44780 and Arduino January 8th, 2012
At the moment i am working on my Geiger-counter which is based on this hardware, but has many more features added to it (GPS, SD-Card and Buttons). I will post more information as soon as i managed to fixate the last piece of hardware in the case.
While working on it i wanted to have a luminous LCD display and stumbled over a very nice piece of hardware: OLED displays from Electronic Assembly.
OLED displays have many advantages over classical LCD displays:
- Low power consumption
- Perfect contrast
- No viewing angle
- Bright
- Background is really Black
But after ordering a 2×16 OLED display for round about 30 euros from Reichelt i was not able to correctly use it with the Arduino LiquidCrystal library, it showed most the time pixel garbage.
At first i thought the display was broken, but as i was digging deeper into the matter i found that this display is only HD44780 controller “compatible”. What that means depends on the manufacturer.
Posted in Plugins, Programming, Tools | No Comments »
How to tame Google November 21st, 2011
There are 3 issues i REALLY hate about the new Google search page:
- The search is way too fuzzy, often i get results for an keyword only related to the keyword i entered
- While i am typing the results page is refreshing, which results in an “optical flickering” of the whole page
- After reloading (and other events i didn’t identify till now) the script sets the cursor on a more or less random point of the search string (or even rearranges the keywords), which results in me typing on places in the search string i didn’t want to
All those points combined compelled me to eliminate those issues with the tools i had at hand: The Opera browser.
Posted in Plugins, Programming | No Comments »
TimeWaster’s Geiger Counter – A system software for microcontrollers to measure radiation November 7th, 2011
TimeWaster’s Geiger Counter v1.1
This software is designed to work with the Arduino Uno and the Radiation Sensor Board for Arduino from Cooking Hacks, but should also work with your own hardware design if you adapt either your hardware or the software.
I suggest to take a look at the documentation of the Radiation Sensor Board, it gives a good summary on radiation detection and the hardware used (Especially the geiger-mueller-tube).
Posted in Programming | 6 Comments »
Open Source Programmers Are Whimps June 6th, 2010
Foreword: I write this article especially with two projects in mind: “Eventscripts” and “Truecrypt”. Come and get me.
The species called “Programmer” seem to be a bit thin-skinned when it comes to issues only “related” to their work.
Posted in Programming, Various | 1 Comment »
HTML 5 – The future starts now May 17th, 2010
This is very much the first project i have done out of curiosity instead of boredom:

An HTML 5 video player with a nice tile repeation effect.
It is mostly a performance test for HTML5′s new Video and Canvas tags allowing you to manipulate pictures and other picture related sources like videos in real time with nothing more than HTML and Javascript!
YES, NO FLASH IS INVOLVED!!!
Please don’t get me wrong: I really like Flash and imho it will never die because it can do much more application like things than HTML5 (for instance: A real time Sequencer and Synthesizer or a complete Picture Editing Suite).
But seeing done such monitor filling animations in HTML5 is really nice.
So check it out and enjoy a whole new video experience on Viiideeeooo.de!
Posted in Design, Programming | No Comments »
Adobe Flash AS 2 snowflakes snowing effect script December 20th, 2009
Well, i was bored again, and here is the outcome: A snow effect for Flash AS 2, which uses very less CPU power.
It is extremely simple to use:
1. Create a new empty movieclip on the top layer of your (root) movie.
2. Move the new movieclip at the x and y position 0 Pixel.
3. Copy the following code to the first frame in your new movieclip: Flash Snow Script
Posted in Programming, Tools | No Comments »
Portal End Credits – The Flash version November 26th, 2009
Are you looking for “Portal The Flash Game – Console Commands List”?
Once there was a bored little Webdesigner.
One day he thought: “Wouldn’t it be nice to make a Flash version of the Portal end credits?”
No sooner said than done, he extracted the commands and the music from the game files itself, and wrote an interpreter for them in Flash.
My luck the Portal end credits are text based commandos and not a video, so i could take the commandos to reproduce the credits 100% identical in flash. You can even copy and paste the text.
Have Fun:

Portal End Credits in Flash
Twitter made easy – How to tweet with PHP with 19 lines of code October 7th, 2009
You know the dilemma, you want to write a simple tweeting PHP script and have to mess around with the Twitter API.
With the following small script you can tweet with a simple function call. It IS that simple (And SSL secured!!!).
Here’s the function:
Posted in Programming | No Comments »
The smallest AJAX framework ever July 21st, 2009
The most AJAX frameworks are bloated with many functions you’ll never use or need. Who wants 60 KB of JavaScript if your only need is to send and load data? I Don’t.
I have found somewhere a short howto for AJAX, and derived (rewritten) the smallest AJAX framework ever out of it:
Posted in Programming, Tools | 1 Comment »
