// File: /workspace/github_c_makefile_star2_O2/back1127[P]linkedge-thing-access-websocket_client_sdk/sdk/test/linux/simulated_device.c
// Function: cb_set_property
static int cb_set_property(const char *pk, const char *dn,
                                       const leda_device_data_t properties[], 
                                       int properties_count, 
                                       void *usr_data)
{
    int ret = LE_ERROR_UNKNOWN, i;

    for (i = 0; i < properties_count; i++) {
        if (strcmp(properties[i].key, PROPERTY_INT32_RW) == 0) {
            ret = set_dev_int32_rw(pk, dn, atoi(properties[i].value));
        } else if (strcmp(properties[i].key, PROPERTY_FLOAT_RW) == 0) {
            ret = set_dev_float_rw(pk, dn, atof(properties[i].value));
        }else if (strcmp(properties[i].key, PROPERTY_DOUBLE_RW) == 0) {
            ret = set_dev_double_rw(pk, dn, atof(properties[i].value));
        } else if (strcmp(properties[i].key, PROPERTY_ENUM_RW) == 0) {
            ret = set_dev_enum_rw(pk, dn, atoi(properties[i].value));
        } else if (strcmp(properties[i].key, PROPERTY_BOOL_RW) == 0) {
            ret = set_dev_bool_rw(pk, dn, atoi(properties[i].value));
        } else if (strcmp(properties[i].key, PROPERTY_STRING_RW) == 0) {
            ret = set_dev_string_rw(pk, dn, properties[i].value);
        } else if (strcmp(properties[i].key, PROPERTY_DATE_RW) == 0) {
            ret = set_dev_date_rw(pk, dn, properties[i].value);
        } else {
            printf("property %s is not exist!\n", properties[i].value);
            return LEDA_ERROR_PROPERTY_NOT_EXIST;
        }
        if (ret != LE_SUCCESS) {
            break;
        }
    }
    if (ret == LE_SUCCESS) {
        //send_signal_property_changed(pk, dn);
    }
    return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
xorl %r12d, %r12d
testl %ecx, %ecx
cmovgl %ecx, %r12d
incq %r12
addq $0x44, %rbx
movl $0x186a0, %ecx          # imm = 0x186A0
leaq 0x839(%rip), %r15       # 0x3053
movl %ecx, %eax
decq %r12
je 0x2953
leaq -0x40(%rbx), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x11d0
testl %eax, %eax
je 0x28d3
movq %r13, %rdi
leaq 0x825(%rip), %rsi       # 0x306b
callq 0x11d0
testl %eax, %eax
je 0x28e7
movq %r13, %rdi
leaq 0x84d(%rip), %rsi       # 0x30aa
callq 0x11d0
testl %eax, %eax
je 0x28fd
movq %r13, %rdi
leaq 0x84d(%rip), %rsi       # 0x30c1
callq 0x11d0
testl %eax, %eax
je 0x290f
movq %r13, %rdi
leaq 0x845(%rip), %rsi       # 0x30d0
callq 0x11d0
testl %eax, %eax
je 0x2923
movq %r13, %rdi
leaq 0x7e1(%rip), %rsi       # 0x3083
callq 0x11d0
testl %eax, %eax
je 0x2937
movq %r13, %rdi
leaq 0x82f(%rip), %rsi       # 0x30e8
callq 0x11d0
testl %eax, %eax
jne 0x2962
movq %r14, %rsi
movq %rbx, %rdx
callq 0x1741
jmp 0x2942
movq %rbx, %rdi
callq 0x11a0
movq %r14, %rsi
movl %eax, %edx
callq 0x13f1
jmp 0x2942
movq %rbx, %rdi
callq 0x1100
cvtsd2ss %xmm0, %xmm0
movq %r14, %rsi
callq 0x146e
jmp 0x2942
movq %rbx, %rdi
callq 0x1100
movq %r14, %rsi
callq 0x14fb
jmp 0x2942
movq %rbx, %rdi
callq 0x11a0
movq %r14, %rsi
movl %eax, %edx
callq 0x158b
jmp 0x2942
movq %rbx, %rdi
callq 0x11a0
movq %r14, %rsi
movl %eax, %edx
callq 0x15fd
jmp 0x2942
movq %r14, %rsi
movq %rbx, %rdx
callq 0x1672
addq $0x844, %rbx            # imm = 0x844
xorl %ecx, %ecx
testl %eax, %eax
je 0x281a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x847(%rip), %rdi       # 0x31b0
movq %rbx, %rsi
xorl %eax, %eax
callq 0x1030
movl $0x1a9ca, %eax          # imm = 0x1A9CA
jmp 0x2953