Author Topic: [Ndless SDK] Problems with the integrated emulator  (Read 8482 times)

0 Members and 1 Guest are viewing this topic.

Offline insertcoolnamehere

  • LV1 Newcomer (Next: 20)
  • *
  • Posts: 8
  • Rating: +0/-0
    • View Profile
[Ndless SDK] Problems with the integrated emulator
« on: May 15, 2013, 10:58:11 am »
(This pertains to the SDK mentioned here: http://ndlessly.wordpress.com/native-development-intro/)

I'm setting up the Ndless SDK which comes with an integrated emulator. The readme file in the /emu_resources directory has instructions:

Quote
To be able to use the 'nspire_emu' TI-Nspire emulator integration with the
NdlessEditor, you must first drop several resources to this directory and let
the OS image install itself to a NAND image.

1) Download OS "TI-Nspire CX (v 3.1)" or "TI-Nspire CX CAS (v 3.1)" from
   http://tiplanet.org/forum/archives_list.php?id=OS+Nspire
   Emulation of non-CX devices is not supported.

2) Drop it in this directory [emu_resources]

3) Use PolyDumper to dump your TI-Nspire CX boot1 and boot2 images:
   a) Install Ndless on your TI-Nspire CX
   b) Transfer the file emu_resources/polydumper/polydumper_3.1.tns to your
      TI-Nspire CX
   c) Run polydumper_3.1.tns

4) Transfer the files boot1.img.tns and boot2.img.tns produced by PolyDumper
   from your TI-Nspire CX to the directory emu_resources/ on the computer side

...

The next step is running the emulator, so I assume these are the steps that are needed to get the emulator to even open. Here is how my /emu_resources folder looks after downloading the OS file, running polydumper on my calculator and copying over the boot image files:



In the ScITE window, when I click on Tools->TI-Nspire emulator, the program hangs. What am I doing wrong?
insertcoolsignaturehere

Offline SpiroH

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 729
  • Rating: +153/-23
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #1 on: May 15, 2013, 05:48:13 pm »
It seems to me you've got the wrong file size for boot2.img.tns. It should be 855KB and not 1,328KB. Double-check it and try again.
Maybe this pic will help you a little: http://ourl.ca/16585;msg=253482
Best of luck,

Offline insertcoolnamehere

  • LV1 Newcomer (Next: 20)
  • *
  • Posts: 8
  • Rating: +0/-0
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #2 on: May 17, 2013, 04:46:48 pm »
I don't know what could be wrong though, all I did was run polydumper on my calculator and copied those files over. Is there something in polydumper that I have to change?
insertcoolsignaturehere

Offline critor

  • Editor
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2079
  • Rating: +439/-13
    • View Profile
    • TI-Planet
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #3 on: May 18, 2013, 02:50:37 am »
Polydumper adds padding/data bytes at the end of the Boot2.img.tns file.
Just truncate the file to 855KB.
TI-Planet co-admin.

Offline SpiroH

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 729
  • Rating: +153/-23
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #4 on: May 18, 2013, 05:40:19 am »
As a workaround you can always extract boot2.img directly from the TI file: 'TI-NspireCXCAS-3.1.0.392.tcc'. Do the following:
1. Make a copy and rename 'TI-NspireCXCAS-3.1.0.392 - Copy.tcc' to 'TI-NspireCXCAS-3.1.0.392 - Copy.zip'
2. Open up 'TI-NspireCXCAS-3.1.0.392 - Copy.zip' and you should see a picture like the one below:

3. Drag the boot2.img out of the zip archive.
4. Rename it to 'boot2.img.tns' and try to start the emulator. Cheers,

Offline insertcoolnamehere

  • LV1 Newcomer (Next: 20)
  • *
  • Posts: 8
  • Rating: +0/-0
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #5 on: May 24, 2013, 10:12:01 am »
Thanks SpiroH, I'll try that now and see if it works.

Polydumper adds padding/data bytes at the end of the Boot2.img.tns file.
Just truncate the file to 855KB.

If what SpiroH said doesn't work, I'll try this. I'm not sure exactly how I'll truncate the file but I'll see what I can do.
insertcoolsignaturehere

Offline Lionel Debroux

  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2135
  • Rating: +290/-45
    • View Profile
    • TI-Chess Team
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #6 on: May 29, 2013, 08:59:05 am »
The easiest way to truncate files is to use some kind of hex editor, there are myriads of no-fee hex editors for all computer OS flavors :)
For instance, for Windows, you can use XVI32.
« Last Edit: May 29, 2013, 08:59:37 am by Lionel Debroux »
Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.

Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #7 on: June 02, 2013, 11:37:57 am »
So I am having the same problem as OP.(When I click run Ti-emulator nothing happens.)




I got to this screen so what do I do?(I hope this isn't asking what do I do when I get to this screen: http://i.imgur.com/OjDaDjX.png)

Edit: Do I just delete all these FF's and Y's?



Edit2: Well I couldn't be bothered to wait for a reply so I did it anyway and the boot2.img.tns is the right size so I guess it worked.

Edit3: The emulator still doesn't work. It may be important to note that I have tried to do this before with an older version but I failed so it may or may not have messed with the path variable(I changed the path variable when trying to install).

Edit4: Edited the path to get rid of the old Ndless directory. Still doesn't work.(I have double checked it)

Edit5: Can't think of anything will need help from you guys to do more.

Edit6: Finally fixed it! All you have to do is copy it to the "C:\" directory. FYI I used the trick SpiroH used to get the boot2.img.tns.

« Last Edit: June 07, 2013, 12:16:35 pm by Augs »

Offline SpiroH

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 729
  • Rating: +153/-23
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #8 on: June 07, 2013, 09:51:56 am »
...
Edit6: Finally fixed it! All you have to do is copy it to the "C:\" directory. FYI I used the trick SpiroH used to get the boot2.img.tns.

Good exercise! Surely other people will benefit from it.
Also:
1. There's a good introduction on ndless 'native development' here: http://ndlessly.wordpress.com/native-development-intro/ . Under 'The Ndless SDK/OnWindows' it states: "Unzip the SDK archive. Make sure that no parent directory contains a space in its name.".

2. You should strikethrough the second paragraph of your post, that reads "I tried what SpiroH did but that didn't work".


Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #9 on: June 07, 2013, 12:20:45 pm »
I saw that.

Could you link me to a good nSDL guide?

Or is it the same is Normal SDL?

Offline Lionel Debroux

  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2135
  • Rating: +290/-45
    • View Profile
    • TI-Chess Team
Re: [Ndless SDK] Problems with the integrated emulator
« Reply #10 on: June 07, 2013, 03:39:12 pm »
nSDL is not entirely the same as normal SDL, but the main differences are described in the nSDL documentation, AFAICT.
Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.