EK-LM3S6965 File

classic Classic list List threaded Threaded
5 messages Options
Stefan Brantschen-3 Stefan Brantschen-3
Reply | Threaded
Open this post in threaded view
|

EK-LM3S6965 File

Hi

When trying to run "pong", I got:

eLua# lua /rom/pong.lua
Press CTRL+Z to exit Lua
lua: /rom/EK-LM3S6965.lua:33: attempt to index global 'lm3s' (a nil value)
stack traceback:
        /rom/EK-LM3S6965.lua:33: in main chunk
        [C]: in function 'require'
        /rom/pong.lua:65: in main chunk
        [C]: ?

The offending line in EK-LM3S6965.lua reads "disp = lm3s.disp", inside a "module" function, hence we miss "local lm3s = lm3s" before the module definition:

local pio = pio
local lm3s = lm3s
 
module(...)

BTN_UP      = pio.PE_0
...

This is still true for the current trunk version.

Cheers
-- Stefan



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
Dado Sutter Dado Sutter
Reply | Threaded
Open this post in threaded view
|

Re: EK-LM3S6965 File

Hello,
   This is a silly issue that we had on closing v0.7 and I apologise for that.
   Pls edit your EK-LM3Sxxxx module (6965 in your case) and insert a

lm3s = lm3s

.... before the module(...) definition.
Feedback is welcome.

Thanksssssss
Dado

On Sun, Jun 13, 2010 at 16:28, Stefan Brantschen <[hidden email]> wrote:
Hi

When trying to run "pong", I got:

eLua# lua /rom/pong.lua
Press CTRL+Z to exit Lua
lua: /rom/EK-LM3S6965.lua:33: attempt to index global 'lm3s' (a nil value)
stack traceback:
       /rom/EK-LM3S6965.lua:33: in main chunk
       [C]: in function 'require'
       /rom/pong.lua:65: in main chunk
       [C]: ?

The offending line in EK-LM3S6965.lua reads "disp = lm3s.disp", inside a "module" function, hence we miss "local lm3s = lm3s" before the module definition:

local pio = pio
local lm3s = lm3s

module(...)

BTN_UP      = pio.PE_0
...

This is still true for the current trunk version.

Cheers
-- Stefan



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
BogdanM BogdanM
Reply | Threaded
Open this post in threaded view
|

Re: EK-LM3S6965 File

You probably mean

local lm3s = lm3s

Right ? :)

Best,
Bogdan

On Mon, Jun 14, 2010 at 10:25 PM, Dado Sutter <[hidden email]> wrote:
Hello,
   This is a silly issue that we had on closing v0.7 and I apologise for that.
   Pls edit your EK-LM3Sxxxx module (6965 in your case) and insert a

lm3s = lm3s

.... before the module(...) definition.
Feedback is welcome.

Thanksssssss
Dado

On Sun, Jun 13, 2010 at 16:28, Stefan Brantschen <[hidden email]> wrote:
Hi

When trying to run "pong", I got:

eLua# lua /rom/pong.lua
Press CTRL+Z to exit Lua
lua: /rom/EK-LM3S6965.lua:33: attempt to index global 'lm3s' (a nil value)
stack traceback:
       /rom/EK-LM3S6965.lua:33: in main chunk
       [C]: in function 'require'
       /rom/pong.lua:65: in main chunk
       [C]: ?

The offending line in EK-LM3S6965.lua reads "disp = lm3s.disp", inside a "module" function, hence we miss "local lm3s = lm3s" before the module definition:

local pio = pio
local lm3s = lm3s

module(...)

BTN_UP      = pio.PE_0
...

This is still true for the current trunk version.

Cheers
-- Stefan



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
Téo Benjamin Téo Benjamin
Reply | Threaded
Open this post in threaded view
|

Re: EK-LM3S6965 File

In reply to this post by Dado Sutter
Don't forget the local!

local lm3s = lm3s

This should work fine.

On Mon, Jun 14, 2010 at 4:25 PM, Dado Sutter <[hidden email]> wrote:
Hello,
   This is a silly issue that we had on closing v0.7 and I apologise for that.
   Pls edit your EK-LM3Sxxxx module (6965 in your case) and insert a

lm3s = lm3s

.... before the module(...) definition.
Feedback is welcome.

Thanksssssss
Dado


On Sun, Jun 13, 2010 at 16:28, Stefan Brantschen <[hidden email]> wrote:
Hi

When trying to run "pong", I got:

eLua# lua /rom/pong.lua
Press CTRL+Z to exit Lua
lua: /rom/EK-LM3S6965.lua:33: attempt to index global 'lm3s' (a nil value)
stack traceback:
       /rom/EK-LM3S6965.lua:33: in main chunk
       [C]: in function 'require'
       /rom/pong.lua:65: in main chunk
       [C]: ?

The offending line in EK-LM3S6965.lua reads "disp = lm3s.disp", inside a "module" function, hence we miss "local lm3s = lm3s" before the module definition:

local pio = pio
local lm3s = lm3s

module(...)

BTN_UP      = pio.PE_0
...

This is still true for the current trunk version.

Cheers
-- Stefan



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
Dado Sutter Dado Sutter
Reply | Threaded
Open this post in threaded view
|

Re: EK-LM3S6965 File

In reply to this post by BogdanM
Yes,
  
local lm3s = lm3s

Sorry.

Best
Dado




On Mon, Jun 14, 2010 at 16:30, Bogdan Marinescu <[hidden email]> wrote:
You probably mean

local lm3s = lm3s

Right ? :)

Best,
Bogdan


On Mon, Jun 14, 2010 at 10:25 PM, Dado Sutter <[hidden email]> wrote:
Hello,
   This is a silly issue that we had on closing v0.7 and I apologise for that.
   Pls edit your EK-LM3Sxxxx module (6965 in your case) and insert a

lm3s = lm3s

.... before the module(...) definition.
Feedback is welcome.

Thanksssssss
Dado

On Sun, Jun 13, 2010 at 16:28, Stefan Brantschen <[hidden email]> wrote:
Hi

When trying to run "pong", I got:

eLua# lua /rom/pong.lua
Press CTRL+Z to exit Lua
lua: /rom/EK-LM3S6965.lua:33: attempt to index global 'lm3s' (a nil value)
stack traceback:
       /rom/EK-LM3S6965.lua:33: in main chunk
       [C]: in function 'require'
       /rom/pong.lua:65: in main chunk
       [C]: ?

The offending line in EK-LM3S6965.lua reads "disp = lm3s.disp", inside a "module" function, hence we miss "local lm3s = lm3s" before the module definition:

local pio = pio
local lm3s = lm3s

module(...)

BTN_UP      = pio.PE_0
...

This is still true for the current trunk version.

Cheers
-- Stefan



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev



_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev