The following warnings occurred:
Warning [2] Undefined array key 60206 - 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 60235 - 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 60236 - 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 60242 - 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 60255 - 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 60325 - 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 60631 - 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 60255 - 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 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 array key 60325 - 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 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 array key 60631 - 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 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





HP48 - Motorola MC68HC08 SCI



#2

Hi,
how can i communicate my HP48GX with an Motorola HC908KX8 microprocessor by RS232 SCI?


#3

Hi Mauricio...

HC08s are nice little CPUs! :) Which variation are you using, how much ROM & RAM? What else does this CPU have to do beside communicate with the HP48?

I'm not an HP48 owner/user but have done a lot of serial comm work for other embedded widgets. I seem to recall the HP48 does (sometimes? always?) use a form of the Kermit transfer protocol for transfers. I'm not sure if 48 user programming can do byte-by-byte serial communications.

I also don't recall the HP48 bitrates/ parity/ stopbits anymore - or even if it configurable by a user program - but when I looked years ago I recall it was something standard.

The HP48 serial port, IIRC, is at a logic level (+5VDC, swinging down to 0V) -- whereas 'true' RS232 communication requires a level converter to deal with swings between +9 to +12VDC and -9 to -12VDC.

So you can connect the 'HC08 to the HP48 directly without an intervening level converter device (like Maxim's MAX232) if your 68HC08 is a 5 Volt CPU. A 3.3V 68HC08 CPU might be problematic but might work. Just set up your SCI port on the HC08 for the proper bitrate, parity, stop bits. Do not use hardware RTS/CTS handshaking.

If the 48 can only communicate using Kermit protocol, and if you're using a C compiler on the 08, you should be able to get Kermit open source code and 'trim the fat' (i.e, remove useless features') to keep code size down to what you can fit in your HC08.


Bill W

San Jose CA


#4

Quote:
The HP48 serial port, IIRC, is at a logic level (+5VDC, swinging down to 0V) -- whereas 'true' RS232 communication requires a level converter to deal with swings between +9 to +12VDC and -9 to -12VDC.

So you can connect the 'HC08 to the HP48 directly without an intervening level converter device (like Maxim's MAX232) if your 68HC08 is a 5 Volt CPU.


You might get away electrically with connecting it directly, but it won't work unless you bit-bang the UART rather than using the hardware UART. EIA-232 drivers and receivers are inverting, so if you connect it directly you'll have the wrong polarity.

I highly recommend using a MAX232 or one of the many equivalent parts. That way you can hook the device up to any EIA-232 devices without risking damage, and you have better ESD protection than using a port pin directly.

If you use some kind of evaluation board, it's likely that there's already a level converter present.


#5

Hi Eric...

All I was saying was _if_ the HP48 was running 5V serial w/o a MAX232 he could directly connect it to a 5V 'HC08, and that maybe a 3.3V HC08 could work too. No inversions, etc. required...

Bill W
San Jose


#6

Quote:
All I was saying was _if_ the HP48 was running 5V serial w/o a MAX232 he could directly connect it to a 5V 'HC08, and that maybe a 3.3V HC08 could work too. No inversions, etc. required...

But the inversion IS required, if you want to use the hardware UART. UARTs have logic levels that are high for space, low for mark. But EIA-232 (even the non-really-EIA-232 of the HP-48) is negative (or in the case of the HP-48, not very positive) for space, and positive (on the HP-48 more positive) for mark.

Example of the transmission of an uppercase letter "E"
(0x45):

+2V ____      ____      ____                ____      ____
TTL \____/ \____/ \____.____.____/ \____/
GND start LSB MSB stop
1 0 1 0 0 0 1 0

+V ____ ____ ____.____.____ ____
EIA ____/ \____/ \____/ \____/ \____
-V start LSB MSB stop
1 0 1 0 0 0 1 0

So if you hook up the HP-48 directly to the UART of a 5V 'HC08, it isn't going to break the 'HC08 (or the HP-48), but it also isn't going to work correctly.

If you implement a software (bit-banged) UART, you can obviously deal with the inversion in software.

#7

Not true! The HP48 does use "true" RS-232 voltage at +/-4.3V, even if they are not the 12V you're used to getting out of a PC's serial port. Quoting Preston Brown from the comp.sys.hp48 FAQ:

Quote:
The 48 has two power supplies VDD at 4.3 and VH at 8.5. VH cannot be regulated higher without exceeding the spec for our CMOS IC process. VH is used as the + voltage for the I/O. In order to meet a +3V output level VH must be more then 3.6V above VDD. (VDD is used as I/O ground). Our power supply system increase the battery life and reduces the cost greatly for the wired I/O.

#8

Quote:
The HP48 serial port, IIRC, is at a logic level (+5VDC,
swinging down to 0V)

You recall incorrectly. Maybe you were thinking of a Sharp model?

For transmitting, it's (minimum) +3.0V for a space and -3.0V for a
mark, and "typically" +3.5V and -3.5V.

For receiving, it's +1.0V to +15.0V for a space, and -15.0V to
-0.3V (Maybe this should be +0.3V, or even -0.03V or +0.03V?) for a mark.

The absolute maximums are listed as -25V to +25V.

Quote:
-- whereas 'true' RS232 communication
requires a level converter to deal with swings between +9 to
+12VDC and -9 to -12VDC.

Actually, if I recall correctly, RS-232 is supposed to transmit at
at +5.0V to +15.0V for space, and -15.0V to -5.0V for mark, and
receive at +3.0V to +25.0V for space, and -25.0V to -3.0V for mark.

So, although it doesn't fully comply with RS-232, it's generally
RS-232 compatible.

Information about the 48 series I/O is available at
http://www.hpcalc.org/details.php?id=1722 and
http://www.hpcalc.org/details.php?id=4741.

Quote:
If the 48 can only communicate using Kermit
protocol,

The 48 series can also use "raw" serial I/O. That is, without any
file transfer protocol; just sending and receiving strings with
the length limited only by available memory. That's what the XMIT
and SRECV commands are all about. Optionally, XON/XOFF software
flow control can be enabled for sending and/or receiving. The
input buffer is only 255 bytes and buffer overruns are quite
likely to occur if you try to receive longer strings without using
software flow control. A variety of parity/pseudo-parity options
are also available.

Actually, the printing commands (with flag -34 set, "Print via
wire") are a lot like XMIT, but decompile an object to a string
form before actually transmitting it from the I/O port.

The 48G series also has the Xmodem protocol built-in, and an
"Xmodem Server" library is included with the Conn4x package.

The built-in speeds on the 48 series are 1200, 2400, 4800, and
9600 bps.

But "Serial IR" is 2400 bps only, and is half-duplex instead of
full-duplex, so software flow control isn't available in this
mode.

The 49G series is similar to the 48G series for I/O via wire, but
IR isn't available, and XON/XOFF software flow control is broken
for both transmitting and receiving. The 49G has the Xmodem server
built-in, and has additional (non-standard) speeds of 1920, 3840,
7680, and 15360 bps built-in.

Regards,
James


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP Prime: Converting number to Sci notation and back BruceTTT 1 1,479 11-12-2013, 02:11 AM
Last Post: Phil Wipf
  Simplify with sci/eng on hp 50g Juraj O. 11 3,182 11-08-2012, 06:26 PM
Last Post: Han
  HP 25c Apps Review: GO 25 SCI, rpn 25 Eddie W. Shore 14 3,766 03-29-2011, 05:10 PM
Last Post: Andrés C. Rodríguez (Argentina)
  Why the resistance to make a true pocket Sci RPN calc Gerardo Rincon 10 2,474 11-15-2010, 01:20 AM
Last Post: Walter B
  Interesting Blog Post (Sci Am, Sept 77) Les Bell 1 936 04-04-2010, 12:19 AM
Last Post: Eric Smith
  Motorola NiMH Batteries Juan J 5 1,720 03-11-2009, 07:18 PM
Last Post: Juan J
  SCI-15C question. Pal G. 5 1,494 11-21-2008, 06:58 PM
Last Post: Eric Smith
  Typograpic issue in Urroz sci and eng hp 49g vol 2? Eric Smith 1 848 09-12-2008, 03:44 AM
Last Post: Gordon Strickland
  now... RPN on motorola!! R Lion (Spain) 4 1,267 05-26-2005, 10:24 PM
Last Post: Marx Pio
  Re: [OT] RPN Calc for Motorola mobile R Lion (Spain) 0 559 04-14-2005, 02:11 AM
Last Post: R Lion

Forum Jump: