PDA

View Full Version : Strange ASM file



barkerben
- 29th November 2004, 17:26
I've just written an attempt at my code in PBP, and compiled it to produce an ASM file. However, the output loos very strange - it seems to use lots of non standard assembler commands, and running it through the microchip assembler compiler gives all sorts of errors.

For instance, it uses:

LABEL?L _change
ICALL?L L00001
and
MOVE?CB 000h, _ID

none of which are standard Assembler. Is something strange going on here?

Ben

Melanie
- 29th November 2004, 18:08
http://www.picbasic.co.uk/forum/showthread.php?s=&threadid=539&highlight=assembler

barkerben
- 29th November 2004, 18:54
Thanks - Proton+ looks amazing, but unfortunately I can only use what the department has available, and they only have PBP :-(

The main reason I wanted to look at the assembler was because my supervisor can only undertand assembler, wheras I find it very tricky!

I'm currently looking theough MPLAB to see if there is the reverse assemble option suggested be Melanie.

However, if someone out there could comment on the following, I would be very grateful:

I am basically generating a pulse stream to drive a steper IC.

1) I am using hardware serial to receive and trasmit data. When a serial command arrives, an interrupt is generated, and the data is read. I was worried about latency leading to overflow of the buffer and other nastiness, so used the hardware timer and a timer interrupt to help guard against that problem - this way the main program is not occupied waiting around as wold be the case with pause statements. Do you think this will enable me to get to my data in time?


2) I was unsure about the syntax for receiving data. I was planning on receiving 6 bytes, and therefore used the following command:

HSERIN [bin ID,bin MODE,bin dist,bin SPEED,bin DIR,bin REQUEST]

Where MODE, dist, etc are variables to store the received bytes in.
Is this correct?



Cheers,


Ben