

Kazymir
-
Posts
18 -
Joined
-
Last visited
Reputation Activity
-
Kazymir reacted to TRay in Orange Pi Zero 2W
Looking on news about kernel 6.8 :
https://www.cnx-software.com/2024/03/11/linux-6-8-release-notable-changes-arm-risc-v-mips-architectures/#arm-updates-in-linux-6-8
it was added support for Orange Pi Zero 2W:
-
Kazymir got a reaction from Gammel in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
si it can help you for a nanopi neo3
you can write a script like
sudo nano extract_mac.sh
#!/bin/bash # Extraire l'adresse MAC de l'EEPROM mac_address="" mac_address+="$(sudo i2cget -y -f 0 0x51 0xfa c):$(sudo i2cget -y -f 0 0x51 0xfb c)" mac_address+=:"$(sudo i2cget -y -f 0 0x51 0xfc c):$(sudo i2cget -y -f 0 0x51 0xfd c)" mac_address+=:"$(sudo i2cget -y -f 0 0x51 0xfe c):$(sudo i2cget -y -f 0 0x51 0xff c)" # Supprimer les préfixes "0x" mac_address="${mac_address//0x/}" mac_address=$(echo $mac_address | tr '[:lower:]' '[:upper:]') echo "MAC address: $mac_address" # Extraire l'adresse MAC du fichier de configuration NetworkManager configured_mac_address="$(sudo grep "mac-address=" /etc/NetworkManager/system-connections/Wired\ connection\ 1.nmconnection | cut -d "=" -f 2)" # configured_mac_address="${configured_mac_address//:/}" echo "configured mac address: $configured_mac_address" # Comparer les adresses MAC if [[ "$mac_address" != "$configured_mac_address" ]]; then echo "Les adresses MAC sont différentes. Mise à jour nécessaire." # Mettre à jour le fichier de configuration NetworkManager avec la nouvelle adresse MAC sudo sed -i "s/mac-address=.*/mac-address=$mac_address/" /etc/NetworkManager/system-connections/Wired\ connection\ 1.nmconnection # Redémarrer NetworkManager pour prendre en compte les modifications sudo service NetworkManager restart echo "Adresse MAC mise à jour et redémarrage du systeme." # Redémarrer complètement le système pour prendre en compte les modifications sudo reboot else echo "Les adresses MAC sont identiques." fi and
and to start script
it's working well for me
best regards
-
Kazymir got a reaction from Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
I am allright with you and i find my MAC Address here
sudo i2cdump 0 0x51
i have a Neo3 with i2c eeprom and the mac is writing inside
and when i go to
/etc/NetworkManager/system-connections# sudo nano Wired\ connection\ 1.nmconnection
i can see that the MAC is fixed
How can we patch this problem?
-
Kazymir got a reaction from Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
i watch this in u-boot????
-
Kazymir got a reaction from Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
si it can help you for a nanopi neo3
you can write a script like
sudo nano extract_mac.sh
#!/bin/bash # Extraire l'adresse MAC de l'EEPROM mac_address="" mac_address+="$(sudo i2cget -y -f 0 0x51 0xfa c):$(sudo i2cget -y -f 0 0x51 0xfb c)" mac_address+=:"$(sudo i2cget -y -f 0 0x51 0xfc c):$(sudo i2cget -y -f 0 0x51 0xfd c)" mac_address+=:"$(sudo i2cget -y -f 0 0x51 0xfe c):$(sudo i2cget -y -f 0 0x51 0xff c)" # Supprimer les préfixes "0x" mac_address="${mac_address//0x/}" mac_address=$(echo $mac_address | tr '[:lower:]' '[:upper:]') echo "MAC address: $mac_address" # Extraire l'adresse MAC du fichier de configuration NetworkManager configured_mac_address="$(sudo grep "mac-address=" /etc/NetworkManager/system-connections/Wired\ connection\ 1.nmconnection | cut -d "=" -f 2)" # configured_mac_address="${configured_mac_address//:/}" echo "configured mac address: $configured_mac_address" # Comparer les adresses MAC if [[ "$mac_address" != "$configured_mac_address" ]]; then echo "Les adresses MAC sont différentes. Mise à jour nécessaire." # Mettre à jour le fichier de configuration NetworkManager avec la nouvelle adresse MAC sudo sed -i "s/mac-address=.*/mac-address=$mac_address/" /etc/NetworkManager/system-connections/Wired\ connection\ 1.nmconnection # Redémarrer NetworkManager pour prendre en compte les modifications sudo service NetworkManager restart echo "Adresse MAC mise à jour et redémarrage du systeme." # Redémarrer complètement le système pour prendre en compte les modifications sudo reboot else echo "Les adresses MAC sont identiques." fi and
and to start script
it's working well for me
best regards
-
Kazymir got a reaction from Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
yes i think they didn't read the i2c eeprom at start
-
Kazymir reacted to Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
You forgot something that i test, you can launch it directly.
You just need to add this in the repository /etc/rc.local before the line "exit 0"
/bin/bash /etc/init.d/extract_mac.sh
If you do this, the script will launch automatically if the MAC didn't correspond, and if they correspond then he will don't reboot so you don't have to launch it manually if you had these line.
-
Kazymir reacted to Lollifeet in NanoPi NEO3 on ARMbian 23.02.2 not using physical MAC address
this is very coded with foot, but its working
thanx you