|
|
View previous topic :: View next topic |
Author |
Message |
cagabit
Joined: 19 Dec 2014 Posts: 7
|
USB CDC with 24f |
Posted: Thu Jan 08, 2015 10:52 pm |
|
|
Hi,
Trying to implement USB CDC with 24FJ128GB206, compiler 5.015
Having 20Mhz crystal set the fuses :
Code: | #fuses NOWINDIS,NOWDT,ICSP3,NOWRT,NOPROTECT,NOJTAG
#fuses NOIESO,NOWPFP,NOWPDIS,NOWPCFG,NOPR,NOIOL1WAY,NOOSCIO,NOCKSNOFSM
#use delay(clock=32M,USB_FULL)
#fuses HS, PR_PLL, PLL5,PLL96MHZ |
But nothing happens in the device manager, on the PC !?
Suspected with the HS fuse but best choice is that i think ?
Dont think any problem with the hardware, used the same circuit to connect USB HID but with XC16 compiler, without any problem.
Any guidance will be my light |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19535
|
|
Posted: Fri Jan 09, 2015 2:16 am |
|
|
Your fuses should complete _before_ your delay statement. As it stands, the compiler may have chosen a different pattern to give the oscillator you want, and you then override this....
Do a search here. There was a thread perhaps two months ago, with the poster having problems getting USB to work on one of the PIC24 'OTG' chips.
It's here:
<http://www.ccsinfo.com/forum/viewtopic.php?t=52758&highlight=usb+otg>
I'm not sure if he ever resolved this?. |
|
|
cagabit
Joined: 19 Dec 2014 Posts: 7
|
|
Posted: Fri Jan 09, 2015 4:34 am |
|
|
Your answer is great Ttelmah, thank you.
For future reference:
First, I missed the init sub of USB i think, I was trying to init with the code,
which was the only acceptable solution for me when trying CDC with the PIC18F2550. But from the post you linked it should be,
And IT IS OK NOW ! Windows shows the COMx port without problem.
Also before this corrected the order or the FUSES and the DELAY line like,
Code: | #fuses NOWINDIS,NOWDT,ICSP3,NOWRT,NOPROTECT,NOJTAG
#fuses NOIESO,NOWPFP,NOWPDIS,NOWPCFG,NOPR,NOIOL1WAY,NOOSCIO,NOCKSNOFSM
#FUSES CKSFSM
#fuses HS, PR_PLL, PLL5,PLL96MHZ
#use delay(clock=32M,USB_FULL) |
|
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19535
|
|
Posted: Fri Jan 09, 2015 10:17 am |
|
|
Good.
Shows the power of some of the records here on the forum.
Have fun. |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|