Omnimaga: The Coders Of Tomorrow
Welcome, Guest. Please login or register.
 
Omnimaga: The Coders Of Tomorrow
23 May, 2013, 05:28:19 *
Welcome, Guest. Please login or register.

Login with username, password and session length
 
   home   news downloads projects tutorials misc forums rules new posts irc about Login Register  
+-OmnomIRC

You must Register, be logged in and have at least 40 posts to use this shout-box! If it still doesn't show up afterward, it might be that OmnomIRC is disabled for your group or under maintenance.

Note: You can also use an IRC client like mIRC, X-Chat or Mibbit to connect to an EFnet server and #omnimaga.

Pages: 1 ... 30 31 [32] 33 34   Go Down
  Print  
Author Topic: Ndless 2.0 for TI-Nspire Clickpad/Touchpad -  (Read 48486 times) Bookmark and Share
0 Members and 1 Guest are viewing this topic.
Silver Shadow
Beta Tester
LV8 Addict (Next: 1000)
********
Offline Offline

Gender: Male
Last Login: 21 December, 2011, 21:23:08
Date Registered: 03 October, 2008, 17:34:52
Location: France
Posts: 799


Total Post Ratings: +20

View Profile
« Reply #465 on: 23 February, 2011, 19:38:17 »
0

Have you added
C:/Users/christiancoors/Desktop/TI-nspire/ndless/trunk/bin
to your PATH variable?
Logged

Former Coder of Tomorrow

Cuervo
LV2 Member (Next: 40)
**
Offline Offline

Last Login: 25 June, 2012, 18:02:26
Date Registered: 22 February, 2011, 18:38:20
Posts: 33

Total Post Ratings: +1

View Profile
« Reply #466 on: 23 February, 2011, 20:01:52 »
0

Yes, I did


1
export PATH=$PATH:/Users/christiancoors/Desktop/TI-nspire/ndless/trunk/bin/

before.. (on Mac OS X there is no 'C'-drive..)


If I don't do that he tells me os.h is missing and with it it's being included. (but not finding stddef.h)
Logged
calc84maniac
Epic z80 roflpwner
Coder Of Tomorrow
LV11 Super Veteran (Next: 3000)
*
Offline Offline

Gender: Male
Last Login: 20 May, 2013, 21:27:24
Date Registered: 28 August, 2008, 05:09:05
Location: Right behind you.
Posts: 2735


Total Post Ratings: +373

View Profile
« Reply #467 on: 23 February, 2011, 20:36:51 »
0

I think stddef.h is part of YAGARTO. Is Yagarto's bin folder also in your path?
Logged

"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman
Cuervo
LV2 Member (Next: 40)
**
Offline Offline

Last Login: 25 June, 2012, 18:02:26
Date Registered: 22 February, 2011, 18:38:20
Posts: 33

Total Post Ratings: +1

View Profile
« Reply #468 on: 24 February, 2011, 18:15:48 »
0

OK, I got very (!) far now, the only thing not working is I'm not getting a ndless_resources.tns..


1
2
3
4
5
6
7
8
9
10
nspire-gcc -Os -nostdlib -Wall -W -Wno-strict-aliasing -c syscalls_cas-2.0.1.c
nspire-gcc -Os -nostdlib -Wall -W -Wno-strict-aliasing -c syscalls_ncas-2.1.0.c
nspire-gcc -Os -nostdlib -Wall -W -Wno-strict-aliasing -c syscalls_cas-2.1.0.c
nspire-ld --light-startup -nostdlib install.o ploaderhook.o ints.o syscalls.o utils.o emu.o syscalls_ncas-1.7.o syscalls_cas-1.7.o syscalls_ncas-2.0.1.o syscalls_cas-2.0.1.o syscalls_ncas-2.1.0.o syscalls_cas-2.1.0.o -o ndless_core.elf
"/usr/local/arm-elf/bin/arm-elf-objcopy" -O binary ndless_core.elf ndless_core.bin
stage2_hexsize=`wc -c ndless_stage2.bin | cut -f1 -d' ' | xargs  printf '%04x'` \
&& test -n "$stage2_hexsize" \
&& echo -e -n "\x${stage2_hexsize:2:2}\x${stage2_hexsize:0:2}\x00\x00" > ../calcbin/ndless_resources.tns
make[1]: *** [ndless_resources.tns] Error 1
make: *** [subdirs] Error 1

I actually do not see, what the problem is..


EDIT:
Ok, if I manually enter the number, I get the file. Does not work on my nspire cas OS 2.1.0 or 2.0.1.. tried many times. Always crashes.

TIA
Cuervo
« Last Edit: 24 February, 2011, 20:59:34 by Cuervo » Logged
DJ Omnimaga
Retired Omnimaga founder (Site issues must be PM'ed to Netham45, Eeems, Shmibs, Deep Thought and AngelFish, not me.)
Editor
LV15 Omnimagician (Next: --)
*
Online Online

Gender: Male
Last Login: Today at 05:17:39
Date Registered: 25 August, 2008, 07:00:21
Location: Québec (Canada)
Posts: 50225


Total Post Ratings: +2615

View Profile WWW
« Reply #469 on: 25 February, 2011, 22:26:20 »
0

Hi Cuervo and welcome to the forums (I wonder if I missed anyone else, but welcome to others too). Hopefully now you should no longer need to compile Ndless as ExtendeD posted a binary of it here: http://www.omnimaga.org/index.php?topic=6770

Just make sure to send the right file to your calculator, though. There is one for OS 1.7, one for 2.0.1 and one for 2.1, and you must also send the resources file.
Logged

Retired 83+ coder, Omnimaga/TIMGUL founder. Now doing power metal music (formerly did electronica)

Follow me on Bandcamp|Facebook|Reverbnation|Youtube|Twitter|Myspace
ExtendeD
Coder Of Tomorrow
LV8 Addict (Next: 1000)
*
Offline Offline

Gender: Male
Last Login: Yesterday at 10:41:34
Date Registered: 02 January, 2010, 13:03:41
Location: France
Posts: 765

Topic starter
Total Post Ratings: +151

View Profile
« Reply #470 on: 26 February, 2011, 00:06:12 »
0

Just found a little bug: I notice that when Ndless tries to restore the FIQ vector (in arm/bootstrapper.S main_copy), it overwrites the Undefined Instruction jump instead:

A4000000  18 F0 9F E5 E4 66 26 10-18 F0 9F E5 18 F0 9F E5
A4000010  18 F0 9F E5 18 F0 9F E5-18 F0 9F E5 18 F0 9F E5
A4000020  30 60 26 10 28 48 04 11-4C 47 04 11 20 48 04 11
A4000030  18 48 04 11 00 00 00 00-C0 66 26 10 40 00 00 00
This one was well hidden! I've just fixed it. I wonder if this could be the source of the random crashes at installation time.
Logged

ndlessly - Progress and insights on Ndless
Ndless / Hackspire - Third-party TI-Nspire development
ExtendeD
Coder Of Tomorrow
LV8 Addict (Next: 1000)
*
Offline Offline

Gender: Male
Last Login: Yesterday at 10:41:34
Date Registered: 02 January, 2010, 13:03:41
Location: France
Posts: 765

Topic starter
Total Post Ratings: +151

View Profile
« Reply #471 on: 26 February, 2011, 00:51:34 »
0

In the meantime, I think that the number keys may actually be easier to use. But do you think it would be possible to move the down arrow to 5? If you're using one hand, the key in the middle makes it hard to use the keys as a joypad.
So:
....8...
.4.5.6.

8 = up
4 = left
5 = down
6 = right

and then maybe make click "2".

Have any apps other than block dude been compiled with this configuration? (i.e., gbc4nspire or nes)

I haven't touched a single line of code since then, but I'm keeping track of your bug reports and suggestions, hopefully I'll try to integrate them soon.


What have you decided about the arrow and number keys?

I think mapping arrow keys to number keys at the Ndless level (which has been introduced in the last builds if I've understood well) is a bad idea.

I can understand this "hack" has been introduced to make old Ndless 1.7 games work without modifying the source...
But let's look at the future and not at the past: there are many reasons a program would like to test for number keys (numerical input, menu choice...).

I think it's up to the program itself to test for number keys and to decide to handle them either as numbers either as arrows.
About this, I have an idea that might make everything work great: how about add a line in Ndless program headers so as to specify for which version they were compiled for. If this line is absent, consider it to be an Ndless 1.7 program, and make Ndless decide which buttons to use, but if the line says that the program was made for Ndless 2.0, let the program decide its own course of action in regard of the keys.
What do you think?

I have implemented codeslicer's suggestion for the v2.0 release. Block Dude and maybe nDoom need to be rebuilt to use the new mapping if apcalc and Mrakoplaz want to, sorry for the inconvenience.

In any case programs written for Ndless 1.1 needs to be rebuilt with this version to be compatible with the Touchpad, and programs will have to be rebuilt once the full Touchpad support is added to Ndless, since the key mapping is actually inlined into the program's codes. With the current implementation the options are the following:
- either the program keeps the current default mapping, and will be rebuilt (and perhaps slightly adapted) once the Touchpad arrows scanning is available in Ndless
- either the program needs both arrow keys and numeric keys as input, and layout the keyboard as it wants, without using the  KEY_NSPIRE_LEFT constants and the like.

Are we all OK with this?
Logged

ndlessly - Progress and insights on Ndless
Ndless / Hackspire - Third-party TI-Nspire development
Lionel Debroux
LV10 31337 u53r (Next: 2000)
**********
Offline Offline

Gender: Male
Last Login: Yesterday at 20:50:31
Date Registered: 17 December, 2009, 09:37:25
Location: France
Posts: 1854

Total Post Ratings: +208

View Profile WWW
« Reply #472 on: 26 February, 2011, 09:40:47 »
0

As I wrote in another topic, for fully abstracting the Clickpad/Touchpad difference wrt. direction and click, and for proper handling of arrow keys and numeric keys used at the same time in a given program, we may want to kill the KEY_NSPIRE_* and usage of isKeyPressed() for those five keys, and move the way to check those keys to a new function.
Logged

Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.
Cuervo
LV2 Member (Next: 40)
**
Offline Offline

Last Login: 25 June, 2012, 18:02:26
Date Registered: 22 February, 2011, 18:38:20
Posts: 33

Total Post Ratings: +1

View Profile
« Reply #473 on: 26 February, 2011, 14:57:01 »
0

Hi Cuervo and welcome to the forums (I wonder if I missed anyone else, but welcome to others too). Hopefully now you should no longer need to compile Ndless as ExtendeD posted a binary of it here: http://www.omnimaga.org/index.php?topic=6770

Just make sure to send the right file to your calculator, though. There is one for OS 1.7, one for 2.0.1 and one for 2.1, and you must also send the resources file.

Ok.. thanks!

That version actually DOES work while the one compiled by me does not. I have no idea why.
Anyway, it's great!
Logged
DJ Omnimaga
Retired Omnimaga founder (Site issues must be PM'ed to Netham45, Eeems, Shmibs, Deep Thought and AngelFish, not me.)
Editor
LV15 Omnimagician (Next: --)
*
Online Online

Gender: Male
Last Login: Today at 05:17:39
Date Registered: 25 August, 2008, 07:00:21
Location: Québec (Canada)
Posts: 50225


Total Post Ratings: +2615

View Profile WWW
« Reply #474 on: 26 February, 2011, 21:04:03 »
0

Ok great to hear. This one might work better since he fixed some errors and is supposedly more stable. It doesn't seem to run nDoom as well for me, though, but I think Mraklopaz has to recompile it.
Logged

Retired 83+ coder, Omnimaga/TIMGUL founder. Now doing power metal music (formerly did electronica)

Follow me on Bandcamp|Facebook|Reverbnation|Youtube|Twitter|Myspace
ExtendeD
Coder Of Tomorrow
LV8 Addict (Next: 1000)
*
Offline Offline

Gender: Male
Last Login: Yesterday at 10:41:34
Date Registered: 02 January, 2010, 13:03:41
Location: France
Posts: 765

Topic starter
Total Post Ratings: +151

View Profile
« Reply #475 on: 04 March, 2011, 17:16:22 »
0

Touchpad scan has been added with the help of Goplat. Since I don't own a TI-Nspire Touchpad and could only rely on emulated tests, I am really interested by any feedback from Touchpad users. For this you need to:

  • Update your Ndless SVN working directory and rebuild everything
  • Rebuild your program or game with this version to check that isKeyPressed([arrow]) works well and there are no regressions. Don't forget to use the new version of Ndless on the calc.
  • Check how isKeyPressed(KEY_NSPIRE_CLICK) reacts since I cannot test it on nspire_emu
  • Run tests/ndless_tpad.tns adapted from Goplat's sample, that shows low-level scan
  • Use the Touchpad API in your own program! The gaming experience could really be enhanced.

Here is a description of the current implementation, that may be adapted if it doesn't behave well on real hardware:
The area is divided in 9 rectangles (left, upper-left, up, upper-right and so one) of identical width and height. Touching the rectangle in the middle make it click. I'm not sure if I should use a non-default proximity sensitivity for this one to be consistent with the OS behavior. I have never used a Touchpad so please tell me how it feels.
« Last Edit: 04 March, 2011, 19:55:45 by ExtendeD » Logged

ndlessly - Progress and insights on Ndless
Ndless / Hackspire - Third-party TI-Nspire development
calc84maniac
Epic z80 roflpwner
Coder Of Tomorrow
LV11 Super Veteran (Next: 3000)
*
Offline Offline

Gender: Male
Last Login: 20 May, 2013, 21:27:24
Date Registered: 28 August, 2008, 05:09:05
Location: Right behind you.
Posts: 2735


Total Post Ratings: +373

View Profile
« Reply #476 on: 04 March, 2011, 18:14:43 »
0

The touchpad isn't divided into 9 rectangles? Also, you say "Touching the rectangle in the middle makes it click." I assume you also have to press the button down for a keypress to register?

Edit:
Also, nice work Smiley
« Last Edit: 04 March, 2011, 18:15:29 by calc84maniac » Logged

"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman
shrear
LV4 Regular (Next: 200)
****
Offline Offline

Gender: Male
Last Login: 26 February, 2013, 19:14:10
Date Registered: 16 October, 2010, 16:32:14
Location: Luxembourg
Posts: 193


Total Post Ratings: +17

View Profile
« Reply #477 on: 04 March, 2011, 19:51:53 »
0

nice that the touchpad is now included, but sadly I get an erro when trying to build this version Sad  Frustrated


1
2
3
4
5
6
7
8
9
10
11
make all in arm...
make[1]: Entering directory /d/Nspire/Ndless/arm
nspire-as -Os -nostdlib -Wall -Wno-strict-aliasing -D OS_VERSION_INT=17 -c bootstrapper.S
c:/program files (x86)/yagarto/lib/gcc/../../arm-none-eabi/sys-include/stdint.h: Assembler message:
41: Error: bad instruction 'typedef signed char int8_t'
c:/program files (x86)/yagarto/lib/gcc/../../arm-none-eabi/sys-include/stdint.h: Assembler message:
42: Error: bad instruction 'typedef unsigned char uint8_t'
...
...lots of similar errors
...

Anyone an idea where to search for the source of this... ?
Logged
Lionel Debroux
LV10 31337 u53r (Next: 2000)
**********
Offline Offline

Gender: Male
Last Login: Yesterday at 20:50:31
Date Registered: 17 December, 2009, 09:37:25
Location: France
Posts: 1854

Total Post Ratings: +208

View Profile WWW
« Reply #478 on: 04 March, 2011, 19:54:59 »
0

This looks like some C code getting included bare-naked into an ASM file ?
Logged

Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.
ExtendeD
Coder Of Tomorrow
LV8 Addict (Next: 1000)
*
Offline Offline

Gender: Male
Last Login: Yesterday at 10:41:34
Date Registered: 02 January, 2010, 13:03:41
Location: France
Posts: 765

Topic starter
Total Post Ratings: +151

View Profile
« Reply #479 on: 04 March, 2011, 20:01:53 »
0

calc84maniac: sorry, yes its 9.
Which button do you mean? (I have never seen a real Touchpad)

shrear, Lionel: you're right, I should have "make clean all". It's fixed.
Logged

ndlessly - Progress and insights on Ndless
Ndless / Hackspire - Third-party TI-Nspire development
Pages: 1 ... 30 31 [32] 33 34   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Powered by MySQL Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Powered by PHP
Page created in 0.33 seconds with 31 queries.
Skin by DJ Omnimaga edited from SMF default theme with the help of tr1p1ea.
All programs, games and songs avaliable on this website are property of their respective owners.
Best viewed in Opera, Firefox, Chrome and Safari with a resolution of 1024x768 or above.