Page 1 of 1

flowcode variable and W register

Posted: Sat Feb 16, 2008 9:12 pm
by elecrobot
Hi

consider i am using a calculation block in which i am equating a variable called SPEED = 127. Then I have a macro which calls a subroutine which is in some other C-Code block. I want to transfer this value of SPEED to W register. How can i do that. Thanks. (Please note i am using Flowcode V2).

Re: flowcode variable and W register

Posted: Mon Feb 18, 2008 12:27 pm
by Benj
Hello Electrobot

In C code you can call Flowcode variables by capitalizing the name and adding the prefix FCV_.

For example Flowcode variable count becomes C variable FCV_COUNT.

If you are using assembler to transfer the C variable then you will need a further _ prefix so the variable name becomes _FCV_COUNT in assembler.