/*
 * e_pq_A.h
 *
 *  Created on: 06-07-2016
 *      Author: Krzysztof Jakubczyk
 */

#ifndef E_PQ_A_H_
#define E_PQ_A_H_

#include "tdefs.h"

struct e_pq_a_logic
{
	float *i1_orta;
	float *i1_ortb;
	float *i2_orta;
	float *i2_ortb;
	float *u1_orta;
	float *u1_ortb;
	float *u2_orta;
	float *u2_ortb;
	float *p;
	float *q;
};

struct e_pq_a_io
{
	u32 i1_orta_float_in;
	u32 i1_ortb_float_in;
	u32 i2_orta_float_in;
	u32 i2_ortb_float_in;
	u32 u1_orta_float_in;
	u32 u1_ortb_float_in;
	u32 u2_orta_float_in;
	u32 u2_ortb_float_in;
	u32 p_float_out;
	u32 q_float_out;
}__attribute__((__packed__));

struct e_pq_a_params
{
}__attribute__((__packed__));

struct e_pq_a_args
{
	struct e_pq_a_io io;
	struct e_pq_a_params params;
//	u16 crc;
}__attribute__((__packed__));

extern void e_pq_a_100hz(void *args, void *logic);
extern int e_pq_a_initlog(void *arguments, void *logic);

#endif /* E_PQ_A_H_ */
