How start Lua programming?

650 views
Skip to first unread message

figureloop

unread,
Jul 23, 2011, 12:42:51 AM7/23/11
to tinspire
Hi:

I just joined this group.

I have heard there are at least 3 ways to enter and run Lua programs.
I am aware of the "Inspired Lua" website but haven't yet followed the
instructions because it entails downloading and running 3rd party
programs that I want to get a little more comfortable with before
going ahead.

Also I'm confused about the role which the TI student or teacher
software plays in this. I just bought a TI Nspire CX CAS, and I
received a trial version of teacher software. But I don't see how to
obtain a full version. I bought this from Vernier. I also see that
they offer student software licenses for about $75.

Must I use the TI software, implying that I have to pay more for a
license for this? If so, is the student version satisfactory?

An outline of the three methods of entering and running Lua programs
would be of interest to read about.

Thanks for comments.

JosJuice

unread,
Jul 23, 2011, 3:12:33 AM7/23/11
to tinspire
I'm not completely sure about the ways to run Lua - I've only heard
about two. The first way is to download TI's official Lua converter,
which will read a Lua program and place it into the clipboard of your
computer. You must then paste the program into the TI-Nspire Student
or Teacher Software in order to run the program or save a .tns file.
If you use third party programs, it works a bit differently. The
program will take a Lua program and produce a .tns file for you,
without using the TI-Nspire Computer Software. However, the .tns files
that it produces can currently only be used on OS 3.0.1 unless you re-
save it using 3.0.1. This is because the newer OSes require stricter
compression and encryption of files, and the methods have not been
fully reverse-engineered yet.

Andy Kemp

unread,
Jul 23, 2011, 3:16:28 AM7/23/11
to tins...@googlegroups.com
How did you buy your CX CAS as you should have received a full copy of
the software with the handheld - If it is the student version of the
handheld then there should be a serial number of case for the
software, and if I remember correctly you have to connect the handheld
when you authorise your handheld.

Whilst there has been some work by the people at TI-Bank to enable
coding directly on the handheld, I would recommend using the official
procedure and do you coding on the computer (if only because typing on
the handheld is a lot slower!)

> --
> To post to this group, send email to tins...@googlegroups.com
> To unsubscribe send email to tinspire+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com.au/group/tinspire?hl=en-GB?hl=en-GB
> The tns documents shared by group members are archived at
> http://lafacroft.com/archive/nspire.php
>

Steve Arnold

unread,
Jul 23, 2011, 3:17:35 AM7/23/11
to tins...@googlegroups.com
I am having great fun with the wonderful OCLua utility, available from 


(You will need to click on one of the English flags at the top of the page to translate from the French) It can also be found at ticalc.org.

This lets you write code and then paste it to run within Nspire itself, both software and handheld.

very cool and simple.

Steve



--
To post to this group, send email to tins...@googlegroups.com
To unsubscribe send email to tinspire+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com.au/group/tinspire?hl=en-GB?hl=en-GB
The tns documents shared by group members are archived at
http://lafacroft.com/archive/nspire.php



--
With best wishes,
Steve
_________________
Dr Stephen Arnold
Educational Technology Consultant
Compass Learning Technologies

T3 Fellow, Teachers Teaching with Technology Australia

Office: +61-2-4232-2080
Mobile: +61-4-0175-3834
Web: http://compasstech.com.au
_________________   

Jim Fullerenex

unread,
Jul 23, 2011, 3:48:44 AM7/23/11
to tins...@googlegroups.com
>How did you buy your CX CAS as you should have received a full copy of
the software with the handheld - If it is the student version of the
handheld then there should be a serial number of case for the
software,
In response to Andy, actually you are buying the standard English version package of TI Nspire CX, so you have no knowledge about products in other places. TI does NOT have a standardized product line: it discriminates against customers in Eastern Asian areas. It charges a higher price while depriving customers of the SS license. I know this because my friends in Shanghai repeatedly complained to TI management level. I have forwarded several complaints to TI-Cares myself, and I accused them of discrimination---- but no one there refuted me with proper justification of the package discrepancy; all I received from their response is apology and "we will call our product development team soon".
Best Wishes,
Jim Fullerenex



2011/7/23 Andy Kemp <an...@kemp.co>

Andy Kemp

unread,
Jul 23, 2011, 3:54:17 AM7/23/11
to tins...@googlegroups.com
Thanks Jim,
I was aware there were some difference in the exact package that is
available (i.e. I know we get cases for the CX in Europe, but I don't
think they do in the US - In fact in the UK, where I am based, you
cannot by the TI-Nspire through retail channels at all, they are all
bought from resellers normally through schools), but was under the
impression that the software was included however you purchased your
handheld... obviously not.

Jim Fullerenex

unread,
Jul 23, 2011, 4:15:44 AM7/23/11
to tins...@googlegroups.com
It's obviously not your mistake Andy. Actually I want to thank you for bringing this issue up. From my perspective, discrimination against any customers worldwide will not be justified and should be labelled as business dishonesty, which may well jeopardize the company's place in the long run. I hope TI officials who happen to see this post should either give some justification for the unreasonable discrepancy in packaging (and price discrimination), or do something about their social images in Eastern Asia (and other parts of the world alike) right away.

Andy Kemp

unread,
Jul 23, 2011, 4:42:51 AM7/23/11
to tins...@googlegroups.com
I do see your point, but it is also worth pointing out that it is a
fairly common practice across all industries - The classic example
until recently was the DVD industry with its artificial borders and
regions which meant they can (and do) charge very different amounts
for what is essentially the same product... The same is still very
much true of the digital downloads where ebooks and movies are
generally much cheaper in the US then Europe (if they are available at
all!)... And let's not even talk about the cost of consumer
electronics which is always substantially higher in the UK then the US
or Asia.

Whether we personally think it is 'fair' it certainly isn't unusual...
Nevertheless I hope TI do decide to include the software in all their
territories, as I think it makes much more sense as a package!

Jim Fullerenex

unread,
Jul 23, 2011, 5:22:48 AM7/23/11
to tins...@googlegroups.com
Yep I see your point also. We can't do anything to change the situation overnight, can we? But I feel TI-Cares was really embarassed by my inquiry (and hopefully a mighty array of complaints... counting in all my victim friends)  :)

figureloop

unread,
Jul 23, 2011, 10:42:17 AM7/23/11
to tinspire
On Jul 23, 12:12 am, JosJuice <JosJu...@hotmail.com> wrote:
> I'm not completely sure about the ways to run Lua - I've only heard
> about two. The first way is to download TI's official Lua converter,
> which will read a Lua program and place it into the clipboard of your
> computer. You must then paste the program into the TI-Nspire Student
> or Teacher Software in order to run the program or save a .tns file.
> If you use third party programs, it works a bit differently. The
> program will take a Lua program and produce a .tns file for you,
> without using the TI-Nspire Computer Software. However, the .tns files
> that it produces can currently only be used on OS 3.0.1 unless you re-
> save it using 3.0.1. This is because the newer OSes require stricter
> compression and encryption of files, and the methods have not been
> fully reverse-engineered yet.

Thanks for this explanation. This solidifies my understanding of what
is the primary means, I suppose. It looks like I need to start using
the TI software, and also get the Lua converter.

figureloop

unread,
Jul 23, 2011, 10:58:46 AM7/23/11
to tinspire
On Jul 23, 12:16 am, Andy Kemp <a...@kemp.co> wrote:
> How did you buy your CX CAS as you should have received a full copy of
> the software with the handheld - If it is the student version of the
> handheld then there should be a serial number of case for the
> software, and if I remember correctly you have to connect the handheld
> when you authorise your handheld.

Well, I bought it from Vernier Software:

http://www.vernier.com/calc/ti-nspire/cas-handhelds.html

Which does indicate that it comes with only a trial version of the
teacher software. Hence, no serial# is included.

> Whilst there has been some work by the people at TI-Bank to enable
> coding directly on the handheld, I would recommend using the official
> procedure and do you coding on the computer (if only because typing on
> the handheld is a lot slower!)

If I can trust the tools used to program directly on the calc., I will
probably want to have these tools too, because sometimes I want to
program while on the run, and I haven't brought myself to buying a
laptop yet, since the usage would be too infrequent to warrant the
higher price compared to a calc.

Thanks for the input.

figureloop

unread,
Jul 23, 2011, 11:39:31 AM7/23/11
to tinspire
On Jul 23, 1:15 am, Jim Fullerenex <smoat...@gmail.com> wrote:
> It's obviously not your mistake Andy. Actually I want to thank you for
> bringing this issue up. From my perspective, discrimination against any
> customers worldwide will not be justified and should be labelled as business
> dishonesty, which may well jeopardize the company's place in the long run. I
> hope TI officials who happen to see this post should either give some
> justification for the unreasonable discrepancy in packaging (and price
> discrimination), or do something about their social images in Eastern Asia
> (and other parts of the world alike) right away.
>  Best Wishes,
> Jim Fullerenex

Jim, I would be cautious about reaching a conclusion about why they
do these things. It is possible that regulatory requirements are a
factor. For instance, the US Government places all sorts of
restrictions on the behavior of US companies and citizens when
interacting with the rest of the world. US export laws are likely to
be the reason for the differences in products sold by TI to different
regions.

Also, there are various tariffs and other factors that affect prices.
Unless one understands the full legal context that TI must operate in
on both sides of the fence, then we just don't know why they are doing
this.

figureloop

unread,
Jul 23, 2011, 11:47:52 AM7/23/11
to tinspire
On Jul 23, 12:17 am, Steve Arnold <st...@compasstech.com.au> wrote:
> I am having great fun with the wonderful OCLua utility, available from
>
> http://ti.bank.free.fr/index.php?mod=news&ac=commentaires&id=1233
>
> (You will need to click on one of the English flags at the top of the page
> to translate from the French) It can also be found at ticalc.org.
>
> This lets you write code and then paste it to run within Nspire itself, both
> software and handheld.
>
> very cool and simple.
>
> Steve

I've downloaded TI's scripting tools and examples so far. I must say:

Whoa! The Lua language is a thing of beauty. I'm an experienced C
embedded systems programmer, old time PC C and assembly language
programmer, and recently have been working with Python as well.
Thankfully, the Python experience makes Lua readable with almost no
effort.

I have been attracted to Lua since I first heard the name. I know
it's somewhat ridiculous, but I tend to get strong feelings about
languages from their name. For instance, I've hated Java since the
first time I heard of it. You might gather, that I'm not fond of
coffee! But Lua sounds like a lovely Chinese lady, so I like that
name :-)

Well, I'm currently in the process of getting into too many new
projects all at the same time, with a study of language compiler
construction going on in Python, among other things. But I hope to
get at least tinkering with Lua in the next few days...

Thanks for all the responses.

Jim Fullerenex

unread,
Jul 23, 2011, 8:51:22 PM7/23/11
to tins...@googlegroups.com
>Unless one understands the full legal context that TI must operate in
on both sides of the fence, then we just don't know why they are doing
this.
Because you are not a victim you would have said this, and I fully understand. Also, the price is not the major concern in this case. The unreasonable lack of SS license is.
In any sense, TI management should have known "why they are doing this".
If TI is indeed justified by some "legal context", the TI-Cares staff members would have refuted my arguments with much confidence long before. Also, why Hongkong has the standardized package while other parts of China do not? The deprivation of SS license is solely designed for "Nspire Chinese version", not to mention the price. 
I cannot find a reason other than discrimination that accounts for this situation better. (unless someday I hear decisive and plausible explanation from TI officials personally)
Since this is a forum for excellency in Nspire education, I don't think it's advisable to discuss the issue further. I just want to raise the issue to the spotlight (and I hope any other customer victims seeing this post could send a complaint as well), and let's stop here. Thanks.
Best Wishes,
Jim Fullerenex



2011/7/23 figureloop <cr...@sbcglobal.net>

--

Bert Wikkerink

unread,
Jul 24, 2011, 9:10:07 AM7/24/11
to tins...@googlegroups.com
How do I get the lua code from my windows Nspire Scripting Tools to the Mac Nspire software?

Bert


-----Oorspronkelijk bericht-----
Van: tins...@googlegroups.com namens Steve Arnold
Verzonden: za 23-7-2011 9:17
Aan: tins...@googlegroups.com
Onderwerp: Re: [tinspire] Re: How start Lua programming?

http://ti.bank.free.fr/index.php?mod=news&ac=commentaires&id=1233

very cool and simple.

Steve

Dit bericht is gescanned op virussen en andere gevaarlijke
inhoud door MailScanner en lijkt schoon te zijn.

--
Dit bericht is gescanned op virussen en andere gevaarlijke
inhoud door MailScanner en lijkt schoon te zijn.

Adrien Bertrand

unread,
Jul 24, 2011, 10:42:22 AM7/24/11
to tinspire
Right now, the official tools are working on windows only and the best
way for now to program on a Mac natively (I do) is to use the third-
party tools (mine, written in bash with Lionel Debroux, that works for
Mac and Linux, or Jayte's python version)

Available on github ( https://github.com/adriweb/BetterLuaAPI-for-TI-Nspire/blob/master/LUAtoTNS.sh
), TI-Bank and ticalc.org.

On Jul 24, 7:10 am, "Bert Wikkerink" <B.Wikker...@csgliudger.nl>
wrote:
> How do I get the lua code from my windows Nspire Scripting Tools to the Mac Nspire software?
>
> Bert
>
> -----Oorspronkelijk bericht-----
> Van: tins...@googlegroups.com namens Steve Arnold
> Verzonden: za 23-7-2011 9:17
> Aan: tins...@googlegroups.com
> Onderwerp: Re: [tinspire] Re: How start Lua programming?
>
> I am having great fun with the wonderful OCLua utility, available from
>
> http://ti.bank.free.fr/index.php?mod=news&ac=commentaires&id=1233
>
> (You will need to click on one of the English flags at the top of the page
> to translate from the French) It can also be found at ticalc.org.
>
> This lets you write code and then paste it to run within Nspire itself, both
> software and handheld.
>
> very cool and simple.
>
> Steve
>
> For more options, visit this group athttp://groups.google.com.au/group/tinspire?hl=en-GB?hl=en-GB
> The tns documents shared by group members are archived athttp://lafacroft.com/archive/nspire.php

Andy Kemp

unread,
Jul 24, 2011, 11:10:41 AM7/24/11
to tins...@googlegroups.com
I run parallels in a second space with the devtool and Nspire software
running in windows but code in textmate on the mac... Not the easiest
but very quick once you get the hang of it.

The problem I have with the 3rd Part tools (which are very good) is
that they create the whole tns file which causes me problems as I'm
often using other pages and passing data between, which means
recreating these parts each time... It'll depend what type of file
you are writing as to which will work best for you.

Cheers
Andy

Sent from my iPhone

Reply all
Reply to author
Forward
0 new messages