Wont produce ASM code

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 2 and 3.

Moderators: Benj, Mods

Post Reply
gharryh
Posts: 5
Joined: Sun Feb 11, 2007 2:09 pm
Location: Enschede, Netherlands
Contact:

Wont produce ASM code

Post by gharryh »

I am a total newbie to flowcode so sorry for the problem but i build something and that compiles to C-code:

Code: Select all

//************************************************************************************
//**  
//**  File name:     \\EIBERGEN01\Users\h.arends\My Documents\ASM Files\SpeedoMeter\Flowcode2.c
//**  Generated by:  Flowcode v3.1.0.31
//**  Date:          Monday, February 12, 2007 22:14:31
//**  Licence:       Demo
//**  
//**        ***DEMO VERSION***
//**  
//**  
//**     NIET VOOR COMMERCIELE TOEPASSINGEN
//**  
//**  http://www.matrixmultimedia.com
//************************************************************************************


//Defines voor de microcontroller
#define P16F628A
#define MX_EE
#define MX_EE_TYPE1
#define MX_EE_SIZE 128
#define MX_UART
#define MX_UART_B
#define MX_UART_TX 2
#define MX_UART_RX 1
#define MX_PWM
#define MX_PWM_PORT portb
#define MX_PWM_TRIS trisb
#define MX_PWM_CNT 1
#define MX_PWM_1 3

//Functies
#include <system.h>
#pragma CLOCK_FREQ 19660800

//Configuratiegegevens
#pragma DATA 0x2007, 0xffffffff

//Interne functies
#include "D:\Program Files\Matrix Multimedia\Flowcode V3\FCD\internals.h"

//Macro functie declaraties


//Variable declaraties
short FCV_TIMEPROD;
char FCV_SKPH;
short FCV_FCV_DISTANCE;
char FCV_SCALE;
short FCV_FCV_SKPH;
short FCV_FCV_SECONDS;
short FCV_DISTANCEPROD;
short FCV_KPH;



//Toegevoegde definities


//Macro implementaties

//Toegevoegde implementaties


void main()
{
	
	//Initialisatie
	cmcon = 0x07;


	//Interrupt initialisatie code
	option_reg = 0xC0;


	//distanceProd
	//Calculation:
	//  distanceProd = FCV_DISTANCE * 36
	FCV_DISTANCEPROD =  FCV_FCV_DISTANCE * 36 ;
	

	//timeProd
	//Calculation:
	//  timeProd = FCV_SECONDS * 10000
	FCV_TIMEPROD =  FCV_FCV_SECONDS * 10000 ;
	

	//KPH
	//Calculation:
	//  KPH = distanceProd / timeProd
	FCV_KPH =  FCV_DISTANCEPROD / FCV_TIMEPROD ;
	

	//ScaleKPH
	//Calculation:
	//  sKPH = FCV_SECONDS * Scale
	FCV_SKPH =  FCV_FCV_SECONDS * FCV_SCALE ;
	

	mainendloop: goto mainendloop;
}

but it wont compile to ASM code. Why is this and can it be corrected.

User avatar
Steve
Matrix Staff
Posts: 3426
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times
Contact:

Post by Steve »


gharryh
Posts: 5
Joined: Sun Feb 11, 2007 2:09 pm
Location: Enschede, Netherlands
Contact:

Post by gharryh »

Sorry Steve,

Excuse my stupidness but i am not a expert programmer in C. I normaly use ASM and i have noticed, not only in computers, that younger people than i am, nearly 50, think that everyone imediate understand everything.

I need a littlebit more explanation off thing, sorry.
I hoped that Flowcode would made things easier for me but now i think i should consider not bying it and remove the program from my computer.

User avatar
Steve
Matrix Staff
Posts: 3426
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times
Contact:

Post by Steve »

I'll try to expand my reply in the other topic. Expect a better answer here in the next few minutes:

http://www.matrixmultimedia.com/mmforum ... php?t=1156

I know that Flowcode may not be suitable for everyone. Unfortunately, the task you are trying to achieve is beyond the native capability of Flowcode itself. However, Flowcode is very powerful because it allows the ability to embed your own C code if you find it cannot do what you require. Embedding C code is not a trivial task for a non-programmer, and as such it should be viewed as an advanced feature of Flowcode.

Post Reply