PDA

View Full Version : PortA reset zero after USBINIT / Service ?



sirnoname
- 29th November 2006, 14:28
Hi,

i wonder why the portA goes zero after the first
USBService behind an USBINIT ?
What is the reason ? The C18 works correct. Seems a problem in PicBasic :(
USBReset=PortReset ?
Also if I use LATA.
If i do a LATA.5=1 every milisecond, i can see that
the Port goes to ground very often after an usbinit, not only one time.

After about 1-2 seconds i have the full control again and all works correctly.

cu

mister_e
- 30th November 2006, 03:59
There's no problem like that here.. post your code, PIC#, Schematic... all you have on hand.

sirnoname
- 30th November 2006, 12:43
Hi mister_e,

are you from Melab, because u wrote it like u are ?

Now i can say that this failure only appears if I use composite devices.
Such as keyboard and mouse. Therefore I modified the the usb18.asm
a little bit, because melab don't support composite. (reportdescriptor x2)
The device works good but not the 1-2 seconds after plugin in.
Seems like it do some reset or overwrites something.

Have you done something like this before ?

regards
sirnoname

ps. 18f2455, 2550 ...

mister_e
- 1st December 2006, 04:10
Nope i'm not from Melabs. I'm just a long time enthusiast and user ;)

Interesting problem so far... nope i never tried the composite stuff in my lasts USB projects... but it's sounds interesting. if you want, post it here for the community and experts benefit or in ZIP on my e-mail.

sirnoname
- 1st December 2006, 15:37
Done now, some mistake in the asm firmware solved.
Now i have 1xCDC, 4xHID working at same time in one device.

Seems the chip dont like twice endpoint resets :)

cu