USBN9603 initialization

Hi,

Recently I interfaced usbn9603 chip by avr mcu. I found many alt events are triggered during initialization in my firware, but none of tx events and rx events are triggered. The typical debug messages from serial port are alt_ev=0A. I have checked the dataheet that 0A means EOP and wakeup event types.

Could anyone gives me some hints?

Reply to
terry
Loading thread data ...

Now the RX event is triggered for setup. But a lot of alt (reset) events are also triggered.

Beides, I found the external interrupt of atmega is set active low-level triggered and from the manual of atmega the INT0 pin should keep low inside interrupt ISR. But how do the USBN9603 know the completion of interrupt at atmega side when it has no acknowledgement?

Could anyone help?

Reply to
terry

Hi,

After rewriting the firmware and making a new PCB, the device get "Get descriptor" RX event. I have traced the firmware that the firmware wants to reply the descriptor to the host by the following instruction.

usbn9603WriteReg(EPTXC0,TX_TOGL+TX_EN); //enable the TX (DATA1)

However, No TX events is triggered for end point 0.

Anyone knows why? Thanks!

Reply to
terry

terry schrieb:

Which parts of the firmware did you rewrite?

You used the sources from

formatting link

I read firmware sources from National last week and will rewrite it to ATmega128 (avr-gcc) soon.

Maybe i have similiar problems in near future :)

servus thomas

Reply to
Thomas Mozgan

I have read the debug mesage from the serial port that the Get descriptor is replied and also TX events are triggered. However, PC host repeats to ask for "Get descriptor" 3 times and then suspending event is triggered. Why? I have searched someone meets exacly the same problem in forum of usb.org but no answer is given.

Reply to
terry

I have some idea about the bug. I finds in between those "Get descriptor" RX events the usbn9603 continously receive alt reset events. So I think this cause the host finally set usbn9603 to suspend state.

Anyone knows why it coninuously receives reset events from host during initialization? And how to solve it?

Reply to
terry

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.