Omnimaga

Calculator Community => TI Calculators => General Calculator Help => Topic started by: Smitty on September 24, 2010, 05:45:29 pm

Title: connecting a Nspire to a Linux comp?
Post by: Smitty on September 24, 2010, 05:45:29 pm
Yeah, so I kind of don't have Windows. Mostly because it sucks. So, since this is a site full of programmers, I'll bet somebody else here has Linux. So, does anybody know how to connect the Nspire to Linux? I'm running Ubuntu 10.04, if that matters. I found this thing called Tilp, but I couldn't get it to do anything. Maybe I'm just using it wrong.
Title: Re: connecting a Nspire to a Linux comp?
Post by: bwang on September 24, 2010, 05:48:08 pm
TILP2 from SVN works with Nspires, although it may require root privileges and/or an edit to some file to allow your user to access USB.
Title: Re: connecting a Nspire to a Linux comp?
Post by: willrandship on September 24, 2010, 05:51:55 pm
sudo tilp should do it. It'll be kinda glitchy though, because the ubuntu repo only has 1.13.

I'm in your boat btw. I use Mint 9 (based on Ubuntu 10.04) so I do pretty much the same stuff as you. Plus, running from a terminal lets you see what your connection is doing better, since it prints it all out while it runs. Don't worry, you'll still use the gui :P.

No need to mess with anything super deep in your case, since you're not using a public computer you'll probably have root access.

If you don't want to open a terminal every time, you can make a launcher:

Name: TiLP
Description: Whatever you want
Command (important one :P): gksu tilp

Edit: The reason you need root access, I'm not sure. I just know it works, and it doesn't give me any viruses. The file browser will always start in the root's home though. That's a little annoying, but liveable. just don't try to use OSes above 1.6 unless you upgrade to the latest TiLP version. OS installs will work, but file transfers won't in 1.13, since TI switched to a new method. 84+ stuff works though, just make sure it's detected as an 84+, not an nspire.

Hope that helps.
Title: Re: connecting a Nspire to a Linux comp?
Post by: Smitty on September 24, 2010, 06:07:11 pm
Thanks guys, I'll try that. Still waiting for my 84+ keypad, so no 84+ stuff yet. But at least I'll be prepared now. Now I just gotta download some games, and maybe Mirage OS or something...
edit: alright, bad news. it's a new calc, so it came with OS 2.0.0.1188(why does TI have such a long OS numver?) But you said newer OSes work with a new TiLP, right? So, where do I get that?
Title: Re: connecting a Nspire to a Linux comp?
Post by: apcalc on September 24, 2010, 06:08:29 pm
You probably want to try DCS for the Nspire, as I believe Mirage OS crashes (does BrandonW's patch work in newer OS versions?)
Title: Re: connecting a Nspire to a Linux comp?
Post by: DJ Omnimaga on September 24, 2010, 06:09:35 pm
/me misses the days (which ended not so long ago) where the TI-Nspire came with the 84+ keypad

Also when you get the keypad, to get Mirage to work on the Nspire you need a patch. Otherwise you should probably use Doors CS (if you dislike the mouse inteface you can just run your programs from the PRGM menu anyway), which is fully Nspire-compatible.

Welcome here by the way :)
Title: Re: connecting a Nspire to a Linux comp?
Post by: willrandship on September 24, 2010, 06:13:21 pm
Yeah, I like the Homerun hooks. The mouse would be fine for me, except for that it's kind of slow. The shortcut keys were a lifesaver :P

DCS is pretty fancy. By the way, If you're not going to use ndless, I recommend OS 1.6, because if it crashes you don't have to reinstall the OS to get 84+ support back. (you still lose everything though :( ) I Really want a real z80 emu on the nspire, with save states and such.
Title: Re: connecting a Nspire to a Linux comp?
Post by: DJ Omnimaga on September 24, 2010, 06:20:46 pm
Does OS 2.0.x do that too?
Title: Re: connecting a Nspire to a Linux comp?
Post by: Smitty on September 24, 2010, 06:22:07 pm
K, so I edited a post because there were no new posts at the time, but now there is and I don't think anyone is reading it. So.
"edit: alright, bad news. it's a new calc, so it came with OS 2.0.0.1188(why does TI have such a long OS numver?) But you said newer OSes work with a new TiLP, right? So, where do I get that?"
Title: Re: connecting a Nspire to a Linux comp?
Post by: Geno on September 24, 2010, 06:35:43 pm
I don't have an nspire, might not be much help.  First off, I think tilp needs to be run as root, it's the only way I've ever gotten it to work.  As for the tilp download, have you checked your package manager?  Mine has tilp-svn, which I assume is the latest.  Not sure where the svn is located if not, maybe someone else can help.
Title: Re: connecting a Nspire to a Linux comp?
Post by: willrandship on September 24, 2010, 07:34:33 pm
Eh, you have to build it from source. I never really got the hang of that  ::) maybe you did.

Here's a link at Ticalc.org

If you do build it, think you could package a deb for me? :P

http://www.ticalc.org/archives/files/fileinfo/374/37480.html (http://www.ticalc.org/archives/files/fileinfo/374/37480.html)

Edit: and Geno, the latest TiLP in any Ubuntu repo is 1.13. No source package available. (not really needed though, since Ticalc.org has one)

You don't really need to update unless you're planning on messing with nspire documents.

And DJ, OS 2.0 doesn't let the reset button erase everything. It just reboots the 84+ emu (idiots, TI are)

Edit2: You do know that you can't do anything but math and very poor BASIC on the nspire's os 2.0 and up, right? Ndless only works up to 1.7 right now. (and even that's still technically alpha stage) Only worthwhile stuff until Ndless 2.0 is 84+ stuff anyways.
Title: Re: connecting a Nspire to a Linux comp?
Post by: Lionel Debroux on September 27, 2010, 03:00:50 pm
The only distribution which has up-to-date TILP packages, thanks to Jonimus, is Arch. On other distros, you need to compile TILP yourself. I made a helper script for this, which has been reported to work across multiple Linux distro types and versions: http://lpg.ticalc.org/prj_tilp/download/install_tilp.sh
It's linked to from the download page on the TILP website. As I wrote there,
Quote
Be sure to look inside it: you can find information on the packages you need for a successful compilation, and modify the path for the checkout and the $PREFIX where the binaries are installed.
(and get some information about the environment variables you need to modify if you choose to install in $HOME)
At the end of the process, the script also prints a pointer to the information you need to make TILP run as non-root user.

Hope that this helps :)
Title: Re: connecting a Nspire to a Linux comp?
Post by: qazz42 on September 27, 2010, 06:35:04 pm
/me misses the days (which ended not so long ago) where the TI-Nspire came with the 84+ keypad

Also when you get the keypad, to get Mirage to work on the Nspire you need a patch. Otherwise you should probably use Doors CS (if you dislike the mouse inteface you can just run your programs from the PRGM menu anyway), which is fully Nspire-compatible.

Welcome here by the way :)

buuut, older versions of DCS would cause you to brick your nspire if you didnt have the nspire pad..
Title: Re: connecting a Nspire to a Linux comp?
Post by: DJ Omnimaga on September 27, 2010, 07:19:06 pm
Ouch yeah I remember some topics about it on Cemetech. And that sucks about the reset thing on OS 2.0. In my case, sometimes when a program crashes, it simply freezes during 3 seconds then automatically RAM clears, though. Sometimes all programs are hidden, though, so you need to do a second reset afterward (RAM) to unhide them.
Title: Re: connecting a Nspire to a Linux comp?
Post by: Smitty on October 23, 2010, 09:44:52 pm
OK, got my 84+ keypad a few days ago, put some games on it via my brother's computer. I'm having issues with compiling TiLP. It's telling me I need a newer version of ticables installed, even though the one I have is the one it tells me I need to upgrade to. So does anybody have any links to the newest version of the libs? (ticables, ticalcs, tifiles, ticonv)
Title: Re: connecting a Nspire to a Linux comp?
Post by: Lionel Debroux on October 24, 2010, 08:41:00 am
The newest versions of the libs are the ones the install_tilp.sh script downloads :)
Please:
* purge all libticonv, libtifiles2, libticables2, libticalcs2, gfm and tilp packages from your package manager (because they're outdated);
* make sure you have modified the PKG_CONFIG_PATH and LD_LIBRARY_PATH environment variables as appropriate depending on the PREFIX you use (described within the script itself, as mentioned above);
* try again, and report back ;)
If everything is configured properly and you have the build dependencies, you will get proper binaries: Ubuntu 10.04 has been reported multiple times to work :)
Title: Re: connecting a Nspire to a Linux comp?
Post by: Smitty on October 25, 2010, 03:25:44 pm
Purged 'em, same result as before. Here (http://dl.dropbox.com/u/7860534/tilp.log)'s a log of the script running.
edit: It seems I can still run tilp  :o, even though the package tilp2 is not installed, nor are any packages containing the name "tilp". Could this cause problems?
Title: Re: connecting a Nspire to a Linux comp?
Post by: Smitty on November 04, 2010, 12:02:49 pm
OK, the packages have been purged properly this time, and tilp doesn't run. So, now I get a different error: "files8x.c:36:20: error: ticonv.h: No such file or directory
files8x.c: In function ‘ti8x_file_read_regular’:
files8x.c:213: warning: implicit declaration of function ‘ticonv_varname_from_tifile_s’
files8x.c: In function ‘ti8x_file_write_regular’:
files8x.c:645: warning: implicit declaration of function ‘ticonv_varname_to_tifile_s’
files8x.c: In function ‘ti8x_content_display_regular’:
files8x.c:896: warning: implicit declaration of function ‘ticonv_varname_to_utf8_s’
make[2]: *** [libtifiles2_la-files8x.lo] Error 1
make[2]: Leaving directory `/media/Home/tim/lpg/tilp/libtifiles/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/media/Home/tim/lpg/tilp/libtifiles'
make: *** [all] Error 2"
I made a new log, at the same link as before.
Title: Re: connecting a Nspire to a Linux comp?
Post by: DJ Omnimaga on November 04, 2010, 07:40:11 pm
Moved to General calculator help section.
Title: Re: connecting a Nspire to a Linux comp?
Post by: Lionel Debroux on November 06, 2010, 04:42:29 am
Smitty: well, the script has been reported multiple times to work on Ubuntu 10.04 :)
The key to the build script working, if you let the script's default of PREFIX being $HOME (i.e. per-user installation), is proper value of the PKG_CONFIG_PATH and LD_LIBRARY_PATH environment variables. In such a case, in your ~/.bashrc, you'll have to add the following lines such as
export LD_LIBRARY_PATH=$HOME/lib:$LD_LIBRARY_PATH
export PKG_CONFIG_PATH=$HOME/lib/pkgconfig:$PKG_CONFIG_PATH
and run `source ~/.bashrc`.

You can also modify the PREFIX to replace $HOME by /usr, in which case you will have to execute install_tilp.sh with sudo, and you won't have to modify LD_LIBRARY_PATH and PKG_CONFIG_PATH.

As usual, don't hesitate to report back ;)