NX2LP Devices Reset and Re-enumerate

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Is there a simmilar way to re-enumerate a NX2LP device as a FX2 device?

0 Likes
3 Replies
Anonymous
Not applicable

 Hi,

   

 

   

Please decribe the whole thing that you are trying ti implement. When you want NX2LP to renumerate? What is the application?

   

 

   

Regards,

   

Gayathri

0 Likes
Anonymous
Not applicable

We need to find a way to make the O/S to querry the device upon our UI's command to dynamically switching Nand Flash configurations. Using destructive switching such as hardware reset or power on off the device is not acceptable. From the other FX2LP forum tag attached below, I might be wrong, however I am lead to believe that it could be a way to make the O/S to querry the device.

   

FX2LP forum tag--------------------

   

I think there is an alternate way.Here what you can do is to implement a vendor command which will re-enumerate your device. You can use the following code to do that :
" case VR_RENUM:
*EP0BUF = 7;
EP0BCH = 0;
EP0BCL = 1; // Arm endpoint with # bytes to transfer
EP0CS |= bmHSNAK; // Acknowledge handshake phase of device request
EZUSB_Delay(1000);
EZUSB_Discon(TRUE); // renumerate until setup received
break;
"
If that does not work, there is one more way.You can issue an 0xa0 vendor command which is implemented in FX2LP hardware to write 0x01 at 0xE600 register which will reset the device.And when again you will write 0x00 at 0xE600 register the device will come out of reset.
The way to issue 0xa0 vendor command is:
1. Req code => 0xa0
2. value field(high and low) => 0xE600
3. Length => 1
4. data => 01 for reset and 00 for reset release in the payload of data phase.

   

End of tag-----------------------------------------------

   

I hope we can use that on the NX2LP device to achieve our goal.

   

Thanks!

   

Howard

0 Likes
Anonymous
Not applicable

 Hi,

   

 

   

Vendor commands in NX2LP will work. But just curious how are you planning to issue the same? How is you GUI talking to NX2LP?

   

 

   

Regards,

   

Gayathri

0 Likes