From: SourceForge.net <no...@so...> - 2011-09-18 13:41:18
|
Bugs item #1772322, was opened at 2007-08-11 16:12 Message generated for change (Settings changed) made by maartenbrock You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1772322&group_id=599 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: pic16 target Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: mirkobo (mirkobo) Assigned to: Nobody/Anonymous (nobody) >Summary: PIC16: VUSB problem Initial Comment: I can't activate the VUSB (pin 14) on a PIC18F2455 compiling my project with SDCC release 2.7.0 and gputils 0.13.4. sdcc -v produces: SDCC : mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08 2.7.0 #4 818 (May 31 2007) (MINGW32) gplink -v produces: gplink-0.13.4 alpha I wrote a small source file that does nothing but activate VUSB (with the instruction UCONbits.USBEN = 1;). The VUSB pin voltage is some millivolt over zero but not 3.3 V, the expected value. The strange thing is that compiling the same project with SDCC 2.5.6 it works well, I get the 3.3 V out of the pin 14. sdcc -v produces: SDCC : pic16/pic14 2.5.6 #4161 (May 10 2006) (MSVC) gplink is the same. I'm uploading the file Makefile_main with the makefile I used to build the project at the top and the source file main.c at the bottom. I used Microsoft nmake to build the project. Anyway in that file there are the compiling options I used. Best regards. Mirko ---------------------------------------------------------------------- Comment By: xander (xan-der) Date: 2007-10-24 14:13 Message: Logged In: YES user_id=245280 Originator: NO Try rebuilding the libraries using 2455 (or 4550, ...) as the default processor. Do not use the libraries in the standard install of sdcc. The 2455 family has SFR's out of the range of what is in stock libraries (which I believe are 242 based). Xander ---------------------------------------------------------------------- Comment By: mirkobo (mirkobo) Date: 2007-08-14 21:57 Message: Logged In: YES user_id=1865392 Originator: YES I've recompiled the libraries using the 2455 as the default processor and now I get 3.3 V on pin 14 (VUSB). Thank you very muxh Xander. ---------------------------------------------------------------------- Comment By: xander (xan-der) Date: 2007-08-13 14:10 Message: Logged In: YES user_id=245280 Originator: NO I've encountered this problem. There is a simple workaround. Recompile the libraries using the 2455 (or 4550, ...) as the default processor. IIRC, the default libraries don't allocate the right address range for the 2455's SFRs (the default PIC 18, the 242 family, has fewer SFRs). Xander ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1772322&group_id=599 |