AN113_Target Sense_V091

AN113_Target Sense_V091
Report No:
AN113
Title:
Automatically sensing the presence of a
Target System using the PPM3-MK2,
PPM4-MK1 or ISPnano Programmer
Author:
John Marriott
Date:
th
6 July 2009
Version Number:
0.91
Abstract:
This application note describes how to set up the Equinox PPM3-MK2, PPM4-MK1 or ISPnano
programmers to automatically detect the presence of a Target System.
All rights are reserved. Reproduction in whole or in part is prohibited without the prior written consent of the copyright owner. The
information presented in this document does not form part of any quotation or contract, is believed to be accurate and reliable and may be
changed without prior notice. No liability will be accepted by the publisher for any consequence of its use. Publication thereof does not
convey nor imply any license under patent or other industrial or intellectual property rights
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
1
Contents
1.0 Introduction.................................................................................................................................... 3
1.1 Programmers supported ............................................................................................................ 3
1.2 Features..................................................................................................................................... 3
1.3 Typical Target Sensing application ............................................................................................ 3
1.4 Typical Target Sensing sequence.............................................................................................. 4
2.0 Target Sensing – hardware overview .......................................................................................... 6
2.1 Introduction ................................................................................................................................ 6
2.2 Target Disconnected Voltage..................................................................................................... 6
2.3 Target Connected Voltage ......................................................................................................... 6
3.0 Target Sensing Project ................................................................................................................. 7
3.1 Overview .................................................................................................................................... 7
3.2 Setting the Project Type............................................................................................................. 7
3.3 Enabling the Target Power Supply............................................................................................. 8
3.4 Enabling the Target Sense function ........................................................................................... 9
3.5 Running the ‘Target Connection Wizard’ ................................................................................. 10
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
2
1.0 Introduction
This application note describes how to set up an Equinox ISP Programmer to automatically sense
when a Target System (UUT) is connected to or disconnected from the programmer. This ‘Target
Sensing’ technique is used to automatically start a ‘Programming Sequence’ without any operator
intervention when a Target System (UUT) is connected to the programmer. Once the ‘Programming
Sequence’ has completed, the operator simply removes the Target System from the programmer and
the programmer then automatically resets itself ready to sense the connection of the next Target
System.
1.1 Programmers supported
The following Equinox programmers are capable of supporting the ‘Target Sensing’ functionality:
Programmer
Target Sense
Capability
PPM3-MK2
YES – uses TVCC pin
PPM4-MK1
YES – uses TVCC pin
ISPnano
YES – uses TVCC pin
Please note:
‘Target Sense’ can only be used if the programmer is controlling the power supply to the Target
System.
1.2 Features
The main features of the ‘Target Sensing’ technique are:
• Uses a load detection technique on the ‘Target Vcc’ pin (TVCC) to sense the presence of the
Target System load.
• The same technique can also be used to sense when a ‘Test Fixture’ lid has been closed and
this signal can then be used to automatically start a ‘Programming Sequence’.
• Automatically detects when a Target System is connected to the programmer
• Automatically triggers the start of a ‘Programming Sequence’ once a Target System has
been detected
• Automatically detects when a Target System has been disconnected from the programmer.
1.3 Typical Target Sensing application
Here is a typical example of how the ‘Target Sensing’ technique can be used:
• The ‘Test Operator’ places UUT onto Test Fixture
• The programmer senses the presence of the Target System
• The programmer then automatically starts a programming sequence to program the Target IC
on the Target System
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
3
•
•
•
Once the programming sequence is complete, the programmer reports PASS or FAIL on the
LED’s and display.
The ‘Test Operator’ removes the UUT from the Test Fixture
The programmer senses that the UUT has been removed, resets itself and goes back to
‘Sensing Target Connection’ mode.
1.4 Typical single Project Target Sensing sequence
The typical sequence of events when using ‘Target Sensing’ to start / stop a single ‘Standalone
Programming Project’ is as follows:
• Programmer waits for UUT to be connected
Æ flashing BUSY LED
Æ LCD: “SENSING TARGET CONNECTION”
• Operator connects UUT to programmer
• Programmer detects connection of UUT
Æ Programmer automatically executes a sequence of one or more ‘Standalone
Programming Projects’
Æ BUSY LED stays on solid
• At the end of the programming sequence, the programmer will FLASH either the PASS or
FAIL LED together with the BUSY LED.
• PASS Æ LCD message: “SUCCESSFUL DISCONNECT NOW”
Æ Programmer then goes into ‘Target Disconnection Sensing’ mode (flashing BUSY LED)
and will remain in this state waiting for the operator to remove the UUT.
• Operator removes the UUT
• Programmer resets itself ready for the next UUT – go to start of sequence
1.5 Using Target Sensing to control multiple projects
In some applications such as ‘Oscillator Calibration’, it is necessary to run a sequence of
‘Standalone Programming Projects’ one after the other in order to create a certain programming
sequence. It is possible to use the ‘Target Sense’ feature to start the execution of a series of chained
projects and then once all the projects have finished execution, ‘Target Sense’ can then be used to
sense when the DUT has been disconnected.
A typical sequence for ‘Oscillator Calibration’ is to use three projects chained together so they
automatically execute one after the other. The programmer waits in ‘Target Connection’ mode for
the Target System (DUT) to be connected to the programmer. When the Target System is detected,
the programmer starts to execute the three projects in sequence. At the end of the last project, the
programmer will then go into ‘Target Sense’ mode waiting for the Target System to be disconnected.
When the disconnection is detected, the programmer then resets and goes back to the first project
and starts sensing for the connection of the next DUT.
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
4
Here is an overview of the sequence:
• Start
• Sense ‘Target Connection’
• Program ‘Calibration Firmware’ into DUT
• Execute ‘Calibration Firmware’ on DUT
• Program ‘Production Firmware’ into DUT
• Sense ‘Target Disconnection’
• Go back to Start
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
5
2.0 Target Sensing – hardware overview
2.1 Introduction
The Target Sensing technique allows the programmers to detect when a Target System is physically
connected or disconnected from the programmer. This can be used to start / stop an automatic
programming sequence. The sensing technique works by placing the Target System as part of a
potential divider. The voltage across the Target System is then measured when the Target System is
connected and disconnected giving a voltage for “Connection” and “Disconnection”.
2.2 Target Disconnected Voltage
The ‘Target Sense Off’ voltage is the voltage present on the ‘TVCC’ (Target Vcc) pin of the
programmer when the Target System is disconnected from the programmer. The programmer will
apply the voltage specified in the ‘Power Supply Settings’ to the Target System so if no load is
attached, the ‘Target Sense Off’ voltage should be within a few 100 mV of the applied voltage.
Example 1
If the ‘Controlled Power Supply voltage’ is set to 5.0V, then the expected ‘Target Sense Off’
voltage should be between 4.7 and 5.0V. If the measured voltage is much lower than this then it is
likely that something on the IO-CON Module or even the ‘Special Function Module’ is taking too much
current.
Example 2
If the ‘Controlled Power Supply voltage’ is set to 3.3V, then the expected ‘Target Sense Off’
voltage should be between 3.1 and 3.3V.
2.3 Target Connected Voltage
The ‘Target Sense On’ voltage is the voltage present on the ‘TVCC’ (Target Vcc) pin of the
programmer when the Target System is connected from the programmer. The programmer will apply
the voltage specified in the ‘Power Supply Settings’ to the Target System and this voltage will be
pulled down by whatever load is attached. If the Target System takes eg. >10mA then this will show
up as corresponding drop in the measured ‘Target Connected Voltage’. The more current drawn,
the lower the voltage measured.
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
6
3.0 Target Sensing Project
3.1 Overview
In order to use the ‘Target Sensing’ function, it is necessary to set up a ‘Standalone Programming
Project’ with the following parameters:
• Programmer controlled Target Power Supply: ON
• The ‘Detect Target Connect’ and ‘Detect Target Disconnect’ options must be enabled
• The ‘Target Connect Voltage’ must be set to a value which allows the programmer to reliably
detect when the Target System is connected to the programmer.
• The ‘Target Disconnect Voltage’ must be set to a value which allows the programmer to
reliably detect when the Target System is disconnected from the programmer.
The next sections explain how to set up a ‘Standalone Programming Project’ to detect Target
connection and disconnection.
3.2 Setting the Project Type
The ‘Target Sensing’ function can only be used with ‘Standalone Programming Projects’. It is
necessary to set the ‘Project Type’ to be ‘Standalone – Autostart (Target Connect/Disconnect)’ –
see screenshot below:
Instructions:
• Launch EQTools
• From the left-hand pane, select <Project Builder> and then <New Project>
• Fill in the relevant screens as you would for a normal project
• Select the <Programmer and Project Type> tab
• Select the correct programmer e.g. PPM3-MK2, PPM4-MK1 or ISPnano
•
Click the list box arrow under the ‘Project Type’ header and select
‘Standalone – Autostart (Target Connect/Disconnect)’
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
7
Æ The ‘Entry/Exit’ tab should now become visible.
3.3 Enabling the Target Power Supply
The ‘Target Sensing’ function will only work when the programmer is set to power the Target
System.
Instructions:
• Select the <Target Power Supply> tab
• Set the ‘Voltage’ to the voltage at which the Target System needs to be powered to.
• Set the ‘Tolerance’ to the required voltage tolerance
• Switch the ‘Target controlled Power Supply’ to ‘ON’ – see screenshot
Æ This means that the programmer will supply power to the Target System.
• Set the ‘Maximum current’ to the maximum expected surge current that will be taken by the
Target System.
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
8
3.4 Enabling the Target Sense function
In order to use the ‘Target Sensing’ function, it is necessary to enable this function in the ‘Entry /
Exit Options’ tab.
Instructions:
• Select the ‘Entry / Exit Options’ tab
• Check the ‘Detect Target Connect’ and ‘Detect Target Disconnect’ boxes – see screenshot
The voltages are defined as follows:
Target Sense ON Voltage
When in ‘Target Sensing Mode’, the programmer will measure the voltage. If the measured voltage
is less than ‘Target Sense On’ voltage, then the programmer will detect that the Target System is
connected.
Target Sense OFF Voltage
When in ‘Target Sensing Mode’, the programmer will measure the voltage. If the measured voltage
is more than ‘Target Sense OFF’ voltage, then the programmer will detect that the Target System is
disconnected.
The ‘Target Connection Wizard’ is used to measure / set up the ‘Target Sense ON / OFF Voltages’
for a given Target System.
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
9
3.5 Running the ‘Target Connection Wizard’
The ‘Target Connection Wizard’ is used to measure / set up the ‘Target Sense ON / OFF Voltages’
for a given Target System.
Instructions:
• Select the ‘Entry / Exit Options’ tab
• Click the ‘Magic Wand’ symbol to launch the ‘Target Connection Wizard’
•
Click the <Next> button
Æ the ‘Connect Target now’ screen is displayed….
Æ The yellow ‘BUSY’ status LED on the programmer should now start to flash indicating the
programmer is in ‘Target Sensing’ mode.
Æ The programmer will now output a voltage (at a very limited current) out of the ‘TVCC’ pin
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
10
•
•
•
•
Connect the ‘Target System’ to the programmer
Click the <Calculate> button
Æ The programmer will now measure the voltage at the ‘TVCC’ pin (Target Voltage)
The ‘Measured voltage’ and ‘Calculated voltage’ are now displayed – see screenshot.
•
The ‘Measured voltage’ is the voltage below which the programmer will detect that the Target
System is connected.
In this example, the ‘Target Sense ON’ voltage must be < 1.6V to trigger a Target
Connection.
Click <Next>
•
Disconnect the ‘Target System’ from the programmer
•
Click the <Calculate> button
Æ The programmer will now measure the voltage at the ‘TVCC’ pin (Target Voltage)
The ‘Measured voltage’ and ‘Calculated voltage’ are now displayed – see screenshot.
•
•
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
11
•
•
•
•
•
The ‘Measured voltage’ is the voltage above which the programmer will detect that the
Target System is disconnected.
In this example, the ‘Target Sense OFF’ voltage must be > 3.1V to trigger a Target
Connection. To give a safe detection margin, this voltage has been reduced to 2.8V.
Click <Next>
Click <Finish>
The voltages will now be automatically placed into the ‘Target Sense ON Voltage’ and
‘Target Sense OFF Voltage’ fields.
th
Application Note 113 – Target Sensing using the PPM-MK2 Programmer Version: 0.91 6 July 2009
12
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement