Tuesday, January 07, 2014

Windows Phone Corrupts MP3 Metadata

Yes, I own a Windows 7 Phone.  I have only two regrets:

  1. Windows Phone doesn't seem to respect ReplayGain.  To be fair, I hadn't heard of ReplayGain when I bought the phone.
  2. Windows Phone corrupts MP3 metadata when it plays songs.  The first hint will be that your phone itself will be confused about the artist and title.  The next time you sync to your computer, Zune will flash a message about syncing something, and then your normal MP3 player (foobar2000) will start showing question marks instead of artist and title.

    Metadata is not corrupted for all played songs.  If I cared enough, I could backup my recently played songs before syncing and break out the hex editor to figure out why some songs aren't corrupted, and what the corruption looks like.  Seems like a waste of time since I can't fix the underlying problem and don't really want to batch rebuild all the metadata in a form that WP likes.
The way forward seems to be keeping two copies of the songs.  One for foobar2000, with good metadata, including ReplayGain annotations.  The second with ReplayGain baked right into the audio, and therefor not really caring if metadata is corrupt.

I haven't found a single complaint that looks like this.  Am I really the only one with one of these phones?

Saturday, May 18, 2013

Hardwood Floors: Lessons Learned

Having completed the hardwood floor of one small room, there are things I wish I had known in advance.

  • quicklock would have allowed me to remove a few rows and undo a spacing mistake that staircased its way through the rest of the floor before I realized what was happening
  • solid hardwood (as opposed to engineered) would have a consistent color throughout, and would therefore make it harder to see gaps between planks
  • you can somewhat undo spacing mistakes by finding the thickest and thinnest boards you have, then using them to rebalance the next row.
  • if you are lucky enough to pick a dark color engineered floor, but unlucky enough to leave gaps between planks, you can mitigate the appearance by using toothpicks to paint the gaps with black ink (I used fountain pen refill cartridges for my ink)
  • floating floors tend to flex up at the edges - no idea if they will settle eventually, or if the baseboards can be used to hold the edges down
  • if there is any flex near the walls of the floor, you can hear the tinfoil-looking part of the underlay crinkling when you walk on it

Monday, January 16, 2012

Path Over 2048 Chars Kills Windir Environment Variable

All of a sudden my cmd prompts in Windows 7 had no PATH environment variable.  And when I tried to change my path (Right Click on My Computer -> Properties -> Advanced Settings) I got a terrible error message about %windir%\systempropertiesadvanced.exe not being found.

Bottom line, if your PATH environment variable is more than 2048 characters it (and WINDIR) stop being visible in many contexts.

I fixed it by manually running c:\windows\system32\systempropertiesadvanced.exe and deleting one entry from my PATH to put me under 2048 chars.  New cmd windows work just fine.

Interesting that you can't use the GUI to increase path length above 2048; only badly behaved installers are allowed to do that?

Props to http://www.sheldor.org/index.php?post/2011/03/03/Windows-7-WINDIR-missing-issue for pointing me in the right direction.  I haven't found any other acknowledgement that this issue exists.

Wednesday, January 11, 2012

OCIDescribeAny Can Allocate Memory

The doc is silent on the matter, but my testing shows pretty clearly that OCIDescribeAny is allocating memory and attaching it to the OCIDescribe in/out param.

So never reuse OCIDescribe structures when making multiple calls to OCIDescribeAny; do OCIHandleAlloc/OCIHandleFree calls for each iteration.

Saturday, October 29, 2011

2011 Surrey Candidates for School Trustee

See also candidates for Mayor and Councillor.

Terry Allen (SFE)



Ijaz Chatha (SCC)



Moh Chelali (SCC)



Sukhy Dhillon (SCC)



Charlene Dobie (SCC)



Pam Glass (SFE)



Laurence Greeff (SCC)



Paul Hilsdon



Malkiat Kang



Laurie Larsen (SFE)



Reni Masi



Ram Sidhu (SCC)



Ann Van Rhyn



Shawn Wilson

2011 Surrey Candidates for Councillor

See also candidates for Mayor and School Trustee.

Kuldip Ardawa (SCC, BCNDP)
Immigrated from England 8 years ago, focus on multiculturalism.

Bob Bose (SCC)
Elected in 2008 in 7th place (out of 8).
Wants a "Living Wage" ($18.17/hour) for anyone doing city work.
Focus on transportation and land-use planning, sister cities (paid vacations).
Endorsed by NWDLC.
Wants to spend more money on a recycling contractor that doesn't throw most of the recycling away.  Bet you feel good about all the sorting you do now!
Wants to "greatly expand our park system", "work to relocate the BNSF heavy rail from our beaches" which I'm sure won't cost approximately a zillion dollars.

Lawrence Chen

Doug Elford (SCC)
Failed in 1999 bid for council.
Endorsed by NWDLC.

Rina Gill (SCC)
Not elected in 2008; 9th place (out of 8).
Endorsed by NWDLC.

Tom Gill (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 2nd place (out of 8).
Focus on "fiscal leadership", public transportation, young families.

Kuljinder "22" Gill
Convicted of uttering threats and mischief under $5000.  Currently charged with impaired driving causing bodily harm, etc.  Focus on youth activities, like shooting ranges... 22 = 22 calibre ammunition?
Generally thinks Surrey "sucks".

Paul Griffin
Former Surrey GM of Communications wants more Skytrain in Surrey (rather than light rail).
Wants "windfall rezoning" tax to prevent flipping after rezoning.

Bruce Hayne (SF)
Endorsed by Surrey Fire Fighters' union.
Partner at thornleyHayne, worried about "red-tape" interfering with business formation and growth.

Linda Hepner (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 4th place (out of 8).
Former Manager of Economic Development for Surrey, chaired the George Bush Summit.
On "red-tape" committee and supporter of the Build Surrey Program.

Judy Higginbotham
Under fire for putting "re-elect" on her signs even though she isn't currently a councillor.
Defeated in the last Federal election, wants a halt to tax increases in Surrey.

Gary Hoffman
Not elected in 2008; 16th place (out of 8).

Marvin Hunt (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 8th place (out of 8).
Rubber-stamped controversial casino documents while acting-Mayor.
Supports clean energy and light rail projects.
Once accused of covering up sexual abuse in the church where he was a Pastor.

Bernadette Keenan (SIGN)
Not elected in 2008; 19th place (out of 8).
Opposed Gateway/South Surrey Freeway, involved in numerous union and protest activities.
Green jobs, social justice, living wage, affordable housing.

Mary Martin (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 5th place (out of 8).
Wants New York-style "community courts".

Imtiaz Popat (SIGN)
"A queer-community activist long known for his Green credentials" who apparently failed to be elected to the Park Board in Vancouver in 2008.
Wants to make Canada more like the nations immigrants are fleeing from.
More transit, cheaper transit, more recycling programs.

Barinder Rasode (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 6th place (out of 8).
Big on discussing social issues like bullying and domestic violence.
Wants light rail.

Grant Rice (SCC)
Not elected in 2008; 12th place (out of 8).
Endorsed by NWDLC.
Thinks Surrey is taking on too much debt.

Gary Robinson (SCC)
Ex-Surry Councillor, ex-junkie, focus on homelessness and addiction.
Was once homeless, wants more "affordable housing".
Endorsed by NWDLC.
No garbage incinerator, opposes toll bridges.
Opposes BC Hydro Smart Meters.

Mike Robinson
Wants to implement direct democracy.

Stephanie Ryan (SCC)
Not elected in 2008; 11th place (out of 8).
Wants developers to dedicate 10-20% of new development to "affordable housing".
Endorsed by NWDLC.
Wants "living-wage" requirement for city employees/contractors.
Fight fan?

Partap Singh
Not elected in 2008; 15th place (out of 8).
Wants Surrey to get involved in operation of Provincial ERs, private walk-in clinics, trucker parking and to legalize all secondary suites.

Barbara Steele (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 3rd place (out of 8).
As President of UBCM accepted nomination of Gordon Campbell for Order of BC.

Susan Thomas
Wants wards, critical of decision to build new City Hall.

Judy Villenueve (SF)
Endorsed by Surrey Fire Fighters' union.
Elected in 2008 in 1st place (out of 8).
Wants homeless put in "stable housing" rather than shelters.
Endorsed by NWDLC.
"Pacific Co-ordinator for the Writer's Union of Canada for two decades."

John Wolanski
Wants to tax all the bridges in the lower mainland, and spend that money just as as fast as it comes in.
If elected will donate "10% of my gross compensation" to the Surrey Food Bank.

Steve Wood (SCC)
Wants a city "rental registry" and secondary suite fees to subsidize "affordable housing".
Endorsed by NWDLC.
Wants more transit (including light rail), more "parks and recreation and sports programs" for youth.

Sunday, October 23, 2011

2011 Surrey Candidates for Mayor

Here is a lightly annotated list of all the candidates running for Mayor of Surrey in 2011. Feel free to leave links, complaints, or a thumbs up for any of them in the comments.

See also candidates for Councillor and School Trustee.

Vikram J.S. Bajwa

Realtor/Mortgage broker who wants an international airport with in Surrey city limits.

He is apparently promoting himself with a photo that is about 50 years out of date.

Wants inflation indexed taxes, RCMP replaced by municipal police, ward system.

Wants a lot more money spent on the homeless (8M vs current 3M).

Wants to "involve local taxpayers in all projects over $10 million".  Developer friends that happen to be local tax payers?
Ross Buchanan

Author and business consultant who believes our tax dollars and Translink levies are being squandered, that developers have too much political influence, and that there shouldn't be any trash incinerators built in the region.

Wants to consider cancelling new city hall construction.

Generally objects to rate of growth in city spending, want more bylaw enforcement.

Touraj  Ghanbar-zadeh
Touraj Ghanbar-Zadeh

Founder of All Nursing, wants to replace Translink gas taxes with property tax increases, decrease lot size required for chickens from 1 acre to a quarter acre.

Generically critical of Watts, not so big on proposing solutions.

If elected will "cancel the new gas tax".  Do we even have a municipal gas tax he could cancel, assuming the council went along with it?

Wants single fare zone for transit.

Headshot
Clifford Tamuno Inimgba

A model/actor who "likes [his] body".  Is the sole member of his own consulting business?  Unfavourable reviews by his students at Northern Lights College.

No particular focus to campaign.

Big signs and website for what I assumed was a joke candidate at first, even if that site misspells "Surry" and links to non-existent endorsements.

Wants to streamline Federal immigration policy, have more bus stops, freeze taxes, encourage local banks to make dubious loans.

Very concerned about minorities.  Wants to both freeze taxes and massively increase services.

Shan Rana

Wants a ward system for Surrey.  Describes himself as a professional activist.

Wants 10 councillors instead of 8, but paid proportionately less.
Dianne Watts (SF)

Endorsed by Surrey Fire Fighters' union.

Brought ex-Presidents Bush and Clinton to speak at 2011 Surrey Regional Economic Summit.

Very big on environmental initiatives, like free (taxpayer funded) electric car charging stations at Surrey City Hall - a nice tax free gift to city employees rich enough to own an electric car.

Hated so much by ex-Liberal (Federal) candidate , ex-SCC Surrey Council candidate Jim McMurty that he's taken to writing deranged complaints against newspapers that claim she lives in Cloverdale.

Takes credit for crazy advance in real estate prices, thinks it's a great thing.

Wants light rail.

Believes Surrey city employees are not overpaid because "We’ve got a collective bargaining process that our bargaining unit is very involved in, and wants to do the very best for the workers."  I'm not sure Watts understands the role the city's negotiators are supposed to be fulfilling.

Deanna WeltersDeanna Welters (SIGN)

Artist who hates Bush., wants "green" infrastructure like light rail.

Wants more public transit, townhome style first floors in new condo developments, and believes something about mature trees but I can't tell what.

Generally an environmental/anti-development focus.

Sunday, September 11, 2011

Replacing Toyota Echo Rear Side Marker Lights

I had to do a ridiculous amount of research to replace some running lights on my Echo, which by all rights should have been a simple job.

Lesson 1:
At some point Toyota (during manufacture or maintenance) put a freakishly large W5W in one socket - now the socket doesn't hold normal bulbs securely enough.  The solution (thanks to the guys at Lordco) is to bend out the contact wires on the bulb - that provides enough tension to hold the bulb in place.

Lesson 2:
There are lots of little bulbs that fit the same socket as the W5W.  If you read online disussions, talk to the parts department at Peace Arch Toyota, or even the otherwise bright folks at Lordco, it is fine to replace W5Ws with any bulb you feel like.  These people will grudgingly admit that yes, there is a brightness difference, but not very much.  The 194 was a popular replacement suggestion, in spite of being only half as bright as the W5W.  WTF?  I don't understand why bulbs aren't labelled with lumens or candlepower, seeing as how that is the most important detail.

My online scavenging says:

  • 194: 2 candlepower
  • 168: 3 candlepower
  • W5W: 4 candlepower

Lesson 3:
2003 Echo user manuals say you should be using W5Ws, but the dealership computer says 192.  I never found out what candlepower that actually is.  (Lordco's computer agreed with the user manual.)