64 static void DoOK(
void);
69 static void Init0(
void);
70 static void Init1(
void);
124 PORTA=0x00; TRISA=0x00;
140 OPTION_REG=0b00111111;
143 PORTA=0x00; TRISA=0x00;
144 PORTB=0x00; TRISB=0x00;
145 PORTC=0x00; TRISC=0x00;
192 #define beep(time) piezo(18,time) 268 static void interrupt
isr(
void)
397 while(ADCON0bits.GO);
401 while(ADCON0bits.GO);
437 if((STATUS & 0x10)) {
595 while( TXIE )
continue;
604 memset(&
gOut[11],
'0', 4);
612 while( TXIE )
continue;
625 while( TXIE )
continue;
645 while( TXIE )
continue;
657 while( TXIE )
continue;
678 while( TXIE )
continue;
695 while( TXIE )
continue;
699 while( TXIE )
continue;
711 while( TXIE )
continue;
718 while( TXIE )
continue;
729 while( TXIE )
continue;
743 while( TXIE )
continue;
836 memset((
char*)
gBuf,0, 10);
906 if(
gRnor > (21400) )
910 if(
gRnor >= (21500) )
985 *ptr++ = n % 10 +
'0';
987 }
while ((n = n / 10) > 0);
988 while(pad--) *ptr++=
'0';
1001 j = s + strlen(s) - 1;
1044 while( TXIE )
continue;
static bank2 BYTE gIdx
index to build packets
volatile bank1 time_t TIME
Timer in unix format.
BYTE OneWire_GetID(BYTE *buff)
long dostounix(struct date *d, struct time *t)
void delay_10us(unsigned char x)
void SCI_Write(BYTE byte)
#define CR_FF
-> STX|E|1|D|ETX|XOR <- ACK > STX|nnnnnnn|ETX|XOR
volatile bank1 BYTE gIn[20]
Input buffer.
#define BSHORT
Beep short time.
unsigned char ti_hour
Hours.
BYTE FS_AppendUnit(UNIT *data)
static void Process(void)
#define bittst(var, bitno)
volatile BYTE gSleep
Sleep mode enable.
void DF_ReadBuffer1(WORD Address, BYTE *data, WORD size)
#define GE_NOSPACE
No enogh disk space.
volatile bank2 BYTE gRXCount
Input buffer index.
volatile bank2 time_t gTampTime
Tamper loop time.
#define FSDN_OFF
Device number.
static void Add(BYTE num)
BYTE FS_WriteUnit(UNIT *data)
BYTE FS_AppendRegis(REGIS *data)
void unixtodos(long time, struct date *d, struct time *t)
volatile bank2 BYTE gByte
Input byte.
#define bitset(var, bitno)
static void SendInfo(void)
BYTE FS_ReadRegis(REGIS *data)
#define GE_LTA
Error on comm.
static bank1 WORD gTbut
antiping touch read
#define W1_OK
Function call success.
static BYTE SearchbyID(WORD id)
static void interrupt isr(void)
volatile bank2 BYTE gError
Error flag state.
#define WSHORT
Wait short time.
static volatile bank2 BYTE gRetry
Retry count.
unsigned char ti_min
Minutes.
static volatile bank1 time_t gTimeout
Protocol Timeout.
BYTE SCI_Init(DWORD baud, BYTE ninebits)
static void SetTime(BYTE dir)
static void SendFlash(void)
static void DoError(void)
static void CheckUnits(WORD id)
#define WLONG
Wait long time.
static void InitPacket(BYTE cmd)
BYTE SCI_CheckOverrun(void)
char da_day
Day of the month.
#define MAX_PAGE_1MBIT_DENSITY
void FS_GetBoot(WORD Offset, BYTE *data, BYTE size)
static VOID xitoa(WORD n, BYTE *s, BYTE pad)
#define CR_INFO
-> STX|E|1|I|ETX|XOR <- ACK > STX|I|n|x|x|x|e|e|e|ETX|XOR
static BYTE Save(WORD id)
volatile bank2 BYTE gState
Protocol Receiver state machine.
void FS_SetBoot(WORD Offset, BYTE *data, BYTE size)
static VOID xreverse(BYTE *s)
static void SendRegis(void)
static void piezo(BYTE t, WORD d)
unsigned char ti_hund
Hundredths of seconds.
void DF_Page2Buffer1(WORD Pagenum)
char da_mon
Month (1 = Jan)
volatile bank2 BYTE gTXCount
Output buffer index.
volatile bank2 BYTE gSleepTime
Count to sleep.
#define bitclr(var, bitno)
JADEKU project defines and dependency headers.
#define FSDT_OFF
date time
#define W1_FOUND
No device found.
static void InitialState(void)
volatile bank1 BYTE gOut[20]
Output buffer.
static BYTE ccp(BYTE idx)
#define CR_FORMAT
-> STX|E|1|F|x|x|x|ETX|XOR <- ACK
unsigned char ti_sec
Seconds.
static BYTE CRO_Crc(volatile BYTE *data, BYTE size)
BYTE FS_ReadUnit(UNIT *data)
volatile bank2 BYTE gCrc
Protocol Checksum.
#define BLONG
Beep long time.
static bank1 BYTE gBuf[10]
general buffer
static bank1 WORD gIbut
Current touch read.