Order Tray | Contact Us | Home | SIG Lists

[wxsig] Programming/Communicaton Problems

Will Beals will at beals5.com
Sun Mar 26 04:40:41 UTC 2006


There are two issues with giving the CPU a clean reset, making sure VCC goes
to ground and that Vtst is available at the rising edge of reset.

I reset by removing power and letting the CPUs internal reset to its job.
As I recall, this is what you need to do in order to make sure you get in
into debug mode correctly.  Problem is I need a clean Vtst (+9V) available
at the rise of VCC.  The Max232 doesn't get to +9V very fast, so if I were
to raise VCC to both the CPU and Max232 at the same time, Vtst would not yet
be at the right voltage.  My solution was to leave VCC to the Max232 on all
the time and just remove power to the CPU.  With other circuitry still
powered on the board, I ran into a back-basing problem where some of the IO
was supplying VCC through the internal protection diodes.  The solution you
see on the T238s is that when I press the reset button to remove power, I
also "short" the CPUs VCC to ground via a 10 ohm resistor to make sure it
really goes to ground.

The purpose of the LED flash is to give signs of basic life, so if it isn't
flashing something pretty basic isn't right.  Pretty much all you need is
VCC, reset, IRQ, clock, and good code.  Having a scope should make it pretty
easy to check everything but the code.  If all the hardware checks out OK
then all that is left is the code.  The P&E tools should be able to verify
that pretty easily.  If you are trying to come up in debug mode, then you
also need to make really sure all of the port C and Port A bits are in the
right state on power-up too.


-----Original Message-----
From: David [mailto:skyhammer at gmail.com] 
Sent: Friday, March 24, 2006 9:09 AM
To: will at beals5.com; TAPR Weather Station SIG Mailing List
Subject: Re: [wxsig] Programming/Communicaton Problems

Hi Will,

Thank you for your helpful suggestions.  I ordered the 9.8304MHz oscillator
from DigiKey, rigged up a little board with some jumpers, and inserted it as
per the original T238 schematic.  It isn't pretty, but it did the trick, and
I successfully programmed the CPU...or at least I think I have.

You mentioned about performing a "clean reset" to the CPU;  I tied the IRQ
pin of the CPU to pin 2 of the MAX232 (V+), is this OK?

I'm still having some other problems though.  In particular, the LED does
not flash, and I have no display.  I'm fairly certain I've eliminated all
the usual suspects:  solder bridges, broken traces, component polarity, etc.
I have also checked the clock, and have verified this with a 'scope and
checked the output pin (pin 4) of the CPU too.  Since there is not much else
between the CPU and the LED itself, I was wondering if I had indeed
programmed the CPU correctly; I don't know if the software will have any
direct effect of the LED or not, so I was hoping you might have some
thoughts on this.  At the moment, the LED's state is always on, and there's
about 2V supplying it.  If I connect a 'scope to pin 21, there doesn't
appear to be any pulsing, as one might expect.

Thanks again,


Will Beals wrote:
> David:
> Cool on building your own board.  To get the P&E tools working, you 
> need remarkably little external support.  To get it to work, you need 
> to ensure that your board is following all of the requirements in 
> Section 15 of the
> MC69HC908GP32 Technical data manual.  In there is the schematic of all 
> the hardware needed which I (mostly) copied in the T238.  The only 
> place I really strayed from their suggested schematic was replacing 
> the 74HC128 IC with a single schotkey diode (kind of proud of this 
> myself).  Of particular note, make sure all the pullup and pulldown 
> resistors on Port A bits 0 and 7, and Port C bits 0, 1, and 3.  I have 
> pullups and pulldowns on there to get the chip to boot into the right 
> state for P&E tools if the CPUs IRQ line is pulled high to Vtst (I get 
> Vtst from the MAX232).  Other than that, all you should need is +5V and
the 9.???MHz clock.
> Finally, make sure you issue a clean reset to the CPU.  That is harder 
> than you think.  If you are tying IRQ to VTST, you end up 
> back-powering the CPU through Vtst.  My solution was to have the RESET 
> button actuall actively pull VCC to the CPU down through a 10 ohm
> That should really do it.  I'm hoping you missed one of those 
> resistors I had in the T238 thinking it was for another purpose or 
> something.  If you are still having trouble, let me know.
> will
> -----Original Message-----
> From: wxsig-bounces at lists.tapr.org 
> [mailto:wxsig-bounces at lists.tapr.org] On Behalf Of John Koster
> Sent: Monday, March 20, 2006 11:47 PM
> To: TAPR Weather Station SIG Mailing List
> Subject: Re: [wxsig] Programming/Communicaton Problems
> OK, now it makes sense.  You would have been better served to have 
> followed the classic T238 schematic.  All the pieces would have been 
> in place to program your MCU from scratch.  That's the platform used 
> to program the chips we put in the T238+ kits.
> I'm sure Will can chime in here later to give you better advise.  
> --
> 73,
> John, W9DDD
> On Tue, 21 Mar 2006, David wrote:
>> Hi John,
>> I am building the board from scratch, so my PCB layout for the traces 
>> are not the same.  However, the general layout of the components are.
>> Since I do not have a pre-programmed MCU, I need to program it 
>> myself, presumably using the P&E toolset.  I have downloaded the 
>> latest software
>> (1.15.8) from http://www.beals5.com/wx/ - This is also the same place 
>> that I downloaded the manuals, schematics, etc., from.  The bottom of 
>> the assembly manual states:  T-238+ Assembly Manual, Rev. 2.1 
>> November 2005, and the operations manual states:  T-238+ Operations
Manual, Rev.
>> 2 April 2005.
>> Software development would be something I'd consider in the future, 
>> but for the time being, I'd just like to program the MCU without 
>> having to buy a programmer.
>> Many thanks,
>> David - VA7DMS
>> John Koster wrote:
>>> Are you trying to do software development, or just load the lastest 
>>> revision of the T238 software?
>>> Also did you download the correct assembly manual?  Otherwise I 
>>> don't understand the comment about the board not being identical?
>> _______________________________________________
>> wxsig mailing list
>> wxsig at lists.tapr.org
>> https://lists.tapr.org/cgi-bin/mailman/listinfo/wxsig
> _______________________________________________
> wxsig mailing list
> wxsig at lists.tapr.org
> https://lists.tapr.org/cgi-bin/mailman/listinfo/wxsig
> _______________________________________________
> wxsig mailing list
> wxsig at lists.tapr.org
> https://lists.tapr.org/cgi-bin/mailman/listinfo/wxsig

More information about the wxsig mailing list