Thursday, February 16, 2006

Get indi baby!

Well, after a year of very hard work, we have finally entered a (limited, invitation-only) Beta for indi. What is indi? You can find out here: http://getindi.com. indi is our answer to folks who believe that you need to put all your stuff on their servers to gain anytime-anywhere access to it.

Technically indi combines a lot of the work I have done in Ruby such as FreeBASE (plug-in framework for the FreeRIDE IDE), Jabber4r and Alph (Ruby to Flash bridge) with the work I have been doing in Flash/ActionScript...specifically the ActionStep port of the OpenStep/Cocoa App Kit to Flash. This combination creates a cross-platform execution environment with Ruby as the data manager, and Flash for the UI.

indi runs on OS X and Windows right now, and as soon as Flash 8 is supported on Linux it will run there as well. indi is more like a platform than an application, and its going to allow us to give some really cool capabilities to our users and deliver on a vision we have of digital independence (reverse the two and you get in..di - indi).

Anyway, we have a busy schedule ahead to release our next Beta in about 4 weeks at O'Reilly's Emerging Technology Conference.

Tuesday, August 30, 2005

Flash and Web 2.0

Mike Chambers from Macromedia posted on his blog about what Web 2.0 is and how the Flash platform relates to it. Having spent the better part of the last six months building a substantial application with Flash which, as a by-product, has produced the ActionStep open-source component framework and using the MTASC compiler for building swfs from ActionScript, I will say that Flash is far better suited to building applications that feel like desktop apps, but that operate in a distributed manner. If Web 2.0 is "the Web as a platform" as Mike says, then Flash should be seriously evaluated for projects that are trying to build applications for that platform. If you want to just use HTML and AJAX, that's fine, but for us Flash is a must...and when you see our applications you will understand why.

Saturday, August 06, 2005

ActionStep and Rails

Some may have heard the crazy story about my integrating ActionStep and Rails at OSCON. ActionStep is an OSS component framework for Flash written in the ActionScript programming language. Rails is...well that goes without saying. I was slotted to speak on ActionStep on Thursday in the Emerging Tech track. I have to admit that although I have been doing Ruby programming for 4 years, I had never touched Rails. My job really has nothing to do with Web frameworks and such, and time slips by... Anyway, OSCON presented an opportunity to see Rails in action and I sat through David's great tutorial session. Rails is a really nice Ruby framework, and it struck me that it would be cool to come up with a templating language to build ActionStep-based UIs with Rails. Monday and Tuesday I iterated on a design with David, Dave Thomas, Glenn Vanderburg...all the fun Ruby folks, and came up with something linguistically nice. David asked me to add to my ActionStep/Rails syntax slides into my presentation as a 'teaser'. Here is an example of the templating format:

NSView :test do
  attributes :rect => {:x => 0, :y => 0, :width => 200, :height => 400}, 
             :backgroundColor => 0xdddd00
  publishes :selected_person_id => execute { names.selectedItem.label }
  NSButton :hello do
    attributes :title => "Test", 
               :rect => {:x => 10, :y => 10, :width => 20, :height => 20}
  end
  ASList :names do 
    attributes :items => @names, 
               :rect => {:x => 10, :y => 50, :width => 100, :height => 200}
  end
end

Having slides that showed this format was cool with me...but on Wednesday night all that changed. I went to hang with the FOSCON folks, and presented the teaser slides to them. People really liked the syntax and the implications of what having a Flash framework attached to Rails could mean. Then all hell broke loose. Well, actually not hell proper, but chaos harnessed in a very Ruby way by _why the lucky stiff. After his side splitting performance I went back to my hotel around 11pm and decided to just implement the syntax in Rails and ActionStep. I mean, how hard could it be to build a Rich Internet Application framework? I started at 11:30 with two Dr. Pepper and by 6:00am had stuff rendering from Rails to ActionStep. I crashed for an hour and a half, and then went to the David's keynote on Rails. His keynote gave me just the boost I needed to push it a little further and I spent the next hour getting data sent back from ActionStep to Rails. At my 11:30am session I was able to fully demonstrate Rails dynamically creating and serving an ActionStep-based UI. You could update the text templates, press refresh in your browser, and the UI would re-render with your changes. Round-tripping data...the works.

I would like to say that it was just a few lines of code, but that is not quite the case...its a few more than a few. I will be creating a Gem by the end of the month to allow people to play with things, and until that time I wrote up what the syntax looks like...you can see it here in more detail:

http://www.osflash.org/doku.php?id=actionstep_rails

To Open Source and all that it implies..um...ok, I need to sleep now.

PS. United Airlines sucks, I just needed to get that out.

Wednesday, May 04, 2005

ActionStep source is on SourceForge

Well, I went released (in CVS) what I have been busy working on for the last month. ActionStep source is now available on the project site under a BSD-style license. Whew. Porting OpenStep to ActionScript is quite a pain, and there is so very much to do. The goal was to mirror the API as much as possible (with necessary syntactic variations). In Objective-C you would create a button like this:

[[NSButton alloc] initWithFrame:NSMakeRect(10,10,50,20)]

In ActionStep you do this:

(new NSButton()).initWithFrame(new NSRect(10,10,50,20));

Other than that, the API is going to attempt to support as much as my/our little fingers can port. I have NSButton and NSTextView working, but will be making them better over the next few days. Scott Hyndman has joined in and is working on NSBox to get his feet wet. NSNotifications all work, target-action, the responder chain...good times!

When I can lay out a strategy for total domination of the UI world, I will post again, for now I need to sleep.

Wednesday, March 09, 2005

Speaking at OSCON 2005

So, my talk on ActionStep was accepted for the 2005 OSCON conference which is being held in Portland from August 1-5. Its a high honor to be accepted at this event, and I thank the program committee for selecting my talk. I will not disappoint. As to what ActionStep is...heh...its coming! ActionStep is an open-source (thus OSCON) component framework for Macromedia's Flash player that InfoEther is paying to develop. There is a lot of open-source momentum building in the Flash community and ActionStep's goal is to be one piece of the puzzle. Another significant piece is the MTASC ActionScript compiler which is freaking incredible and makes ActionStep possible. I will be posting more about ActionStep soon, and will be switching my CVS to the SourceForge project soon as well. Oh, and don't worry, Ruby is still my best friend...this ActionScript language is a necessary evil!

Saturday, October 02, 2004

Alph code released into the wild

Well, here is the first public release of Alph:

Alph Project Site

Alph is a Ruby/Java/Flash (I know...I am insane) that bridges the Ruby and Flash runtimes (and Java too...but that is to solve the cross-platform projector problem that Macromedia will not solve.) With Alph and Ruby (>= 1.8.1) you can create Flash user interfaces (forms, etc) that are fully coded in, and controlled by Ruby. No Actionscript required, no Flash IDE required, just Ruby (and those dependent runtimes). Here is a simple ruby script:

This example demonstrates the List Box family of components (ComboBox, ListBox, Grid). See: http://www.ultrashock.com/tutorials/flashmx2004/ui-components06.php

$:.unshift '../lib'
require 'alph'
app = Alph::Application.new
frame = app.new_frame
frame.control.setBounds(100, 100, 640, 480)
flash = frame.flash
myComboBox = flash.new_component("mx.controls.ComboBox", 
  :editable=>false, :rowCount=>5,
  :_x=> 14, :_y=>26, :_width=>291, :_height=>22)
myComboBox.labels = ['Organic Snacks', 
 'Recycled Office Paper', 'Wind Energy', 
 'Solar Power']
myComboBox.change do |event|
  # The myComboBox.selectedItem method returns 
  # the label (not an object) because the data is not set.
  puts "You selected #{myComboBox.selectedItem}."
end
myList = flash.new_component("mx.controls.List", 
  :_x=> 14, :_y=>66, :_width=>291, :_height=>120)
# Data provider is an array of anonymous objects (label/data)
myList.dataProvider = [ 
  {:label=> "Organic cotton underwear", :data=> 7.25},
  {:label=> "Organic T-Shirt", :data=> 15},
  {:label=> "Recycled Office Paper", :data=> 6.99},
  {:label=> "Organic Cola", :data=> 1.25}
]
myList.change do |event|
  # The myList.selectedItem method returns an object with
  # a label and data property because the data _is_ set.
  item = myList.selectedItem
  puts "#{item.label} costs $#{item.data}"
end
myDataGrid = flash.new_component("mx.controls.DataGrid",
  :_x=> 14, :_y=>200, :_width=>291, :_height=>120)
# Column names align with column ids
myDataGrid.setColumnNames( ["Product", "Price", "Quantity"] )
# Data provider is an array of anonymous objects (keys = column ids)
myDataGrid.dataProvider = [
  {:Product=> "Underwear", :Price=> 7.25, :Quantity=> 3},
  {:Product=> "T-Shirt", :Price=> 15, :Quantity=> 1},
  {:Product=> "Paper", :Price=> 6.99, :Quantity=> 7},
  {:Product=> "Cola", :Price=> 1.25, :Quantity=> 24}
]
myDataGrid.change do |event|
  # The myDataGrid.selectedItem method returns the anonymous object
  item = myDataGrid.selectedItem
  puts "#{item.Product} costs $#{item.Price} (#{item.Quantity} left in stock)"
end
# You can rename column names by index
myDataGrid.getColumnAt(0).headerText = "Product Name";
myDataGrid.getColumnAt(1).headerText = "Price";
myDataGrid.getColumnAt(2).headerText = "Quantity Left";
flash.new_component("mx.controls.Button", :label=>" Close", 
  :_x=>380, :_y=>89, :_width=>120, :_height=>35, 
  :icon=>"icon_16x16_warning") do |closeButton|
  closeButton.click do 
    frame.control.close
    exit
  end
end
frame.control.show
app.wait_until_done

Pretty sweet eh?

Go download it, and let me know what you think.

Sunday, December 28, 2003

The Alph Project?

The Alph Project is a bridge between two language runtimes; the Ruby interpreter and the Macromedia Flash player. Flash was originally constructed to be an animation runtime and because of this it has attracted a more design-oriented rather then developer-oriented community. The Flash player is actually a stack-based virtual machine which now supports the ability to write graphical component-based applications in the ActionScript 2.0 language. Although Flash and ActionScript are powerful, the downside to developing in it is that each application you build is compiled into a binary (swf) movie, and the main development environment (Macromedia Flash) is a commercial (> $500) product. Although the Flash development tools are commercial, the player runtime is free and cross-platform.

Alph will create a free, open-source alternative for constructing dynamic Flash-based interfaces in pure Ruby and aims to be an unique, comprehensive user interface framework. Alph ships with a single binary (swf) file that when executed connects to the Ruby-based service (which could be in-machine or network/web-based). This single swf file contains all the Flash 2.0 components compiled in with a network protocol handler, method dispatcher, and event manager which allows Flash-based interfaces to be created at run-time by Ruby over a TCP/IP socket. Ruby programs will have access to the full version 2 GUI component model of Flash 2004 without the commercial costs of existing Flash tools, and those Flash interfaces will have the full power of Ruby (and its library of extensions) behind them.

I originally demonstrated an Alph interface during my RubyJDWP presentation at the Third Annual Ruby Conference in November. I am currently working (as free time allows) on getting this fully running, and will be posting the source to the Alph Project website when it gets in a state where it is possible for others to develop with. I expect the code to be online by the end of January. As I make progress, I will keep my blog up to date with interesting tidbits and things I'm learning along the way.

Thursday, October 30, 2003

Down with Activation

Jim Rapoza over at eWeek just published an opinion piece on Macromedia using product activation titled "Down with Activation". As you can see from my previous post I rather dislike activation. Jim documents how Intuit included activation in their last TurboTax (2002) product and it was a terrible failure. Macromedia should learn from others mistakes before they have to learn the hard way.

Nice job Jim!

Wednesday, October 29, 2003

Macromedia's Activation and Panther Woes

Well, its been one of those days. Actually, it started last night when I tried to start my installed copy of Macromedia Flash 2004. First some background.

Last friday (10/24/03) I upgraded to Panther from 10.2.8. When I performed the upgrade I selected the Archive/Install option. The upgrade went great...no worries...all my applications were still there in my dock after the upgrade. The first thing I did (after playing with some new features of Panther) was build Ruby 1.8.1. You can read my instructions on how to do this here. Last night I needed to jump back into a super-secret cool Ruby project I am planning that uses Flash. I will blog that project as I get something to show, but the problem arose when I clicked on the Flash icon. The icon started bouncing, then just stopped. No error messages, no dialog boxes...nothing.

I actually paid $$$ for a Macromedia Devnet subscription so I called the hotline (yeah right!). It was 7:30pm EST (4:30 on the west coast) and their tech support was closed! OK...so...I just started Googling around a bit and discovered that Macromedia now incorporates activation technology into their programs. One listing I found stated that you should deactivate the product prior to installing Panther. Nice suggestion, but too late for me. Suck!

So, I went on a deletion spree and removed all hints of Macromedia stuff from my computer. I removed the folders in the Applications folder, the /Library/Application Support/Macromedia folder and the ~/Library/Application Support/Macromedia folder. I then re-installed the application. I figured this purging would suffice, but lo and behold demons were still present. I double-clicked on the Flash 2004 icon and it bounced around and the quit...just like before. Suck^2!

The next day I called tech support and finally reached a human and told them my problem. They recommended that I remove all the Macromedia folders and try again. I told them I already did, and that threw them off the script a bit...then they told me they would call me back. I got many calls. Each one asking me to try something that I had already done, like installing other Macromedia apps (Dreamweaver, etc). All those apps behaved the exact same way. I did some more searching and stumbled across this page. About half way down you see a section titled Mac OS 10.3 user authentication dialog fail.

Just before reading this I opened up the Console application to see if there were any reported errors there. What I saw was re-enforced by what the release note said. I saw a message "Authentication Service: Started" appear just before the bouncing Flash icon died. Hm...smells like smoke. It seems that there is this creepy little application in this creepy little folder (/Library/Application Support/Macrovision/AuthenticationService). Ah ha! I cried and promptly removed this folder, removed all the Macromedia folders (again) and re-installed. I then clicked on the Flash 2004 application and it bounced a couple of times, then quit...just like before. Suck^3!

Fortunately Macromedia tech support called back and told me to try something. They said to delete this folder named /Library/Application Support/Macrovision. "Been there--done that!", was my reply, and they told me it was time to escalate the problem to the next level of tech support. I was really just pissed at this point. Then something struck me...plists. What if this damned Authentication Service had little plists somewhere. I went to the /Library/Preferences and there I found a Macrovision directory. "Move to trash" was what I said and then double-clicked on the Flash 2004 application and....

Bam! The dialog that said "You need to activate Flash on this computer..."

Yippie. I entered my 10^1000 digit license code and...chorus of angels singing...Flash worked (as did Dreamweaver, etc). So, like a good citizen I called back Macromedia and told them how I fixed their freaking activation service. They were so thankful that they closed the issue and charged me one of my tech support incidents.

A couple of lessons learned:

(1) If Macromedia did not have cool technology, I would never do business with them.

(2) Activation-based software license enforcement sucks^4!

My Photo

May 2008

Sun Mon Tue Wed Thu Fri Sat
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Recent Posts

Photo Albums