Virtual Keyboard Sample

Crank Storyboard Designer samples and code snippets.

Moderator: jamiev

Virtual Keyboard Sample

Postby jamiev » Wed Feb 03, 2010 3:57 pm

Hello All,

I posted a virtual keyboard sample here.

How to import the sample:

1. Unzip archive.
2. In Storyboard Designer goto File -> Import -> Storyboard Embedded Engine (GAPP)
3. Point to the gapp file from the archive you just uncompressed.
4. Give the project a name.
5. Bobs your uncle

How to use the sample:

Use the physical w, a, s, d, x, keys on your keyboard to navigate and select on the virtual keyboard.

Thanks,

-Jamie
User avatar
jamiev
 
Posts: 57
Joined: Wed Nov 04, 2009 2:14 pm

Re: Virtual Keyboard Sample

Postby jason » Wed Feb 03, 2010 4:05 pm

FYI this example is designed for a OSD (onscreen display) that is being controlled with key events from a remote control or hard buttons on the device. This means that the keys aren't responsive to press events.

Touch behavior could pretty easily be added, but thought we'd mention this before someone gets frustrated trying to press the keys
User avatar
jason
 
Posts: 191
Joined: Mon Nov 02, 2009 4:53 pm

Re: Virtual Keyboard Sample

Postby nmak » Thu Dec 18, 2014 4:34 pm

Hi, I'm getting the following error about set_data. Leads me to think something is wrong with the lua library but I can't fathom. Any ideas appreciated.

Code: Select all
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-greio.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-logger.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-model3d.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-timer.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-animation.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-dynamic-rext.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-dev-input.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-screen-3d.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-event-redirect.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-rext-external.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-screen-path.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-system.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-audio.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-lua.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-media.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-poly.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-tslib.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-gesture.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-screen-scale.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//librender-plugin-opengles_2.0.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-screen-dump.so]
DIAG  (1993945088):Detected plugin [/usr/crank/plugins//libgre-plugin-capture-playback.so]
INFO  (1993945088):Manager: data_mgr Internal: 0x76f94e84
INFO  (1993945088):Manager: model_mgr Internal: 0x76f91c90
INFO  (1993945088):Manager: io_mgr Internal: 0x76f9bbe8
INFO  (1993945088):Manager: action_mgr Internal: 0x76f9c930
INFO  (1993945088):Manager: render_mgr Plugin: /usr/crank/plugins//librender-plugin-opengles_2.0.so
INFO  (1993945088):Manager: screen_mgr Internal: 0x76f9a804
INFO  (1993945088):Manager: resource_mgr Internal: 0x76f9624c
INFO  (1993945088):Initialize Data Manager []
INFO  (1993945088):Initialize Model Manager []
INFO  (1993945088):Initialize IO Manager []
INFO  (1993945088):Initialize Action Manager []
INFO  (1993945088):Initialize Render Manager []
INFO  (1993945088):Initialize Screen Manager []
INFO  (1993945088):Initialize Resource Manager []
INFO  (1993945088):Initialize plugin 22: [greio (3.2.0.12417)] []
INFO  (1993945088):GREIO receiver registered @ [keyboard_demo.gapp]
INFO  (1993945088):Initialize plugin 22: [logger (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [model3d (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [timer (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [animate (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [dynamic.rextension (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [dev-input (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [screen-hmgl2 (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [redirect (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [rext-external (3.2.0.120)] []
INFO  (1993945088):Initialize plugin 22: [screen-path (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [system (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [audio (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [lua (3.2.0.12417)] []
calling LuaLock uninitialized...
Calling LuaLockInitial
DIAG  (1993945088):Loading LUA script [/test/scripts/keyboard.lua]
DIAG  (1993945088):Loading LUA script [/test/scripts/stb.lua]
INFO  (1993945088):Initialize plugin 22: [media (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [poly (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [tslib (3.2.0.12417)] []
WARN  (1964819552):Unable to attach to tslib deviceINFO  (1993945088):Initialize plugin 22: [gesture (3.2.0.12417)] []

INFO  (1993945088):Initialize plugin 22: [screen-scale (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [screen-dump (3.2.0.12417)] []
INFO  (1993945088):Initialize plugin 22: [capture_playback (3.2.0.12417)] []
DIAG  (1993945088):IO: Dispatch [gre.internalinit]
DIAG  (1993945088):IO: Dispatch [gre.init]
DIAG  (1993945088):ACTION: Invoke [gre.init]->[gra.lua] on app [app]
DIAG  (1993945088):Lua: [populate_keys]
>>>>>>>>>>>>>entering function - POPULATING
ERROR (1993945088):LUA script failure (entry function: populate_keys): /test/scripts/keyboard.lua:76: attempt to call field 'set_data' (a nil value)
WARN  (1993945088):media: Can't open channel to backend media player [media-backend] error 2

DIAG  (1993945088):IO: Dispatch [gre.screenshow.pre]
DIAG  (1993945088):IO: Dispatch [gre.gotfocus]
DIAG  (1993945088):ACTION: Invoke [gre.gotfocus]->[gra.datachange] on control [k1]
DIAG  (1993945088):IO: Dispatch [gre.screenshow.post]
DIAG  (1993945088):IO: Dispatch [gre.redraw]
nmak
 
Posts: 3
Joined: Tue Dec 16, 2014 11:02 am

Re: Virtual Keyboard Sample

Postby jason » Thu Dec 18, 2014 4:48 pm

Is there any chance you have another liblua on your system that it's trying to use?

We build those functions into our custom liblua, but if you tried to use a standard version they would be missing.

Regards,
Jason
User avatar
jason
 
Posts: 191
Joined: Mon Nov 02, 2009 4:53 pm

Re: Virtual Keyboard Sample

Postby nmak » Fri Dec 19, 2014 10:46 am

Yes that's probably what's going on. I need to sort out our distro.

Thanks for the quick response
nmak
 
Posts: 3
Joined: Tue Dec 16, 2014 11:02 am


Return to Samples

Who is online

Users browsing this forum: No registered users and 1 guest

cron