The following warnings occurred:
Warning [2] Undefined array key 18527 - 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 18542 - 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 18542 - 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 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





Make a text file in HP-9114B, and teach me the method which does reading and writing.



#3

*** Machine composition ***
COMPUTER HP-71B (HP-BASIC)
STORAGE HP-9114B Disc Drive (HP-IL device #1)

*** Background ***
I tried to do a text file by using 71B.
The following program was made by using the standard basic command as the first trial.

10 ! SAMPLE PROGRAM #1 FOR HP-71B
20 INITIALIZE :1
30 CREATE TEXT "SAMPLE:1",5000
40 ASSIGN #1 TO SAMPLE:1
50 INPUT "SAMPLE DATA=";D$
60 IF D$ = "" THEN 90
70 PRINT #1;D$
80 GOTO 50
90 END

This program is a bad program obviously.
I find many problems that it should be improved in this program.
For example.
(1) I make a little file first, and I should add it if necessary.
(2) Before writing it in to the file, I should check the condition of the file.
(3) If all writing is completed, I should close a file.

I improve a program, and want to try to deal with it in accordance with the following process.

Step1 It is checked whether a text file "SAMPLE" has already existed.
Step2 It is deleted if a text file "SAMPLE" exists.
Step3 It is checked whether the free capacity of the floppy disk is sufficient.
Step4 It is finished if it is short of the free capacity of the floppy disk.
Step5 A text file "SAMPLE" is made in the little capacity.
<Step6 The beginning of the writing loop of the data>
Step6-1 The rest of the text files "SAMPLE" of the capacity are checked.
Step6-2 File capacity is added if it is short of the capacity of the text file "SAMPLE".
Step6-3 Data are written in the text file "SAMPLE".
<Step6 The end of the writing loop of the data>
Step7 A text file "SAMPLE" is closed.

But, as for the standard command obviously, it is short of the function.
I must know how to control 9114B directly with a HP-IL command.
I couldn't know the information to control 9114B carefully though I read a manual.

*** Please teach me! ***

Won't you put up the short two sample program which becomes anyone, a hint?

Sample1 The writing sample program which followed the above process.

Sample2 The sample program which reads a text file.


#4

look on page 251 of the HP71 Owner's manual - if you do not have it you can get on CDROM from the HP Museum.

There you will find a program similar to the one you are trying to make. Note that *your* program does not close the file, you need to execute

ASSIGN #1 TO *
to close a file.

Also you are essentially hardwiring into the program the position of the floppy drive in the HP-IL. It is better to use the command

ASSIGNIO ":FD"
to associate the
:FD
name with the floppy and then access the file as
SAMPLE:FD

It will also be helpful if you try to explain what you want to do with the program, maybe using text files is not the best way.

**vp


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to copy files from 9114B to hard drive via PIL-box? Joe Horn 23 10,048 12-14-2013, 11:57 PM
Last Post: Geoff Quickfall
  HP50g: Writing a function that returns a function Chris de Castro 2 2,070 12-10-2013, 06:49 PM
Last Post: Han
  Writing RPL programs on OS X Sean Freeman 18 5,061 11-30-2013, 03:59 PM
Last Post: Sean Freeman
  A fast Bernoulli Number method for the HP Prime Namir 16 5,382 11-22-2013, 04:46 PM
Last Post: Namir
  Cannot delete file Les Koller 4 1,998 11-07-2013, 12:17 AM
Last Post: Les Koller
  [HP-Prime] - Shortcuts for program writing Jean-Michel 4 1,892 11-01-2013, 07:55 AM
Last Post: Jean-Michel
  File Format: hpprgm Thomas Chrapkiewicz 6 2,572 10-30-2013, 09:32 PM
Last Post: Thomas Chrapkiewicz
  Prime 'CONTENT' section not retaining info text Geoff Quickfall 2 1,331 10-17-2013, 05:24 PM
Last Post: Geoff Quickfall
  HP-Prime File extension Paul D. Fox 6 2,191 10-07-2013, 01:45 AM
Last Post: cyrille de Brébisson
  A brand new calculator benchmark: "middle square method seed test" Pier Aiello 25 6,787 09-13-2013, 01:58 PM
Last Post: Pier Aiello

Forum Jump: