Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rmii example #89

Merged
merged 4 commits into from
Feb 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ pipeline {
dir("${REPO}") {
warnError("Docs") {
buildDocs()
dir("examples/app_rmii_100Mbit_icmp") {
buildDocs()
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2013-2021 XMOS LIMITED.
// Copyright 2013-2025 XMOS LIMITED.
// This Software is subject to the terms of the XMOS Public Licence: Version 1.
#ifndef __icmp_h__
#define __icmp_h__
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2013-2021 XMOS LIMITED.
// Copyright 2013-2025 XMOS LIMITED.
// This Software is subject to the terms of the XMOS Public Licence: Version 1.
#include <debug_print.h>
#include <xclib.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2015-2024 XMOS LIMITED.
// Copyright 2015-2025 XMOS LIMITED.
// This Software is subject to the terms of the XMOS Public Licence: Version 1.
#include <xs1.h>
#include <platform.h>
Expand Down
2 changes: 1 addition & 1 deletion examples/app_mii_demo/src/main.xc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2015-2021 XMOS LIMITED.
// Copyright 2015-2025 XMOS LIMITED.
// This Software is subject to the terms of the XMOS Public Licence: Version 1.
#include <xs1.h>
#include <platform.h>
Expand Down
24 changes: 24 additions & 0 deletions examples/app_rmii_100Mbit_icmp/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
cmake_minimum_required(VERSION 3.21)
include($ENV{XMOS_CMAKE_PATH}/xcommon.cmake)
project(app_rmii_100Mbit_icmp)

set(APP_HW_TARGET xk-eth-xu316-dual-100m.xn)

include(${CMAKE_CURRENT_LIST_DIR}/../deps.cmake)

set(APP_PCA_ENABLE ON)

set(COMPILER_FLAGS_COMMON -g
-report
-DDEBUG_PRINT_ENABLE=1
-Os
-Wno-reinterpret-alignment
-DBOARD_SUPPORT_BOARD=XK_ETH_XU316_DUAL_100M)

set(APP_COMPILER_FLAGS ${COMPILER_FLAGS_COMMON})

set(APP_XSCOPE_SRCS src/config.xscope)

set(XMOS_SANDBOX_DIR ${CMAKE_CURRENT_LIST_DIR}/../../..)

XMOS_REGISTER_APP()
73 changes: 73 additions & 0 deletions examples/app_rmii_100Mbit_icmp/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
:orphan

#############################
100Mbit Ethernet RMII example
#############################

*******
Summary
*******

Ethernet connectivity is an essential part of the explosion of connected
devices known collectively as the Internet of Things (IoT). XMOS technology is
perfectly suited to these applications - offering future proof and reliable
ethernet connectivity whilst offering the flexibility to interface to a huge
variety of "Things".

This example that demonstrates the use
of the XMOS Ethernet library to create a layer 2 ethernet MAC
interface on an XMOS multicore microcontroller.

The code associated with this application note provides an example of
using the Ethernet Library to provide a framework for the creation of an
ethernet Reduced Media Independent Interface (RMII) and MAC interface for
100Mbps.

The applcation note uses XMOS libraries to provide a simple IP stack
capable of responding to an ICMP ping message. The code used in the
application note provides both RMII communication to the PHY and a MAC
transport layer for ethernet packets and enables a client to connect
to it and send/receive packets.

*****************
Required hardware
*****************

The example code provided with this application has been implemented and tested
on the xk_eth_xu316_dual_100m board.

**************
Required tools
**************

* XMOS XTC Tools: 15.3.0

*********************************
Required libraries (dependencies)
*********************************

* `lib_ethernet <https://www.xmos.com/file/lib_ethernet>`_
* `lib_xua <https://www.xmos.com/file/lib_xua>`_
* `lib_board_support <https://www.xmos.com/file/lib_board_support>`_
* `lib_otpinfo <https://www.xmos.com/file/lib_otpinfo>`_


*************
Prerequisites
*************

* This document assumes familarity with the XMOS xCORE architecture,
the Ethernet standards IEEE 802.3u (RMII), the XMOS tool chain and
the XC language. Documentation related to these aspects which are
not specific to this application note are linked to in the
references appendix.

* For an overview of the Ethernet library, please see the Ethernet
library user guide.


*******
Support
*******

This package is supported by XMOS Ltd. Issues can be raised against the software at: http://www.xmos.com/support
6 changes: 6 additions & 0 deletions examples/app_rmii_100Mbit_icmp/doc/exclude_patterns.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# The following patterns are to be excluded from the documentation build
examples
tests
.pytest_cache
CHANGELOG.rst
LICENSE.rst
Loading