Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Home
About
Team
Rules
Stats
Status
Sitemap
Chat
Downloads
Forum
News
Our Projects
Major Community Projects
Recent Posts
Unread Posts
Replies
Tools
SourceCoder3
Other Things...
Omnimaga Radio
TI-83 Plus ASM File Unsquisher
Z80 Conversion Tools
IES TI File Editor
Free RAM areas
Comprehensive Getkeyr table
URL Shortener
Online Axe Tilemap Editor
Help
Contact Us
Change Request
Report Issue/Bug
Team
Articles
Members
View the memberlist
Search For Members
Buddies
Login
Register
Omnimaga
»
Forum
»
Calculator Community
»
Other Calc-Related Projects and Ideas
»
TI-Nspire
»
It is possible to convert lua to c, and vice versa!
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: It is possible to convert lua to c, and vice versa! (Read 7208 times)
0 Members and 1 Guest are viewing this topic.
njaddison
LV4
Regular (Next: 200)
Posts: 176
Rating: +24/-27
It is possible to convert lua to c, and vice versa!
«
on:
January 03, 2012, 06:52:59 pm »
I was surfing the internet, and I found a lua to c converter, and a c to lua converter. It would be possible to convert standard lua scripts to c, so we can run them with ndless, but we would need to create a c to lua converter. This would be awesome because we would be able to play c games without ndless because of the nspire's 3.x lua capabilities.
-Nelson
«
Last Edit: January 03, 2012, 06:53:37 pm by njaddison
»
Logged
<a href="
http://www.nerdtests.com/ft_nt2.php
">
<img src="
http://www.nerdtests.com/images/badge/nt2/5f42ec78e054645d.png
" alt="NerdTests.com says I'm a Highly Dorky Nerd God. Click here to take the Nerd Test, get geeky images and jokes, and talk to others on the nerd forum!">
</a>
epic7
Chopin!
LV11
Super Veteran (Next: 3000)
Posts: 2200
Rating: +135/-8
I like robots
Re: It is possible to convert lua to c, and vice versa!
«
Reply #1 on:
January 03, 2012, 06:56:03 pm »
Wouldn't it be slower in lua if C was converted?
Logged
njaddison
LV4
Regular (Next: 200)
Posts: 176
Rating: +24/-27
Re: It is possible to convert lua to c, and vice versa!
«
Reply #2 on:
January 03, 2012, 07:00:53 pm »
Well, yeah. But it would originally be c, and I can be patient when using a lua script that was originally c.
«
Last Edit: January 03, 2012, 07:01:24 pm by njaddison
»
Logged
<a href="
http://www.nerdtests.com/ft_nt2.php
">
<img src="
http://www.nerdtests.com/images/badge/nt2/5f42ec78e054645d.png
" alt="NerdTests.com says I'm a Highly Dorky Nerd God. Click here to take the Nerd Test, get geeky images and jokes, and talk to others on the nerd forum!">
</a>
cyanophycean314
LV6
Super Member (Next: 500)
Posts: 363
Rating: +43/-1
It's You!
Re: It is possible to convert lua to c, and vice versa!
«
Reply #3 on:
January 03, 2012, 07:38:27 pm »
I think C being converted to Lua would have many problems. Speed would probably be an issue, but there are so many features that Lua could not support. I'm not too familiar with either C or Lua, but it seems this wouldn't work.
Secondly, njaddison. You should put that userbar into your signature. That way it's attached to every post, so you don't need to copy and paste it every post.
Logged
+1/-0 karm for this message
Programs (Nspire Lua)
Hangman
|
Checkers
|
Rush Hour
|
Base Converter
|
Flashlight, Mempi, and Strategy Steps
|
Jumper
|
Scramble/Boggle
jwalker
LV7
Elite (Next: 700)
Posts: 660
Rating: +13/-0
Almost everything I have released includes a 'WZ'
Re: It is possible to convert lua to c, and vice versa!
«
Reply #4 on:
January 03, 2012, 07:47:26 pm »
you could probably run a lua script indirectly through ndless any way scince there is a lua interpreter, of course i could be wrong
Logged
<a href="
http://www.nerdtests.com/ft_cg.php?im
">
<img src="
http://www.nerdtests.com/images/ft/cg.php?val=9612
" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>
Support
Casio-Scene
against the attacks of matt @ matpac.co.uk ! For more information:
Casio-Scene shuts down
&
Matt actions
threads
TIfanx1999
ಠ_ಠ ( ͡° ͜ʖ ͡°)
CoT Emeritus
LV13
Extreme Addict (Next: 9001)
Posts: 6173
Rating: +191/-9
Re: It is possible to convert lua to c, and vice versa!
«
Reply #5 on:
January 03, 2012, 10:05:03 pm »
It also depends. Although the converter may work, it is a matter of how efficient the code it produces is. Also, what may be good design in one language may not be good coding practice in the other, thus producing overly bloated code. Just some things to keep in mind.
«
Last Edit: January 03, 2012, 10:05:27 pm by Art_of_camelot
»
Logged
Nick
LV9
Veteran (Next: 1337)
Posts: 1166
Rating: +161/-3
You just got omnom'd
Re: It is possible to convert lua to c, and vice versa!
«
Reply #6 on:
January 04, 2012, 01:31:51 pm »
i'm afraid it won't work.. switching between languages is already hard to do manually, than how are you supposed to do it automatically?
it won't work by just replacing all the commands, you really need to dig into the syntax and structure to make it useable, and how're you supposed to do that?
Logged
Jim Bauwens
Lua! Nspire! Linux!
Editor
LV10
31337 u53r (Next: 2000)
Posts: 1881
Rating: +206/-7
Linux!
Re: It is possible to convert lua to c, and vice versa!
«
Reply #7 on:
January 04, 2012, 03:09:14 pm »
Converting lua to C is pretty easy as Lua is programmed to be easily intergrated with C.
Converting C to Lua however is a much bigger task, because:
1. It has many different types of variables which are not available in Lua.
2. Most programs access specific stuff (screen, timers, etc) which you can not do from Lua.
3. If you can bypass these limitations, speed would be a very big issue. My logo interpreter just runs at ok speeds, but C is a billion times more complex.
So in short : C to Lua is not possible.
Of course, you can convert some programs manually, but thats another case
Logged
+1/-0 karm for this message
TI-Nspire projects of me:
nCreator
|
PCspire
|
Klondike Lua
|
LogoMagic
|
EEPro for the TI-Nspire
|
Pegs
|
General math definitions
|
Mini vMac
|
CHIP-8 emulator
Print
Pages: [
1
]
Go Up
« previous
next »
Omnimaga
»
Forum
»
Calculator Community
»
Other Calc-Related Projects and Ideas
»
TI-Nspire
»
It is possible to convert lua to c, and vice versa!