浏览代码

ulp: Add aditional uint32_t object to `ulp_insn_t`

Used to get the encoded instruction from bit-field structs.

Merges https://github.com/espressif/esp-idf/pull/3759
Saket Dandawate 6 年之前
父节点
当前提交
ccc95191ea
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      components/ulp/include/esp32/ulp.h

+ 2 - 0
components/ulp/include/esp32/ulp.h

@@ -293,6 +293,8 @@ typedef union {
         uint32_t opcode: 4;         /*!< Opcode (OPCODE_MACRO) */
         uint32_t opcode: 4;         /*!< Opcode (OPCODE_MACRO) */
     } macro;                        /*!< Format of tokens used by MACROs */
     } macro;                        /*!< Format of tokens used by MACROs */
 
 
+    uint32_t instruction;           /*!< Encoded instruction for ULP coprocessor */
+
 } ulp_insn_t;
 } ulp_insn_t;
 
 
 _Static_assert(sizeof(ulp_insn_t) == 4, "ULP coprocessor instruction size should be 4 bytes");
 _Static_assert(sizeof(ulp_insn_t) == 4, "ULP coprocessor instruction size should be 4 bytes");