element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Arduino Projects
  • Products
  • Arduino
  • Arduino Projects
  • More
  • Cancel
Arduino Projects
Blog Working router with PoE support
  • Blog
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Arduino Projects requires membership for participation - click to join
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: embeddedguy
  • Date Created: 10 Jul 2024 7:57 AM Date Created
  • Views 670 views
  • Likes 5 likes
  • Comments 3 comments
  • raspberrypi
  • iot
  • router
Related
Recommended

Working router with PoE support

embeddedguy
embeddedguy
10 Jul 2024

Created and installed rpi4 based router to access internet. This also has PoE hat on it..

image

Introduction

Recently, I was having a need for a router or a wifi range extender. Because, the high speed internet in my home router was not connecting to other Flores. For that I could either have to buy a router or create my own. 

I thought of creating a router by myself. For that I would like to thank Element14 because they have sent me few Raspberry Pi 4 over time. As far as I remember one was for one meter of pi challenge, other was for asking a good question in one of the webinar from Micron about memory technologies. And one more for some quiz winners announcement. 

One more thing is that I am using PoE(Power over Ethernet) to supply to the Raspberry Pi. I have road tested that HaT some years ago. 

Raspberry Pi PoE HaT with Raspberry Pi 4 roadtest review

Real Stuff

There are many Linux versions and distros that could run on Raspberry Pi. All or many of them have advantages and are designed for specific use case. Normally they all support basic networking and other raspberry Pi project use case scenarios. But for advance configurations some are specifically designed. For example, Kali Linux is for people who are interested in penetration testing. There are other distros for gaming, automation, automotive applications etc.

For creating a router that works in home or office, I have decided to use Ubuntu server image for Raspberry Pi 4. This is because Ubuntu provides good documentation and networking related  software configurations. For creating router it is important that networking related settings are properly configured. For that, Ubuntu has Netplan software that takes care of networking settings. Netplan is configurable through .YAML files and  Linux commands. 

https://ubuntu.com/download/server/arm

For creating a router it is required to configure Raspberry Pi WiFi interface as Access point(AP) rather than a station device.

Also, raspberry pi Ethernet interface such as ETH0 is configured as access point. Which means it gets a WAN connection and shares it will other interface. Normally, with Netplan there was no need to explicitly specify  a Bridge connection between these two device interfaces(ETH0 and WLAN0).

Now let's have a look at how does the .YAML files for Netplan looks like. Netplan is stored in /etc/netplan/50-cloud-init.yaml file.

After coping the contents of netplan into a Netplan file, restart the netplan with

$ sudo netplan apply

The above command will apply the netplan settings as described in the below file. Hence, you will have a working Router.

You can try to connect the network using a mobile phone with SSID and password mentioned in the netplan file and be able to connect to the internet. The condition here is that there should be working internet on Ethernet interface.

image

Conclusion and future plans

It was quite interesting to work on this project in my free time. Nevertheless, there are improvements and other features that one might want to add. For me adding a official camera module to this device will be interesting. Because then it will have a Router plus a camera in one device and it will be quite awesome. I have tested that the camera is indeed working on this 64-bit version of Ubuntu. I would also love to make a video tutorial and post it online, how I have created this device. Also, I would love to hear some feedback from the community members about this project. Specially, thanks to DAB  for motivating me to post this tiny blog and share my work so that others can follow.

  • Sign in to reply
  • DAB
    DAB 10 months ago in reply to embeddedguy

    OK, thanks.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • embeddedguy
    embeddedguy 10 months ago in reply to DAB

    Hi, I have added some details but I want to try and add some more stuff to the existing project such as camera support and also something like home automation. Be it adding a printer support or accessing PLC. That is why this is a small blog post and letter stage I will try to edit it.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB 10 months ago

    Details?

    Someone might want to copy your accomplishment.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube