packet->final_delay = 128;
}
-static void mfx_receive_feedback()
+static void mfx_receive_feedback(uint8_t type)
{
/* The decoder should activate a 52.6 kHz carrier to indicate positive
acknowledgement, but so far I've been unable to build a circuit that detects
}
uint8_t reply[2];
- reply[0] = MFX_FEEDBACK;
+ reply[0] = type;
if(current[1]>feedback_threshold)
{
current[1] -= feedback_threshold;
mask_bits <<= 16;
mask_bits |= (uint16_t)(cmd[3]<<8)|cmd[4];
mfx_search_packet(mask_bits, mask_size);
- mfx_receive_feedback();
+ mfx_receive_feedback(MFX_SEARCH_FEEDBACK);
}
else if(cmd[0]==MFX_ASSIGN_ADDRESS || cmd[0]==MFX_PING)
{
else
{
mfx_ping_packet(addr, id);
- mfx_receive_feedback();
+ mfx_receive_feedback(MFX_PING_FEEDBACK);
}
}
else if(cmd[0]==MFX_SPEED || cmd[0]==MFX_SPEED_FUNCS8 || cmd[0]==MFX_SPEED_FUNCS16)