How to get HP 48G to talk to MacOS X?



#2

I recently acquired an HP48G calculator, and my current obession is to get it to communicate with my beige Power Macintosh G3, which is running MacOS X 10.2.8.

To this end, I have built a cable.

I've connected this calculator to my wife's Windows 2000 system using the cable that I have built, and installed this software on my wife's computer, and verified that this works.

I've then connected the calculator to my Macintosh, to which I have downloaded and installed this software, which only works under MacOS 9 or lower, and verified that this works. So my cable is good, and my whole hardware setup is good.

So, what do I need to do to communicate with this calculator from MacOS X? I understand that this calculator wants to use the Kermit protocol, or alternatively, XMODEM. I'm an old fossil back from the days before mere mortals had access to the Internet, when geeks like myself communicated and exchanged software via standalone BBSes which we would dial directly into with our modems; so I have some basic familiarity with using a terminal program, and with protocols like Xmodem and Kermit.

I tried using ZTerm to talk to my HP48G, to no avail. It seemed obvious enough how to configure the HP48G and to configure ZTerm so that they should each be trying to speak the same protocols at the same speeds and everything, but try as I might, I could not get either ZTerm or the calculator to respond to anything done at the other.

Thinking there may be some problem inherent in ZTerm, I downloaded, compiled, and installed C-Kermit and tried using it. I got the same results as with ZTerm, which is to say, no results at all. (BTW, the answer to the trouble that the guy at the end of this thread had getting it to work seems to be that for whatever reason, C-Kermit needs to have root access in order to talk to the serial port. Don't ask me why. If I run it directly, it doesn't have permission to talk to /dev/cu.printer but it seems to work that far if I run it via sudo.)

So, I seem to have the hardware connection straight, and I've got two different pieces of software that should be able to speak Kermit. What am I missing? What do I need to do on each side of the connection to get the two sides to talk to each other?


Edited: 24 Mar 2007, 8:45 a.m. after one or more responses were posted


#3

Quote:
...but try as I might, I could not get either ZTerm or the calculator to respond to anything done at the other.
Actually, this isn't completely true. If I type rapidly into ZTerm, I can see a little arrow-shaped icon flickering near the upper right corner on the calculator's display.

Also, if I run the serial loopback test on the calculator (On-D then PRG), ZTerm receives the following string: "AAAAAU_LB 20000" (The "U_LB 20000" also being displayed on the calculator, a code indicating the test failed (which is to be expected because there isn't a loopback connection)).

Edited: 24 Mar 2007, 10:58 a.m.

#4

To get Kermit to work between my PC and my HP-48G under Linux, I downloaded and compiled C-Kermit, and I use the following settings in my .kermrc file:

    set modem type none
set line /dev/ttyUSB0
set carrier-watch off
set speed 9600
set parity none
set flow xon/xoff
set block-check 3
set transfer mode manual
set file type binary
set control prefix all

I expect you'll need something different for the "set line" command (don't be confused by the ttyUSB0 in my .kermrc: it looks that way because I'm using a USB-to-serial adapter). Most of the other settings are fairly obvious, except the "set control prefix all", which I finally found out about thanks to some helpful people on this forum.


BTW, you shouldn't have to be root to run Kermit; you can also just change the permissions on the serial port to allow read and write access for everyone: chmod 666 /dev/cu.printer -- or, make the kermit executable setuid root (not recommended).

When it comes to using Xmodem, you need to install an Xmodem server on the 48G; in my case, I use the misleadingly-named HP48GII and HP49G+ PC Connectivity Kit (which supports the 48G just fine); it includes a nice Windows-based Explorer-like GUI for browsing files and directories on the calculator, and it includes the Xmodem server, which it will even install for you (it walks you through the commands you have to execute on the calculator for the upload -- very painless). The GUI won't do you any good on the Mac, but you may need the Xmodem server in case your Mac-based connectivity package doesn't already include one.

- Thomas


#5

Quote:
To get Kermit to work between my PC and my HP-48G under Linux, I downloaded and compiled C-Kermit, and I use the following settings in my .kermrc file:

    set modem type none
set line /dev/ttyUSB0
set carrier-watch off
set speed 9600
set parity none
set flow xon/xoff
set block-check 3
set transfer mode manual
set file type binary
set control prefix all

I expect you'll need something different for the "set line" command...


On my system, the two serial ports (mine was the very last desktop Macintosh model to have built-in serial ports) are /dev/cu.modem and /dev/cu.printer. As I have an actual modem connected to cu.modem, I'm using cu.printer for my HP48G.

OK, now I seem to be getting somewhere. With these settings, I can now send files to the HP48G. I can also do a directory, that shows what the HP48G has at its root directory. I can't seem to CD on the HP48G, nor can I receive files, or do anything else, though.

And with similar settings, I can now also get ZTerm to send files to the HP48G as well; but I can't seem to interact with it in any other way.

All this is with the HP48G set to be in server mode.

On further experiementation, I see that if I type "connect" into kermit, and then go to the TRANSFER menu on the HP48G, I can send files from the HP48G to my Macintosh. But If I try to transfer "Remote Files from PC", I get error messages on both sides. I guess each side agrees on how to send a file from whatever side is being manually operated, but not on how to tell the side that is acting as a server what files to send.


Quote:
BTW, you shouldn't have to be root to run Kermit; you can also just change the permissions on the serial port to allow read and write access for everyone: chmod 666 /dev/cu.printer -- or, make the kermit executable setuid root (not recommended).

No, I shouldn't. Other programs don't have this problem, but for some reason, kermit does.

0 [24 Mar 2007 13:52:02 Bob:/tmp] bob% kermit
/var/spool/lock: Permission denied
?SET SPEED has no effect without prior SET LINE
C-Kermit 8.0.211, 10 Apr 2004, for Mac OS X
Copyright (C) 1985, 2004,
Trustees of Columbia University in the City of New York.
Type ? or HELP for help.
(/tmp/) C-Kermit>set line /dev/cu.printer
/var/spool/lock: Permission denied
Sorry, write access to UUCP lockfile directory denied.

*************************
HINT (Use SET HINTS OFF to suppress future hints):
Please read the installation instructions file, ckuins.txt,
or the UNIX appendix of the manual, "Using C-Kermit"
or visit http://www.columbia.edu/kermit/ckuins.html
*************************

(/tmp/) C-Kermit>exit
0 [24 Mar 2007 13:52:19 Bob:/tmp] bob% sudo kermit
Password:
C-Kermit 8.0.211, 10 Apr 2004, for Mac OS X
Copyright (C) 1985, 2004,
Trustees of Columbia University in the City of New York.
Type ? or HELP for help.
(/tmp/) C-Kermit>set line /dev/cu.printer
(/tmp/) C-Kermit>exit
Closing /dev/cu.printer...OK
0 [24 Mar 2007 13:52:37 Bob:/tmp] bob% ls -alg /dev/cu*
crw-rw-rw- 1 root wheel 8, 3 Mar 24 03:16 /dev/cu.modem
crw-rw-rw- 1 root wheel 8, 1 Mar 24 13:51 /dev/cu.printer
0 [24 Mar 2007 13:52:57 Bob:/tmp] bob%

I see now that it's complaining about not having permission to write to /var/spool/lock. Setting permissions on that directory to allow writing to it seems to solve that problem.

Quote:
When it comes to using Xmodem, you need to install an Xmodem server on the 48G; in my case, I use the misleadingly-named HP48GII and HP49G+ PC Connectivity Kit (which supports the 48G just fine)

It's not evident that that will help me.

Anyway, I seem to be making progress. There's still obviously quite a bit that I don't yet quite get. Any additonal guidance would be appreciated.


#6

Quote:
Quote:
When it comes to using Xmodem, you need to install an Xmodem server on the 48G; in my case, I use the misleadingly-named HP48GII and HP49G+ PC Connectivity Kit (which supports the 48G just fine)

It's not evident that that will help me.


Perhaps not, but installing the Xmodem server on the calculator means that you'll be able to do server-mode Xmodem transfers, which is presumably a bit less error-prone than manual transfers. I can't give advice on Xmodem beyond this, since I use Conn4x on the Windows side, meaning I never issue any Xmodem commands at all, it's all automated by this nice GUI.

As far as your Kermit problems are concerned, you may find this page -- straight from the horse's mouth -- helpful: http://www.columbia.edu/kermit/hp48.html.

Best of luck,

- Thomas


Possibly Related Threads…
Thread Author Replies Views Last Post
  An amazing day: Giving a talk at HP about their calculators Geir Isene 9 4,648 12-16-2013, 06:14 PM
Last Post: aurelio
  TED Talk: Adam Spencer: Why I fell in love with monster prime numbers Les Bell 3 1,777 09-05-2013, 12:54 PM
Last Post: Ken Shaw
  Riemann's Zeta Function update (HP-28S, HP-48G/GX/G+, HP-49G/G+/50g) Gerson W. Barbosa 0 1,095 06-30-2013, 01:01 AM
Last Post: Gerson W. Barbosa
  OT: DIFFERENTIAL EQUATIONS using the HP-48G/GX Ivan Rancati 2 1,420 06-04-2013, 04:11 AM
Last Post: Frank Boehm (Germany)
  Able to set HP 48G axis tick marks at integers? Randal B 1 1,100 01-24-2013, 12:40 AM
Last Post: Chris Dreher
  HP 48G -- entering more than one equation into the PLOT application Randal B 1 1,107 01-24-2013, 12:25 AM
Last Post: Chris Dreher
  HP 48G series -> 20 years NACHO 0 962 12-13-2012, 09:40 AM
Last Post: Nacho
  hp clock does not talk to hp 71 Hans Holzach 15 4,133 07-29-2012, 04:13 PM
Last Post: Hans Holzach
  ROOT bug? HP 48S/48G Eddie W. Shore 8 3,986 07-13-2012, 07:05 PM
Last Post: Eddie W. Shore
  RPL prog for Fibonacci on HP 48G needs minor modification. help. wildpig 68 17,173 07-09-2012, 09:38 AM
Last Post: Gilles Carpentier

Forum Jump: