// File: /workspace/github_c_makefile_star2_O1/back1127[P]linkedge-thing-access-websocket_client_sdk/sdk/test/linux/simulated_device.c
// Function: cb_get_property
static int cb_get_property(const char *pk, const char *dn,
                                       leda_device_data_t properties[], 
                                       int properties_count, 
                                       void *usr_data)
{
    int i;
    for (i = 0; i < properties_count; i++) {
        if (strcmp(properties[i].key, PROPERTY_INT32_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_int32_rw(pk, dn));
            properties[i].type = LEDA_TYPE_INT;
        } else if (strcmp(properties[i].key, PROPERTY_INT32_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_int32_r(pk, dn));
            properties[i].type = LEDA_TYPE_INT;
        } else if (strcmp(properties[i].key, PROPERTY_FLOAT_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%f", get_dev_float_rw(pk, dn));
            properties[i].type = LEDA_TYPE_FLOAT;
        } else if (strcmp(properties[i].key, PROPERTY_FLOAT_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%f", get_dev_float_r(pk, dn));
            properties[i].type = LEDA_TYPE_FLOAT;
        } else if (strcmp(properties[i].key, PROPERTY_DOUBLE_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%lf", get_dev_double_rw(pk, dn));
            properties[i].type = LEDA_TYPE_DOUBLE;
        } else if (strcmp(properties[i].key, PROPERTY_DOUBLE_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%lf", get_dev_double_r(pk, dn));
            properties[i].type = LEDA_TYPE_DOUBLE;
        } else if (strcmp(properties[i].key, PROPERTY_ENUM_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_enum_rw(pk, dn));
            properties[i].type = LEDA_TYPE_ENUM;
        } else if (strcmp(properties[i].key, PROPERTY_ENUM_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_enum_r(pk, dn));
            properties[i].type = LEDA_TYPE_ENUM;
        }  else if (strcmp(properties[i].key, PROPERTY_BOOL_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_bool_rw(pk, dn));
            properties[i].type = LEDA_TYPE_BOOL;
        } else if (strcmp(properties[i].key, PROPERTY_BOOL_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_dev_bool_r(pk, dn));
            properties[i].type = LEDA_TYPE_BOOL;
        } else if (strcmp(properties[i].key, PROPERTY_STRING_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%s", get_dev_string_rw(pk, dn));
            properties[i].type = LEDA_TYPE_TEXT;
        } else if (strcmp(properties[i].key, PROPERTY_STRING_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%s", get_dev_string_r(pk, dn));
            properties[i].type = LEDA_TYPE_TEXT;
        }  else if (strcmp(properties[i].key, PROPERTY_DATE_RW) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%s", get_dev_date_rw(pk, dn));
            properties[i].type = LEDA_TYPE_DATE;
        }   else if (strcmp(properties[i].key, PROPERTY_DATE_R) == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%s", get_dev_date_r(pk, dn));
            properties[i].type = LEDA_TYPE_DATE;
        } else {
            return LEDA_ERROR_PROPERTY_NOT_EXIST;
        }
    }

    return LE_SUCCESS;
}

// Assembly:
testl %ecx, %ecx
jle 0x2b2c
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movl %ecx, %r12d
addq $0x44, %rbx
leaq 0x93b(%rip), %r15       # 0x3053
leaq -0x40(%rbx), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x11e0
testl %eax, %eax
je 0x2879
movq %r13, %rdi
leaq 0x961(%rip), %rsi       # 0x309a
callq 0x11e0
testl %eax, %eax
je 0x2897
movq %r13, %rdi
leaq 0x91b(%rip), %rsi       # 0x306b
callq 0x11e0
testl %eax, %eax
je 0x28d1
movq %r13, %rdi
leaq 0x93b(%rip), %rsi       # 0x30a2
callq 0x11e0
testl %eax, %eax
je 0x28f4
movq %r13, %rdi
leaq 0x92c(%rip), %rsi       # 0x30aa
callq 0x11e0
testl %eax, %eax
je 0x2936
movq %r13, %rdi
leaq 0x923(%rip), %rsi       # 0x30b8
callq 0x11e0
testl %eax, %eax
je 0x2956
movq %r13, %rdi
leaq 0x915(%rip), %rsi       # 0x30c1
callq 0x11e0
testl %eax, %eax
je 0x2995
movq %r13, %rdi
leaq 0x906(%rip), %rsi       # 0x30c9
callq 0x11e0
testl %eax, %eax
je 0x29b3
movq %r13, %rdi
leaq 0x8f6(%rip), %rsi       # 0x30d0
callq 0x11e0
testl %eax, %eax
je 0x29f0
movq %r13, %rdi
leaq 0x8e7(%rip), %rsi       # 0x30d8
callq 0x11e0
testl %eax, %eax
je 0x2a0f
movq %r13, %rdi
leaq 0x87b(%rip), %rsi       # 0x3083
callq 0x11e0
testl %eax, %eax
je 0x2a4d
movq %r13, %rdi
leaq 0x8c0(%rip), %rsi       # 0x30df
callq 0x11e0
testl %eax, %eax
je 0x2a6e
movq %r13, %rdi
leaq 0x8b2(%rip), %rsi       # 0x30e8
callq 0x11e0
testl %eax, %eax
je 0x2ac9
movq %r13, %rdi
leaq 0x8a3(%rip), %rsi       # 0x30f0
callq 0x11e0
testl %eax, %eax
jne 0x2b2f
movq %r14, %rsi
callq 0x17b3
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x7cf(%rip), %rdx       # 0x3040
movq %rax, %rcx
jmp 0x2afa
movq %r14, %rsi
callq 0x137c
movq 0x2a08(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movl 0x34(%rcx,%rax), %ecx
jmp 0x28b3
movq %r14, %rsi
callq 0x137c
movq 0x29ea(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movl 0x38(%rcx,%rax), %ecx
xorl %r13d, %r13d
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x797(%rip), %rdx       # 0x305c
xorl %eax, %eax
callq 0x1050
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x29b0(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
xorps %xmm0, %xmm0
cvtss2sd 0x3c(%rcx,%rax), %xmm0
jmp 0x2915
movq %r14, %rsi
callq 0x137c
movq 0x298d(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
xorps %xmm0, %xmm0
cvtss2sd 0x40(%rcx,%rax), %xmm0
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x750(%rip), %rdx       # 0x3074
movb $0x1, %al
callq 0x1050
movl $0x2, %r13d
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x294b(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movsd 0x48(%rcx,%rax), %xmm0
jmp 0x2974
movq %r14, %rsi
callq 0x137c
movq 0x292b(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movsd 0x50(%rcx,%rax), %xmm0
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x731(%rip), %rdx       # 0x30b4
movb $0x1, %al
callq 0x1050
movl $0x8, %r13d
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x28ec(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movl 0x58(%rcx,%rax), %ecx
jmp 0x29cf
movq %r14, %rsi
callq 0x137c
movq 0x28ce(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movl 0x5c(%rcx,%rax), %ecx
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x67e(%rip), %rdx       # 0x305c
xorl %eax, %eax
callq 0x1050
movl $0x5, %r13d
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x2891(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movzbl 0x60(%rcx,%rax), %ecx
jmp 0x2a2c
movq %r14, %rsi
callq 0x137c
movq 0x2872(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
movzbl 0x61(%rcx,%rax), %ecx
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x621(%rip), %rdx       # 0x305c
xorl %eax, %eax
callq 0x1050
movl $0x1, %r13d
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x2834(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
addq %rax, %rcx
addq $0x62, %rcx
jmp 0x2aab
movq %r14, %rsi
callq 0x137c
movq 0x2813(%rip), %rdx      # 0x5290
cltq
imulq $0x10a8, %rax, %rcx     # imm = 0x10A8
movl $0x56526c4d, 0x862(%rdx,%rcx) # imm = 0x56526C4D
movl $0x715a56, 0x865(%rdx,%rcx) # imm = 0x715A56
addq 0x27ed(%rip), %rcx      # 0x5290
movl $0x862, %eax            # imm = 0x862
addq %rax, %rcx
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x586(%rip), %rdx       # 0x3040
xorl %eax, %eax
callq 0x1050
movl $0x3, %r13d
jmp 0x2b07
movq %r14, %rsi
callq 0x137c
movq 0x27b8(%rip), %rcx      # 0x5290
cltq
imulq $0x10a8, %rax, %rax     # imm = 0x10A8
addq %rax, %rcx
addq $0x1062, %rcx           # imm = 0x1062
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x546(%rip), %rdx       # 0x3040
xorl %eax, %eax
callq 0x1050
movl $0x4, %r13d
movl %r13d, -0x44(%rbx)
addq $0x844, %rbx            # imm = 0x844
decq %r12
jne 0x2718
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %eax, %eax
retq
movl $0x1a9ca, %eax          # imm = 0x1A9CA
jmp 0x2b1d