Recent content by widdernix

  1. W

    LUA Catching keyboard keys in LUA

    I am searching for a method to catch a pressed key in LUA. In the help file I found a method oapi.keydown(kstate,<Scanode_of_key>) but I get a error message, when I call it: oapi_keydown: argument1: invalid type (expected handle). This is what I tried so far: kstate = {} for i=1,256 do...
  2. W

    Talking to serial devices

    Hi JDat. I found a solution for serial input. Library "luars232" is needed. It's part of the luaforwindows tools. Search and install this great toolbox it has tons of usefull LUA extensions. Copy the luars232.DLL to your Orbiter main folder. Modified script example: rs232 = require("luars232")...
  3. W

    Talking to serial devices

    I can't get a solution for "Serial in". Opening the COM in read mode freezes Orbiter because LUA is waiting for incoming bytes. Maybe somebody has a better solution? I suggest using projects like MJoy16 in combination with SV Mapper to control the ship. It's easy to make a MJoy16 if you are...
  4. W

    Talking to serial devices

    This seems to be tricky. I need a little bit time to check that.
  5. W

    Talking to serial devices

    What is the lack of Orbiter compared to flight simulators? We miss a possibility to display values, light led's and so on. With LUA we can do this! We can now talk to a serial device and this is how to do it (works under XP and Windows 7). What do we need. 1. Orbiter (of course :)) 2. A free...
  6. W

    Interfacing serial with Orbiter

    If you are using a Orbiter beta version, you can use a lua script to communicate via serial interface. I did that with my retro style 7 segment led display (PIC based). Dr. Schweiger implemented nearly all API functions in lua, so you don't need to write (and debug) a DLL.
Top