The Museum of HP Calculators

HP Forum Archive 21

[ Return to Index | Top of Index ]

Somehow I can't get it to work
Message #1 Posted by Harald on 27 Feb 2012, 2:46 p.m.

I have connected everything and tried to flash the calculator now. I believe I successfully put it into bootload mode, but the samba tool tells me it is unable to flash. The Calculator RXD and TXD lines are both high. When clicking the "send file" button, I get a sequence of pulses on the RXD (coming from my RS232 com port).

70Ás low, 18Ás high, 70Ás low, 18Ás high, 8.5Ás low, 18Ás high, 25Ás low, 9.5Ás high, 18Ás low.

This is then followed by 18Ás low, 42Ás high, 18Ás low on the TXD. Sorry, can't upload a pic from here. Will add this later.

Any idea what's wrong?

Cheers, Harald

      
Re: Somehow I can't get it to work
Message #2 Posted by Marcus von Cube, Germany on 27 Feb 2012, 5:44 p.m.,
in response to message #1 by Harald

This seems to be an answer from the SAM-BA boot loader that is not recognized by your PC. What make of a serial adapter on your PC do you use?

The 9 Ás pulse is a single bit @ 110 kbit/s. Asynchronous serial communication is a start bit (low), 8 data bits, parity (optional) and at least one stop bit (high). Lets translate your sequence to data:

Quote:
70Ás low, 18Ás high, 70Ás low, 18Ás high, 8.5Ás low, 18Ás high, 25Ás low, 9.5Ás high, 18Ás low.

This is 0_0000_0001_1 0_0000_0001_1 0_1100_0100_1. The first two are 0x80s, the third is a 0x23 ('#').

The answer from the device is 18Ás low, 42Ás high, 18Ás low, which translates to 0_0111_1100_1 (slightly on the short side). The trouble is that the device isn't driven by a quartz. The boot loader tries to adjust the clock frequency to match the 110 kbit/s as closely as possible. The pattern reads 0x3e ('>') which is the supposed answer. The timing isn't correct and therefore the PC can't read it. Normally, the PC shall now repeat its request (0x80, 0x80, 0x23) and wait again for a new answer from the device at a slightly different rate.

All in all you can assume that your device is running the boot loader but the communication isn't working correctly.

            
Re: Somehow I can't get it to work
Message #3 Posted by Harald on 27 Feb 2012, 6:17 p.m.,
in response to message #2 by Marcus von Cube, Germany

Hi Marcus,

thanks again for the quick reply. I am not using an adaptor. This is a real com port on my laptop. The computer does repeate the sequnece several times, but only gets an answer once (or maybe twice). I have already fitted a quartz to the calculator, but I guess the bootloader uses the internal resonator anyway. Since I haven't got the HP cable yet, I used an adaptor I made for a TI controller years ago. Maybe that is responsible for the timing issuses as it is opto-isolated. I will try and bypass the optocouplers.

Thanks for your help, it is much appreciated.

Cheers, Harald

                  
Success!
Message #4 Posted by Harald on 28 Feb 2012, 5:28 a.m.,
in response to message #3 by Harald

You were right Marcus, it was a timing issue. Although I am not sure if the optocouplers were resposible or the max232. I now used an FTDI USB to RS485 converter. I connected TxD directly to the FTDI chip and RxD via a resistor divider to level shift down to 3V. The 34s is allive now!!!!

                        
Re: Success!
Message #5 Posted by Marcus von Cube, Germany on 28 Feb 2012, 10:30 a.m.,
in response to message #4 by Harald

Your hardware skills are far beyond mine. :-)

Edited: 28 Feb 2012, 10:30 a.m.

                              
Re: Success!
Message #6 Posted by Harald on 28 Feb 2012, 3:07 p.m.,
in response to message #5 by Marcus von Cube, Germany

Quote:
Your hardware skills are far beyond mine. :-)


Maybe. But your software skills are way beyond mine :-)

It is just amazing what you guys have achieved here!


[ Return to Index | Top of Index ]

Go back to the main exhibit hall