5892bffd3c
1. 實作 Dev mode 2. 實作 cis_version 3. ADC_DRV 新增 adc_read_mutiple_channels()/adc_read_mutiple_channels_ex(), 連續轉換多個 ADC channel 備註: 目前設定使用 adc_read_mutiple_channels()/adc_read_mutiple_channels_ex() 每筆 ADC 需要 sample 40us
36 lines
855 B
C
36 lines
855 B
C
#pragma once
|
|
#ifndef __PEL_H__
|
|
#define __PEL_H__
|
|
|
|
#include "app_config.h"
|
|
#include "elite_board.h"
|
|
#include "elite.h"
|
|
|
|
#define PEL_0P5R_MASK (0x01 << 0)
|
|
#define PEL_1P0R_MASK (0x01 << 1)
|
|
#define PEL_2P0R_MASK (0x01 << 2)
|
|
#define PEL_4P0R_MASK (0x01 << 3)
|
|
#define PEL_8P0R_MASK (0x01 << 4)
|
|
#define PEL_16P2R_MASK (0x01 << 5)
|
|
#define PEL_32P4R_MASK (0x01 << 6)
|
|
#define PEL_63P4R_MASK (0x01 << 7)
|
|
#define PEL_127R_MASK (0x01 << 8)
|
|
#define PEL_255R_MASK (0x01 << 9)
|
|
#define PEL_511R_MASK (0x01 << 10)
|
|
#define PEL_1000R_MASK (0x01 << 11)
|
|
|
|
typedef struct
|
|
{
|
|
int32_t output_r1;
|
|
int32_t output_r2;
|
|
int32_t output_vo;
|
|
int32_t output_vc;
|
|
int32_t output_ve;
|
|
} pel_output_t;
|
|
|
|
void pel_relays_set(uint32_t measure_out);
|
|
pel_output_t pel_smaple_and_convt_all(uint32_t load_mask);
|
|
const elite_instance_t *pel_init(void);
|
|
|
|
#endif // !__PEL_H__
|