PDA

View Full Version : Command line



Bopo
- 26th February 2006, 01:54
Hello, i want to use PBP with the command line, and i want PBP to be on a CD, so the hex file cannot be saved in the directory of PBP.
What i have to do for the hex file be saved in the same directory the .bas is or in a selected directory??

Thanks,
Sorry for my english.

Archilochus
- 26th February 2006, 02:46
In the PBP manual you'll see a section "command line options".
There is one to pass options onto your assembler. If using PM, you can find PM's command line options in the PM.txt file in your PBP directory.

Bopo
- 27th February 2006, 03:47
In the PBP manual you'll see a section "command line options".
There is one to pass options onto your assembler. If using PM, you can find PM's command line options in the PM.txt file in your PBP directory.

i don't find something that help me..
i do this:
http://www.picbasic.co.uk/forum/showthread.php?t=536&highlight=directory

it works, but no it doesn't work, i don't know why
is another way to do this but with only commands?


thanks

DynamoBen
- 27th February 2006, 04:05
Try this:

http://www.melabs.com/resources/pbpmanual/3_0.htm

Bopo
- 27th February 2006, 05:12
Try this:

http://www.melabs.com/resources/pbpmanual/3_0.htm

what option i have to use?, there is no option in that page..

Melanie
- 27th February 2006, 09:13
A little experimentation and you would have discovered that you can have PBP in any directory or drive that you wish totally independant of your program files...

Let's set up one example world...

The PICBasic files are installed in C:\PIC\PBP246
MPLAB (if you use it) is installed in C:\Program Files\Microchip\MPASM Suite
Our Data files are located in C:\Files

Our PATH is set to C:\PIC\PBP246;C:\Program Files\Microchip\MPASM Suite

From a DOS Command Window, Log into your FILES directory (C:\FILES) and from there simply execute your compiler command line (typical example containing whatever options you want)...

PBP -p16F628 MyProgram -v

or...

PBP -p16F628 MyProgram -v -ampasm

...all your datafiles, ie...

MyProgram.bas
MyProgram.hex
Myprogram.asm
MyProgram.mac
MyProgram.cod
MyProgram.err
MyProgram.lst

(the files your get are dependant on which assembler you use) will all be located in our FILES directory, remote and away from the PBP or MPLAB/MPASM installations.

The above is just one example of how you can distribute your datafiles away from your compiler and assembler files. Naturally you can substitute C: for any drive of your choice as long as the directory for the DATAFILES is on a drive capable of READ/WRITE.