Exemplo n.º 1
0
int main(void)
{
	__init__();
	test_7seg();
	int i;
	uchar value = 0;
	while(true)
	{
		i=0;
		do{
			send2display(toBCD(value));
			delay(refresh_rate_SSD);
		}while(++i < (refresh_counter_rate/refresh_rate_SSD));
		if((value = counter_8bits(value)) == 100)
		{
			value = 0;
			int j;
			for(j=0; j < 5; j++)
			{
				i=0;
				do{
					send2display(toBCD(value));
					delay(refresh_rate_SSD);
				}while(++i < half_second/refresh_rate_SSD);
				LATB &= 0xFC00;
				delay(half_second);
//				LATB |= 0x0200;
			}
		}
	}
	return 0;
}
 Engine::Engine(int __ss_init)
 {
     // Tell shedkin generated classes that this class corresponds to class
     // with name cl_Engine
     this->__class__ = cl_Engine;
     Engine::instance = this;
     __init__();
 }
Exemplo n.º 3
0
Reference::Reference(std::string  key, ReferenceType*  pFromReferenceType)
:	_pFirstToAttributeValue(nullptr)
,	_pLastToAttributeValue(nullptr)
,	_ToAttributeValueCount(0UL)
,	_key(key)
,	_pNextFromReferenceType(nullptr)
,	_pPrevFromReferenceType(nullptr)
,	_pFromReferenceType(pFromReferenceType)
{
		__init__(pFromReferenceType);
}
Exemplo n.º 4
0
static TimeStampobject *
newTimeStamp(PyObject *ignored, PyObject *args)
{
  TimeStamp *self;
	
  UNLESS(self = PyObject_NEW(TimeStamp, &TimeStampType)) return NULL;
  
  ignored=__init__(self, args);
  if (! ignored) return NULL;
    
  Py_DECREF(ignored);
  return self;
}
Exemplo n.º 5
0
Arquivo: p1.c Projeto: ptrodrigues/AC2
int main(void)
{
	__init__();
	while(true)
	{
		AD1CON1bits.ASAM = 1;
		LATEbits.LATE0	= 1;
		while( IFS1bits.AD1IF == 0 );
		//printStr("\n0x");
		//printInt(ADC1BUF0, (3 << 16) + 16);
		IFS1bits.AD1IF = 0;
		LATEbits.LATE0	= 0;
	}
	return 0;
}
Exemplo n.º 6
0
Arquivo: p3.c Projeto: ptrodrigues/AC2
int main(void)
{
	__init__();
	test_7seg();
	boolean SSD_high = false;
	while(1)
	{			
		LATB = set_SSD_Hex(LATB,segment_decode(getChar()),SSD_high);
		if((LATB & 0xFF) == 0x00)
		{
			SSD_high ^= 0x1;
			LATB = set_SSD_Hex(LATB,segment_decode(0),SSD_high);
		}
		printStr("0x");
		printInt(LATB,(4<<16)+16);
		printStr("; 0b");
		printInt(LATB,(16<<16)+2);
		putChar('\n');
	}
	return 0;
}
Exemplo n.º 7
0
void _init_(double epsilon)
{
        __init__(epsilon);
}