Post Reply 
Pre Release HP01 Running
07-13-2016, 12:14 PM
Post: #1
Pre Release HP01 Running
Hi all,

I have uploaded a HP-01 module to the emulators at teenix.org

It turned out to be a tricky device to get going and took some time to do as I didn't have anything to work with except the 4158285 patent document.

This watch/calculator is obviously a pre-release version as the code occupies 9 ROM pages except 8. A lot of vacant ROM space is also present which I imagine would represent an expensive waste if it went into production.

It also doesn't have the percent (%) key. I didn't notice this at first and it threw me as some of the code appeared to be flawed and I wasted a lot of time trying to re-model the code to get it to work.

Running simulations was a bit tricky too because the simulator had to deal with the module in sleep mode while still keeping the two timers active, one down to 100th of a second, plus still allow single stepping etc.

However, as far as I can tell it is working fully as described in the document including the hourly timer wakeups. It also has the original alarm sound.

The emulator exe file was modified to accept the new instructions and simulator functions for this model, so the new version cce33.zip will need to be downloaded to run the HP-01 module.

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-13-2016, 11:17 PM
Post: #2
RE: Pre Release HP01 Running
(07-13-2016 12:14 PM)teenix Wrote:  Hi all,

I have uploaded a HP-01 module to the emulators at teenix.org

It turned out to be a tricky device to get going and took some time to do as I didn't have anything to work with except the 4158285 patent document.

This watch/calculator is obviously a pre-release version as the code occupies 9 ROM pages except 8. A lot of vacant ROM space is also present which I imagine would represent an expensive waste if it went into production.

It also doesn't have the percent (%) key. I didn't notice this at first and it threw me as some of the code appeared to be flawed and I wasted a lot of time trying to re-model the code to get it to work.

Running simulations was a bit tricky too because the simulator had to deal with the module in sleep mode while still keeping the two timers active, one down to 100th of a second, plus still allow single stepping etc.

However, as far as I can tell it is working fully as described in the document including the hourly timer wakeups. It also has the original alarm sound.

The emulator exe file was modified to accept the new instructions and simulator functions for this model, so the new version cce33.zip will need to be downloaded to run the HP-01 module.

cheers

Tony

Congratulations! Now you are the second person ever, who knows how tricky a HP-01 Emulator really is. Did you try dynamic calculations? Smile

Bernhard

That's one small step for a man - one giant leap for mankind.
Find all posts by this user
Quote this message in a reply
07-14-2016, 01:06 AM
Post: #3
RE: Pre Release HP01 Running
(07-13-2016 11:17 PM)PANAMATIK Wrote:  Congratulations! Now you are the second person ever, who knows how tricky a HP-01 Emulator really is. Did you try dynamic calculations? Smile

Bernhard

Hi Bernhard,

No, I missed that one. That functioning is very vague at times in the patent document. I wondered why the ENSCWP instruction never executed. Now I know.

I have the logic already in place, so I will work on it when I get some time. My boss is putting me through a first aid course for some obscure reason so I will be out of action for a bit.

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-14-2016, 01:58 AM
Post: #4
RE: Pre Release HP01 Running
(07-13-2016 11:17 PM)PANAMATIK Wrote:  Congratulations! Now you are the second person ever, who knows how tricky a HP-01 Emulator really is. Did you try dynamic calculations? Smile

Bernhard

Amazing...

I turned on the "switch" to allow the ENSCWP instructions to execute and hey presto it worked. The calculations auto update every second and the total is displayed with the equals key at the end.

I forgot to mention, I couldn't find a manual to make available for this watch/calculator, but if anyone wants one, the HP Museum has them available on CD.

I posted a new cce33.zip - v140716

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-14-2016, 03:25 AM
Post: #5
RE: Pre Release HP01 Running
The watch image I had was a bit rushed and didn't look the part so I have uploaded a more elegant version.

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-14-2016, 07:56 AM (This post was last modified: 07-14-2016 08:26 AM by fhub.)
Post: #6
RE: Pre Release HP01 Running
Hi,

I have a question: is it possible to switch off the auto-power-off for the HP01 emulator?

Of course this function makes sense for the real HP01, but for the PC emulator it's quite annoying when the display goes off every few seonds.

PS: and one more question: couldn't it be done that the emulator uses the date & time from the PC clock?

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-14-2016, 09:29 AM
Post: #7
RE: Pre Release HP01 Running
(07-14-2016 07:56 AM)fhub Wrote:  Hi,

I have a question: is it possible to switch off the auto-power-off for the HP01 emulator?

Of course this function makes sense for the real HP01, but for the PC emulator it's quite annoying when the display goes off every few seonds.

PS: and one more question: couldn't it be done that the emulator uses the date & time from the PC clock?

Franz

Hi Franz,

Yes on both questions, but there is always a "however" Smile

On start up the time is not transferred to the display register until the [T] button is pressed. You can see this if you open the simulator before pressing any calculator keys. So if the display is on at this stage, it will just show [0].

I suppose I can "force" a [T] button press at start up if an [Auto Display ON] option is active.

I have the PC time option in mind already. I don't want to sync the PC all the time, but just initialise the time/date register on start up if an option is set. The emulator has an instruction time trimmer function anyway, so the timing can be adjusted.

I am hemmed in with work at the moment, but will address it when I can.

Maybe your PC CMOS battery will go flat if the display is left on tho ;-)

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-14-2016, 09:56 AM
Post: #8
RE: Pre Release HP01 Running
Hi Tony!
(07-14-2016 09:29 AM)teenix Wrote:  I don't want to sync the PC all the time, but just initialise the time/date register on start up if an option is set.

Yes, that's exactly how I would do it, too.

Quote:Maybe your PC CMOS battery will go flat if the display is left on tho ;-)

LOL, maybe then I should replace the CMOS battery in my PC with my 50Ah car battery? Big Grin

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-14-2016, 10:50 AM
Post: #9
RE: Pre Release HP01 Running
Wow Tony!

It is really amazing how much you have achieved. I continue to be amazed!

Cheers,
Harald
Find all posts by this user
Quote this message in a reply
07-14-2016, 01:12 PM
Post: #10
RE: Pre Release HP01 Running
(07-14-2016 07:56 AM)fhub Wrote:  Hi,

I have a question: is it possible to switch off the auto-power-off for the HP01 emulator?

Of course this function makes sense for the real HP01, but for the PC emulator it's quite annoying when the display goes off every few seonds.

PS: and one more question: couldn't it be done that the emulator uses the date & time from the PC clock?

Franz

I found some free time, and it didn't take long.

You can now set an option to have the display on all the time and also another option to load the time and date from the PC when the emulator starts in HP01 mode. These options are available when right clicking the calculator.

See: Menu -> Options -> HP-01 Display

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-14-2016, 02:43 PM
Post: #11
RE: Pre Release HP01 Running
(07-14-2016 01:12 PM)teenix Wrote:  You can now set an option to have the display on all the time and also another option to load the time and date from the PC when the emulator starts in HP01 mode.

WOW, you're really amazing, many thanks!

Now only one thing is missing: the watch should be in 3D, so that I could take it from the screen and strip it on my wrist. Wink

But seriously again: remembering the format options for date&time (settable with [delta][.]) would be great (but only if it's easy to implement).

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-15-2016, 12:26 AM
Post: #12
RE: Pre Release HP01 Running
(07-14-2016 02:43 PM)fhub Wrote:  Now only one thing is missing: the watch should be in 3D, so that I could take it from the screen and strip it on my wrist. Wink

But seriously again: remembering the format options for date&time (settable with [delta][.]) would be great (but only if it's easy to implement).

Franz

I'm sure someone will make an iWatch or similar App for it one day.

The emulator will now generate an ini file for the HP01 and load it when the watch runs again and should continue from where it left off

New upload available

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-15-2016, 06:11 AM
Post: #13
RE: Pre Release HP01 Running
(07-14-2016 02:43 PM)fhub Wrote:  Now only one thing is missing: the watch should be in 3D, so that I could take it from the screen and strip it on my wrist. Wink

Just strap your PC to your wrist. It's not much bigger than an HP-01, which I've heard described as "a doorjamb detector". Smile

<0|ΙΈ|0>
-Joe-
Visit this user's website Find all posts by this user
Quote this message in a reply
07-15-2016, 09:24 AM (This post was last modified: 07-15-2016 09:25 AM by fhub.)
Post: #14
RE: Pre Release HP01 Running
(07-15-2016 12:26 AM)teenix Wrote:  The emulator will now generate an ini file for the HP01 and load it when the watch runs again and should continue from where it left off

Thanks, now it's perfect! Smile

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-15-2016, 07:55 PM (This post was last modified: 07-15-2016 07:56 PM by fhub.)
Post: #15
RE: Pre Release HP01 Running
(07-15-2016 09:24 AM)fhub Wrote:  
(07-15-2016 12:26 AM)teenix Wrote:  The emulator will now generate an ini file for the HP01 and load it when the watch runs again and should continue from where it left off
Thanks, now it's perfect! Smile

I've just found a small problem with the new ini file:
If you close the program with the clock displayed, and start it again later, then only the minutes and seconds are updated, the hour is still showing the old value (when leaving the program).

Example:
Closing the program at 16:25:10 and restarting it again at 21:42:35, the clock shows 16:42:35 (instead of 20:42:35) - only after clicking [T] it's correctly updated again.

And the same is true for the date display: the date is not updated at all, if you start the program again e.g. a few days later.

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-17-2016, 04:25 AM
Post: #16
RE: Pre Release HP01 Running
(07-15-2016 06:11 AM)Joe Horn Wrote:  
(07-14-2016 02:43 PM)fhub Wrote:  Now only one thing is missing: the watch should be in 3D, so that I could take it from the screen and strip it on my wrist. Wink

Just strap your PC to your wrist. It's not much bigger than an HP-01, which I've heard described as "a doorjamb detector". Smile

Oh, Joe, you tease. You *know* PCs have gotten smaller since the old Tower sized ones...
Find all posts by this user
Quote this message in a reply
07-17-2016, 05:18 AM
Post: #17
RE: Pre Release HP01 Running
(07-15-2016 07:55 PM)fhub Wrote:  I've just found a small problem with the new ini file:
If you close the program with the clock displayed, and start it again later, then only the minutes and seconds are updated, the hour is still showing the old value (when leaving the program).

Example:
Closing the program at 16:25:10 and restarting it again at 21:42:35, the clock shows 16:42:35 (instead of 20:42:35) - only after clicking [T] it's correctly updated again.

And the same is true for the date display: the date is not updated at all, if you start the program again e.g. a few days later.

Franz

Hi Franz,

Sorry for the delay, I have been at work, but knew of the problem.

It is caused by the watch not knowing that a date or time has actually changed on start up. I had to compromise a bit and simulate a [T] key press on start up if a valid HP01.ini file is found. That way the microcode can update its registers with the present time/date values as set by the PC. The 12/24 hour mode etc should still be set as previous.

It seems ok as far as I can tell.

A new download is available.

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-17-2016, 08:26 AM
Post: #18
RE: Pre Release HP01 Running
(07-17-2016 05:18 AM)teenix Wrote:  A new download is available.

Thanks, Tony!

In the meantime I've found 2 other problems:
1) in your HP-01 version the clock is running much too slow!
I've compared it with PANAMATIK's emulator (both running side by side), and already after 1-2 minutes your emulation is a few seconds behind!?

2) I know that this HP-01 prerelease/prototype version is a bit different to the official version, but I guess there's something wrong with the "a" key on your emulator. I don't know exactly what this "a" should do on the prototype version, but in your emulator it is the same as "C" (i.e. clears the display) - in PANAMATIK's version it behaves differently.
And with the integrated debugger in your version I see that this "a" key produces exactly the same keycode as "C" - I doubt that this is intention!?

Regards,
Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
07-17-2016, 10:44 AM
Post: #19
RE: Pre Release HP01 Running
(07-17-2016 08:26 AM)fhub Wrote:  Thanks, Tony!

In the meantime I've found 2 other problems:
1) in your HP-01 version the clock is running much too slow!
I've compared it with PANAMATIK's emulator (both running side by side), and already after 1-2 minutes your emulation is a few seconds behind!?

2) I know that this HP-01 prerelease/prototype version is a bit different to the official version, but I guess there's something wrong with the "a" key on your emulator. I don't know exactly what this "a" should do on the prototype version, but in your emulator it is the same as "C" (i.e. clears the display) - in PANAMATIK's version it behaves differently.
And with the integrated debugger in your version I see that this "a" key produces exactly the same keycode as "C" - I doubt that this is intention!?

Regards,
Franz

1) If you look in the menu you can see an option [Fine tune timer] This will adjust the timer for the processor execution loop and therefore the time updates. A bit like using the crystal trimmer on the watch circuit board. It will never be perfect, but neither was the actual watch. The time will always drift slightly. It will sync to the PC time on start up.

2) Oops, I must have left a test value there in the keyboard lookup table. I have fixed the key code value.

The 'a' key sets the time or alarm to [am] if it is in the default 12 hour mode of operation.

New download ready.

cheers

Tony
Find all posts by this user
Quote this message in a reply
07-17-2016, 11:09 AM (This post was last modified: 07-17-2016 11:57 AM by fhub.)
Post: #20
RE: Pre Release HP01 Running
(07-17-2016 10:44 AM)teenix Wrote:  1) If you look in the menu you can see an option [Fine tune timer] This will adjust the timer for the processor execution loop and therefore the time updates. A bit like using the crystal trimmer on the watch circuit board. It will never be perfect, but neither was the actual watch. The time will always drift slightly. It will sync to the PC time on start up.

Well, of course I've seen this option, but without showing a scale with any values such a slider is almost useless - how many trials would be needed to adjust the speed to be (almost) exact?
And moreover, is this fine tune setting stored in the cce33.ini or hp01.ini?
If not then you would have to set it again and again ...

Quote:The 'a' key sets the time or alarm to [am] if it is in the default 12 hour mode of operation.

Ok, the manual of the official release describes it in the same way, but nevertheless it sounds a bit strange to me: why waste one key (or even two keys in the prerelease version) for am/pm, when you can simply enter the time in both formats (e.g. 4:15 or 16:15)?
So I still don't really understand the benefit of these keys. And BTW, when the stopwatch is running, both keys ("a" and "p") seem to have any other function, but I haven't yet found out what it is - it looks like some kind of 'pause', but showing a different display value. Very mysterious ...

Franz
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




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