Hi,
I am using the AT86RF231 radio in extended mode to get the hardware ACKs working. When a receiver receives a message, the following interrupts are raised: RX_START, AMI (Address Match Interrupt) followed by end of reception (TRX_END interrupt). The transmitter gets back the ACK successfully as well. However, when there are 2 receivers and a msg is meant only to one of them, both of them receive the msg and send back an ACK. This means that somehow the address filtering logic is not working. I need help figuring this out please. Here are my configuration details:
1. The transmission msg header is as follows:
a. FCF (2 bytes) - bit 0 to 15 - 34851
Bit 0,1,2 - Frame type is MAC - 011
Bit 3 (security enabled) - 0
Bit 4 (frame pending) - 0
Bit 5 (Ack request) - 1
Bit 6 (Intra pan) - 0 (src PAN is not omitted)
Bit 7,8,9 (Reserved) - 000
Bit 10, 11 (16-bit short src address) - 10
Bit 12, 13 (Frame version) - 00
Bit 14,15 (dest address) - 10
b. Sequence number - 1 byte
c. Dest pan - 2 bytes
d. Dest address - 2 bytes
e. Src pan - 2 bytes
f. Src address - 2 bytes
g. Some extra information needed by my MAC protocol such as length, type of the msg - 4 bytes. Not sure if including this in the header causes any problems.
2. AACK_UPLD_RES_FT and AACK_FLTR_RES_FT - set to 0
3. AACK_FVN_MODE - set to 00 so that only frame version 0 is acknowledged.
In the initialization routine of the radio, the address and PAN_IDs are set as follows:
UINT16 addressHigh = GetAddress() >> 8;
UINT16 addressLow = GetAddress() & 0xFF;
WriteRegister(RF230_SHORT_ADDR_0, addressLow);
WriteRegister(RF230_SHORT_ADDR_1, addressHigh);
However, only when AACK_UPLD_RES_FT and AACK_FLTR_RES_FT are set to 1 and AACK_FVN_MODE is set to 11, are ACKs generated. This indicates that my msg header has some reserved fields. I am not sure what I am doing wrong. Any help in this regard would be great.
UPDATE 1:
1. AACK_FVN_MODE is set to 01 (Acknowledge frames with version number 0 or 1) and AACK_UPLD_RES_FT and AACK_FLTR_RES_FT are set to 0 (not process reserved frame types).
2. FCF is set to 33809 (No reserved frame types).
Bit 0,1,2 - Frame type is DATA - 100
Bit 3 (security enabled) - 0
Bit 4 (frame pending) - 0
Bit 5 (Ack request) - 1
Bit 6 (Intra pan) - 0 (srcpan is ignored)
Bit 7,8,9 (Reserved) - 000
Bit 10, 11 (16-bit short src address) - 01
Bit 12, 13 (Frame version) - 00
Bit 14,15 (dest address) - 01
3. Radio's address is set to 0x0.
WriteRegister(RF230_SHORT_ADDR_0, 0x00);
WriteRegister(RF230_SHORT_ADDR_1, 0x00);
4. Transmitter sends msg to 0x00 (dest address is 0x00), then an AMI and TRX_END interrupts are generated and an ACK is generated as well.
5. However, if transmitter sends msg to 0x1111 for instance (dest address is still 0x00), then an AMI and TRX_END interrupts along with an ACK are generated. This should not happen if address filtering works correctly.
b. This indicates that there is something wrong with the address field configuration. I am not sure what the problem is though.
Thanks,
Ananth.