driver - Dave's Blog

Search
My timeline on Mastodon

Tweet from Clickbait Robot

2016 Sep 26, 12:53
18 Screwdrivers That Look Like Matt LeBlanc
PermalinkComments

Tweet from David Risney

2016 Jun 5, 4:10
I played Chrome, Edge, FF & IE against each other in WebDriverChess. Edge just beats out Firefox for #1. Results: https://github.com/david-risney/webDriverChess/#browser-face-off 
PermalinkComments

Tweet from David Risney

2016 Jun 5, 3:55
I finished WebDriverChess https://github.com/david-risney/webDriverChess/ : Two webdriver supporting browsers play a friendly game of chess. pic.twitter.com/axs92w3uF6
PermalinkComments

Tweet from David_Risney

2015 Nov 13, 1:37
Cop pulls over car for driving 10mph under speed limit to find no driver in self driving car and issues no ticket. http://boingboing.net/2015/11/13/cop-pulls-over-google-self-dri.html …
PermalinkComments

Retweet of SwiftOnSecurity

2015 Nov 1, 10:18
"Should driverless cars kill their occupants to save pedestrians?" Humans will evolve to walk in packs for protection. Time is a circle.
PermalinkComments

Retweet of CompSciFact

2015 Oct 30, 12:44
Twins denied drivers permits because software couldn't tell their faces apart. http://wbay.com/2015/10/23/twins-denied-drivers-permit-because-dmv-cant-tell-them-apart/ …
PermalinkComments

Video memory offer and reclaim (Windows Drivers)

2013 Sep 18, 9:41PermalinkCommentstechnical windows driver memory offer-reclaim

With WP7 Mango available for all, Microsoft pushes ahead with new updates

2011 Dec 1, 3:22

“including driver updates to enable Internet sharing on some models such as the HTC HD7” Just upgraded and saw this. Very cool.

PermalinkCommentstechnical cell-phone wifi router wp7

Washington Driver's License Numbers

2010 Feb 24, 12:42Apparently Washington State uses an algorithm to generate drivers license numbers. Unless someone else has the same name and birth date your license number is based entirely on your name and birth date.PermalinkCommentsmath identity washington reference

Developing on a Device | Android Developers

2009 Dec 26, 7:11Wow, that was easy to setup. After installing the driver Eclipse just asks me if I want to debug on my phone or my virtual device.PermalinkCommentstechnical reference android programming development cellphone g1 documentation google

YouTube - "Move B*tch Get Out The Way!" Desperate House CAT on Roomba Driver Bitch Slaps a Dog pit bull Sharky

2009 Dec 20, 12:19Lazy cat is also disgruntled and rides a RoombaPermalinkCommentsvideo humor cat dog roomba

Fake Zombies attacking an innocent driver

2009 Aug 17, 8:39Laughed for this comment on the zombie photo used in the Wired article: 'Funny, the Wired article attribution ... says, "Fake Zombies attacking an innocent driver." I don't know who decided on that caption, but it made me immediately want to ask 1. How do you know they're FAKE zombies? 2. How do you know the driver is INNOCENT?'
PermalinkCommentshumor zombie photo flickr wired

PowerShell Scanning Script

2009 Jun 27, 3:42

I've hooked up the printer/scanner to the Media Center PC since I leave that on all the time anyway so we can have a networked printer. I wanted to hook up the scanner in a somewhat similar fashion but I didn't want to install HP's software (other than the drivers of course). So I've written my own script for scanning in PowerShell that does the following:

  1. Scans using the Windows Image Acquisition APIs via COM
  2. Runs OCR on the image using Microsoft Office Document Imaging via COM (which may already be on your PC if you have Office installed)
  3. Converts the image to JPEG using .NET Image APIs
  4. Stores the OCR text into the EXIF comment field using .NET Image APIs (which means Windows Search can index the image by the text in the image)
  5. Moves the image to the public share

Here's the actual code from my scan.ps1 file:

param([Switch] $ShowProgress, [switch] $OpenCompletedResult)

$filePathTemplate = "C:\users\public\pictures\scanned\scan {0} {1}.{2}";
$time = get-date -uformat "%Y-%m-%d";

[void]([reflection.assembly]::loadfile( "C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll"))

$deviceManager = new-object -ComObject WIA.DeviceManager
$device = $deviceManager.DeviceInfos.Item(1).Connect();

foreach ($item in $device.Items) {
        $fileIdx = 0;
        while (test-path ($filePathTemplate -f $time,$fileIdx,"*")) {
                [void](++$fileIdx);
        }

        if ($ShowProgress) { "Scanning..." }

        $image = $item.Transfer();
        $fileName = ($filePathTemplate -f $time,$fileIdx,$image.FileExtension);
        $image.SaveFile($fileName);
        clear-variable image

        if ($ShowProgress) { "Running OCR..." }

        $modiDocument = new-object -comobject modi.document;
        $modiDocument.Create($fileName);
        $modiDocument.OCR();
        if ($modiDocument.Images.Count -gt 0) {
                $ocrText = $modiDocument.Images.Item(0).Layout.Text.ToString().Trim();
                $modiDocument.Close();
                clear-variable modiDocument

                if (!($ocrText.Equals(""))) {
                        $fileAsImage = New-Object -TypeName system.drawing.bitmap -ArgumentList $fileName
                        if (!($fileName.EndsWith(".jpg") -or $fileName.EndsWith(".jpeg"))) {
                                if ($ShowProgress) { "Converting to JPEG..." }

                                $newFileName = ($filePathTemplate -f $time,$fileIdx,"jpg");
                                $fileAsImage.Save($newFileName, [System.Drawing.Imaging.ImageFormat]::Jpeg);
                                $fileAsImage.Dispose();
                                del $fileName;

                                $fileAsImage = New-Object -TypeName system.drawing.bitmap -ArgumentList $newFileName 
                                $fileName = $newFileName
                        }

                        if ($ShowProgress) { "Saving OCR Text..." }

                        $property = $fileAsImage.PropertyItems[0];
                        $property.Id = 40092;
                        $property.Type = 1;
                        $property.Value = [system.text.encoding]::Unicode.GetBytes($ocrText);
                        $property.Len = $property.Value.Count;
                        $fileAsImage.SetPropertyItem($property);
                        $fileAsImage.Save(($fileName + ".new"));
                        $fileAsImage.Dispose();
                        del $fileName;
                        ren ($fileName + ".new") $fileName
                }
        }
        else {
                $modiDocument.Close();
                clear-variable modiDocument
        }

        if ($ShowProgress) { "Done." }

        if ($OpenCompletedResult) {
                . $fileName;
        }
        else {
                $result = dir $fileName;
                $result | add-member -membertype noteproperty -name OCRText -value $ocrText
                $result
        }
}

I ran into a few issues:

PermalinkCommentstechnical scanner ocr .net modi powershell office wia

HP All-in-Ones-The Scan Button on the All-in-One Does Not Function When the Printer is Connected to Windows Vista

2009 Jun 20, 9:45"When the scan button is pressed on the product, nothing happens. The scan button does not work correctly." The workarounds are all basically, "don't use that button then." They say their Vista driver doesn't support sending the appropriate event. Lame.PermalinkCommentsvista hp scanner driver lame technical

Eco Cars: EDAG Showcases Electric, Recyclable Concept Car For Geneva Motor Show - Ecofriend

2009 Jan 22, 9:57'Dubbed the "Light Car," the concept car is designed to communicate with other drivers using a system of OLED lights, which rest on the some part of the body of the car including the front and rear light, in the form of an OLED display panel.'PermalinkCommentscar led communication sign signal

A Reporter at Large: Atomic John: Reporting and Essays: The New Yorker

2008 Dec 29, 2:20"But the most accurate account of the bomb's inner workings-an unnervingly detailed reconstruction, based on old photographs and documents-has been written by a sixty-one-year-old truck driver from Waukesha, Wisconsin, named John Coster-Mullen, who was once a commercial photographer, and has never received a college degree."PermalinkCommentsvia:swannman bomb atom-bomb atomic-bomb history goverment nuclear physics security research science

Signs of Fall Tree

2008 Oct 28, 9:01

sequelguy posted a photo:

Signs of Fall Tree

Immediately after Sarah took this photo, a truck pulled into the empty parking spot and the driver jumped out to apologize for messing up the photo. The driver was a zombie.

PermalinkCommentsseattle tree nature gasworkspark sarahtookthisphoto

Tired Of Traffic? A New DOT Report Urges Drivers: 'Honk' | The Onion - America's Finest News Source

2007 Jun 26, 1:14Onion report on DOT study suggesting honking to alleviate trafficPermalinkCommentsonion humor video car driving traffic honk

vLite - Windows Vista configuration tool

2007 Mar 12, 5:21vLite lets you create custom installs of Vista on a DVD. It lets you remove system components and drivers.PermalinkCommentsvista windows tools howto iso boot dvd free install

Vroom

2004 Sep 10, 12:04I got my driver's license today. Imagine that. I lost all of the points that I could on the parallel parking portion of the test. You know in California they don't test you on parallel parking ability. With my new license my functional impairment level has moved from minor to non-existent. Hoo-raw. Incidentally if you search for the phrase "stealth geriatrics" on google, the first link is to a power point presentation entitled "stealth geriatrics." I just thought that was a funny phrase.PermalinkComments
Older Entries Creative Commons License Some rights reserved.