The following warnings occurred:
Warning [2] Undefined array key 246054 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 246055 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 246298 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 246306 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $thread - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $fid - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 246306 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $lang - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Attempt to read property "messages_in_thread" on null - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks





wp34s library tool



#5

How do I compile a program and put it into emulator?

When I create wp34s.dat and put it into the AppData\Roaming\WP-34s directory, the emulator complans that the file has to be 2048 bytes when it is 512. I thought it has something to do with the 'state' vs 'flash' subformats and try several combinations of -conv -flash and -state options to convert it, too numerous to list them here, but all unsuccessful.

What is the exact command line that would allow me to read a file that was created by the wp34s_asm.pl into format that emulator will understand?


#6

Andrew, its a bit more complicated then I'd like but it is Neil's tool and he decided to do it the way it is now.

To update the wp34s-lib.dat file use the following syntax:

wp34s_lib.pl your_source.wp34s ... -ilib wp34s-lib.dat -olib wp34s-lib.dat

Multiple source files are possible. The program will be merged into the existing library. Without -ilib libfile the library would be created from scratch. If I read the manual correctly -olib libfile can be replaced by -f (force overwrite). -olib newlib can be used to leave the original untouched and create a new lib instead.

To update the state file instead use the same syntax but add the -state switch and name the state file in -ilib and -olib. You cannot create a valid state file from scratch, you'll need one created by the emulator.

The manual Neil wrote is worth a read!

It's easiest to create a program with Neil's tools, add it to a library (or state file), debug it on the emulator and then send it to the device with the I/O commands.


#7

Marcus, thank you.

Quote:
You cannot create a valid state file from scratch, you'll need one created by the emulator.

This is the critical piece I was missing. The manual uses different wording that made me think that I need to create the clean state file with the tool and then update it (rather than specifying new name).

The command line I was after is:

perl %TOOLS%\wp34s_lib.pl temporary.wp34s -ilib %MEMFILE% -state -olib %MEMFILE%
%MEMFILE% points to location of emulators's .dat. I saved clean version of it into separate file and to intialize, just copy it over.

-state switch must be present

#8

If I understand the manual correctly, -olib %MEMFILE% can be replaced by -f (no further argument).

A few words why the state file must be created by the emulator: As of version 3, the size and location of various data such as registers and user code are no longer fixed but variable. The emulator puts pointers in fixed locations so that the assembler can find the area where to insert its output. The assembler has no chance to create a valid file from scratch. In V2 this was much easier because the program code was in a fixed location (first KB of memory) and the emulator just accepted such a short file and added the missing data. No chance to do the same in the current version.


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP Prime - definitely no education tool bluesun08 5 1,898 11-17-2013, 11:35 AM
Last Post: Alberto Candel
  "HexZombie - a tool for real programmers" Thomas Chrapkiewicz 8 2,752 11-16-2013, 12:46 AM
Last Post: Kiyoshi Akima
  Library#4 Modules mass-update and New Overlays Ángel Martin 0 1,201 11-09-2013, 05:55 AM
Last Post: 'Angel Martin
  [HP Prime] Constants Library Values Timothy Roche 24 7,054 11-02-2013, 04:17 PM
Last Post: Les Koller
  [HP-Prime CAS] Vector Calculus Library CompSystems 7 2,635 10-31-2013, 12:48 PM
Last Post: Han
  Equation Library/App for the Prime Harold A Climer 3 1,667 10-30-2013, 10:14 AM
Last Post: CompSystems
  Equation Library on the PRIME Harold A Climer 0 1,022 10-26-2013, 10:01 AM
Last Post: Harold A Climer
  CASplus Library for HP-Prime CompSystems 1 1,176 10-05-2013, 12:44 AM
Last Post: CompSystems
  The Rich HP Calculator Library Eddie W. Shore 0 845 09-27-2013, 10:19 PM
Last Post: Eddie W. Shore
  So, latest 41CL / Library 4 config is... Gene Wright 4 1,929 09-22-2013, 02:59 AM
Last Post: Ángel Martin

Forum Jump: