/*
 *========================================================================
 *
 *    : AZN_PLAZA_LANE APP
 *      : wrk_end_def.h
 *      : JBY
 *      : 2018.07.13
 *      :
 *        : Shared Memory Create. 
 *              Shared Memory Attach. 
 *              Shared Memory Deattch.
 *                  
 *========================================================================
*/

#include <sys/types.h>

#include "def_set.h"
#include "lane_stat_info.h"

typedef struct {             /*#33  #1        */
    unint    seq_no;           /*                 */
    uchar    kind;           /*                     */
    uchar    io_hnd_div[1];        /*           */
    unint    serial_no;           /*                 */
    char     wrkr_no[ 5+1];   /*  */
    char     wrk_date[ 8+1];   /*    pk2 asc */

    ushort   wrk_year;           /*               */
    uchar    wrk_month;           /*                       */
    uchar    wrk_day;           /*                       */
    char     wrk_no[ 4+1];   /*    pk3 asc */

    ushort   wrk_strt_year;           /*           */
    uchar    wrk_strt_month;           /*                       */
    uchar    wrk_strt_day;           /*                       */
    uchar    wrk_strt_hour;           /*                       */
    uchar    wrk_strt_min;           /*                       */
    uchar    wrk_strt_sec;           /*                       */

    ushort   wrk_end_year;            /*           */
    uchar    wrk_end_month;           /*                       */
    uchar    wrk_end_day;             /*                       */
    uchar    wrk_end_hour;            /*                       */
    uchar    wrk_end_min;             /*                       */
    uchar    wrk_end_sec;             /*                       */

    int      hnd_cnt;           /*                 */

    ushort   adv_cnt;           /*             */
    ushort   rev_cnt;           /*             */
    ushort   rev_axle;           /*                 */

    ushort   rsv_cnt;           /*  ¥ì           */
    uchar    dummy1;           /* DUMMY                   */

    unint    dc_crd_n_mny[7][8];    /*   */
                             /* 0: ,        1:  
                                2:  3: 
                                4: 
                                   1 - 8            */
    unint    dc_crd_y_mny[8][8];        /*    */
                             /* 0:  1: 
                                2:  3: 
                                4:   5: 
                                   1-8             */

    ushort  dc_crd_yn_cnt[2][7][8];    /*  / */
                             /* 0:  1:         */
                             /* 2:  /        */
                             /* 4: ,,,         */
                             /* 5:                   */
                             /* 8:                       */

    uchar    dummy2[106];     /* DUMMY          106B    */

} sh_wrk_end1;
#define  SIZE_D_ICGGMJR   sizeof (sh_wrk_end1)

typedef struct  {           /*#33  #2         */

    unint    seq_no;           /*                 */
    uchar    kind;           /*                     */
    uchar    io_hnd_div[1];        /*           */
    unint    serial_no;           /*                 */
    char    wrkr_no[ 5+1];   /*  */
    char    wrk_date[ 8+1];   /*    pk2 asc */

    ushort   wrk_year;           /*               */
    uchar    wrk_month;           /*                       */
    uchar    wrk_day;           /*                       */
    char    wrk_no[ 4+1];   /*    pk3 asc */

    ushort   exmt_crd_cnt[8];        /*                        */
      ushort   vio_typ_cnt[30];       /*$$             27*2B    */
    ushort   spcl_hnd_cnt[27];       /*                        */
    ushort   ofc_hnd_cnt;           /* Í¨                     */
    ushort   escp_cnt[8];        /*                            */
      ushort   car_knd_vio_hnd_cnt[3][8];     /*$$        3*8*2B    */
      unint    car_knd_vio_mny[2][8];     /*$$            2*8*8D    */
      ushort   lnk_exmt_cnt[8];        /*$$                8*2B    */
      ushort   sens_hnd_cnt[9];        /*$$ /              9*2B    */
      ushort   un_hnd_cnt[9];        /*$$                  9*2B    */
    ushort   dummy_cnt;           /*                  */
    uchar    gun_err_cnt;           /*                          */
    uchar    forc_end_yn;           /*                            */
    uchar    wrk_stop;           /*                            */
    uchar    cv_op;           /* ¨¨                           */
    ushort   exmt_cnt[8];        /*                            */

    ushort   no_have_cnt[4][8];     /*                    */
    ushort   passtk_car_cnt[8][9];     /*                      */

    ushort   car_cnt[7];
    ushort   car_knd_ofc_hnd_cnt[8];        /* Í¨                     */

    unint    vat[5][8];      /*                              */
      ushort   ecar_exmt_cnt[4];    /*$$                        */

      unint    dc_tm_org_fare[8];    /*$$ ¥í©£                   */
      unint    dc_tm_dcmny[8];    /*$$ ¥í©£ ¥á                */
      unint    extr_tm_org_fare[8];    /*$$ ©£                   */
      unint    extr_tm_fare[8];    /*$$ ©£                 */
      ushort   dc_tm_cnt[8];    /*$$ ¥í©£                     */
      ushort   extr_tm_cnt[8];    /*$$ ©£                     */
      unint    cmut_dc_tm_org_fare[8];    /*$$ ¥í©£             */
      unint    cmut_dc_tm_dcmny[8];    /*$$                ¥á           */
      ushort   cmut_dc_tm_cnt[8];    /*$$                                */
unint    car_hnd_cnt;       /*$$                  8D    */
unint    hnd_toc_cnt;       /*$$ TCS              8D    */

    /*  LSAM  */
unint    lsam_chrg_mny;           /* LSAM                       */
unint    use_crd_chrg_mny;           /*                  */
unint    lsam_balc;           /* LSAM                           */
       unint    lane_upid_rct_mny;       /*$$                  */
    uchar    dummy[25];             /* DUMMY          25B    */

} sh_wrk_end2;

#define  SIZE_D_ICGGMJR1  sizeof(sh_wrk_end2)

typedef struct  {          /*#30  #3        */
    unint    seq_no;           /*                   */
    uchar    kind;           /*                       */
    uchar    wrkr_no[5];        /*                 */
    ushort   wrk_year;           /*                 */
    uchar    wrk_month;           /*                         */
    uchar    wrk_day;           /*                         */
    uchar    wrk_no[4];        /*                   */
    struct {
        ushort  cnt[8];
        unint   orgn_fare[8];
        unint   pass_fare[8];
        unint   rct_fare[8];
    } tm_zone[8];
    uchar    dum1[107];             /* DUMMY          107B    */
} sh_wrk_end3;

#define  SIZE_D_ICGGMJR2  sizeof(sh_wrk_end3)

typedef struct  {          /*#30  #4        */

    unint    seq_no;           /*                   */
    uchar    kind;           /*                       */
    uchar    wrkr_no[5];        /*                 */
    ushort   wrk_year;           /*                 */
    uchar    wrk_month;           /*                         */
    uchar    wrk_day;           /*                         */
    uchar    wrk_no[4];        /*                   */

    ushort   ecar_exmt_cnt[8];        /*      */
    unint    ecar_exmt_mny[8];        /*      */
    ushort   lnk_hnd_cnt[8];           /*  ygds[6]           4D    */
    unint    lnk_hnd_org_pass_fare[8];           /* ygok[6]     8D    */
    unint    lnk_hnd_col_pass_fare[8];           /* ygtk[6] ¢®    8D    */
    unint    lnk_hnd_rct_pass_fare[8];           /* ygsk[6]       8D    */

        struct {                 /* (, , , ) */
                ushort cnt;     /*            4D    */
                unint  mny;      /*            8D    */
        } upid_rct[5];

		ushort ofc_hnd_cnt[8];                 /*  Í¨        */
        ushort unqf_cnt[8];                 /*              */
        ushort exmt_cnt[10];                /*              */
        ushort wrkr_crd_cnt[8];                 /*              */
        unint  wrkr_crd_mny[8];                 /*         8D    */

    uchar   dummy[113];

} sh_wrk_end4;

#define  SIZE_D_ICGGMJR3  sizeof(sh_wrk_end4)

typedef struct  {
sh_wrk_end1   arr_wrk_end1 [MAX_LANE]; /* MAX_LANE     60           ¥ì      */
sh_wrk_end2   arr_wrk_end2 [MAX_LANE];

} st_wrk_end12;

/*#define  SIZE_TCSCJDA12  sizeof(st_wrk_end12)*/

typedef struct  {

sh_wrk_end3   arr_wrk_end3 [MAX_LANE]; /* MAX_LANE     60           ¥ì      */
sh_wrk_end4   arr_wrk_end4 [MAX_LANE];
} st_wrk_end34;

/*#define  SIZE_TCSCJDA34  sizeof(st_wrk_end34)*/
