bstc doesn't like some code?
cbmeeks
Posts: 634
I was playing around with the waitvid.2048 examples but found that the library would not assemble.
The offending code is:
With an error message of:
It doesn't like the "wc" at the end.
I'm re-learning some PASM so I can't remember what that's for. Anyone know why bstc doesn't like that?
Here is the command line I am using:
Thanks!
The offending code is:
call #blank wc ' back porch
With an error message of:
waitvid.320x240.driver.2048 - Error at (81,32) Expected End of Line call #blank wc ' back porch _______________________________^
It doesn't like the "wc" at the end.
I'm re-learning some PASM so I can't remember what that's for. Anyone know why bstc doesn't like that?
Here is the command line I am using:
d:\Dropbox\bin\BST\bstc.exe -l -b -d COM5 -p0 waitvid.320x240.demo.spin
Thanks!
Comments
Besides, I don't understand what you are trying to achieve with a wc in a call. Perhaps before a return you might use a wc in an operation, but not in the call itself if this was even possible.
I take it that this wc was in some code, but could you always make sure you attach the zip of the code rather than a single line so we can check it out? I'm trying to find the source you are using but shouldn't have to.
Ok, I found the code and it does have a wc in there, but I'm not sure why.
(You can also use WZ to clear the Z flag, I think?)
I should have specified the repo location but I (falsely) assumed everyone was familiar with the waitvid.2048 repo.
Which is located here:
https://github.com/konimaru/waitvid.2048
And more specifically here:
https://github.com/konimaru/waitvid.2048/tree/master/scanline/320x240
I never really said there was anything wrong with the assembler. I just asked why it didn't like that line of code.
Thanks for the explanation. I remember when I used to use the official Parallax IDE, it seemed to work just fine with that code. So I'm not sure what I'm doing wrong.
Oh well...no worries. Thanks. :-)
However, I checked a later version of the P1 manual and it does say wc can be used. Well there you go. Now I will go and find out why bst doesn't like it (voluntarily).
You know what? Don't bother...I'm not interested any more. I don't know why you always have to give a smart Smile answer when all I was doing was asking a simple question.
Also I think that there is homespun or one of those that might work.
I took offense? You're the one that lashed out and said I was expecting everyone to have a "yes sir" attitude to my thoughtless question and saying I assumed everyone to read my mind. I can't win with with you. No matter what I ask you have to give lip about it. You are LITERALLY the reason I left this forum TWICE over the years and went elsewhere. I then start getting fond memories of the Propeller, come back and have to get it from you again.
But like I said...don't bother. I'm just not interested anymore.
Funny that I never saw that before with the call instruction but then again kuroneko always liked to discover all that there was to know about PASM. Interesting though that bst just won't handle any wc wz after a call. The original Prop manual didn't specify a wc.
I don't think any offense was meant. Sometimes you can read into comments things that were not actually said.
The WC is used to set the C flag as it's not likely that this instruction executed from the shadow ram at $1FF whereby the next instruction would be $000 (rollover) when C would be cleared.
The WZ is set to Z if the return address is $000 which is again unlikely. So it is used to set NZ.
WC & WZ are just artifacts of the P1 design and the documentation was probably updated as Peter suggested to specify what really happens, and then someone used it in their code. I have seen WC and WZ used on the DJNZ instructions. IIRC the P2 Tricks and Traps documents the P2 differences.
@Cluso99 - It's interesting that the source code says this wc "clears the c flag" yet the Prop manual says it sets the flag