Cypress AN6077の取扱説明書

23ページ 0.23 mb
ダウンロード

ページに移動 of 23

Summary
  • Cypress AN6077 - page 1

    February 19, 2008 Document No. 001-15342 Rev . ** 1 with FX2LP Implementing an 8-Bit Asynchronous Interface Application Note Abstract This application note discusses how to configure the General Programmable Interface (GPIF) and slave FIFOs of the EZ-USB FX2LP™ to implement an 8-bit asynchronous interface. The GPIF is a prog ramma ble 8 or 1 6-bi ...

  • Cypress AN6077 - page 2

    February 19, 2008 Document No. 001-15342 Rev . ** 2 AN6077 GPIF Master Pin Descriptions The GPIF pin names, descriptions, an d their uses are dis- cussed in this section. RDYn Input s RDY[5:0] are ‘ready’ inputs that can be sampled and allow a transaction to wait (inserting wa it states), continue, or repeat until the signal is at the appr opri ...

  • Cypress AN6077 - page 3

    February 19, 2008 Document No. 001-15342 Rev . ** 3 AN6077 Figure 2 shows the GPIF De signer view of the FIFO Read waveform. FIFOWR When creating the F IFOWR waveform the following timin g parameters must be met. tWR pwl - SL WR Pulse Wid th LO W = 50 ns (minimum) tWR pwh - SL WR Pulse Width HIGH = 50 ns (minimum) tSFD - SL WR to FIFO DA T A Setup ...

  • Cypress AN6077 - page 4

    February 19, 2008 Document No. 001-15342 Rev . ** 4 AN6077 Figure 4. FIFO Read Waveform in gpif.c Figure 5. FIFO Write W avefo rm in gpif.c 8051 Firmware Programming (Master) This section describes how to config ure the 8051 to support the interface on the master side (registe r se ttings and others) and discusses the firmware implemented to perfor ...

  • Cypress AN6077 - page 5

    February 19, 2008 Document No. 001-15342 Rev . ** 5 AN6077 The firmware uses the AUTO mode for both IN and OUT transfers. Th is means that the maximum size (512 bytes) packets are committed automat ical ly from the pe ripheral domain to the USB domai n for OUT transfers. For IN trans- fers, they are committed from USB to the peripheral doma in. The ...

  • Cypress AN6077 - page 6

    February 19, 2008 Document No. 001-15342 Rev . ** 6 AN6077 IOA = 0x80; xFIFOTC_OUT = ( ( EP2FIFOBCH << 8 ) + EP2FIFOBCL ); // setup GPIF transaction count SYNCDELAY; EP2GPIFTCH = EP2FIFOBCH; SYNCDELAY; EP2GPIFTCL = EP2FIFOBCL; // trigger FIFO write transaction(s) SYNCDELAY; GPIFTRIG = GPIFTRIGWR | GP IF_EP2; // once master (GPIF) drains OUT p ...

  • Cypress AN6077 - page 7

    February 19, 2008 Document No. 001-15342 Rev . ** 7 AN6077 if( EP68FIFOFLGS & 0x01 ) { // EP6FF=1, when fifo "full" } else { // EP6FF=0, when fifo "not full", fo r example, buffer available // setup GPIF transaction count SYNCDELAY; EP6GPIFTCH = 0x02; SYNCDELAY; EP6GPIFTCL = 0x00; // trigger FIFO read transaction(s), using S ...

  • Cypress AN6077 - page 8

    February 19, 2008 Document No. 001-15342 Rev . ** 8 AN6077 Code Listing for Master Side #pragma NOIV // D o not generate interrupt vectors #include "fx2.h" #include "fx2regs.h" #include "fx2sdly.h" // S YNCDELAY macro extern BOOL GotSUD; // R eceived setup data flag extern BOOL Sleep; extern BOOL Rwuen; extern BOOL Sel ...

  • Cypress AN6077 - page 9

    February 19, 2008 Document No. 001-15342 Rev . ** 9 AN6077 // EP4 and EP8 are not used in thi s implementation SYNCDELAY; // EP4CFG = 0x20; // c lear valid bit SYNCDELAY; // EP8CFG = 0x60; // c lear valid bit SYNCDELAY; // FIFORESET = 0x80; // a ctivate NAK-ALL to avoid race co nditions SYNCDELAY; // FIFORESET = 0x82; // r eset, FIFO 2 SYNCDELAY; / ...

  • Cypress AN6077 - page 10

    February 19, 2008 Document No. 001-15342 Rev . ** 10 AN6077 } #define GPIFTRIGWR 0 #define GPIFTRIGRD 4 #define GPIF_EP2 0 #define GPIF_EP4 1 #define GPIF_EP6 2 #define GPIF_EP8 3 void TD_Poll( void ) { // Called repeatedly while the dev ice is idle static WORD xFIFOTC_OUT = 0x0000; static WORD xFIFOTC_IN = 0x0000; // Registers which require a sync ...

  • Cypress AN6077 - page 11

    February 19, 2008 Document No. 001-15342 Rev . ** 1 1 AN6077 // setup GPIF transaction count SYNCDELAY; EP2GPIFTCH = EP2FIFOBCH; SYNCDELAY; EP2GPIFTCL = EP2FIFOBCL; // trigger FIFO write tran saction(s), using SFR SYNCDELAY; GPIFTRIG = GPIFTRIGWR | GP IF_EP2; // once master (GPIF) drai ns OUT packet, it (re)arms to us b domain // this path is alway ...

  • Cypress AN6077 - page 12

    February 19, 2008 Document No. 001-15342 Rev . ** 12 AN6077 // RDY0=1, when peripheral i s "not empty" // drive FIFOADDR lines OEA = 0xC0; IOA = 0x00; if( EP68FIFOFLGS & 0x01 ) { // EP6FF=1, when fifo "ful l" } else { // EP6FF=0, when fifo "not full", for example, buffer avai lable // setup GPIF transaction count S ...

  • Cypress AN6077 - page 13

    February 19, 2008 Document No. 001-15342 Rev . ** 13 AN6077 } BOOL TD_Suspend( void ) { // Called before the device goes i nto suspend mode return( TRUE ); } BOOL TD_Resume( void ) { // Called after the device resumes return( TRUE ); } //---------------------------------- -------------------------------- ----------- // Device Request hooks // The f ...

  • Cypress AN6077 - page 14

    February 19, 2008 Document No. 001-15342 Rev . ** 14 AN6077 { // Called when a Set Interface com mand is received EP0BUF[ 0 ] = AlternateSetting; EP0BCH = 0; EP0BCL = 1; return( TRUE ); // Handled by user code } BOOL DR_GetStatus( void ) { return( TRUE ); } BOOL DR_ClearFeature( void ) { return( TRUE ); } BOOL DR_SetFeature( void ) { return( TRUE ) ...

  • Cypress AN6077 - page 15

    February 19, 2008 Document No. 001-15342 Rev . ** 15 AN6077 EZUSB_IRQ_CLEAR( ); USBIRQ = bmURES; // Clear U RES IRQ } void ISR_Susp( void ) interrupt 0 { Sleep = TRUE; EZUSB_IRQ_CLEAR( ); USBIRQ = bmSUSP; } void ISR_Highspeed( void ) interrupt 0 { if ( EZUSB_HIGHSPEED( ) ) { pConfigDscr = pHighSpeedConfig Dscr; pOtherConfigDscr = pFullSpeedC onfigD ...

  • Cypress AN6077 - page 16

    February 19, 2008 Document No. 001-15342 Rev . ** 16 AN6077 } void ISR_Ep1pingnak( void ) interrup t 0 { } void ISR_Ep2pingnak( void ) interrup t 0 { } void ISR_Ep4pingnak( void ) interrup t 0 { } void ISR_Ep6pingnak( void ) interrup t 0 { } void ISR_Ep8pingnak( void ) interrup t 0 { } void ISR_Errorlimit( void ) interrup t 0 { } void ISR_Ep2piderr ...

  • Cypress AN6077 - page 17

    February 19, 2008 Document No. 001-15342 Rev . ** 17 AN6077 } void ISR_Ep8fflag( void ) interrupt 0 { } void ISR_GpifComplete( void ) interr upt 0 { } void ISR_GpifWaveform( void ) interr upt 0 { // FIFORd WF detected peripheral prematurely empty (less than max . pkt. size) GPIFABORT = 0xFF; // a bort to handle shortpkt INPKTEND = 0x06; SYNCDELAY; ...

  • Cypress AN6077 - page 18

    February 19, 2008 Document No. 001-15342 Rev . ** 18 AN6077 // PINFLAGSxx EPxFIFOIRQ // EPxFIFOIE GPIFIRQ // GPIFIE GPIFADRH:L // UDMACRCH:L EPxGPIFTRIG // GPIFTRIG SYNCDELAY; FIFORESET = 0x80; // a ctivate NAK-ALL to avoid race co nditions SYNCDELAY; // s ee TRM section 15.14 FIFORESET = 0x82; // r eset, FIFO 2 SYNCDELAY; // FIFORESET = 0x84; // r ...

  • Cypress AN6077 - page 19

    February 19, 2008 Document No. 001-15342 Rev . ** 19 AN6077 EP2FIFOCFG = 0x10; // A UTOOUT=1, WORDWIDE=0 SYNCDELAY; EP6FIFOCFG = 0x0C; // A UTOIN=1, ZEROLENIN=1, WORDWIDE=0 SYNCDELAY; } void TD_Poll( void ) { // Called repeatedly while the dev ice is idle // nothing to do;slave fifo's are in AUTO mode } BOOL TD_Suspend( void ) { // Called befo ...

  • Cypress AN6077 - page 20

    February 19, 2008 Document No. 001-15342 Rev . ** 20 AN6077 EP0BUF[ 0 ] = Configuration; EP0BCH = 0; EP0BCL = 1; return(TRUE); // Handled by user code } BOOL DR_SetInterface( void ) { // Called when a Set Interface com mand is received AlternateSetting = SETUPDAT[ 2 ]; return( TRUE ); // Handled by user code } BOOL DR_GetInterface( void ) { // Call ...

  • Cypress AN6077 - page 21

    February 19, 2008 Document No. 001-15342 Rev . ** 21 AN6077 USBIRQ = bmSOF; // Clear S OF IRQ } void ISR_Ures( void ) interrupt 0 { if ( EZUSB_HIGHSPEED( ) ) { pConfigDscr = pHighSpeedConfig Dscr; pOtherConfigDscr = pFullSpeedC onfigDscr; } else { pConfigDscr = pFullSpeedConfig Dscr; pOtherConfigDscr = pHighSpeedC onfigDscr; } EZUSB_IRQ_CLEAR( ); U ...

  • Cypress AN6077 - page 22

    February 19, 2008 Document No. 001-15342 Rev . ** 22 AN6077 } void ISR_Ep4inout( void ) interrupt 0 { } void ISR_Ep6inout( void ) interrupt 0 { } void ISR_Ep8inout( void ) interrupt 0 { } void ISR_Ibn( void ) interrupt 0 { } void ISR_Ep0pingnak( void ) interrup t 0 { } void ISR_Ep1pingnak( void ) interrup t 0 { } void ISR_Ep2pingnak( void ) interru ...

  • Cypress AN6077 - page 23

    AN6077 Cypress Semico nd uctor 198 Champi on Cou rt San Jose, CA 9513 4-1709 Phone: 408- 943-2600 Fax: 408-94 3-4730 http://www.cypr ess.com © Cypress S emiconducto r Corpora tion, 200 6-2008. The informati on contained herein is subject to chang e without notice. Cy press Semiconducto r Corporation a ssumes no resp onsibility for t he use of an y ...

メーカー Cypress カテゴリー Network Card

Cypress AN6077のメーカーから受け取ることができるドキュメントは、いくつかのグループに分けられます。その一部は次の通りです:
- #BRANDの図面#
- AN6077の取扱説明書
- Cypressの製品カード
- パンフレット
- またはCypress AN6077の消費電力シール
それらは全部重要ですが、デバイス使用の観点から最も重要な情報は、Cypress AN6077の取扱説明書に含まれています。

取扱説明書と呼ばれる文書のグループは、Cypress AN6077の取り付け説明書、サービスマニュアル、簡易説明書、またはCypress AN6077のユーザーマニュアル等、より具体的なカテゴリーに分類されます。ご必要に応じてドキュメントを検索しましょう。私たちのウェブサイトでは、Cypress AN6077の製品を使用するにあたって最も人気のある説明書を閲覧できます。

関連する取扱説明書

Cypress AN6077デバイスの取扱説明書はどのようなものですか?
取扱説明書は、ユーザーマニュアル又は単に「マニュアル」とも呼ばれ、ユーザーがCypress AN6077を使用するのを助ける技術的文書のことです。説明書は通常、全てのCypress AN6077ユーザーが容易に理解できる文章にて書かれており、その作成者はその分野の専門家です。

Cypressの取扱説明書には、基本的な要素が記載されているはずです。その一部は、カバー/タイトルページ、著作権ページ等、比較的重要度の低いものです。ですが、その他の部分には、ユーザーにとって重要な情報が記載されているはずです。

1. Cypress AN6077の説明書の概要と使用方法。説明書にはまず、その閲覧方法に関する手引きが書かれているはずです。そこにははCypress AN6077の目次に関する情報やよくある質問、最も一般的な問題に関する情報を見つけられるはずです。つまり、それらはユーザーが取扱説明書に最も期待する情報なのです。
2. 目次。Cypress AN6077に関してこのドキュメントで見つけることができる全てのヒントの目次
3. Cypress AN6077デバイスの基本機能を使うにあたってのヒント。 Cypress AN6077のユーザーが使い始めるのを助けてくれるはずです。
4. トラブルシューティング。Cypress AN6077に関する最も重要な問題を診断し、解決するために役立つ体系化された手続き
5. FAQ。よくある質問
6. 連絡先。一人では問題を解決できない場合に、その国におけるCypress AN6077のメーカー/サービスへの連絡先に関する情報。

Cypress AN6077についてご質問がありますか?

次のフォームを使用してください

見つけた説明書を読んでもCypress AN6077の問題を解決できない場合、下記のフォームを使用して質問をしましょう。ユーザーのどなたかがCypress AN6077で同様の問題を抱えていた場合、その解決方法を共有したいと考えるかもしれません。

画像のテキストを入力してください

コメント (0)