6 ms·
This is coming close to the way I envision we’ll be programming in the future. This goes from traditional 1-dimensional text-based programming to 2-dimensional
by sjayasinghe 10y ago
This is coming close to the way I envision we’ll be programming in the future.
This goes from traditional 1-dimensional text-based programming to 2-dimensional visual programming.
What I envision is a 3-dimensional augmented-reality programming language where program elements will be floating around in 3d space around us and we use an augmented-reality interface to interact with them.
It’ll also enable us to do IoT programming in a very literal sense.
For example if you look at an air conditioner, light switch, or some other network-connected appliance that’s in front of you in the real world then the augmented-reality display will overlay the interface exposed by that device.
Let’s say that you’re looking at your phone (not the screen but the actual object). Since this is a device with a GPS chip your AR interface will indicate that you can do location-based programming with it.
Then you create the equivalent of an if-condition specifying a 10m radius around your current location.
if (phone is within 10m of current location) {
}
Now you look at a lightbulb in the room and your interface shows you that the lightbulb has a method for turning on.
You draw a line from the then-branch of the if condition to the light bulb.
You’ve created a program that turns on the light bulb in your room whenever you’re within 10m of this room.
- DonaldFisk 10y agoWhile in my optimistic moments I imagine we'll be programming visually in the not too distant future, and am doing all I can to bring this about, I still would prefer to turn on light bulbs by flicking switches, which simply close electrical circuits rather than call methods. For that, some might consider me a Luddite.
- sjayasinghe 10y agoRight, I'm totally with you on this. I only used the light bulb to illustrate the basic idea. This need not be limited to network-connected devices either. You can define interfaces for any object even if they aren't electronic. For example you can define the interface for a bottle as something that can be opened. You can define processes based on the interfaces of multiple objects. These process definitions can then be transferred to a robot that will then be able to interact with the real world based on those definitions.
- leovander 10y agoThere are a few other games out there like this, but what you described reminded me of Glitchspace[0]. There was a post about zachtronics some time ago that listed similar games. [0] http://store.steampowered.com/app/290060/ http://store.steampowered.com/app/290060/ [1] http://www.zachtronics.com/ http://www.zachtronics.com/
- sytelus 10y agoI've been using Unreal Bluescript since past few months. It's probably as practical and large scale as any visual programming system ever have been designed. There are many good things about it, for example, it "compiles" instantly. There is even some visual debugging. You can change a variable name and it gets refactored automatically. It gives you definitive errors right away instead of waiting for compilation. It has nice abstraction of subroutine and macros. However, I have to disagree that visual programming will actually become more mainstream than programming mechanism for less savvy users. As soon as Blueprints gets bigger (equivalent to may be 200 lines of code), it becomes absolutely unwieldy. You will find yourself clicking all over places all day long. It becomes very hard to parse giant graphs. It becomes hard to keep layout of what is where. It simply doesn't scale. Compare this to even lousy speed of typing 40 WPM, ability to write 1000s of lines of code and be perfectly at peace with everything. Ability to quickly copy paste, refactor, move around by blazing fast keyboard navigation as opposed to just two buttons on mouse. I was using Hololens other day and created bunch of objects around my room. It became overwhelming just after dozen of objects around me and my hands were getting tired by expensive gesturing all over place. A code that would fit in to 13" display probably takes significant portion of 3D space because each "if()", "while()" etc must be represented by space consuming graphic objects and forest of connections between them. Humans are good at absorbing small graph but as soon as nodes and connections starts climbing they become frustrated. This is why small toy examples look good in visual programming but no one seems to write 10,000 lines of code in those systems. So keep your expectations accordingly. Visual programming is good for people who don't want to be full time developer but whose job entails them writing may be 100 lines of code every other week.
- sjayasinghe 10y agoSo I think programming will eventually become a tool used by everyone rather than something for only for programmers and other tech-savvy individuals. It'll be something that everyone uses the same way basic arithmetic is a tool that everyone uses these days. These days programming is reserved for the few because in order to program you have to learn a language with very specific grammar and the level of abstraction is still quite low. The underlying operations being expressed by current languages are not themselves intuitively hard to understand but the average person is prevented from doing so because of the language barrier. The level of abstraction that the average programmer is working with is moving continuously higher. In the past there was a time when the average programmer was working at the level of assembly language but today the average programmer is working at much higher levels of abstraction. There are obvious disadvantages to current visual programming systems as you've described but it may be the case that we just haven't developed the right abstractions and interfaces that work best for visual programming.
- dirkk0 10y agoOne way to do this would be the Reality Editor from MIT. http://fluid.media.mit.edu/realityeditor http://fluid.media.mit.edu/realityeditor