March 2011 - Posts - More Wally - Wallace B. McClure
in

MoreWally.com

Giving people what they want, More Wally. This is the technical and personal blog site of
Wallace B. (Wally) McClure.

This Blog

Syndication

News

Please goy buy 3-4 copies of my book on MonoTouch titled "Professional Android Programming with Mono for Android for .NET/C# Developers." They make great gifts all year round. Plus, I get about $.25 when you buy a copy.

Technical Sites

More Wally - Wallace B. McClure

This blog will have all kinds of posts about Wally McClure. In it, there will be tons of .NET and computer programming posts as well as Wally's views on life in general. As you might guess, this site and blog help you get More Wally in your life. What more could anyone want? iPhone, Android, MonoTouch, MonoDroid, Mobile, HTML5, .NET, ADO.NET, ASP.NET, AJAX, jQuery, jQuery Mobile, ASP.NET AJAX, and Windows Azure............follow me on twitter at Wally

March 2011 - Posts

  • My article on iPhone & iPad Programming for .NET/C# Developers with MonoTouch has been published

  • Turn-By-Turn Driving Directions in Android with Mono for Android (MonoDroid)

    I needed to open some turn-by-turn directions in Android.  I did the following with Mono for Android, and this code worked:

                        String url = String.Format("http://maps.google.com/maps?saddr={0},{1}&daddr={2}", lat, lon, dAddr);

                        Intent intent = new Intent(Android.Content.Intent.ActionView, Android.Net.Uri.Parse(url));

                        StartActivity(intent);

     In this code, I needed to get some directions from the current latitude and longitude.
  • Mobile Connections - Las Vegas, NV - April 17-21

    I'll be speaking at Mobile Connections in Las Vegas, NV. I'll be speaking on:

    • Programming Android with MonoDroid.
    • Mobile Web Apps with HTML5.
    If you are there, please look me up.
  • The Android Emulator Keyboard

    I'm not the only one that finds the Android Emulator's keyboard brain damaged.  It wants to show Asian characters by default.  Can't it detect the system its running on and show that language by default?  Of course not.  Thank fully, there is a parameter that you can set in the hardware setting of the Android Emulator to show things just a little bit better.  Once I set it, things worked much better for me.  I got the English style keyboard and I got the keyboard to properly move between various hints in the InputType property of an EditText field.  Here it is:

  • Android Emulator - Increasing Performance Suggestions for MonoDroid

    Like everyone else in the world, I've been asking myself how I can increase the performance of the Android emulator.  Dear god, the emulator is a poor performer.  I mean bad, as in really bad.  I was at AnDevCon this week.  While there, I met Eric Cloninger and Mike Wolfson.  Both had a couple of suggestions for increasing performance and fixing the little annoying issues.  If you want to fix this with MonoDroid, then here's the command that I issued to start the emulator:

    emulator @AvdName -no-boot-anim -partition-size 512 -scale .75

    • The @AvdName param is the name of the Avd that you want to start.
    • -no-boot-anim tells the emulator not to not show the cool wavy (annoying?) Android emulator graphic.  This turns startup on my system from about a minute to a few seconds.
    • -partition-size 512 sets the partition size.  This is needed by MonoDroid.
    • -scale .75 sets the scaling of the emulator image.It supports numbers between .1 and 3.  Setting this to a value of less than 1 means that there are fewer pixels to move around in memory.  More than 1 means that there are more pixels to move around in memory.

    Finally, while not an emulator option on startup, I find that the emulator starts up without network connectivity a number of times.  To toggle network connectivity, use the f8 key.  It does seem to turn on properly.

    Having done this, your MonoDroid app will see the running instance and will allow you to connect to it, just like you had started it inside of Visual Studio (or MonoDevelop).

  • HTML5 Presentation from AnDevCon using ASP.NET Web Pages and Razor

     Here is my presentation on HTML5 Applications from AnDevCon.

    I hope you enjoy the source and the pptx file.  It has info about:

    • ASP.NET Web Pages.
    • Razor.
    • jQuery.
    • jQuery Mobile.
  • Code Project Mobile Virtual Conference with MonoDroid

    I'm speaking on Wednesday at the Code Project Mobile Virtual Conference on the subject of Android Programming for .NET/C# Developers with MonoDroid (aka Mono for Android).  Check it out, I think its free.  Hopefully, you'll find this helpful in your mobile pursuits.

  • Why Mono for Android?

    I have gotten a few questions asking why a developer should use Mono for Android (aka MonoDroid).  I thought I would just do a brain dump on my thoughts on this.

    Java Developers are looking at MonoDroid and wondering "Why"?  They see that the core of Android is Linux, an open source operating system, with a bunch of passionette people behind it.  Java developers have a free runtime, they have a free IDE (Eclips) to develop with, they have a free SDK to develop with, they view Java as an easy language to learn (and I'm not debating any of these points).  Why would anyone want something else?  Let me introduce myself, I'm Wally McClure.  I'm a .NET developer, and I think you have a product that is being accepted into the marketplace.  I want to get my some of that.  How do I do it in a productive manner that doesn't require me to take all my existing knowledge and throw it away?  For a developer to be productive, they need a language that they understand, an IDE that helps them to be successful, and knowledge of the underlying operating system (the -isms).

    • I'd like to "get me some of that."  I'd like to be able to write programs that run on your platform.  I'd like to do that with the least amount of pain possible.  I'd like to reuse as much of my existing .NET knowledge as I can.  Mono, the open source implementation of .NET runs on a variety of platforms.  I can take my existing knowledge of C#/.NET and apply it to Android.  This solves my problem of the language.
    • I'd like to use my existing tools as much as possible.  I've invested time, money, and energy in learning Visual Studio .NET.  I am productive in my existing environment, why should I have to add a new environment to program in.  Because Mono for Android integrates in with my existing IDE, the problem of having an IDE that I understand has been solved.
    • Now, ultimately, I still have to learn the Android-isms to be productive.  We've already faught the Java, cross platform wars and we know that writte one run anywhere failed.  I don't think that anything can really help us on this. 

    Now, I don't mean to imply that learning the Android-isms is simple.  Its hard.  You have to learn the platform.  There's no getting around that.  Does Mono for Android solve two thirds of my problem?  That would be underestimating the problem of learning the Android-isms.  I do think that it helps with half the problem.  Now that I am up and going, it seems that learning the Android-isms isn't that hard, but I would have had to learn them either way.

    If I had to learn a new language, platform, and IDE, that's probably too much of a time commitment for most developers(and me).  It would be the equivalent of putting a permanent stop sign in front of me, just something I don't have the time to overcome.  Some developers will trivialize the time required to learn a language or IDE.  I've been through this and the time is not insignificant.  When you compare to bill rates, the time required can get upto speed will dwarf the cost of a plugin.

    However, if I only have to learn the Android-isms, I can probably handle that.  Now, there's nothing wrong with Java.  For me, the cost of Mono for Android will more than offset the time required to learn a new IDE and language.

    Now, lets take this a step further.  What about iPhone and WP7?  How does my Java code translate to iPhone and WP7?  It doesn't.  However, if I commit to using Mono/.NET then I can hit those 3 platforms for a significant portion of my non-UI logic.

    Posted Mar 02 2011, 12:30 PM by wallym with 2 comment(s)
    Filed under: ,
2006 - Wallace B. McClure
Powered by Community Server (Non-Commercial Edition), by Telligent Systems