cancel
Showing results for 
Search instead for 
Did you mean: 

Programmation ST7

daniellambert59
Associate II
Posted on May 13, 2007 at 20:46

Programmation ST7

5 REPLIES 5
daniellambert59
Associate II
Posted on May 02, 2007 at 18:31

Bonjour

Je voudrais savoir comment paramétrer la config et les options byte avec STVP pour programmer un ST7FLITE 29F2 qui va tourner avec un quartz de 8Mhz. A quoi servent les cases à cocher RC protect?

J'ai dû mal programmer des options car je n'ai pu ni relire ni reprogrammer des puces une seconde fois.

Merci

Translation by the moderator:

Hi,

How to configure the option bytes with STVP to program a ST7FLITE29F2 running with a 8MHz crystal. What are the RC protect used for ?

I got some troubles to program options because I cannot neither read back nor program twice the chip.

Thank you

[ This message was edited by: laubey on 04-05-2007 18:28 ]

laurent239955_stm1
Associate II
Posted on May 03, 2007 at 11:35

Bonjour,

Premièrement, j'attire votre attention sur la présence d'un diviseur par 2 lorsqu'une horloge externe (quartz ou oscillateur) est utilisée. Dans votre cas, si vous utilisez un quartz à 8MHz, le CPU fonctionnera à 4MHz et vous ne pourrez pas sélectionner la PLL32 (pour alimenter le timer à 32MHz).

Dans le cas d'un quartz à 8MHz vous pouvez choisir pour l'option OSCRANGE MS ou HS. MS (Medium Speed)vous permettra de diminuer lègèrement la consommation mais sera légèrement moins robuste (les specifications sont toutefois respectées). Si vous ne faites pas la ''chasse aux microampères'' je vous conseille d'utiliser HS (High Speed) (solution recommandée pour sa robustesse).

Les cases à cocher RC protect servent à protéger l'emplacement où sont copiées les valeurs de RC calibration. Si vous ne cochez pas ces cases, vous perdrez la calibration faite en usine. Ces octets doivent être recopiés dans les registres de calibration après chaque reset, de manière à ce que le RC interne soit à 8MHz (dans ce cas le CPU fonctionne également à 8MHz). Si vous utilisez un quartz vous n'utilisez certainement pas le RC interne et donc vous pouvez écraser ces valeurs.

Concernant votre problème d'écriture et de lecture, j'ai l'impression que vos pièces ont été protégées en écriture et en lecture grace aux bits Read-out protection et WRITE protection (normalement à OFF) dans les options bytes.

Cordialement

Laurent

-------------

For my english spoken friends,

First, be aware there is a divider by 2 on the external clock input (crystal or external oscillator). In your case, with a 8MHz crystal the CPU will run at 4MHz and you cannot use the PLL32 (to supply the timer with a 32MHz clock).

In the case of a 8MHz quartz you can select either MS or HS OSCRANGE option in the option bytes. MS (Medium speed) will allow to decrease a lightly the current consumption but this solution is lightly less robust (the specifications being respected anyway). If you don't care about earning few microamps then I advise to use the HS(High Speed) option (recommended for the robustness).

The RC protect check box are to protect the location where the RC calibration values are stored in the user readable memory. If you don't check theses boxes you will lose the factory calibration. These bytes must be copied in the calibration registers after any reset in order to have the internal RC running at 8MHz (if selected - in this case the CPU runs at 8MHZ - no divider). If a crystal is connected you can use these byte locations for your code.

Concerning the read and write error, I have the feeling that your parts are write and read protected by the Read-out protection and WRITE protection bits normally switched off in the option bytes.

Regards

Laurent

[ This message was edited by: laubey on 04-05-2007 18:44 ]

wolfgang2399
Associate II
Posted on May 04, 2007 at 14:35

Hi Laubey,

I think it should be token for granted, that less the moderator takes care that everybody uses english as common language in this forum.

No problem when you translate the question and the answer!!

Regards

WoRo

laurent239955_stm1
Associate II
Posted on May 04, 2007 at 15:16

You are right Woro.

It is translated.

Best regards

Laurent

daniellambert59
Associate II
Posted on May 13, 2007 at 20:46

Thank you

I thought that one could program a microcomputer without his quartz

since the stick generates a clock. It is obvious that if it is

programmed this manner with the option quartz, one cannot read again!

Good continuation... :o