LoginSignup
0
0

More than 1 year has passed since last update.

ATF22V10Cプログラミング 対訳

Last updated at Posted at 2021-02-09

プログラマブルなゲート

ATF22V10C Programming

https://www.retrobrewcomputers.org/forum/index.php?t=msg&goto=1362&
ATF22V10C Programming w/Arduino

In the past I had a $50 EEPROM programmer, an old TOP853. The software/drivers wouldn't work in 64-bit Windows, so I had to run an XP VM inside Linux and forward the USB devices to make it work (or use an old laptop with XP). It also would only program GAL22V10s, not ATF22V10's which have a different programming algorithm.

過去に私は50ドルのEEPROMプログラマー、古いTOP853を持っていました。 ソフトウェア/ドライバは64ビットWindowsでは動作しないので、Linuxの中でXP VMを実行し、USBデバイスを転送して動作させなければなりませんでした(XPでは古いラップトップを使用します)。 また、プログラミングアルゴリズムが異なるATF22V10ではなく、GAL22V10だけをプログラムします。

With the SBC6120 group buy in full swing, and wanting to use the low-current-draw and still in production ATF parts, I decided to buy a new programmer and settled on the Wellon VP598, since it had the most recent software updates of any of the Wellon programmers and the best price:device support ratio.

本格的なSBC6120グループの購入で、低電流引き込みを使用していて、まだ生産用のATF部品を使用したいと思った私は、新しいプログラマーを買うことにしました。そして、Wellon VP598は、 ウェロン・プログラマーの中で最も優れた価格:デバイス・サポート率。

Imagine my annoyance when the VP598 failed to program the ATF22V10 either Mad It does have a neato 'mass production mode' that will be helpful when programming all the EEPROMs & ATF16V8's, but a no-go on the 22V10s.

VP598がATF22V10をプログラムするのに失敗したときの煩わしさを想像してみてください.Madは、すべてのEEPROMとATF16V8をプログラミングする際に役立つネート「量産モード」を持っていますが、22V10では何もしません。

I found a handy webpage here where a person spent the time to reverse engineer the ATF22V10 algorithm. Using a logic analyzer I captured what the VP598 was doing when trying to erase and program the chip and found the following:

  • Rather than using the simple erase-everything algorithm described (enter programming mode, setup some pins, lower strobe, and the whole chip erases) the VP598 tries to erase the chip by writing all '0s' to it. So right off the bat, Wellon's software is not doing things correctly.
  • When programming the chip, the clock signal stops in the middle of the 132 bits of data. So the data is not being clocked in properly by the programmer.
  • Reading the chip seemed to be done properly! A nice constant clock and follows what is on the website as far as the algorithm.

ATF22V10アルゴリズムのリバースエンジニアリングに時間を費やした便利なWebページが見つかりました。 ロジック・アナライザを使用して、チップを消去してプログラムしようとしたときにVP598が何をしているのかを確認し、

  • VP598は、説明したシンプルなイレーズ・オール・アルゴリズム(プログラミング・モードに入り、いくつかのピンを設定し、ストローブを下げ、チップ全体を消去する)を使用するのではなく、すべての「0」を書き込むことによってチップを消去しようとします。 だから、バットから離れて、Wellonのソフトウェアは正しく機能していない。
  • チップをプログラムするとき、クロック信号は132ビットのデータの途中で停止します。 したがって、データはプログラマによって適切にクロックされていません。
  • チップを読むことが適切に行われたようだ! 素敵な一定の時計で、アルゴリズムまではウェブサイトにあるものに従います。

Not waiting to be defeated, I pulled out an Arduino and wrote some code to follow the algorithm outlined for programming. 2 days of coding, testing, and bread-boarding and a trip to Frys for some DIP-package relays later and I can program both the IOT1 and IOT2 chips perfectly fine with my homemade programmer and have them read & verify OK on the VP598 and work in the Rev 1.0 SBC6120-RBC board.

敗北を待たずに、私はArduinoを取り出し、プログラミングのために概説されたアルゴリズムに従うためにいくつかのコードを書いた。 後でいくつかのDIPパッケージリレーのコーディング、テスト、パンケーキやフライズへの2日間のツアーを行い、自作のプログラマーにIOT1とIOT2の両方のチップを完全にうまくプログラミングし、VP598と Rev 1.0 SBC6120-RBCボードで動作します。

The biggest drawback right now is that to save time, I baked the fusemap data into the Arduino sketch as a series of unsigned longs (32-bit integers) which correspond to the 32-bit lines of binary data in the .JED files. So a different sketch has to be uploaded to the Arduino for each chip, and I had to pre-process the .JED files with a Python script to turn them into a list of integers to paste into the Arduino code.

今の最大の欠点は、時間を節約するために、フュージマップデータを.JEDファイルの32ビットのバイナリデータに対応する一連の符号なしlong(32ビット整数)としてArduinoスケッチに焼き付けたことです。 そこで、各チップのArduinoに別のスケッチをアップロードする必要がありました.JEDファイルをPythonスクリプトでプリプロセスして、Arduinoコードに貼り付ける整数のリストにする必要がありました。

Still I thought this was worth sharing - both as a warning that the latest Wellon software on the VP598 won't program ATF22V10's and to point out a workaround. This was a relatively complicated thing to work out so it got the "yay it works" dance at the end!

それでもVP598の最新のWellonソフトウェアがATF22V10をプログラムして回避策を指摘するという警告として、これは分かち合う価値があると思いました。 これは実際に動き出すのは比較的複雑なことでしたので、最終的には "それはうまくいく"ダンスがありました!

  • I am also using v4.70. Maybe I have a bad Wellon programmer? It programs the Lattice GAL 16V8 and 22V10 parts fine, as well as ATF16V8's, and the 28C256 EEPROMs. And it properly READS the ATF22V10s, with the correct clock signals, it just drops the clock during WRITING for some reason....

Anyway I took my breadboard circuit and soldered it onto an Arduino protoshield with a nice ZIF socket, and bought a 12V barrel plug adapter to power the Arduino & provide Vpp. It will erase/write/verify the ATF22V10 with no issues:

私はv4.70も使用しています。 多分Wellonのプログラマーが悪いですか? それは、ラティスGAL 16V8と22V10パーツだけでなく、ATF16V8と28C256 EEPROMをプログラムします。 そしてそれは適切なクロック信号でATF22V10を適切に読んで、何らかの理由でWRITING中にクロックを落とします。

とにかく私はブレッドボードの回路を取り出し、素敵なZIFソケット付きのArduinoプロトシールドにハンダ付けし、Arduinoに電源を供給してVppを供給するために12Vバレル・プラグ・アダプターを購入しました。 ATF22V10の消去/書き込み/ベリファイは問題ありません:

  • I wish I had taken screenshots of my logic analyzer while it was trying to program. It's clearly capable of twiddling all the required pins, just the algorithm is wrong. The read-back algorithm works fine! Super annoying.

The Atmel parts use a serial interface for programming where bits get shifted in and out, while the Lattice parts use a row/column style interface where bits are loaded in parallel groups, so I'm not surprised that one would work and the other would fail.

The same unit programs 16V8s and EEPROMs just fine.

I can post my Arduino code, but it's pretty janky (the fuse map is baked into the Arduino code, I wrote a Python script to read the JDEC file and convert it into C constants that get pasted into the sketch).

I did end up programming 120+ ATF22V10s with it, so it's been tested at least.

私がプログラミングしようとしている間、ロジックアナライザのスクリーンショットを撮りたがっています。 それは明らかにすべての必要なピンをつまずかせることができます。ちょうどアルゴリズムが間違っています。 リードバックアルゴリズムは正常に動作します! 超迷惑な。

Atmelのパーツは、ビットがどこにシフト・インされているかをプログラミングするためにシリアル・インターフェースを使用していますが、ラティスのパーツは並列のグループにビットがロードされる行/列スタイルのインターフェースを使用しています。 失敗します。

同じユニットが16V8とEEPROMをうまくプログラムします。

私はArduinoコードを投稿することができますが、それはかなりjankyです(ヒューズマップはArduinoコードに焼き付けられ、JDECファイルを読み込んでスケッチに貼り付けられるC定数に変換するPythonスクリプトを書いています)。

私は120 + ATF22V10sをプログラミングしてしまったので、少なくともテストされています。

ATF22V10C Programming Algorithm

This page is about the programming algorithm (what you need to know if you want to build your own programmer) for the ATF22V10C.

このページは、ATF22V10C用のプログラミングアルゴリズム(独自のプログラマを構築したい場合に知る必要があるもの)に関するものです。

Random Conversation

The programming algorithm is essentially undocumented, both officially and unofficially. Search for Atmel documents about how to program the chips and all you end up with are two-page PDF documents that say "buy one of these commercial programmers." Search for random internet information on the topic and all you find are newsgroup postings that say "it's a secret, no one knows."

プログラミングアルゴリズムは公式にも非公式にも本質的に文書化されていません。 チップをどのようにプログラムするかについてAtmelの文書を検索すると、「商用プログラマーの1人を買う」という2ページのPDF文書が完成します。 トピックに関するランダムなインターネット情報を検索します。ニュースグループの投稿には、「秘密だ、誰も知らない」と書いてあるだけです。

I was able to find a homebrew programmer with source code, but it didn't support the ATF22V10C. I found another homebrew programmer for which the author said that he didn't know how to make it compatible with ATF22V10, but he did know of a piece of software (closed-source and compiled for Windows 3.1) which could utilize his circuit to program the chips, assuming you still have a PC that has a parallel port.

私はソースコードを持つ自作プログラマーを見つけることができましたが、ATF22V10Cをサポートしていませんでした。 私は、ATF22V10と互換性のある方法を知らなかったと著者が言った別の自家製プログラマーを見つけましたが、彼の回路を使ってプログラムすることができるソフトウェア(クローズドソースとWindows 3.1用にコンパイルされたもの) は、あなたがまだパラレルポートチップを持つPCを持っていると仮定した物でした。

I then found something on sourceforge apparently created much more recently, specifically for the ATF22V10C, but both the source code and a text file of notes from the author proved to be so utterly incomprehensible that I could have figured out how to program the chip in half the time had I simply never found that project.

私はその後、ATF22V10C用のソースフォージ上のものを発見しましたが、ソースコードとテキストファイルの両方が完全に理解できないことが判明し、チップを半分にプログラムする方法を考え出すことができました 時間は私が単にそのプロジェクトを見つけたことはありませんでした。

How Atmel manages to sell the chips in such a vacuum of information is beyond my understanding. I realize there are commercial programmers, but judging from what I've read on the internet, most of them fail to program the ATF22V10 as well.

Atmelがそのような情報の欠乏でチップを売却する方法は、私の理解を超えています。 私は商用プログラマがいることを認識していますが、私がインターネットで読んだことから判断すると、彼らのほとんどはATF22V10をプログラムすることができません。

...but that doesn't matter, as I'm not the type to buy chips that I can't program myself, and so using someone else's programmer, homebrew or commercial, was never an option anyway. So I took what information I could find for the GAL22V10, applied that process to the ATF22V10, figured out why that process wasn't working and how to correct it, and this page documents the results.

...しかし、それは問題ではありません。自分でプログラムできないチップを購入するタイプではないので、他の誰かのプログラマー、自家製または商用のものを使用することは決して選択肢にはなりませんでした。 そこで私はGAL22V10の情報をとり、そのプロセスをATF22V10に適用し、そのプロセスが動作しなかった理由とその修正方法を理解し、このページに結果を記録しました。

Programming Pins

During programming, 5 volts should be applied to pin 24 and ground to pin 12, as is done so when not programming.

プログラミング時には、プログラミングしないときと同様に、ピン24には5ボルト、ピン12にはグランドを印加する必要があります。

Pin 1, and pins 15 through 23, are not used during programming. Every document I read suggest that they should be tied low with 4.7 kΩ resistors, and totally not 10 kΩ resistors because they must be pulled low enough to counteract internal pull-up resistors, otherwise invalid logic states may exist, even for the output pins since they might be inputs. Needless to say, this all sounds like a bunch of bullshit, and so I removed the damn resistors from my design and, surprise, it seems to make no difference whatsoever. So if you feel like being pedantic you can put some 4.7 kΩ pull-down resistors on these pins, but I wouldn't bother.

ピン1、およびピン15〜23は、プログラミング中は使用されません。 私が読んだすべてのドキュメントでは、10kΩではなく4.7kΩの抵抗で十分に低くする必要があることが示唆されています。なぜなら、内部プルアップ抵抗に十分に低く引っ張らなければならないからです。 彼らは入力かもしれない。 言うまでもなく、これはすべての馬鹿げた音のように聞こえるので、私は自分のデザインからその抵抗器を取り除きましたが、驚いたことにそれは何の違いもないようです。 ペダンティクな感じがするなら、これらのピンに4.7kΩのプルダウン抵抗を付けることができますが、私は気にしません。

Pin 2 is the programming enable pin. You enable programming by applying 12 volts to this pin. Documents I've read suggest that this should happen 10 ms after 5 volts is applied to pin 24, and so that is what I have done, though I suspect the chip doesn't really care as long as you're sure that it has 5 volts on pin 24 before you apply 12 volts to pin 2.

ピン2はプログラミング・イネーブル・ピンです。 このピンに12Vを印加してプログラミングをイネーブルにします。 私が読んだドキュメントでは、ピン24に5ボルトを印加してから10ミリ秒後に起こるはずであることが示唆されています。これは私がやったことですが、チップが本当に気にしない限り、 ピン2に12Vを印加する前にピン24に5Vを印加してください。

One circuit design I saw on the internet had a button wired between the programming voltage and pin 2. While the programmer circuit also controlled the programming voltage automatically, this switch served as a fail-safe in case the user left a chip in their programmer when they shouldn't have.

I seriously recommend that you include such a button in your programmer. I didn't have one at first, but added one after rendering pin 2 useless for logic input on one of my chips. (The chip otherwise still works, so it isn't a complete loss.) If you decide not to have such a safety button, be sure that you realize that in addition to ensuring that the programming voltage isn't applied during power-up of your programmer, you must ensure that it isn't applied during power-down as well, and also during weird conditions such as slow rise/fall times of supply voltage, brown-outs (which are common with USB power), etc. ...

or just add the fucking button.

私がインターネットで見た1つの回路設計では、プログラミング電圧とピン2の間に配線されたボタンがありました。プログラマ回路もプログラミング電圧を自動的に制御していましたが、このスイッチはユーザーがプログラマにチップを残した場合 彼らは持ってはいけません。

私は真剣にあなたのプログラマーにそのようなボタンを含めることをお勧めします。 私は最初は持っていませんでしたが、私のチップの1つのロジック入力用ピン2をダメにしてから追加しました。 (そうでなければ、チップはまだ動作しているので、完全なロスではありません)。そのような安全ボタンを使用しないことに決めた場合は、電源投入時にプログラミング電圧が印加されないようにすることに加えて パワーダウン時や電源電圧の立ち上がり/立ち下がり時間が遅い、ブラウンアウト(USB電源に共通する)などの奇妙な条件の間にも電源が印加されないようにする必要があります...

でなければクソボタンを追加するだけです。


Pin 3 is the P/V pin, which I assume means "program/verify." When low you can read from the chip, and when high you can write to the chip. The state of this pin matters only when the strobe pin is brought low, otherwise it may be in either state without any effect.

ピン3はP / Vピンです。プログラム/検証を意味します。 低いときはチップから読み込み、高いときはチップに書き込むことができます。 このピンの状態は、ストローブ・ピンがローになったときにのみ重要です。そうでない場合は、どちらの状態でも何の効果もありません。


Pins 4 through 9 are "row address" pins. In old GAL designs, these pins selected which row of the EPROM data you were writing to. In the ATF22V10, row addresses are instead shifted into the chip along with the data to be programmed into those rows. Thus, these row address pins are almost unused. There are only two patterns the chip pays any attention to, resulting in 3 modes of operation:

ピン4〜9は「行アドレス」ピンである。 古いGALデザインでは、これらのピンは書き込み先のEPROMデータの行を選択しました。 ATF22V10では、行アドレスは、代わりに、それらの行にプログラムされるデータとともにチップにシフトされます。 したがって、これらのロウアドレスピンはほとんど使用されない。 チップが注意を払うのは2つのパターンだけで、3つの動作モードが得られます。

If pins 4, 6, 7, and 9 are high, then bringing the strobe pin low for 10 ms while pin 3 is high will cause the chip to be erased.

If the above condition is not met, and if pin 8 is high, then the 20 bits which control latching and active high/low of the output pins are accessed.

ピン4,6,7,9がハイの場合、ピン3がハイの間にストローブ・ピンを10ms間ローにすると、チップが消去されます。

上記の条件が満たされず、ピン8がハイであれば、出力ピンのラッチおよびアクティブ・ハイ/ロウを制御する20ビットにアクセスできます。

If neither of the above conditions are met, then all of the remaining bits in the chip are accessed.

上記の条件のいずれも満たされない場合、チップ内の残りのビットすべてにアクセスできます。

The state of pin 5 seems to be entirely irrelevant.

ピン5の状態は完全に無関係なようです。


Pin 10 is the clock pin. It only took me about 8 hours to figure out the correct polarity of this pin. As best I can tell, the best approach is that at power-up, this pin should be high, then for each bit-shifting operation, you should first sample the chip's data output pin, then lower the clock, then change the chip's data input pin, then raise the clock.

ピン10はクロックピンです。 このピンの正しい極性を理解するのに約8時間しかかかりませんでした。 最良の方法は、電源投入時にこのピンをハイにし、ビットシフト動作ごとにまずチップのデータ出力ピンをサンプリングしてからクロックを下げ、次に入力端子に接続しチップのデータを変更し、クロックを立ち上げます。

As it presently exists, my programmer never makes use of a clock signal that remains high or low for less than 10 µs. So you can go at least as fast as 100 kHz in some cases, though in other cases my programmer goes much slower (it is just a bit-bang interface), so perhaps 20 kHz is a safer choice if you want to be certain you're going slow enough.

現在存在するように、私のプログラマは、10μs以下の間、ハイまたはローのままであるクロック信号を決して使用しません。 だから、場合によっては少なくとも100kHzの高速化が可能ですが、他のケースでは私のプログラマの速度がかなり遅くなります(ちょうどビットバンインターフェースです)、20kHzはより確かな選択です。あなたにとって遅すぎなければ。

Pin 11 is the serial data input pin. Its state is sampled by the chip on the rising edge of the clock signal.

ピン11はシリアルデータ入力ピンです。 その状態は、クロック信号の立ち上がりエッジでチップによってサンプリングされます。

Pin 13 is the strobe pin. It is active low. Because of this, it must be brought high after 5 volts is applied to pin 24, but before 12 volts is applied to pin 2.

ピン13はストローブ・ピンです。 アクティブローです。 このため、ピン24に5ボルトが印加された後で、ピン2に12ボルトが印加される前にハイにします。

For erasing the chip, it seems that the strobe pin must be held low for 10 ms, as a simple pulse won't erase the chip, even if I delay for 100 ms after giving that short pulse. I'm not certain that the pulse length is essential. It's possible that its timing is used to time the erase operation, but it's also possible that because the erase process is so easy to set up (just raise pins 3, 4, 6, 7, and 9, then lower pin 13) that there is a minimum strobe length simply to prevent circuit glitches from erasing the chip.

チップを消去するには、その短いパルスを与えた後に100ms遅延しても、単純なパルスでチップが消去されないため、ストローブピンを10ms間ローに保持する必要があるようです。 私は、パルスの長さが必須であるとは確信していません。 そのタイミングは消去操作の時間を計るために使用される可能性がありますが、消去プロセスが設定が簡単なため(ピン3,4,6,7,9を上げてから下のピン13を上げるだけであるため)、 回路のグリッチがチップを消去するのを防ぐだけの最小ストローブ長です。

I've so far only tested pulses of 10 µs and 50 ms in addition to the recommended 10 ms, and the only ill effects I noticed was that the 10 µs pulse failed to erase the chip. The 50 ms pulse didn't seem to over-erase the chip, as subsequent programming succeeded as usual.

私は今まで10ミリ秒と50ミリ秒のパルスを推奨していましたが、10ミリ秒のパルスはチップを消去できませんでした。 後続のプログラミングが通常どおり成功したので、50msパルスはチップを過消去していないように見えました。


For general programming and for reading the chip, a 10 µs pulse seems to work just fine, even though one source I read claims that the programming pulse must last for 5 ms. I've tested 10 µs pulses and 50 ms pulses and I saw no ill effects from either extreme. So I suspect the chip times the write operations itself. It likely still needs some time to perform the operation, but it isn't clear to me how much time that is.

I've waited as little as 2 ms before shifting more bits into the chip for the next write operation, but with that bit shifting requiring 6 ms, the chip still has 8 ms between write strobes. Just to be on the safe side, I recommend making the pulse 5 ms anyway, and waiting at least another 5 ms before issuing another write pulse, as 10 ms is commonly how much time EEPROM chips require to program data into themselves.

一般的なプログラミングとチップの読み取りでは、10μsのパルスがうまくいくように見えますが、1つのソースがプログラミングパルスを5ms持続させなければならないと主張しています。 私は10μsのパルスと50msのパルスをテストしました。どちらの極端なものも悪影響は見られませんでした。 だから私は、チップが書き込み操作自体に時間をかけると思う。 操作を実行するにはまだ時間がかかる可能性がありますが、どれくらい時間がかかるかはわかりません。

私は次の書き込み操作のためにチップにさらに多くのビットをシフトする前に2msほど待っていましたが、そのビットシフトで6msが必要ですが、書き込みストローブ間に8msのチップがあります。 安全面を保つためには、とにかくパルスを5ms作り、別の書き込みパルスを発行する前に少なくとも5ms待つことをお勧めします。通常、EEPROMチップがデータをプログラムするために必要な時間は10msです。

Pin 14 is the serial data out pin. It should be sampled only when the clock pin is high. When the clock pin is low, the output is on some occasions merely an inverted echo of the serial data input pin, and so the pin cannot be sampled on either edge of the clock, but must be sampled when the clock is high.

ピン14はシリアルデータ出力ピンです。 クロックピンがハイの場合にのみサンプリングする必要があります。 クロックピンがローのとき、出力は時にはシリアルデータ入力ピンの反転エコーだけであるため、クロックのいずれかのエッジでピンをサンプリングすることはできませんが、クロックがハイのときにサンプリングする必要があります。

Programming Process

Entering Programming Mode

Apply 5 volts to pin 24, wait 5 ms, raise the strobe and clock signals, wait another 5 ms, then apply 12 volts to pin 2.

ピン24に5ボルトを印加し、5ミリ秒間待機させ、ストローブおよびクロック信号を立ち上げ、さらに5ミリ秒間待機させてから、ピン2に12ボルトを印加する。

Reading / Verifying

  1. Set a low voltage on the P/V pin.

  2. Set one or all of pins 4, 6, 7 and 9 low. Set pin 8 according to the type of data you want to read.

  3. Clock a zero bit into the chip for each data bit you plan to read.

  4. If the data is addressed, clock the 6 address bits, most-significant bit first, into the chip.

  5. Bring the strobe pin low, then high again.

  6. Clock the data bits out of the chip.

  7. P / Vピンに低電圧を設定します。

  8. ピン4,6,7,9のいずれかまたはすべてを低く設定します。 読み取るデータのタイプに応じてピン8を設定します。

  9. 読み出す予定の各データビットに対して、ゼロをクロックする。

  10. データがアドレス指定されている場合、最上位ビットの6アドレスビットをチップにクロックします。

  11. ストローブ・ピンをローにした後、再びハイにします。

  12. チップからデータビットを出すためのクロックを入れる。

Erasing / Wiping

  1. Set a high voltage on the P/V pin.

  2. Set pins 4, 6, 7 and 9 to a high state.

  3. Bring the strobe pin low, keep it low for 10 ms, then raise it.

  4. Wait another 10 ms just for shits and giggles. (no idea if its necessary, but just to be safe)

  5. P / Vピンに高電圧を設定します。

  6. ピン4,6,7および9をハイに設定します。

  7. ストローブ・ピンをLowにし、10ms間Lowにしてから、それを上げます。

  8. 10ミリ秒待ってください。 (それが必要かどうかは分かりませんが、念のため)

Writing / Programming

  1. Set a high voltage on the P/V pin.

  2. Set one or all of pins 4, 6, 7 and 9 low. Set pin 8 according to the type of data you want to write.

  3. Clock the data bits into the chip.

  4. If the data is addressed, clock the 6 address bits, most-significant bit first, into the chip.

  5. Bring the strobe pin low, keep it low for 5 ms, then raise it.

  6. Wait another 10 ms just for shits and giggles. (no idea if its necessary, but just to be safe)

  7. P / Vピンに高電圧を設定します。

  8. ピン4,6,7,9のいずれかまたはすべてを低く設定します。 書きたいデータのタイプに応じてピン8を設定します。

  9. データビットをチップにクロックする。

  10. データがアドレス指定されている場合、最上位ビットの6アドレスビットをチップにクロックします。

  11. ストローブ・ピンをローにし、5ms間ロー・レベルに保ち、それを上げます。

  12. 10ミリ秒(以下略)。

Leaving Programming Mode

Remove the 12 volts from pin 2, wait 5 ms, lower the strobe and clock signals, wait another 5 ms, then remove the 5 volts from pin 24.

ピン2から12ボルトを取り除き、5ミリ秒間待ってからストローブとクロック信号を下げ、さらに5ミリ秒間待ってからピン24から5ボルトを外します。

Fuse Data

The main data area is accessed when pin 8 and at least one of pins 4, 6, 7 and 9 are low. It consists of 64 rows (requiring a 6 bit address) of 132 bits each.

Rows 0 through 43 contain the bulk of the fuse data which configures the operation of the device. Row 44 will store data but is not utilized by the chip, so you can store identification information there if you'd like, in particular you might want to utilize that area to track how many times each chip has been reprogrammed, in order to know when a chip is near its end of life.

Row 58 contains the text "1F22V10C3" stored in reverse order, with both the bits and the bytes reversed. This row can be written to, but unlike the rest of the chip which is reset to the default state whenever the chip erase command is used, any writes to row 58 are irreversable. Row 59 has no data, but writing to it disables the power-down feature of the ATF22V10C, which is otherwise activated by default.

Row 61 also has no data, but writing to it actiaves the "security fuse" which prevents the data in the chip from being read by returning all 1 bits whenever the chip is read. All other rows contain no data and writing to them has no effect.

メインデータエリアは、ピン8とピン4,6,7および9のうちの少なくとも1つがローのときにアクセスされます。これは、それぞれ132ビットの64行(6ビットアドレスが必要)で構成されています。

行0から43は、デバイスの動作を構成する大量のヒューズデータを含む。行44はデータを保存しますが、チップでは利用されないため、必要に応じて識別情報を格納できます。特に、その領域を利用して各チップが何回再プログラムされたかを知りたい場合がありますチップの寿命が近づいているとき。

行58は、逆の順序で格納されたテキスト「1F22V10C3」を含み、ビットとバイトの両方が反転される。この行は書き込み可能であるが、チップ消去コマンドが使用されるたびにデフォルト状態にリセットされるチップの残りの部分とは異なり、行58への書き込みは不可逆的である。行59にはデータはありませんが、それに書き込むとATF22V10Cのパワーダウン機能が無効になります。そうしないとデフォルトでアクティブになります。

行61にもデータはありませんが、それに書き込むと、チップが読み取られるたびにすべての1ビットを返すことで、チップ内のデータが読み取られるのを防ぐ「セキュリティヒューズ」が働きます。他のすべての行にはデータが含まれておらず、それらへの書き込みは効果がありません。

The remaining 20 bits of fuse data are accessed by making pin 8 high and at least one of pins 4, 6, 7 and 9 low. In this mode, row addresses are not shifted into the chip, as there are no row addresses in this mode. Instead you simply shift the data in and out of the chip before or after activating the strobe.

ヒューズデータの残りの20ビットは、ピン8をハイにし、ピン4,6,7および9の少なくとも1つをローにすることによってアクセスされる。 このモードでは、行アドレスはチップ内にシフトされません。 このモードでは行アドレスが存在しないためです。代わりに、ストローブをアクティブにする前または後に、データをチップの内外にシフトするだけです。

The bulk of the fuse data configures an array of AND gates which feed in groups of 8 to 16 (depending on which output pin we're speaking of) into an OR gate, the output of which goes into "macrocells" which are configured by those extra 20 bits of data, with two bits configuring each pin's macrocell.

フューズデータの大部分は、8から16のグループ(我々が話している出力ピンに依存する)をORゲートに供給するANDゲートのアレイを構成し、その出力は「マクロセル」に入り、 これらの余分な20ビットのデータは、各ピンのマクロセルを構成する2ビットである。

This data can be obtained from what is referred to as a JEDEC file (as apparently electronics people just aren't happy if they aren't naming file formats after standards organizations) which is produced from software like WinCUPL which is available for free from Atmel. Documentation for the JEDEC file is easy to find, so I won't describe it in depth here, but there are two details you won't find in descriptions of the file format:

  1. The chip expects 44 rows of 132 bits, but the data in the JEDEC file is arranged as 132 rows of 44 bits. So you need to reorganize it. Row 0 in the chip should receive bits 0, 44, 88, 132, ..., 5676, 5720, 5764, from the JEDEC file. Then row 1 contains bits 1, 45, 89, ..., 5677, 5721, 5765. Finally row 43 contains bits 43, 87, 131, ..., 5719, 5763, 5807.

  2. The 20 bits that program the macrocells are at offset 5808 in the JEDEC data. They're in the wrong order too, in that each pair of bits needs to be reversed. So first you shift bit 1 into the chip, then bit 0, then bit 3, then bit 2, then bit 5, then bit 4, etc.

このデータは、Atemelから無料で入手可能なWinCUPLのようなソフトウェアから作成された、JEDECファイルと呼ばれるものから得ることができます(エレクトロニクスの人々は標準化団体の後にファイルフォーマットを命名していないと)。JEDECファイルのドキュメントは簡単に見つかりますので、ここでは詳しく説明しませんが、ファイルフォーマットの説明には2つの詳細があります。

  1. チップは、132ビットの44行を必要とするが、JEDECファイル内のデータは、44ビットの132行として構成される。だからあなたはそれを再構成する必要があります。チップ内の行0は、JEDECファイルからビット0,44,88,132、...、5676,5720,5644を受信する必要があります。次に、行1はビット1,45,89、...、5677,5721,5765を含む。最後の行43はビット43,87,131、...、5719,5763,5807を含む。

  2. マクロセルをプログラムする20ビットは、JEDECデータのオフセット5808にある。彼らは間違った順序になっています。それぞれのビットのペアを逆にする必要があります。最初にビット1をチップに入れ、次にビット0、ビット3、ビット2、ビット5、ビット4などをシフトします。

If you wish to construct your own fuse data, have a look at page 5 of this datasheet. You'll note numbers written next to various lines. These are the address in the JEDEC file where each bit belongs. Set all of the bits to 1, then put a 0 at addresses that coorespond to where you want to join lines in the matrix.

For AND gates which you do not wish to use, you can either make all bits 1 to cause the AND gate to output a high level, or make all bits 0 to cause the AND gate to output a low level.
The two bits that configure the macrocells are explained on page 4.

Keep in mind when trying to design circuits that (a | b | c) == !(!a & !b & !c) as this allows you to put complex equations into a single AND gate row rather than use multiple rows.
There are really enough AND gate rows in there that I can't imagine running out, but if you want to, for example, make pin 23 output the logical OR of all 12 of the input pins, you'll have to use that trick to make it happen as it only has 8 AND gates assigned to it, and since those AND gates are the inputs to the OR gate, there are only 8 inputs to that OR gate, so you have to perform the operation with one of the AND gates instead, which have many more inputs. (...and WinCUPL is incapable of figuring that out, so if you don't realize it can be done, WinCUPL isn't going to help you.)

Another useful equation, as there aren't XOR gates in there, is that a ^ b = (a & !b) | (!a & b). Having both the inverted and non-inverted version of each input pin available makes constructing complex logic out of such a simple array rather easy.

独自のヒューズデータを作成する場合は、このデータシートの5ページを参照してください。さまざまな行の隣に書かれた数字に注意します。これらは、各ビットが属するJEDECファイルのアドレスです。すべてのビットを1に設定し、行列の行を結合する場所に対応するアドレスに0を設定します。

使用したくないANDゲートは、すべてのビットを1にしてANDゲートをハイレベルにするか、すべてのビットを0にしてANDゲートにローレベルを出力させます。
マクロセルを構成する2つのビットは4ページで説明しています。

(a | b | c)==!(!a&!b&!c)のような回路を設計しようとすると、複雑な方程式を入れることができます。複数の行を使用するのではなく、1つのANDゲート行に格納します。実際にそこには十分なANDゲートの行がありますが、私は不足するとは思いませんが、たとえばピン23に12個の入力ピンすべての論理和を出力させたい場合は、そのトリックを使用する必要があります。

それには8つのANDゲートしか割り当てられていないため、ANDゲートはORゲートへの入力であるため、そのORゲートには8つの入力しかないので、AND代わりに多くの入力を持つゲートを使用します(WinCUPLはそれを理解することができないので、WinCUPLはそれを行うことができないと分かっていないと助けにならないでしょう)。

XORゲートがないので、もう一つの便利な式があります。そのa ^ b =(a&!b)| (!a&b)。各入力ピンの反転バージョンと非反転バージョンの両方を使用できるようにすることで、複雑なロジックを簡単なアレイから簡単に構成することができます。

Unsolved Mysteries

The ATF22V10C does many strange things.

ATF22V10Cは多くの変なことをします。

Strange Behavior when Clock Input is Low

クロック入力がLoの場合の不思議な動作

While the data on the serial data output pin during the low half of the clock cycle is correct in most cases, for very particular bits of very particular rows (repeatable for every run with every chip I have), it is merely the inverse of the current state of the serial data input pin.
Exactly why it does this I have no idea, but it only happens on certain bits of certain rows and it's the same with every chip I have.
Whatever the reason, the result is that the serial data output pin must be sampled when the clock is high. Sampling it when it is low, or on either the rising or falling edge, will cause random failures on those bits.
I'm tempted to think that this is because of special hidden features in the chip, but absent of any reason to suspect that the chip has hidden features (as I've already figured out how to make it do everything it is documented to do) it's a lot easier to just assume the chip is glitchy.

ほとんどの場合、クロックサイクルのLoの間、シリアルデータ出力ピンのデータは正しいですが、非常に特定の行の非常に特定のビット(すべてのチップで再現する症状)は、 シリアルデータ入力ピンの現在の状態の半手が出力されます。
正確にはなぜこれを行うのか分かりませんが、特定の行の特定のビットでのみ発生し、それはすべてのチップで同じです。
理由が何であれ、クロックがハイのときシリアルデータ出力ピンをサンプリングする必要があります。 ロー・レベルまたは立ち上がりエッジまたは立ち下がりエッジのいずれかでサンプリングすると、それらのビットにランダムな障害が発生します。
私はこれがチップの特別な隠された特徴のためであると思うように誘惑されるが、チップが隠された特徴を持っていると疑う何らかの理由がない(私はすでにそれが文書化されたすべてを行う方法を考え出したので )チップがグリッチであると仮定するのはずっと簡単です。

The Second Bit of Row 31

Correctly reading bit 1 of row 31 takes some extra effort. This mystery is similar to the previous mystery, except that the chip always outputs a zero bit initially, but then, if the bit is actually programmed as a 1, and if the serial data input is changed while the chip is outputting the false 0 bit, it will switch the output to a 1 bit and keep it a 1 bit regardless of further changes on the serial data input. There are four other bits with the same problem (bits 0 of rows 45 and 62, and bit 1 of row 63) but thankfully there's nothing to read in those locations, so they can be ignored. Bit 1 of row 31 is annoying in that it's part of the fuse array that controls the device's function.

行31のビット1を正しく読み取るには、多少の努力が必要です。 このミステリーは、チップが最初は常にゼロビットを出力しますが、ビットが実際に1としてプログラムされている場合、およびチップが偽の0ビットを出力している間にシリアルデータ入力が変更された場合を除いて、 それは、シリアルデータ入力のそれ以上の変化にかかわらず、出力を1ビットに切り替え、1ビットに保ちます。 同じ問題(行45と行62のビット0と行63のビット1)を持つ4つの他のビットがありますが、ありがたいことにそれらの場所では何も読んでいないので無視できます。 31行目のビット1は、デバイスの機能を制御するヒューズアレイの一部であるという点で厄介です。

I have discovered a totally ridiculous algorithm which is able to correctly read all of the bits:

私はすべてのビットを正しく読み取ることができるまったくばかげたアルゴリズムを発見しました。

  1. sample the serial data output

  2. lower the clock input

  3. apply a high level to the serial data input

  4. sample the serial data output again

  5. apply a low level to the serial data input

  6. sample the serial data output again

  7. raise the clock input

  8. シリアルデータ出力をサンプリングする

  9. クロック入力を下げる

  10. シリアルデータ入力にハイレベルを印加する

  11. シリアルデータ出力を再度サンプリングします

  12. シリアルデータ入力にローレベルを印加する

  13. シリアルデータ出力を再度サンプリングする

  14. クロック入力を上げる

After these steps are complete, you have three versions of this particular bit. If they are "000" or "111" then there is no question as to whether the bit is a 0 or a 1. However, in a small number of cases, you'll have one of "001", "010", "101" or "110". In these cases, the chip is simply doing its rare but usual thing of making the serial data output mimic the serial data input when the clock is low, which is why I recommend above that you sample the serial data output pin when the clock is high. However, on bits like bit 1 of row 31, you'll sometimes have "011" or "100". In these cases, the bit that the chip output when the clock was high is incorrect, and so you should accept the bit that it output after you started playing with the serial data input while the clock was low.

これらのステップが完了したら、この特定のビットの3つのバージョンがあります。 "000"か "111"の場合、そのビットが0か1かは問われません。しかし、少数のケースでは、 "001"、 "010" "101"または "110"。 これらのケースでは、チップはクロックが低いときにシリアルデータ出力をシリアルデータ入力に似せるというまれな、しかし普通のことを単に行っているので、クロックが高いときにシリアルデータ出力ピンをサンプリングすることをお勧めします 。 しかし、31行目のビット1のようなビットでは、「011」または「100」が表示されることがあります。 このような場合、クロックがハイのときにチップが出力するビットは正しくないため、クロックがローの間にシリアルデータ入力で再生を開始した後に出力するビットを受け入れる必要があります。

Half-Disabled Power-Down Pin

The power-down pin, after being disabled, sometimes is only half-disabled, in that the chip will be in power-down mode when it is first turned on and remain in that mode until pin 4 becomes high, at which point it latches the non-powered-down mode and never returns to it regardless of what happens to pin 4. I've seen this happen to two chips, but both have since ceased to do it, leaving me with nothing to experiment with to find a solution.

パワーダウン・ピンは、ディスエーブルされた後、最初にオンにされたときにチップがパワーダウン・モードになり、ピン4がハイになるまでそのモードに留まり、その時点でラッチされます 私はこれが2つのチップに起こるのを見たことがありますが、両方はそれ以来、解決を見つけるために何も実験を残して、それをやめてしまいました 。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0