Skip to content

Unable to capture ACK #13

@charlescao460

Description

@charlescao460

So...I was trying to capture some ACKs to verify @ammaraskar's finding. However it can't receive anything from the base after I send answer using iClicker.
Here is my sketch, could you please check this problem?

#include "iClickerEmulator.h"
#include <string.h>
#include <RingBufCPP.h>
#include <stdint.h>


/*For Arduino Nano and RFM69HW*/
#define IS_RFM69HW true //make true if using w version
#define IRQ_PIN 3		// Must Be 3 for Nano
#define CSN 10			// NSS pin,10 for Nano
/*End For Arduino Nano and RFM69HW*/
#define MAX_BUFFERED_PACKETS 5 

iClickerEmulator clicker(CSN, IRQ_PIN, digitalPinToInterrupt(IRQ_PIN), IS_RFM69HW);
RingBufCPP<iClickerPacket, MAX_BUFFERED_PACKETS> recvBuf;


// the setup function runs once when you press reset or power the board
void setup()
{
	Serial.begin(115200);
	clicker.begin(iClickerChannels::AA);
	clicker.startPromiscuous(CHANNEL_RECV, recvPacketHandler);
}

// the loop function runs over and over again until power down or reset
void loop()
{
	iClickerPacket r;
	while (recvBuf.pull(&r)) 
	{
		uint8_t* ack = r.packet.respPacket.unknown;
		for (int i = 0; i < 7; ++i) 
		{
			char temp[5];
			snprintf(temp, sizeof(temp), "%02X ", ack[i]);
			Serial.print(temp);
		}
		Serial.println();

	}
}

void recvPacketHandler(iClickerPacket *recvd)
{
	recvBuf.add(*recvd);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions