📄 data.c
字号:
*/
word Logi_Code; /* The logical key code */
byte mode_disp_flag; /* Indication dispaly the mode or not
0: Not dispaly the working mode
1: Displaying the working mode
*/
byte Feed_Flag; /* Support feed the paper or not flag
0: Not feed the paper
1: Feed the paper
*/
byte en_long_dec_input_flag; /* Enable the long decimal dots input flag
0: Not enable.
1: Enable
*/
byte long_dec_input_len; /* When the long decimal dots input flag is true,
this variable record the length of the decimal input.
*/
//byte port_sel; /* Indicate the serial port used, High 4 bits: PRORT1, Low 4 bits: PROT0
// PT_ISP // Use the port for ISP function
// PT_PC_COMM // Use the port for PC communication function
// PT_SCANNER // Scanner
// PT_KP // Kitchen printer
// PT_SP // Slip printer
// PT_ELEC_SCALE // Electronic scale
// PT_MODEM // Modem
// */
//byte save_flag; /* Save the serial ports status or not, High 4 bits: PORT1, Low 4 bits: PORT0
// 0: Did not save the status
// 1: Has saved the status.
// */
//#ifdef VER_RSNT /* Support the restaurant function */
//#endif /* End VER_RSNT */
/*********************************************************************
The programmable string.
*********************************************************************/
char Var_Str_VOID[MAX_08_LENGTH*2+1];
char Var_Str_RM[MAX_12_LENGTH*2+1];
char Var_Str_Item[MAX_12_LENGTH*2+1];
char Var_Str_SubTtl[MAX_12_LENGTH*2+1];
char Var_Str_Auto_Per[MAX_12_LENGTH*2+1];
char Var_Str_EC[MAX_20_LENGTH*2+1];
char Var_Str_Subttl[MAX_20_LENGTH*2+1];
char Var_Str_Misc[MAX_20_LENGTH*2+1];
char Var_Str_Cash[MAX_20_LENGTH*2+1];
char Var_Str_TotQty[MAX_20_LENGTH*2+1];
char Var_Str_Change[MAX_20_LENGTH*2+1];
char Var_Str_RA[MAX_20_LENGTH*2+1];
char Var_Str_PO[MAX_20_LENGTH*2+1];
char Var_Str_LstSpndAmt[MAX_20_LENGTH*2+1];
char Var_Str_SpndAmt[MAX_20_LENGTH*2+1];
char Var_Str_Trng_Head[MAX_32_LENGTH*2+1];
char Var_Str_NS[MAX_32_LENGTH*2+1];
char Var_Str_TSVD[MAX_32_LENGTH*2+1];
char Var_Str_Tnsfer[MAX_32_LENGTH*2+1];
/*********************************************************************/
/*====================================================================*/
/* End data defination */
byte qcTestFlag = 0; // qc test flag, cleart it every power on,
/*----------------------------------------------------------------------*
2004-8-21 13:56 new add:
*----------------------------------------------------------------------*/
word BaudRate2; /* Store the baud rate settings(PORT1) */
byte port0_parity; /* PORT0, the parity mode(NONE, ODD, EVEN) */
byte port0_datalen; /* PORT0, the data len(7, 8, 9) */
byte port0_stopbit; /* PORT0, the stop bit(1, 2) */
byte port1_parity; /* PORT1, the parity mode(NONE, ODD, EVEN) */
byte port1_datalen; /* PORT1, the data len(7, 8, 9) */
byte port1_stopbit; /* PORT1, the stop bit(1, 2) */
byte out_print_kind; /* The outside printer kind */
byte port_use_print = PRN_PORT; /* Which port to use the outside printer */
byte out_print_type; /* The outside printer type */
byte kp_font; /* Kitchen printer print font */
byte handshake_method; /* The handshaking method */
byte cut_paper_flag; /* Cut the paper or not flag */
#ifdef VER_RSNT /* Support the restaurant function */
byte KP_LineFeedCnt; /* The kitchen printers line feed counter */
byte Ack_Send_KP; /* Acknowledge send the register information to the kitchen printer flag
0: Not allow
1: allow
*/
byte KP_Prn_Head; /* The kitchen printer head print flag */
byte send_ec_flag; /* Send the EC information to the kitchen printer */
byte prn_rm_flag; /* Print the Return Merchandise flag */
byte KP_Sfx_Desc[MAX_KP_SFX_NUM][MAX_PRN_LEN+1]; /* Send to the kitchen printer's description */
#endif /* End VER_RSNT */
//byte PrnAdj_Flag; /* Adjust the receipt print flag */
//byte LogoPosi_Flag; /* Logo print position flag */
byte prePrnLine; /* The last printing, receipt head print lines */
byte store_head_step; /* Store the head step, for the discount head has store two times */
#ifdef ELEC_JRNL
//byte Log_Atv_Flag; /* Electronic journal active or not flag */
#endif
//long top_cash_ttl; /* The top cash total in drawer */
//const byte CS_Adj[256] = { /* Adjust the check sum array */
// 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF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// 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
// 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
// 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x1B, 0x00, 0x00, 0x00,
// 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
// 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
//};
byte ra_flag;
byte po_flag;
long ra_input; /* The RA operation input data */
long po_input; /* The PO operation input data */
/*****************************/
DWORD uc_kp_wait_timer = 0;/* kp wait timer, maximu wait time is 5s*/
CHR fl_kp_rp_busy = 0; /* kp/rp busy flag */
CHR fl_kp_tm_out = 0; /* kp/rp timer out flag */
CHR kp_clr_cntr = 0; /* kp/rp timer out counter */
byte COMM_PORT;
byte tmp_port_sel1; /* temporay store the download value */
byte tmp_port_sel2; /* during communication */
byte port_sel1; /* Indicate the serial port1 used
PT_NONE // No use
PT_PC_COMM // Use the port for PC communication function
PT_POS_KB // External POS keyboard
PT_KP // Kitchen printer
PT_RP // Receipt printer
PT_SC // Scanner
PT_ELEC_SCALE // Electronic scale
*/
byte port_sel2; /* Indicate the serial port2 usage
PT_NONE // No use
PT_PC_COMM // Use the port for PC communication function
PT_POS_KB // External POS keyboard
PT_KP // Kitchen printer
PT_RP // Receipt printer
PT_SC // Scanner
PT_ELEC_SCALE // Electronic scale
*/
byte last_port_sel1; /* 默认的端口用途 */
byte last_port_sel2;
//WGT_BAR_DEF wgt_bar; /* The weight bar PLU structure */
#ifdef REST_PLU_FUNC
PLUTABDEF plu_relation_tab[MAX_PLUTAB_NO];
MENUPLUDEF Menu_Table[MAX_MENU_KEY_CNTR];
long menu_sub_count;
long menu_sub_total;
word store_plu_index;
long store_trans_price;
byte menu_length;
byte PPLU_Menu_Flag; /* Program the PLU MENU flag
1: In the Program PLU MENU mode.
0: Not in the program PLU MENU mode.
*/
byte do_menu_flag;
byte id_order_posi;
byte prn_gift_symbol_flag;
#endif
word Dplu_Pluno[MAX_DPLU_NO];
#ifdef ELEC_JRNL
BOOL elec_jrnl_up; /* Electronic journal up-load flag */
BOOL elec_jrnl_send; /* Electronic the sale journal flag */
byte elec_jrnl_status; /* Electronic journal status */
byte elec_tmp_buf[MAX_PRN_LEN]; /* The temporary buffer */
byte elec_tax_flag; /* The tax attribute has changed flag */
byte elec_tax_round;
byte elec_tax_mode;
TVATDEF elec_tax_rate[MAX_VAT_NUM];
#endif
BOOL aster_prn_flag; /* Print the aster or not flag when call the function
'LongPrnfmt', 'LongPrnFmt_Ex', 'Cal_Len2'
*/
BOOL split_prn_flag; /* Print hte split character (',') or not flag when call the
function 'LongPrnfmt', 'LongPrnFmt_Ex', 'Cal_Len2'
*/
byte table_awake_len; /* The table awaking length */
byte prn_tab_pre_flag; /* Print the table previous sale item flag */
//PORTDEF *Port[MAX_PORT_NUM];
volatile byte g_Cs_Drive = 0;
byte vfd_lcd_Disp; // VFD or LCD display
byte dis_buff[MAX_LCD_NUM]; /* Display buffer, used in the LCD display */
byte temp_disp_dot_flag = 0;
PORTDEF ser_port[PORT_MAX];
// TS
word TS_timercnt; /*count the time between the data received from Touch Scream*/
byte TS_keyenable;
byte TS_Init_Flag;
BOOL skip_null_key = TRUE; /*注解?*/
byte Rp_Auto_Space; /* The receipt printer auto space */
// CMOS的这个标志位可以放在最后面
byte cmosValid2[40+1]; /* The data check the above data is right or not in the SRAM */
BYTE sPrn_Port = 0;
word Ts_KeyMap[LCD_LAYOUT_VRT_LINE*LCD_LAYOUT_HOR_LINE];
VIRTUAL_KEY_DEF Vir_Key[MAX_VIR_KEY];
BOOL Disp_Table_Detail = 0; /* 是否显示当前台的明细 */
BOOL Disp_Table_List = 0; /* 是否显示当前台的交易细项 */
byte curr_dept; // 当前部门
byte CkMsg[MAX_DEPT_CM_NO]; // 一个临时的数组, 存储当前部门的Cooking Message
byte CM_Cnt; // Cooking Message counter
word Linked_PLU[MAX_PLU_CNT]; // 当前部门所被连接的PLU, 这是一个临时数组.
word Linked_Cnt; // 连接的数量
byte Open_Step = 0; // The table open step
word Table_True_Idx; // The table true index
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -