If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.
I tried with pkt_bridge using the example of CoBox programmers guide:
Code:
#include <eth.h>
extern void (*pkt_bridge)();
void bridge_default(BYTE *rb);
demo()
{
pkt_bridge = bridge_default;
/* .... */
}
void bridge_default(BYTE *rb)
{
sendblk(rb,32); /* for example first 32 byte */
}
The result is that only IP or ARP packets (i.e. with ethernet type 0x800 and 0x806) are sent to serial. I need to handle PPP or PPPoE packets (ethernet type 0x8863 and 0x8864). I tried also to use pkt_default instead of pkt_bridge but the result is the same: it seems that these packets are not received or not handled properly.
I need to handle Ethernet frames other than IP type. What I need to do is simply to send to serial port the payload of a non-IP Ethernet frame and to build and send a Ethernet frame whose payload is received from the serial port.
In CoBox Pogrammer's Guide 611010 I found the Ethernet Frame Handling chapter for inbound and outbound frame processing.
The instructions contained in "Inbound Frame Processing" work only if ethernet type is 0x0800 (IP) or 0x0806 (ARP). I need instead to handle other types of Ethernet frames and I cannot handle those frames, neither with bridge functionality.
Leave a comment: