Hi,
I have created an application in CCS C for the 18f4550 chip, which works very well in simulated mode (Proteus 7) and on my own demo board.
I have been porting it across to C18, the simulated version works fine in Proteus, however, the "real" version doesn't seem happy, it will create a COM port and when I connect to Hyperterminal, none of the commands are accepted, I have debugged the application and it appears for some reason to constantly be recieving '6' into the input buffer of the USB.
I reflashed with my CCS C app and it works absolutely perfectly, reflash with C18 app, and it goes wrong.
I am sure the code is correct, as it is a port from the CCS C and it works in the SIM.
There is a define which sets the OSC speed between 4 and 48MHz, and I checked this was correct, the board is using a 20MHz crystal.
Is there any reason why the USB would be constantly receving '6' on the buffer? The Chip is working fine, I use the Microchip FS USB demo code as a base, not checked the code yet, but it also worked in simulator setting freq to 4MHz, the crystal is fine as the CCS C app works, RS232 works fine through the MAX 232 CPE chip.
Any ideas anyone? It's really bugging me now.
Kind Regards
Wilksey
I have created an application in CCS C for the 18f4550 chip, which works very well in simulated mode (Proteus 7) and on my own demo board.
I have been porting it across to C18, the simulated version works fine in Proteus, however, the "real" version doesn't seem happy, it will create a COM port and when I connect to Hyperterminal, none of the commands are accepted, I have debugged the application and it appears for some reason to constantly be recieving '6' into the input buffer of the USB.
I reflashed with my CCS C app and it works absolutely perfectly, reflash with C18 app, and it goes wrong.
I am sure the code is correct, as it is a port from the CCS C and it works in the SIM.
There is a define which sets the OSC speed between 4 and 48MHz, and I checked this was correct, the board is using a 20MHz crystal.
Is there any reason why the USB would be constantly receving '6' on the buffer? The Chip is working fine, I use the Microchip FS USB demo code as a base, not checked the code yet, but it also worked in simulator setting freq to 4MHz, the crystal is fine as the CCS C app works, RS232 works fine through the MAX 232 CPE chip.
Any ideas anyone? It's really bugging me now.
Kind Regards
Wilksey