Post Reply 
Outputting from notepad++ directly to hpemu48? (HP50g)
05-16-2016, 02:33 AM (This post was last modified: 05-16-2016 01:14 PM by chris b.)
Post: #1
Outputting from notepad++ directly to hpemu48? (HP50g)
EDIT: Decided to figure it out for myself, came up with a very workable solution.

You can download a portable version here (self hosted):

save files as a .s or .hpprgm for notepad++ to pick up the syntax highlighting.

alt+f1 will open up the emulator and pipe your program into the emulator. From there, hit the "CONV" softkey (either from the HOME directory variable or saved in the custom menu) to convert from ASCII to binary, and you can either evaluate it or store as a variable from there.

Please note that the header must have translation code 3 in it to work properly, so your header should look like this:
%%HP: T(3)A(D)F(.);

All the programs involved (emu48, notepad++, hp prime syntax) are under the GNU GPL, and *should* (in theory) be redistributable.

Quote:So currently, I have been developing in User RPL for the HP50g calculator. To this end, I have been using two major programs, Debug4x and Notepad++, with a language definition file for user RPL.

I would prefer to stick to one program for continuity, and I would like that program to be debug4x, but the editing environment is extremely buggy. It seems to randomly decide whether tabs are considered white space, predefined characters don't always display properly, and there are multiple visual bugs.

So I program in ascii in notepad++, and my code comes out something like this:
%%HP: T(0)A(D)F(.);
4 FIX @set to 4 decimal points
DEG RECT -105 SF @set degree mode and approximate mode
-42 SF @set dd/mm/yy
-56 SF @turn off beep
-95 CF @turn on RPN mode
-117 SF @turn on soft menu
500\->KEYTIME @set the delay between keystrokes lower
\<< 500\->KEYTIME \>> 'STARTUP' STO @add to startup

One feature I really miss though is that debug4x lets you compile ascii code directly into the emulator for testing, and I am looking for a way to do that with notepad++. At the moment I have to set up a dummy file, copy my code into debug4x, and export to the emulator. It would be nice if I could compile directly from notepad++.

Anyone have a clear idea how that might work?

EDIT: decided to do it myself, attached a working example below. Reply soon on how to use it.
Find all posts by this user
Quote this message in a reply
05-16-2016, 08:52 AM
Post: #2
RE: Outputting from notepad++ directly to hpemu48? (HP50g)
Alright, decided to take the initiative and wrote up a way to do it. Technically this uses the HP prime markup, but it's startlingly similar to user RPL, so syntax highlighting is very usable (and customizable).

Programs used:
Notepad++ (license: GPl Enhanced)
HP Prime Markup for Notepad++ (license: none?)
DDE48 (license: GNU?)
Emu48 (License: GNU?)
Ascii to binary (license: none?)

And some scripts I wrote up for the purpose.

Translation header must be set to 3 (EX: %%HP: T(3)A(D)F(.)Wink

So, save your ascii program with the extension .s or .hpprgm (for notepad++ to detect syntax highlighting). Open it up with the portable notepad++ attached.

[Image: lQs7iBw.png]

[Image: G83d8Td.png]

To run, hit alt + f1, it'll open like this:

[Image: uWSWsRk.png]

click on CONV (in the soft menu) to convert to binary, then run with EVAL or save as a variable. You're done!

[Image: S3CABr8.png]
Find all posts by this user
Quote this message in a reply
05-16-2016, 07:58 PM
Post: #3
RE: Outputting from notepad++ directly to hpemu48? (HP50g)
You could also try a couple of Notepad++ plugins: NppExec and RunMe.


-+×÷ ↔ left is right and right is wrong
Visit this user's website Find all posts by this user
Quote this message in a reply
05-17-2016, 11:54 PM (This post was last modified: 05-18-2016 01:38 AM by RPL Calcs.)
Post: #4
RE: Outputting from notepad++ directly to hpemu48? (HP50g)

To create/edit objects to the HP's 48/49/50 ...

I still prefer the HPUserEdit because it is both simple and quite complete. I use it to create libraries and to write code in System RPL, too.

It is a single package (editor & Emu48). It features tab of special characters, commands tab, etc. Just install and use.

To use simply edit the object in HPUserEdit and hit [F9] to run it or [Ctrl] + [E] to send it to the emulator.

You can also send emulator objects to HPUserEdit:
- put the object in level 1 of the stack;
- run the command -> STR;
- in the menu bar of the emulator, select the "Edit" menu and the "Copy Stack" option;
- Then paste (Ctrl + V) in the HPUserEdit window.

HPUserEdit 5 - (multiple languages)

HPUserEdit 6 - (Spanish)

Language file to translate HPUserEdit 6 from Spanish into English.

Best regards.

PS: I'm sorry for the errors of the electronic translation.

HPUserEdit image
Find all posts by this user
Quote this message in a reply
Post Reply 

User(s) browsing this thread: 1 Guest(s)