Hello there ... so I was attempting to test some program that I wanted to transmogrify... from mikroC PRO compiler... C - coding... into flowcode8.. and came across something really peculiar...!!
So I have attached some PNG screenshots of flowcode program, and then the compiler errors it produces... It's really all plain to see....
The problem seems that the "effect" of the C-code icon.. does not stop at the end of the text one has typed into the C-code icon box...!! but when compilation takes place... the next icon... as a calculation icon.. becomes involved in the compilation... (even though it's got nothing to do with the C-code part.,... so errors occur... as can be seen in the PNG files...
What I have noted... is that if I have just one line... of coding... then for some reason... it like .... OVERFLOWS ... downwards into the next icon... whatever it is... (in the examples... the calculation box)... If I add another line of code... whatever... it seems to then leave the calculation box alone.... BUT... have a look please at the PNG files...
Then if I want a variable... from a calculation in the code... to 'become involved'... in the C-coding.. I have to define that variable... with a FCV_ preceding the variable name... (is this correct?)...
So now... also I want to know... does flowcode ... support direct usage ... as variables.. REGISTERS from the hardware of the selected PIC chip.??
In mikroC PRO code... it appears to me that... like for example... the one REGISTER within the processor... namely CCPR1L ... lower 8 bits of the two 8 bit registers, is used directly... in the program... (there are other registers... BUT.. just an example... does flowcode do that...?? please...??
Then if so... do I just use it as it's name... or must I declare it somewhere... somehow...??? MikroC PRO does not need this declaration or manipulation at all.. you merely just merrily add the variable... into the C-code... and away you go..???
I hope you can fix this problem... pretty simply.... please...???..
I will have to attach the other files to 2 other empty messages...
regards DCW...
C-code icon.. does not stop ..!!! (1)
Moderator: Benj
-
- Posts: 64
- Joined: Mon Sep 28, 2015 8:19 pm
- Has thanked: 14 times
- Been thanked: 10 times
- Contact:
C-code icon.. does not stop ..!!! (1)
- Attachments
-
- Screenshot (12).png
- (134.67 KiB) Downloaded 1003 times
-
- Screenshot (11).png
- (133.54 KiB) Downloaded 1003 times
-
- Screenshot (10).png
- (112.26 KiB) Downloaded 1003 times
-
- Posts: 64
- Joined: Mon Sep 28, 2015 8:19 pm
- Has thanked: 14 times
- Been thanked: 10 times
- Contact:
Re: C-code icon.. does not stop ..!!! (2)
this is message 2 part ... containing 3 more screenshots...
- Attachments
-
- Screenshot (15).png
- (130.86 KiB) Downloaded 1001 times
-
- Screenshot (14).png
- (135.64 KiB) Downloaded 1001 times
-
- Screenshot (13).png
- (129.36 KiB) Downloaded 1001 times
-
- Posts: 64
- Joined: Mon Sep 28, 2015 8:19 pm
- Has thanked: 14 times
- Been thanked: 10 times
- Contact:
Re: C-code icon.. does not stop ..!!! (3)
this is part 3... of the message ... where I needed to post screenshots of program and errors...
- Attachments
-
- Screenshot (16).png
- (131.21 KiB) Downloaded 1001 times
-
- Valued Contributor
- Posts: 1189
- Joined: Wed May 31, 2017 11:57 am
- Has thanked: 70 times
- Been thanked: 439 times
- Contact:
Re: C-code icon.. does not stop ..!!! (1)
You'll need a ';' (semi-colon) at the end of the (or each if more than one) C statement (1)
Nop isn't a C statement (its an asm instruction)
Use FCV_ or FCL_ for global or locals. (and CAPITALS too)
Martin
Nop isn't a C statement (its an asm instruction)
Use FCV_ or FCL_ for global or locals. (and CAPITALS too)
Martin
- QMESAR
- Valued Contributor
- Posts: 1287
- Joined: Sun Oct 05, 2014 3:20 pm
- Location: Russia
- Has thanked: 384 times
- Been thanked: 614 times
- Contact:
Re: C-code icon.. does not stop ..!!! (1)
HI
You miss the ball by about 1000 miles !
It has nothing to do with Flowcode or Flowcode C Icon, it is you using wrong syntax for example mikroC use NOP the XC 8 use NOP();
fix the syntax errors and all will work as expected.
Secondly there is nothing magic about mikroC accessing Registers, it is standard practice for all compilers, it also has nothing to do with Flowcode
so please stop your rant about flowcode investigate how C is used
again we told you many times in the past if you have problems post the actual Flowchart nobody can help you on your screen prints .
You miss the ball by about 1000 miles !
It has nothing to do with Flowcode or Flowcode C Icon, it is you using wrong syntax for example mikroC use NOP the XC 8 use NOP();
fix the syntax errors and all will work as expected.
Secondly there is nothing magic about mikroC accessing Registers, it is standard practice for all compilers, it also has nothing to do with Flowcode
so please stop your rant about flowcode investigate how C is used
again we told you many times in the past if you have problems post the actual Flowchart nobody can help you on your screen prints .
https://www.flowcodexchange.com/
Regards QMESAR
Regards QMESAR
- QMESAR
- Valued Contributor
- Posts: 1287
- Joined: Sun Oct 05, 2014 3:20 pm
- Location: Russia
- Has thanked: 384 times
- Been thanked: 614 times
- Contact:
Re: C-code icon.. does not stop ..!!! (1)
Hi Martin
you are right NOP is an assembly instruction however XC8 has a wrapper NOP(); which works fine in FC and XC8 however mikroC use only NOP instruction but you have to use the asm statement in front this in both cases DCW has it wrongNop isn't a C statement (its an asm instruction)
Code: Select all
//mikroC syntax
asm Nop ;
//XC8 syntax
NOP() ;
https://www.flowcodexchange.com/
Regards QMESAR
Regards QMESAR
-
- Posts: 64
- Joined: Mon Sep 28, 2015 8:19 pm
- Has thanked: 14 times
- Been thanked: 10 times
- Contact:
Re: C-code icon.. does not stop ..!!! (1)
As USUAL a BUG of this type is not attacked by the authors of flowcode... because they know about it... I am sure....!!!
and will make you PAY for a fix of it.... in the next version.. of flowcode...!!!
So ...the story goes...!!!!... on and on....!!
there is a saying... "warts 'n all".... in flowcode...it's like..... "bugs 'n all"...
one day - someone is going to take flowcode apart.... take out the protection... and give it free to the world...!!!!...
That day ... I am sure... is getting closer and closer ...now....!!!!...
and will make you PAY for a fix of it.... in the next version.. of flowcode...!!!
So ...the story goes...!!!!... on and on....!!
there is a saying... "warts 'n all".... in flowcode...it's like..... "bugs 'n all"...
one day - someone is going to take flowcode apart.... take out the protection... and give it free to the world...!!!!...
That day ... I am sure... is getting closer and closer ...now....!!!!...
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: C-code icon.. does not stop ..!!! (1)
Hi Spencer,
It would be much better for us and for you if you came on and said I have this problem, can you help me. I'm not sure why you always come to us instead looking for a fight and blaming us for every single problem you encounter or thing you don't understand.
We endevour to help our users and also to listen to our users to try and make a better product but we are not magicians and have to rely on the operation of underlying tools such as the C compilers.
I'm sorry you have such a poor amount of respect and faith in us, It's not like I have helped you again and again in the past. Oh wait...
Your last post is very disrespectful and is likely to get you banned from the forums if you continue. You have been warned.
It would be much better for us and for you if you came on and said I have this problem, can you help me. I'm not sure why you always come to us instead looking for a fight and blaming us for every single problem you encounter or thing you don't understand.
We endevour to help our users and also to listen to our users to try and make a better product but we are not magicians and have to rely on the operation of underlying tools such as the C compilers.
I'm sorry you have such a poor amount of respect and faith in us, It's not like I have helped you again and again in the past. Oh wait...
Your last post is very disrespectful and is likely to get you banned from the forums if you continue. You have been warned.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel