Join us on Discord!
You can help CodeWalrus stay online by donating here.

HP Prime and HP-PPL Statistics and useful tips and tricks

Started by alexgt, May 10, 2016, 11:34:15 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

alexgt

So this is the place to share any tests or tricks you have learned while programming/ using the HP Prime!

So DJ was wondering about if the new firmware made any speed differences with the speed of displaying GROBs, I have updated to the firmware 107701 (if that is the right number xD) and here is the speeds (in milliseconds):

G1 is set to 320x240
G1 no zoom, no alpha blending: 3-12 (consistent mostly on 3 with some spikes)
G1 2x zoom, no alpha blending: 29-41 (we see a significant speed drop here but I didn't specify the exact cords on G1 on what to display, when I did that it went down to 29-35 which isn't that big of a drop though)
G1 no-zoom, 50% alpha blending: 17-26 (it jumped once to 40 but that was only once)
G1 2x zoom, 50% alpha blending: 49-53 (this is super high so don't use this combo unless you are not drawing to the screen frequently)
G1 4x zoom, no alpha blending: 29-37, I don't know why 2x and 4x are so similar but it is probably because it stops drawing pixels after the coords are more than 320,240 or less than 0,0.
G1 4x zoom, 50% alpha blending: 49-56 again with the zoom and alpha the render time is high but like the others it is about the same to 2x zoom for some reason.

There is one bug with BLIT however and that is when you try and use 12 arguments. I saw a post on hp museum that said something about it and @timwessman confermed that it was a problem with the amount of args and it is a known bug. So that means you can't do zoom with alpha blending <_<. but that only means that 2 tests cannot be complete...

I used this program to time them:

EXPORT LineTime()
BEGIN
DIMGROB_P(G1,320,240);
A:=TICKS;
BLIT_P(G0,G1,[other arguments]);
B:=TICKS;
END;
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

Interesting, but didn't he say that you can simply omit the G0 at the start (since it defaults to G0 for BLIT_P)? IIRC that allowed you to squeeze the extra blending argument in.

Also you totally misspelled Tim Wessman's name there so I fixed it <_<
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

Quote from: DJ Omnimaga on May 10, 2016, 08:07:58 PM
Interesting, but didn't he say that you can simply omit the G0 at the start (since it defaults to G0 for BLIT_P)? IIRC that allowed you to squeeze the extra blending argument in.

Also you totally misspelled Tim Wessman's name there so I fixed it <_<
Oops, about the name and the command xD. Sorry Tim. But yeah, I will edit that tomorrow since I need to do homework.

EDIT: And on a side note is HP selling wireless connectivity kits because I really want one <_<
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

I don't remember if the wireless kit is available for sale yet, but you need hardware C anyway so if your calculator is too old then it might not be compatible. If the HP Prime was more mainstream then the wireless unit would have ruled, since we could have gotten some multiplayer games.
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

I think I have hardware version C since I got a new calc off the warranty for since mine had a broken screen :P
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

Oh right, but again we never know, since on HP website they still sold both hardwares as separate item IDs not so long ago.

By the way, did you have any luch testing the speed of alpha-blended graphics with the method I suggested?
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

sorry, I haven't done that but I will on the bus today ;)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

Ah ok. Let me know when you did it (maybe edit the first post and @mention me in a new post). Or report if it doesn't work (it might also be wise to report the issue on HP Museum if even omiting G0 doesn't work)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

Sure thing, I am posting the results now

EDIT: @DJ Omnimaga the results are posted ;)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

Thanks for the tests. I think the speed isn't bad so that could still be handy for stuff that doesn't require speed. :) (and maybe make it easier to do :walrii: Maker
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

Yeah, come to think of it if I made a walrii mob then I would have the colors randomized O.O
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

That could work. My idea actually was to use alpha blending for the shading of the walrus sprites, such as making a 2nd layer with white and black pixels displaying at 36% opacity and a third layer with 18% opacity or something like that. So I could change the gray in the Walrii sprite to anything without losing the rest. I would also need to allow choosing different types of shading, though (since some walrus sprites like Walriichu did it differently)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

Yeah, that would be cool. Especially if you had an auto up loader to apps that then could use them as sprites. Or if you could somehow return the GROB data  for DIMGROB() :P
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

An uploader could be nice, but then we might as well do the Walrii maker on the PC or web :P. On0calc the easiest way would be to get the user to manually copy/paste each frame from the emulator screenshot utility into an image software, although that wouldn't be convenient.
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

alexgt

Well if you had it on calc then you could just make the final GROB an AFile and then you wouldn't have to use  PC at all, what I have gathered from Tim Wessman is that GROBs are .png images so they are ready to be implemented in Apps ;)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Powered by EzPortal