<root>
<document schema='101' license='1,Dan81,82F2KA' title='' description='' target='PIC.16F.16F690' >
	<config data='!0,30d1%0,1%3,0%4,1%5,0%6,1%7,1%8,0%a,0%b,0' clkspd='4000000' simspd='1' usewdt='0' constif='0' />
	<plugins >
		<dll_models enabled='1' />
		<dll_upgrader enabled='1' />
		<dll_webhelp enabled='1' />
	</plugins>
	<supplement use='0' head='' body='' />
	<debug />
	<components >
		<settings autoimg='1' center='1' unitscale='0' fixedscale='0' fixedx='1' fixedy='1' fixedz='1' headcode='0' />
		<definition guid='c97da728-649b-48ba-b1a5-7728864f6da5' vstate='40' vmin='0' vmaj='1' srcleaf='' visiblename='' description='' category='' catenable='1' author='' manuname='' manucode='' sysinfo='0' keywords='' dynamic='0' iconpath='' />
		<component class_type='root' codename='panel' x='0' y='0' z='0' xsz='1' ysz='1' zsz='1' xang='0' yang='0' zang='0' xquat='0' yquat='0' zquat='0' wquat='1' visible='1' interactive='1' solid='1' layer='0' poslock='0' >
			<resources />
			<properties />
			<values />
			<events />
			<apis />
			<variables >
				<variable public='0' >
					<def class_type='variable' name='false' type='b1' description='' isconst='1' isinit='1' usrinit='0' setinit='0' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='TMR_ALLUMAGE' type='u16' description='' isconst='0' isinit='0' usrinit='0' setinit='' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='TMR' type='f32' description='' isconst='0' isinit='0' usrinit='0.0' setinit='' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='VAL' type='s32' description='' isconst='0' isinit='0' usrinit='0' setinit='' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='TEMPS_AV_ALLUMAGE' type='f32' description='' isconst='0' isinit='0' usrinit='0.0' setinit='' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='TRMIN' type='s32' description='' isconst='0' isinit='0' usrinit='0' setinit='' />
				</variable>
				<variable public='0' >
					<def class_type='variable' name='true' type='b1' description='' isconst='1' isinit='1' usrinit='1' setinit='1' />
				</variable>
			</variables>
			<macros >
				<macro >
					<flowline name='TIMER1' description='' >
						<return name='Return' type='v0' description='' isconst='0' isinit='0' usrinit='' setinit='' />
					</flowline>
				</macro>
				<macro >
					<flowline name='INTER' description='' >
						<return name='Return' type='v0' description='' isconst='0' isinit='0' usrinit='' setinit='' />
						<command class_type='native' title='disable ' ccode='// Interrupt: Disable INT0
	cr_bit(intcon, INTE);


' language='C' />
						<command class_type='native' title='Code C 1' ccode='FCV_VAL=(tmr1h &lt;&lt; 8) + tmr1l;
' language='C' />
						<command class_type='native' title='Code C 2' ccode='tmr1l=0;
tmr1h=0;' language='C' />
						<command class_type='calculation' title='Calcul du temps d&apos;attente avant allumage' >
							<exp exp='//conversion de val en valeur à virgule' />
							<exp exp='TMR = float2int (VAL)' />
							<exp exp='' />
							<exp exp='//valeur du timer x 8 car diviser par 8 à l&apos;origine' />
							<exp exp='TMR = TMR * 8' />
							<exp exp='' />
							<exp exp='//nombre de plusation de l&apos;horlogue du µC / 4' />
							<exp exp='//le tout diviser par le nombre compter par le timer' />
							<exp exp='TMR = (1000000 / TMR)' />
							<exp exp='' />
							<exp exp='//multiplier par 60 pour avoir ça en minute' />
							<exp exp='TRMIN = TMR * 60' />
							<exp exp='' />
							<exp exp='//conversion nombre à virgule' />
							<exp exp='TEMPS_AV_ALLUMAGE = int2float (TRMIN)' />
							<exp exp='' />
							<exp exp='//calcul du temps avant allumage en ms' />
							<exp exp='TEMPS_AV_ALLUMAGE = ((60 / TEMPS_AV_ALLUMAGE) * 1000) - 2.2' />
							<exp exp='' />
							<exp exp='//conversion en &quot;temps&quot; timer' />
							<exp exp='TMR_ALLUMAGE = (1000 * TEMPS_AV_ALLUMAGE) / 8' />
						</command>
						<command class_type='native' title='Code C' ccode='//attente avant l&apos;allumage

while(((tmr1h &lt;&lt; 8)+ tmr1l)&lt; FCV_TMR_ALLUMAGE)
{
}
' language='C' />
						<command class_type='call' title='Appel de la Routine Composant' component='allumage' macro='TurnOn' />
						<command class_type='delay' title='Pause' exp='1' type='1' />
						<command class_type='delay' title='Pause' exp='500' type='0' />
						<command class_type='call' title='Appel de la Routine Composant' component='allumage' macro='TurnOff' />
						<command class_type='native' title='enable ' ccode='// Interrupt: Disable INT0
	st_bit(intcon, INTE);


' language='C' />
					</flowline>
				</macro>
				<macro >
					<flowline name='Main' description='' >
						<return name='Return' type='v0' description='' isconst='0' isinit='0' usrinit='' setinit='' />
						<command class_type='interrupt' title='Interruption' enable='1' name='INT0' call='INTER' >
							<settings timer='0' prescale='-1' postscale='-1' rollover='-1' bitcount='-1' trigger='1' maskhi='--------------------------------------------------------------------------------------------------------------------------------------------------------------------------8' masklo='--------------------------------------------------------------------------------------------------------------------------------------------------------------------------8' >
								<option value='0' />
								<option value='0' />
								<option value='0' />
								<option value='0' />
							</settings>
						</command>
						<command class_type='interrupt' title='Interruption' enable='1' name='TMR1' call='TIMER1' >
							<settings timer='1' prescale='1' postscale='-1' rollover='-1' bitcount='-1' trigger='3' maskhi='--------------------------------------------------------------------------------------------------------------------------------------------------------------------------8' masklo='--------------------------------------------------------------------------------------------------------------------------------------------------------------------------8' >
								<option value='1' />
								<option value='0' />
								<option value='-1' />
								<option value='-1' />
							</settings>
						</command>
						<command class_type='native' title='Code CRRRRR' ccode='cr_bit(pir1, TMR1IF);' language='C' />
						<command class_type='loop' title='Boucle' type='0' exp='1' >
							<flowline />
						</command>
					</flowline>
				</macro>
			</macros>
			<component class_type='ref' guid='7fdaec78-394e-4ec9-a578-4f1a12a12076' vmin='1' vmaj='1' codename='allumage' x='0' y='0' z='-6.9' xsz='1' ysz='1' zsz='1' xang='0' yang='0' zang='0' xquat='0' yquat='0' zquat='0' wquat='1' visible='1' interactive='1' solid='1' layer='1' poslock='0' >
				<resources />
				<properties />
				<values >
					<value target='pin' data='$PORTB.6' />
					<value target='polarity' data='001' />
					<value target='on_color' data='8453975' />
					<value target='show_label' data='002' />
					<value target='label_property' data='pin' />
					<value target='label_color' data='16777215' />
					<value target='label_scale' data='1.000000' />
					<value target='label_auto_scale' data='0' />
					<value target='label_position' data='003' />
				</values>
				<events />
				<apis />
				<variables />
				<macros />
			</component>
			<component class_type='ref' guid='5c1da48f-ce54-4622-bdd9-fc812e373696' vmin='0' vmaj='1' codename='sw_push_rnd_pnl1' x='-46.7056' y='0.299875' z='-6.175' xsz='1' ysz='1' zsz='1' xang='0' yang='0' zang='0' xquat='0' yquat='0' zquat='0' wquat='1' visible='1' interactive='1' solid='1' layer='1' poslock='0' >
				<resources />
				<properties />
				<values >
					<value target='pin' data='$PORTA.2' />
					<value target='polarity' data='000' />
					<value target='debounce' data='10' />
					<value target='operation' data='000' />
				</values>
				<events />
				<apis />
				<variables />
				<macros />
			</component>
			<component class_type='text' codename='label1' x='-45.297' y='23.4963' z='0' xsz='8' ysz='8' zsz='1' xang='0' yang='0' zang='0' xquat='0' yquat='0' zquat='0' wquat='1' visible='1' interactive='1' solid='1' layer='1' poslock='0' >
				<resources />
				<properties />
				<values >
					<value target='Color' data='192' />
					<value target='Background' data='-1' />
					<value target='Font' data='Arial' />
					<value target='Text' data='IN' />
				</values>
				<events />
				<apis />
				<variables />
				<macros />
			</component>
			<component class_type='text' codename='label2' x='0.72669' y='23.9808' z='0' xsz='8' ysz='8' zsz='1' xang='0' yang='0' zang='0' xquat='0' yquat='0' zquat='0' wquat='1' visible='1' interactive='1' solid='1' layer='1' poslock='0' >
				<resources />
				<properties />
				<values >
					<value target='Color' data='192' />
					<value target='Background' data='-1' />
					<value target='Font' data='Arial' />
					<value target='Text' data='OUT' />
				</values>
				<events />
				<apis />
				<variables />
				<macros />
			</component>
		</component>
	</components>
	<keymap />
	<panel2d shadows='0' lighting='2' brightness='0' perspective='0' >
		<background rgb='9737364' img='' style='0' />
		<camera xe='0' ye='0' ze='300' xt='0' yt='0' zt='0' xquat='0' yquat='0' zquat='0' wquat='1' />
	</panel2d>
	<panel3d shadows='0' lighting='2' brightness='0' perspective='0' >
		<background rgb='8409120' img='' style='0' />
		<table rgb='7884836' img='' style='0' size='25' />
		<camera xe='0' ye='0' ze='300' xt='0' yt='0' zt='0' xquat='0' yquat='0' zquat='0' wquat='1' />
	</panel3d>
	<layout >
		<view type='0' name='INTER' mode='0' placement='LAAAAAAAAAABAAAA----------8AAAAAFAAAAAAAAAAUAAAAFAQAABgDAAA' zoom='100' scrollx='0' scrolly='0' flags='0' />
		<view type='0' name='Main' mode='0' placement='LAAAAAAAAAABAAAA---------------------wAAAAAUAAAAFAQAABgDAAA' zoom='100' scrollx='0' scrolly='0' flags='0' />
	</layout>
</document>
</root>
