cancel
Showing results for 
Search instead for 
Did you mean: 

USB Low-Full-High Speed Peripherals

HiMa_3794786
New Contributor

Hi,

I met a problem with devices of cy7c68013a and 24lc128.

I wrote a firmware and got two formats: .hex and .iic. After xxx.hex loaded into the RAM, the usb renumerated and worked well.  But when I loaded the xxx.iic into the eeprom, the usb can't renumerate.

I assure xxx.iic was loaded into eeprom and the format is right. The first byte is 0xC2.

I don't know whether the program in eeprom wasn't loaded into RAM or loaded but not renumerated.

Development environment

1) I am using a Cypress FX2LP DVK.

2) Firmware is being used after modifying AN 63787 - EZ - USB ® FX 2 L 1.

Confirmed

1) We probed the I2C line and confirmed that it was receiving the signal.

2) Using Vend_ax example (FX 2 LP DVK), read from EEPROM using vendor command and confirm that the first byte is 0 x C 2.

I attach a hex and an iic file here.

Regards,

thanks in advance

0 Likes
1 Solution
HirotakaT_91
Moderator
Moderator

Hi Maeda-san,

We found that your program have an improper statement in the "Setup Data Available" interrupt.

Your code:

// Setup Data Available Interrupt Handler

void ISR_Sudav(void) interrupt 0

{

   GotSUD = TRUE;            // Set flag

   EZUSB_IRQ_CLEAR();

   USBIRQ = bmSUDAV;    // Clear SUDAV IRQ

  GotSUD = TRUE;            // Set flag

   EZUSB_IRQ_CLEAR();

   USBIRQ = bmSUDAV;    // Clear SUDAV IRQ

   GotSUD = TRUE;           // Set flag

   EZUSB_IRQ_CLEAR();

   USBIRQ = bmSUDAV;   // Clear SUDAV IRQ

}

Could you please modify your code as follows? Then, it works.

Modified code:

// Setup Data Available Interrupt Handler

void ISR_Sudav( void ) interrupt 0

{

   GotSUD = TRUE;         // Set flag

   EZUSB_IRQ_CLEAR( );

   USBIRQ = bmSUDAV; // Clear SUDAV IRQ

}

Best regards,

Hirotaka Takayama

View solution in original post

0 Likes
10 Replies