Ejemplo n.º 1
0
void
sc_begin(t_sc *sc)
/*
 * Send a BEGIN message
 */
{
	sc_send(sc, SC_BEGIN, 0);		 /* Highest priority	      */
}						 /* sc_begin()		      */
Ejemplo n.º 2
0
void
sc_ready(t_sc *sc)
/*
 * Send a READY message
 */
{
	sc_send(sc, SC_READY, 1);		 /* Lower priority than BEGIN */
}						 /* sc_ready()		      */
Ejemplo n.º 3
0
/* ************************************************ */
void sc_sendLine(char* cBuf) {
	int i=0;
	
	while (cBuf[i] != '\0') {
		TXBuffer[TXBufferI++] = cBuf[i];
		i++;
	}
	TXSendEnabled = TRUE;
	sc_send();
	
}
Ejemplo n.º 4
0
void
sc_reset(t_sc *sc)
/*
 * Reset the given syhcronisation controller so that it resets the
 * count and waits for the first message to come in
 * We make this a low priority mesage so that if there are any
 * messages in the queue then they will be processed first, ensuring
 * the queue is empty before we do the reset.  Of course - this should
 * never happen!
 */
{
	sc_send(sc, SC_RESET, 2);
}						 /* sc_reset()		      */