<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Servus!<br>
</p>
<div class="moz-cite-prefix">On 03.01.21 12:35, Matthias Weber via
tiptoi-hw wrote:<br>
</div>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de">
<p>Hallo!</p>
<div class="moz-cite-prefix">Sven A. Huerlimann via tiptoi-hw
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:9da8ef97-a5b2-c561-0cc2-5cb4369b69bb@sighup.ch">
<pre class="moz-quote-pre" wrap="">Hallo zusammen, ein gutes Neues!
Ich hab nochmals ein Verständnisproblem beim NAND Controller, ev. kann
mir da jemand weiterhelfen:
Ich hab ein halbwegs brauchbares Fundament für die NFC-Emulation. Ein
ungefähres Gespür für die Register und den Ablauf einer Flash-Read
Operation.</pre>
</blockquote>
<p>Uh, war kurz verwirrt. NFC = NAND Flash Controller?</p>
<p>Für mich hat sich NFC als <span>Near Field Communication
eingebrannt.<br>
</span></p>
</blockquote>
Genau.. Bei mir eigentlich auch, aber irgendwann hab ich kapituliert
und das Anyka-Wording übernommen.<br>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de">
<p><span> </span></p>
<blockquote type="cite"
cite="mid:9da8ef97-a5b2-c561-0cc2-5cb4369b69bb@sighup.ch">
<pre class="moz-quote-pre" wrap="">Was ich jetzt sehe, ist das die FW folgendes macht:
- NAND-Reset (0xff, no cycles)
- NAND-Read (0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30)
- und dann ein weiteres Command mit dem "Continue" bit gesetzt, aber nur
"ein" write ins command register.</pre>
</blockquote>
<p>Kannst du kurz nochmal erläutern, was du mit der Beschreibung
in den Klammern meinst? Beziehst du dich immer auf das Kommando?<br>
</p>
</blockquote>
<p>Jup. Der NFC hat ein Register an 0x0404a000 (nennen wir es mal
NFC_COMMAND) und darüber (0ffset 0x04 - 0x1C) weitere Register im
opensource-treiber nicht explizit benannt sind, aber offenbar die
weiteren Cycle abbilden.</p>
<p>Ein Read-Cycle mit Addresse schreibt zum Beispiel (Sorry fürs
Spamen und die etwas infantile Formatierung):</p>
<p><font face="monospace">nfc status write<br>
Command valid bit set<br>
Chipselect asserted<br>
NFC_CTRL_REG_CE_SAVE_BIT asserted<br>
nfc status<br>
nfc status write<br>
Start of Command Cyce
///////////////////////////////////////////////<br>
NFC_COMMAND write (cycle 0): 00000064<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH ENABLE<br>
ADDRESSS LATCH DISABLE<br>
NFC_CMD_REG_CMD_CONF
++++++++++++++++++++++++++++++++++++++++++++++++++++++++<br>
Commmand Cycle<br>
NFC_COMMAND write (cycle 1): 00000062<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH ENABLE<br>
NFC_CMD_REG_ADD_CONF
========================================================<br>
00000062<br>
NFC_COMMAND write (cycle 2): 00000062<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH ENABLE<br>
NFC_CMD_REG_ADD_CONF
========================================================<br>
00000062<br>
NFC_COMMAND write (cycle 3): 00000062<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH ENABLE<br>
NFC_CMD_REG_ADD_CONF
========================================================<br>
00000062<br>
NFC_COMMAND write (cycle 4): 00000062<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH ENABLE<br>
NFC_CMD_REG_ADD_CONF
========================================================<br>
00000062<br>
NFC_COMMAND write (cycle 5): 00000062<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH ENABLE<br>
NFC_CMD_REG_ADD_CONF
========================================================<br>
00000062<br>
NFC_COMMAND write (cycle 6): 00018064<br>
NFC_CMD_REG_INFO_POS write: 0030<br>
NFC_CMD_REG_CMD_BIT write<br>
WRITE ENABLE<br>
COMMAND LATCH ENABLE<br>
ADDRESSS LATCH DISABLE<br>
NFC_CMD_REG_CMD_CONF
++++++++++++++++++++++++++++++++++++++++++++++++++++++++<br>
NFC_COMMAND write (cycle 7): 0001dc01<br>
NFC_CMD_REG_INFO_POS write: 003b<br>
NFC_CMD_REG_DELAY_BIT write<br>
WRTIE DISABLE<br>
COMMAND LATCH DISABLE<br>
ADDRESSS LATCH DISABLE<br>
NFC_CMD_REG_DELAY_BIT
-------------------------------------------------------<br>
EEEENNNNNDDDD of TRANSACTION
oooooooooooooooooooooooooooooooooooo<br>
NFC_CMD_REG_LAST_BIT write<br>
End Cycle<br>
Got NAND command: 00, Address: 00, 00, 00, 00, 00, End: 30,
Delay: 3b<br>
EEEENNNNNDDDD of TRANSACTION
oooooooooooooooooooooooooooooooooooo</font><br>
</p>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de">
<p> </p>
<p>Ich habe gerade das Datenblatt eines HY27UF084G2B und
<a class="moz-txt-link-freetext"
href="https://github.com/maehw/ftdi-nand-flash-reader/blob/master/bitbang_ft2232.c"
moz-do-not-send="true">https://github.com/maehw/ftdi-nand-flash-reader/blob/master/bitbang_ft2232.c</a>
befragt.</p>
<p>0x00 0x30 ist ein Page Read (READ1) Kommando. Zwischen 0x00 und
0x30 kommen 5 Adress-Bytes (2x Spalte, 3x Zeile).<br>
</p>
<p>Und dann werden bei einer Page wahrscheinlich <span
class="pl-c1">2112 Bytes am Stück gelesen. Vielleicht siehst
du das und ein interner Puffer füllt sich?<br>
</span></p>
</blockquote>
<p>Ok. Hier ist das Problem, dass ich ja den Puffer füllen muss :) <br>
</p>
<p>Ich denk ich schaufel einfach mal 2112 Bytes und sehe was
passiert.<br>
</p>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de">
<p><span class="pl-c1"> </span></p>
<blockquote type="cite"
cite="mid:9da8ef97-a5b2-c561-0cc2-5cb4369b69bb@sighup.ch">
<pre class="moz-quote-pre" wrap="">Meine naive Annahme: Read-Cycle setzt mal auf (Startadresse, etc. etc.)
und danach kann mit diesem "Continue" einfach die nächste
Page?Block?Sector?Huga abgefragt werden?</pre>
</blockquote>
<p>Bei SPI-Flash kenne ich das, dass man keine weiteren Adressen
explizit angeben muss. Hier könnte ich mir vorstellen, dass der
NAND Flash Controller einen Autoinkrement durchführt.<br>
</p>
</blockquote>
Was wird dann inkrementiert? Zeile? Spalte? Da magelts bei mir stark
an Durchblick.<br>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de">
<p> </p>
Gruß<br>
Matthias<br>
</blockquote>
Gruss Sven<br>
<blockquote type="cite"
cite="mid:f2691b57-e634-441b-7b99-793781174ae9@gmx.de"> <br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
tiptoi-hw mailing list
<a class="moz-txt-link-abbreviated" href="mailto:tiptoi-hw@lists.nomeata.de">tiptoi-hw@lists.nomeata.de</a>
<a class="moz-txt-link-freetext" href="https://lists.nomeata.de/mailman/listinfo/tiptoi-hw">https://lists.nomeata.de/mailman/listinfo/tiptoi-hw</a>
</pre>
</blockquote>
</body>
</html>