lua on steroids - eclipsecon na 2012

Post on 19-May-2015

1.323 Views

Category:

Technology

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Lua on

Steroids

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

??? What is

Lua all about

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

“Lua is a powerful, fast, lightweight, embeddable

scripting language.”

http://www.lua.org/about.html

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Extending C/C++ applications with a configuration / scripting engine

Rationale

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Extending C/C++ applications with a configuration / scripting engine

§  Based on a virtual machine

§  Can load source code / read char streams

§  And compile it into portable bytecode

Rationale

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Extending C/C++ applications with a configuration / scripting engine

§  Tiny core (150kB)

§  Pure ANSI C

§  Simple C API

Rationale

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Extending C/C++ applications with a configuration / scripting engine

§  DSL building kit

§  Provides only basic features

§  And a powerful runtime

Rationale

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

A language gaining momentum

§ Video games §  World of Warcraft

§  Havoc physics engine

§  AI scripting

§ Mobile §  Corona SDK

§  Moai

§  LÖVE

§ App scripting §  Adobe Lightroom

§  Redis (key-value store)

§ Embedded §  Brew MP

(Qualcomm)

§  eLua (Petrobras)

§  AAF (Sierra Wireless)

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

??? What is

missing

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

IDE support

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

http://www.eclipse.org/koneki/ldt/

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

A tool that follows Lua’s philosophy

Providing lots of modern features while remaining easily embeddable in larger systems.

Rationale

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Lua strengths §  Dynamic §  Embeddable

are double-edged swords

that make tooling support tedious.

However…

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Editor VS.

Dynamic code

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Debugger VS.

Embedded application

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

LDT for m2m development

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

m2m.eclipse.org MQTT broker

Wireless gateway Mobile phone

Wireless (Zigbee) sensors

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

§ Embedded

Aleos Application Framework

Collects Zigbee data on device’s serial port

Publishes MQTT messages

§ Mobile

Corona SDK   .

Subscribes to MQTT messages

Displays sensor data with a fancy UI

Two Lua applications

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

??? What’s Next

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

§ LDT 0.8 will be in Juno

§ Content-assist (pending CQ) §  Beta product here: http://goo.gl/NZgCc

§ Execution environments

§ Next… §  Launch configurations (w/ embedded interpreter)

§  Pre-bundled execution environments

LDT Roadmap

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Eclipse §  RSE http://www.eclipse.org/tm/

§  DLTK http://www.eclipse.org/dltk/

Lua §  JNLua http://code.google.com/p/jnlua/

§  MetaLua http://metalua.luaforge.net/

§  LDoc http://github.com/stevedonovan/LDoc

Big thanks to

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

Lua §  Main site http://lua.org

§  Kepler project http://www.keplerproject.org/

LDT §  Koneki http://www.eclipse.org/koneki/

§  Installation http://download.eclipse.org/koneki/updates/

§  Wiki http://wiki.eclipse.org/Koneki

§  Forum http://www.eclipse.org/forums/eclipse.koneki

Useful links

Copyright © 2012 Sierra Wireless. All Right reserved. Made available under the Eclipse Public License v1.0.

top related