USB pins
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB pins
Hello,
The 16F877A does not have the USB functionality.
The 18F4550 has 3 pins on port C which are used for USB comms.
These pins are marked on the Flowcode chip diagram.
D+ - USB D+ Signal
D- - USB D- Signal
Vusb - USB regulator output - connects to an external 220nF capacitor between Vusb and ground.
As well as the USB signals you also have to use a supported oscillator configuration. My advise is to use a crystal with one of the following frequencies. Any frequency can be used, the microcontroller will still run at the same speed 12MIPs.
Compatible crystal frequencies - 4MHz, 8MHz, 12MHz, 16MHz, 20MHz
Configuration settings for the device should be loaded as seen here:
http://www.matrixmultimedia.com/resourc ... %20PIC.pdf
And here is the link to the Article
http://www.matrixmultimedia.com/article.php?a=363
The 16F877A does not have the USB functionality.
The 18F4550 has 3 pins on port C which are used for USB comms.
These pins are marked on the Flowcode chip diagram.
D+ - USB D+ Signal
D- - USB D- Signal
Vusb - USB regulator output - connects to an external 220nF capacitor between Vusb and ground.
As well as the USB signals you also have to use a supported oscillator configuration. My advise is to use a crystal with one of the following frequencies. Any frequency can be used, the microcontroller will still run at the same speed 12MIPs.
Compatible crystal frequencies - 4MHz, 8MHz, 12MHz, 16MHz, 20MHz
Configuration settings for the device should be loaded as seen here:
http://www.matrixmultimedia.com/resourc ... %20PIC.pdf
And here is the link to the Article
http://www.matrixmultimedia.com/article.php?a=363
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- JohnCrow
- Valued Contributor
- Posts: 1367
- Joined: Wed Sep 19, 2007 1:21 pm
- Location: Lincolnshire
- Has thanked: 364 times
- Been thanked: 716 times
- Contact:
Re: USB pins
Hi Andreas
The 16F877A does not have USB built in.
The 18F4550 is on port C, not sure which pins without looking in the datasheets though.
You should be able to see it by viewing the chip pinout in flowcode though.
If using the E-block the information should be on the data file that goes with that too.
Remember to use a 4MHz crystal, setup the advanced settings and change flowcode frequency to 48MHz
There are posts that cover setting up in some depth on this forum
Regards John
The 16F877A does not have USB built in.
The 18F4550 is on port C, not sure which pins without looking in the datasheets though.
You should be able to see it by viewing the chip pinout in flowcode though.
If using the E-block the information should be on the data file that goes with that too.
Remember to use a 4MHz crystal, setup the advanced settings and change flowcode frequency to 48MHz
There are posts that cover setting up in some depth on this forum
Regards John
1 in 10 people understand binary, the other one doesn't !
- JohnCrow
- Valued Contributor
- Posts: 1367
- Joined: Wed Sep 19, 2007 1:21 pm
- Location: Lincolnshire
- Has thanked: 364 times
- Been thanked: 716 times
- Contact:
Re: USB pins
Looks like we posted almost at the same time:)
1 in 10 people understand binary, the other one doesn't !
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB pins
Sorry John must have just beat you to it, looks like you answer has more info anyway.
Cheers for posting
Cheers for posting
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- achillis1
- Posts: 347
- Joined: Thu Oct 09, 2008 9:19 am
- Has thanked: 91 times
- Been thanked: 8 times
- Contact:
Re: USB pins
Thanks a lot!!!
Yes, sorry about the 16F877A!
I did searched about usb connection to find a previous topic but I must be blind
John says to use a 4Mhz crystal, can't I use the 20 Mhz?
Never the less I have a ready made board with 18F4550 and built in USB adaptor so I think that for the moment I will not be bothering with crystals!
Thanks again!
Yes, sorry about the 16F877A!
I did searched about usb connection to find a previous topic but I must be blind
John says to use a 4Mhz crystal, can't I use the 20 Mhz?
Never the less I have a ready made board with 18F4550 and built in USB adaptor so I think that for the moment I will not be bothering with crystals!
Thanks again!
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB pins
Hello,
You can use any of the following crystal frequencies.
4MHz, 8MHz, 12MHz, 16MHz, 20MHz
I have also been informed that you can set the config setting to use the 20MHz option and then use the standard 19.6608MHz crystal we supply on our hardware. This seems to work reliably but I wouldn't recommended it for actual wholesale products.
You can use any of the following crystal frequencies.
4MHz, 8MHz, 12MHz, 16MHz, 20MHz
I have also been informed that you can set the config setting to use the 20MHz option and then use the standard 19.6608MHz crystal we supply on our hardware. This seems to work reliably but I wouldn't recommended it for actual wholesale products.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- achillis1
- Posts: 347
- Joined: Thu Oct 09, 2008 9:19 am
- Has thanked: 91 times
- Been thanked: 8 times
- Contact:
Re: USB pins
!!! why not use it for actual wholesale products?
By the way, does your products pass for the CE marking?
By the way, does your products pass for the CE marking?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB pins
I wouldn't use the 19.6608 MHz crystal for wholesale products as it is out of tolerance for the device. E.g. it is not the 20MHz crystal specified and while it may work in one offs there may be problems with mass markets and slightly less tolerant USB host hardware.
Yes all of our products are CE approved.
Yes all of our products are CE approved.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel