Enocean RPS报文发送例程

#include "EO3000I_API.h"
#include "EO3000I_CFG.h"

/************************************************************************-
EVA Board:
    EVA300-3 

Input PIN:

Output PIN:
    RSDADIO3    LMI LED

Description:
    Project template to start your own project.

Notes:
	1. Ensure to add the correct radio settings assembler file according your HW module. 
	2. use DolphinStudio to configure the API
	3. modify main()....

-************************************************************************/
#include <stdio.h>


// ------------------------------------------------------------------
code uint8 VERSION_APP[] = {0xE0,'V','E','R','S','I','O','N',
                            1,0,1,0,                                  // change APP Version here  
                            'A',
                            'T','E','M','P','L','A','T','E',          // change APP Description here (max. 15 chars)
                            0x00,0xE0};
// ------------------------------------------------------------------
void main()
{		
	TEL_RADIO_TYPE rTel;
	TEL_PARAM_TYPE pTel;
	pTel.p_tx.u8SubTelNum = 3;
	pTel.p_tx.u32DestinationId = 0;	 
	
	mainInit();	                                                      // API initialisation
	
	rTel.trps.u8Choice = RADIO_CHOICE_RPS;

        rTel.trps.u32Id = 0;
        rTel.trps.u8Status = 0;
        rTel.trps.u8Data = 0;
        rTel.trps.u8Length = RADIO_DEC_LENGTH_RPS; 

 	while(1)
	{			
                io_togDigital(RSDADIO_3);                                     // toggle LMI LED
		radio_ulpPrepareTelegram(&rTel,NULL);
                radio_ulpSend3SubTels();
		time_wait(2000);                                               // wait 500ms
		CLR_WDT();
	}
}

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值