The ethernet layer 2 mac component documentation says that the full implementation will allow multiple clients.
How do two clients use the mac_tx function?
Is it by using different tx channel ends of the array of tx channel ends that are passed to the ethernet_server function?
Is there a limit to the number of clients or the size of this channel end array?
How to use multiple clients with ethernet mac_tx function?
-
- XCore Addict
- Posts: 204
- Joined: Sun Jun 01, 2014 10:25 pm
-
- Respected Member
- Posts: 279
- Joined: Fri Dec 11, 2009 1:34 pm
Hi Gerry,
which can be found in ethernet_conf.h or avb_conf.h (if an AVB design).
That's right.gerrykurz wrote: Is it by using different tx channel ends of the array of tx channel ends that are passed to the ethernet_server function?
The limit is defined bygerrykurz wrote: Is there a limit to the number of clients or the size of this channel end array?
Code: Select all
#define MAX_ETHERNET_CLIENTS
-
- XCore Addict
- Posts: 204
- Joined: Sun Jun 01, 2014 10:25 pm
How do you get the text framing in your reply and the sub window to put code into?
Here is the ethernet_config.h file in the Low Level Ethernet Demo code that I am using.
Where is CONFIG_FULL defined?
I am doing a FULL build but the second ethernet tx client is not working. I have confirmed this by swapping the channel between the two clients.
Here is my main function:
When downlink_repeater uses tx[0] it is able to transmit but demo using tx[1] is not
When demo uses tx[0] it transmits but downlink_repeater using tx[1] does not
Any suggestions?
Here is the ethernet_config.h file in the Low Level Ethernet Demo code that I am using.
Code: Select all
// Copyright (c) 2011, XMOS Ltd, All rights reserved
// This software is freely distributable under a derivative of the
// University of Illinois/NCSA Open Source License posted in
// LICENSE.txt and at <http://github.xcore.com/>
#ifdef CONFIG_FULL
#define ETHERNET_DEFAULT_IMPLEMENTATION full
#define MAX_ETHERNET_PACKET_SIZE (1518)
#define MAX_ETHERNET_CLIENTS (4)
#else
#define ETHERNET_DEFAULT_IMPLEMENTATION lite
#endif
I am doing a FULL build but the second ethernet tx client is not working. I have confirmed this by swapping the channel between the two clients.
Here is my main function:
Code: Select all
int main()
{
chan rx[1], tx[2], DownPort1Rx[1], DownPort1Tx[1], packet_channel_up, packet_channel_down;
par
{
//::ethernet
on ETHERNET_DEFAULT_TILE:
{
char mac_address[6];
otp_board_info_get_mac(otp_ports, 0, mac_address);
eth_phy_reset(eth_rst);
smi_init(smi);
eth_phy_config(1, smi);
ethernet_server(mii,
null,
mac_address,
rx, 1,
tx, 1);
}
//::
//::demo
// on ETHERNET_DEFAULT_TILE : demo(tx[0], rx[0]);
on ETHERNET_DEFAULT_TILE: demo(tx[1], rx[0], packet_channel_down);
on ETHERNET_DEFAULT_TILE: downlink_repeater (tx[0], packet_channel_up);
When demo uses tx[0] it transmits but downlink_repeater using tx[1] does not
Any suggestions?
-
- XCore Addict
- Posts: 204
- Joined: Sun Jun 01, 2014 10:25 pm
Never mind about the code tags question, I figured it out.
-
- XCore Addict
- Posts: 204
- Joined: Sun Jun 01, 2014 10:25 pm
Also figured out the multiple client issue......
-
- XCore Expert
- Posts: 589
- Joined: Wed Feb 29, 2012 10:03 am
Have a look at the Ethernet MAC library application notes in the following link, if you need more information:
https://www.xmos.com/download/public/AN ... 0.0%29.pdf
https://www.xmos.com/download/public/AN ... 0.0%29.pdf