Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Levak

Pages: [1] 2 3 ... 68
1
TI-Nspire / Re: nGL - a fast (enough) 3D engine for the nspire
« on: April 30, 2014, 02:10:28 am »
Quote
For fonts, you can use nGC or Freetype (which works without any changes)
Does nGC support rendering into (raw) buffers with different width than the screen?

It maybe does, but never managed to do so. The OS simply uses a gui_gc_clipRect before gui_gc_blit_buffer in order to draw part of the 3D engine (splitted app for example).
gui_gc_blit_buffer is not that slow IIRC, Of course I never had the opportunity to test it with a real 3D buffer.

Two ways offer to you :
Code: [Select]
static char* screen_buffer[SCREEN_BYTES];
void draw()
{
  ngl(screen_buffer, scene);
  gui_gc_blit_buffer(gc, screen_buffer); /* syscall */
  gui_gc_drawString(gc, "H\0e\0l\0l\0o\0 \0W\0o\0r\0l\0d\0\0", 0, 10);
  gui_gc_blit_to_screen(gc); /* part of libndls */
}

Code: [Select]
static Gc text_gc;
void init()
{
  text_gc = gui_gc_copy(gc, 100, 100)
  gui_gc_setColorRGB(255, 255, 255);
  gui_gc_fillRect(0, 0, 100, 100);
  gui_gc_setColorRGB(0, 0, 0);
  gui_gc_drawString(text_gc, "H\0e\0l\0l\0o\0 \0W\0o\0r\0l\0d\0\0", 0, 10);
}

void draw()
{
  ngl(scene);
  gui_gc_blit_to_screen_region(text_gc, 0, 0, 100, 100); /* You can even redefine this function in order to handle alpha */
}

Quote
nGC uses the OS' font routines AFAIK which are slow and ugly
Slow because of syscalls, and in my second example the draw method doesn't use any syscall on time critical code.
Ugly ? Their code is mainly a top level API over Nucleus GRAFIX in order to define primitive like in Java's Graphic2D.
The only thing you need to bother with nGC is utf16 which is simpler to use with the String API.

2
Calculator C / Re: Ndless Hooking Tutorial (especially key-hooks)
« on: April 12, 2014, 07:14:28 pm »

Vogtinator told me that the os interrupt handler is a good place to set up a hook. You tell me that the key code translator is the better place.
He said "Os key interrupt handler", I said "key code translator" which are, in fact the same fonction call tree. I pointed you the address to look for CX CAS 3.1.


Quote
I "just" wanted a little code example cause i cant rly figure out how i can manipulate the ram(?)
Even if I give you the code to install a hook and explain it you, there is still the correct location in the OS to find.


Quote
I just wanted something like this if its possible:
Code: [Select]
installhook(ram_address, function_to_activate_when_ram_has_a_specific_value());
This is excatly what the macro HOOK_INSTALL does, except it takes an array of addresses.


Quote
Afaik, a hook means a ram address and if the value is changed, my code activates(?)
A hook is more like that. Ndless hooks need to ensure every opcode are still called beside the code you add. You cannot shift the entire RAM to insert your hook.


Suppose you have these opcodes :
Code: [Select]
0x00  MOV r1, #0
0x04  MOV r2, #42
0x08  MOV r3, #69
0x0C  BL    foo
0x10  BL    bar


Take this simple hook mecanism :
Code: [Select]
/* Hook at address 0x0 on every OS version */
static const int hook_addrs[] = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0};
#define HOOK_ADDR (nl_osvalue((int*)hook_addrs, sizeof(hook_addrs)/sizeof(hook_addrs[0])))


HOOK_DEFINE(my_hook) {
  /* Code */
}


int main() {
  HOOK_INSTALL(HOOK_ADDR , my_hook)
  nl_set_resident();
  return 0;
}


Ndless hooks will result in something like this :
Code: [Select]
0x00  ADD LR, PC, #4           ; compute return address
0x04  STMFD !SP, {R0-R12, LR}  ; save the context
0x08  B hook_handler           ; jump to handler
0x0C  BL   foo                 ; previous context
0x10  BL   bar                 ; previous context
[...] ; elsewhere in RAM
hook_handler:
0x40  BL my_hook     ; the hook defined in C with HOOK_DEFINE
0x44  MOV r1, #0     ;\
0x48  MOV r2, #42    ; }all the previous context saved because we erased it with custom code
0x4C  MOV r3, #69    ;/
0x50  LDMFD !SP, {R0-R12, PC} ; return to previous context


But as I said, the place where you hook up needs to be found by your own.

3
Calculator C / Re: Ndless Hooking Tutorial (especially key-hooks)
« on: April 12, 2014, 06:15:51 pm »
Is there any good hooking tutorial for ndless on the ti-nspire 3.6?
As far as I know, no, but its pretty simple. Reading Ndless code tells you all.

Quote
I wanted to make a notepad which i can activate by something like ctrl+return.
A hook in the key code translator should be a rather good place (on CX CAS 3.1 : look around 0x10230140).

Quote
Code: [Select]
// Defines the adresses and value(?)

static const int hook_addrs[] = {0x100B66C8, 0x100B6988,  // Clickpad / Touchpad 3.1
                                 0x100EAAAC, 0x100EADC4,  // CX 3.1
                                 0x100E72CC, 0x100E75E4,  // CM 3.1
                                 0x101122b8, 0x100eb288,  // Clickpad / Touchpad 3.6
                                 0x10111cfc, 0x1011201C}; // CX 3.6


//What does this mean? what does nl_osvalue(... , ...); do?
#define HOOK_ADDR (nl_osvalue((int*)hook_addrs, sizeof(hook_addrs)/sizeof(hook_addrs[0])))


static const int hook_values[] = {0xe92d47f0, 0xe92d47f0,
                                  0xE59F1030, 0xE59F1030,
                                  0xE59F1030, 0xE59F1030,
                                  0xE59F1030, 0xE59F1030,
                                  0xE59F1030, 0xE59F1030};


#define HOOK_VALUE (nl_osvalue((int*)hook_values, sizeof(hook_values)/sizeof(hook_values[0])))

For each OS version and calc serie, I define where the hook has to installs itself. hook_values contains the original WORD contained at that specific address. This prevents from installing multiple time the same hook.

Quote
The full code of nclock is attached.
I'd rather prefer you to link to the archive directly.

So this means that for every os version the author of nclock has a specific address?
For every version of Ndless (3.1, 3.6) and every Nspire serie (Clickpad/Touchpad, CX, CM), yes.

Quote
How do i get these addresses?

You can, for instance, find them in nspire_emu, entering the debugger and start exploring. On a more serious level, by reading the disassembled code of the OS (for obvious reasons, tools and such things cannot be found pubicly).



By finding out what interrupts are and everything around it, the only thread was this one:
Interrupts are not what you're looking for. The OS already set them up.

Quote

http://www.omnimaga.org/calculator-c-language/(ndless)-interrupts-newbie-here

You tried to help him and he seems to understand... I don't
He may have discontinued his idea. Interrupt controlers are not that hard, except if you hate reading datasheets.

4
Site Feedback and Questions / Re: Signatures & ponies
« on: January 27, 2014, 12:08:10 pm »
May I point you to http://www.omnimaga.org/index.php?action=ezportal;sa=page;p=2 and strongly remind you that we will enforce them.

I still do not see why using appropriate words is considered "provocative". Even being rude is not provocative, its just a matter of using a different style. I've read along the rules twice before posting it the way I wrote it, trust me. Call it language barrier if you want, I don't have other words to describe my pain.

Quote
While you may find it annoying you still do not have the right to be rude or provocative to members of this site. If you have complaints about specific individuals then submit an issue on http://ourl.ca/issue and if you have a request about our policy or changing how the site works use http://ourl.ca/request

You won't hear any request from me if, as you wrote, a single 200*200 image in a sig is considered as spam.

It seems we have different point of view. I personally see a forum-sig as an e-mail sig.
Thus, it is at miles away from what the netiquette says :
Code: [Select]
    - If you include a signature keep it short.  Rule of thumb
      is no longer than 4 lines.  Remember that many people pay for
      connectivity by the minute, and the longer your message is,
      the more they pay.

The reason why I post it publicly instead of demanding it (not requesting, I know my English) via PM/email, is that I first want to see if I'm not the only one around here thinking there is abuse everywhere. Since abuse is everywhere, nothing is preventing people to stop, and nothing is encouraging people like me to complain, since even admin are thinking everything is normal.

Since nothing is willing to move, I won't fight endlessly, so I disabled user-sig, that's it.
And don't tell me I want to "drive the administrator choice" and "make my own law", I'm just saying things without ornament.
May it please you or not, things have shown that I'm not the only one thinking what I've said.

Irony-proof : Have a nice day,


edit:

Also Levak, before accusing people from being trolls, you should maybe look at yourself. YOU are the troll for the following reasons:

-For trying in every way possible (at least, since the last 6 months or so) to ruin Omnimaga friendly atmosphere.
-For trying in every way possible to start fights with other members by being rude on purpose
-Trying to get a reaction from other people by posting controversial (or controversially-written) messages to make them angry or leave the forums (eg, Stefos)
-Harassment (eg, always jumping on me, although you stopped it seems, or stefos)
-By denying the fact you are actually being rude (at least per Omnimaga standards) and that way, acting like you are perfect, throwing the blame on everyone else (example: your post right above)
-For breaking the forum rules on purpose:
  *Flaming (calling people names or insulting them, such as calling them immature)
  *Intolerance (insulting someone or an entire group of people for liking MLP, colored sigs, being gay, black, etc, or a calculator RPG for being larger than 5 KB and 1 file, for example)
  *Provocative comments (trolling, being confrontational, being rude or anything else that can make people angry)

Okay, goodbye world.

5
Site Feedback and Questions / Re: Signatures & ponies
« on: January 27, 2014, 11:27:12 am »
Even if I'm not fine yet with some people's signature showing their wild immaturity, I'm fine with this option.
Maybe you should be a little less rude about how you word that? Some of the members may take offence with you calling them wildly immature.

Less rude or less realistic ? I cannot close my eyes (well, its what I'm doing by disabling signatures) on such a thing.

Liking MLP is a fact, flooding and spamming it in every sig is more like a troll or immature thing.

Thus, I hope being rude can make them wake up. I'm not demanding them to change, but if they can understand they are annoying people, it will be a good thing for them.

6
Site Feedback and Questions / Re: Signatures & ponies
« on: January 27, 2014, 08:28:16 am »
I bump this thread - not to yell at somebody (once) - in order to exchange with an option I've just found in my profile settings while disabling the "send email notification for each topic replies" :

You can disable the user's signature in Layout > "Don't show user's signature".

Even if I'm not fine yet with some people's signature showing their wild immaturity, I'm fine with this option.

7
TI-Nspire / Re: Minecraft 2D for TI-Nspire
« on: January 25, 2014, 08:26:24 am »
hay. i havn't heared any thing latly is this program still up/running?
Last update is one week old, is that your definition of "lately" ?
Just look one page before this one, seriously ...

8
Miscellaneous / Re: Post your desktop
« on: January 23, 2014, 05:16:30 pm »
ew, internet explorer :P

IE 10 is not that bad, you know...

9
TI-Nspire / Re: nCoder
« on: January 15, 2014, 01:26:19 pm »
Monospace font doesn't exist out of the box on TI-Nspire.
You have to hack the output, either displaying char by char, or displaying tiles by tiles with a custom font made of images.

On another note : How could we lok like a  hacker without fullscreen and with Lua code displayed ?

10
Lua / Re: Updating WZGUILib
« on: January 14, 2014, 02:02:03 pm »
So I really don't see why I got a downvote.

The real problem is on the form, as I said it in my previous post, even if he has the will to port it.
Also, if he already said he has the will to do it, why demanding it again ? (yes, your post looks like a demand).

11
hello all
i tried to download Ndless v3.1 beta for OS v3.1 with TI-Nspire CX CAS but i get to an error pop pup wich says,


Hi,

I have no error when donwloading from http://www.unsads.com/projects/nsptools/downloader/download/release/1

Does this help ?

12
General Calculator Help / Re: nSpire CX update to CAS
« on: January 12, 2014, 06:09:37 pm »
OS 3.6 adds an anti-downgrade protection that removes your freedom to do whatever you want with the machine you just spent $150 on.

Do I have any other option for that to be possible

http://www.shopping.hp.com/en_US/home-office/-/products/Accessories/Calculators/NW280AA?HP-Prime-Graphing-Calculator

Are you trying to convince him to buy another 150$ calculator in order to have CAS ? Is that what should be undertood from your message ?

So, if I buy that thing, is it possible? Explain me if there is any kind of chance. I need to have the CAS system because I need my calculator to give me exact values in equations and stuff like that. Do I have any other option for that to be possible, if I can't put the CAS OS (like a program or something)?

Buy a 10$ max TTL/USB adaptator. Many many many topics here and elsewhere talk about that technique.

Edit:
Just to be sure, what is your hardware revision (last letter of the right number at the bottom back of the calculator) ? If I'm not wrong you dont have a J or K revision, since you installed OS 3.6 by your own and used nLaunch, don't you ?

13
General Calculator Help / Re: nSpire CX update to CAS
« on: January 12, 2014, 05:12:36 pm »
You can't.

And the most amazing thing here is that you can't get backward unless you buy a TTL/USB adaptator to plug in the docking port in order to reflash your boot2 (and then your OS).

14
General Calculator Help / Re: New CX CAS OS......Worth upgrading?
« on: January 11, 2014, 05:48:34 pm »
One big concern I have is that Adobe Acrobat is constantly updated with new features. As people upgrade, there are chances that more and more PDF files won't be convertable anymore using mViewer GX if there are two versions to maintain, delaying updates.

If this is your biggest fear, you may be pleased to hear that mViewer GX core code doesn't process any PDF directly. It uses external libraries to generate the tns. Most of the work is done in the standalone Lua script, not actually in the generator.

15
General Calculator Help / Re: TiLP can't find calculator
« on: January 11, 2014, 01:46:59 pm »
I got tilp built now, but I still get a corrupted double-linked list error. I'm running tilp with sudo, so permissions should not be an issue.

But I don't get what you're expecting if you're running TILP in a non-GUI environment (through ssh)
Also, I got the linking error when running as root on openSUSE and had to add the udev conf as detailled in the TILP readme.

Pages: [1] 2 3 ... 68