element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • 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
Atmel Xplained Boards
  • Products
  • Dev Tools
  • Atmel Xplained Boards
  • More
  • Cancel
Atmel Xplained Boards
Blog MAC address fix on SAMA5D3 Xplained
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Atmel Xplained Boards to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: dragonunderling
  • Date Created: 23 Feb 2015 3:49 AM Date Created
  • Views 860 views
  • Likes 1 like
  • Comments 2 comments
Related
Recommended

MAC address fix on SAMA5D3 Xplained

dragonunderling
dragonunderling
23 Feb 2015

I found it very frustrating to try to access the Xplained from SSH. It never had a MAC address set so it would assign a new one every boot and a new IP to go with it. Here are the instructions to set the MAC address so this doesn't happen any more.

 

First, you must have a TTL cable. These are usually about $10 US. This is a must so you can see the device boot.

 

Second, at the prompt to enter U-Boot hit any key to get dumped in. You should see a prompt like this:  U-Boot>

 

Once here use the "printenv" command to view the environment variables. You should see this:

 

 

baudrate=115200

bootargs=console=ttyS0,115200 earlyprintk mtdparts=atmel_nand:256k(bootstrap)ro,512k(uboot)ro,256K(env),256k(evn_redundent),256k(spare),512k(dtb),6M(kernel)ro,-(rootfs) rootfstype=ubifs ubi.mtd=7 root=ubi0:rootfs

bootcmd=nand read 0x21000000 0x180000 0x80000;nand read 0x22000000 0x200000 0x600000;bootz 0x22000000 - 0x21000000

bootdelay=3

ethact=gmac0

stderr=serial

stdin=serial

stdout=serial

 

Once you have these variables you can change any here. I changed my boot delay to 5 to give me more time.

 

Third, using the "setenv" command you can change/set new vairables. ex : setenv ethaddr 24:56:44:22:5b:ab This sets the first MAC address. NOTE: Once this one is saved it cannot be changed without wiping the entire flash memory! At this point you can set the second MAC address using the variable eth1address. This sets the second address, and can be changed.

 

Fourth, use the "printenv" command again to view your changes. At this point nothing is saved to memory and can be changed/corrected including the first MAC address. EX:

 

baudrate=115200

bootargs=console=ttyS0,115200 earlyprintk mtdparts=atmel_nand:256k(bootstrap)ro,512k(uboot)ro,256K(env),256k(evn_redundent),256k(spare),512k(dtb),6M(kernel)ro,-(rootfs) rootfstype=ubifs ubi.mtd=7 root=ubi0:rootfs

bootcmd=nand read 0x21000000 0x180000 0x80000;nand read 0x22000000 0x200000 0x600000;bootz 0x22000000 - 0x21000000

bootdelay=5

eth1addr=22:65:46:29:4b:cb

ethact=gmac0

ethaddr=24:56:44:22:5b:ab

stderr=serial

stdin=serial

stdout=serial

 

 

Fifth, use "saveenv" to save all changes. This will write all changes to memory so they won't be lost during a reset/reboot. NOTE: Once again, after this command is used the first MAC address cannot be changed!

 

Finnally, you can reboot the device using the "reset" command and poof it now has MAC addresses assigned to each port. YAY!

  • Sign in to reply
  • dragonunderling
    dragonunderling over 10 years ago in reply to clem57

    It still has the stock Linux on it. I am playing around with Debian as I'm not too fond of Yocto.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • clem57
    clem57 over 10 years ago

    What linux is this on SAMA5D3? Good documentation!

    • 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