Dunfield Development Services Inc.
APPLICATION NOTE
Home
Products
Ordering & Status
Free Download Files
Links
Notices
Contact Us

 

Dunfield Development Services Inc.
Customer Support -- Application Note #5103

Emily52 Simulator
Using the DALLAS DS5000TK

Applies to: [Emily52 Simulator ]
Last updated: Sunday May 04, 2003 .
Application Note Index

Back ]

PROCEDURE

DALLAS SEMICONDUCTOR, maker of the DS5000 and DS2250 "Soft Microcontroller" also offer a small in-circuit evaluation kit using the DS5000 called the DS5000TK. This kit plugs into a CPU socket, and connects to the PC via a serial port. The software supplied with this kit is only a simple loader,
however the hardware can be made to support EMILY/MONICA52 with the construction of a special cable, and careful attention to a few details.

OVERVIEW OF DS5000TK HARDWARE
------------------------------------------------------------------------
In addition to the standard DS5000 features, the DS5000TK features a DTR load control with switchable crystal and serial port connections:

When DTR is raised (ASSERTED), the DS5000TK resets and begins execution of it's on-chip loader. At this time the serial port of the DS5000 is connected to the PC (using the supplied modular cable), and the DS5000TK runs from it's internal 11.059Mhz crystal.

When DTR is dropped (DEASSERTED), the DS5000TK resets and begins running in "normal" mode. The crystal inputs (pins 18,19) are connected to the DIP header (requiring a valid crystal), and the -EA signal (pin 31) must be held high (+5V) to enable the on-chip program memory. If these conditions are met, the DS5000 will begin executing the last loaded user program when DTR is dropped.

The operation of the serial port in "normal" mode depends on the "A/B" switch located beside the modular jack. When "A" is selected, the DS5000TK connects the serial I/O pins of the DS5000 to the corresponding pins (10,11) of the DIP header. When "B" is selected, the serial port of the DS5000 remains connected to the PC via the modular cable.

The serial cable shipped with the DS5000TK is wired as follows:

__==__ Front view of modular connector (cable exiting from back)
[||||] Both cable connectors are wired with the same pinout.
^^^^
|||| *** COLOR *** DB25 *** SIGNAL NAME ***
|||+----- Yellow --- 2 ----- Transmit Data (TXD)
||+------ Green --- 7 ----- Signal Ground (SG)
|+------- Red --- 20 ----- Data Terminal Ready (DTR)
+-------- Black --- 3 ----- Receive Data (RXD)
(DB25 = Pin number of DB25 serial connector to PC)

USING EMILY52 WITH THE DS5000TK
------------------------------------------------------------------------
EMILY52 uses the RTS signal to RESET the target system. Although the DS5000 loader is not used, you can use the DS5000TK's load signal as a RESET because it also resets the device. The fact that it also invokes the DS5000 load mode temporarily (while DTR is asserted) does not interfere with the operation of the EMILY/MONICA software.

To use EMILY52 with the DS5000TK, you must perform these steps:

  1. Make a special cable which connects RTS (pin 4) from the PC to the DTR signal (RED) wire of the DS5000TK cable. DTR from the PC should be left unconnected. If you do not have a mudular DB25 head-shell to modify, you can strip one end of a modular cable, and solder the wires directly to a DB25 connector. Be sure to maintain the same color positions and wiring as shown above (except for connecting the RED wire to pin 4 of the DB25 connector instead of pin 20).
  2. Run EMSETUP for the EMILY52 and MONICA52 programs, and set the "RESET Logic Level" option to "RESET when RTS asserted". At this time you may also want to set the default serial port and speed (the speed depends on the crystal you have connected to the DS5000TK, see the notes in the file KERNAL.ASM for details of selecting a serial speed.
  3. Assemble KERNAL.HEX file into INTEL format: ASM51 KERNAL -I  Then load it into the DS5000TK, using the ORIGINAL DALLAS cable! You can use the KIT5K software:
    kit5k - Run the Dallas software
    COM 1 - Select comm port
    PR KERNAL.HEX - Load KERNAL.HEX into memory
    Or any TTY program which runs at 9600-8N1, and asserts DTR:
    <return> - Press RETURN to autobaud the loader
    U - Unlock DS5000 internal RAM
    L - Load file into memory
    <transmit KERNAL.HEX as ASCII upload>
    W 18 - Set MCON address
  4. Since the EMILY/MONICA kernal runs as a "user" program, you must have a valid crystal attached to the DS5000TK, as well as insuring that pin 31 (-EA) is pulled HIGH (See *NOTE). Also, make sure that you are using the new (constructed) serial cable, and that the "A/B" switch is set to the "B" position.
  5. Run EMILY52/H or MONICA52/DS5000, and verify that you have communication.
    If not, the most likely causes are:
    bulletA/B switch in wrong position, crystal not attached, or -EA
    signal not pulled high on the DS5000TK.
    bulletDS5000TK not connected to EMILY/MONICA's Control COM PORT
    bulletKERNAL not configured for crystal, and/or software not configured for matching serial baud rate.
    bulletRESET option not configured correctly in EMSETUP.
    bulletCable failure / incorrect connections


*NOTE: If pin 31 (EA) is pulled LOW, the DS5000 will execute code from EXTERNAL memory instead of the on-chip program RAM. If you plug the DS5000TK into a circuit designed for an 8031 (EA=0), it will
run code from the external ROM. You must pull EA high to disable the external ROM, and execute from the internal program RAM.

I have received reports that the DS2252 device has changed the use of pin 31 to SDI (Self-Destruct-Immediately), and pulling it high will erase the on-chip memory. I have not been able to verify this, but I am told that when using these devices, pin 31 should be unconnected or tied to circuit ground.

Once you have the software communicating with the DS5000TK, you should be able to load and debug software with EMILY/MONICA just as you would on any other system. Once loaded into the DS5000TK, the kernal should not have to be re-loaded unless you have overwritten it.

The DS5000TK has no provision for re-routing the second PC serial port back to the in-circuit emulated CPU's serial pins (as is done with the DDS 8051 ICE design), however you can interface with the second serial port directly from the PC if desired, or construct a header adapter with an appropriate
RS-232 transceiver (MAX232 or equiv.) to convert the RS-232 signal levels from the PC back to 0-+5V logic, and apply them to your circuit directly. Be sure to disconnect the serial pins from the DS5000TK header when doing
this.

 

 

Back ]

© 2008 Dunfield Development Services Inc.     View our Privacy Statement
Refunds given at the discretion of management.
 Last Updated:  Tuesday, March 18, 2008