mirror of
https://github.com/pocopico/tinycore-redpill.git
synced 2025-09-15 12:51:13 +08:00
Merge pull request #374 from dodert/main
This commit is contained in:
11
rploader.sh
11
rploader.sh
@ -2300,11 +2300,19 @@ function serialgen() {
|
||||
[ ! -z "$GATEWAY_INTERFACE" ] && shift 0 || shift 1
|
||||
|
||||
[ "$2" == "realmac" ] && let keepmac=1 || let keepmac=0
|
||||
|
||||
keepmacinterface="eth0"
|
||||
|
||||
if [[ -n "$3" ]]; then
|
||||
keepmacinterface="$3"
|
||||
fi
|
||||
|
||||
echo "Interface selected : $keepmacinterface"
|
||||
|
||||
if [ "$1" = "DS3615xs" ] || [ "$1" = "DS3617xs" ] || [ "$1" = "DS916+" ] || [ "$1" = "DS918+" ] || [ "$1" = "DS920+" ] || [ "$1" = "DS3622xs+" ] || [ "$1" = "FS6400" ] || [ "$1" = "DVA3219" ] || [ "$1" = "DVA3221" ] || [ "$1" = "DS1621+" ] || [ "$1" = "DVA1622" ] || [ "$1" = "DS2422+" ] || [ "$1" = "RS4021xs+" ] || [ "$1" = "DS1522+" ] || [ "$1" = "DS923+" ] || [ "$1" = "SA6400" ] || [ "$1" = "FS2500" ] || [ "$1" = "RS3413xs+" ] || [ "$1" = "ds1019p" ] || [ "$1" = "dS1520p" ] || [ "$1" = "ds1621xsp" ] || [ "$1" = "ds723p" ]; then
|
||||
serial="$(generateSerial $1)"
|
||||
mac="$(generateMacAddress $1)"
|
||||
realmac=$(ifconfig eth0 | head -1 | awk '{print $NF}')
|
||||
realmac=$(ifconfig $keepmacinterface | head -1 | awk '{print $NF}')
|
||||
echo "Serial Number for Model = $serial"
|
||||
echo "Mac Address for Model $1 = $mac "
|
||||
[ $keepmac -eq 1 ] && echo "Real Mac Address : $realmac"
|
||||
@ -2818,6 +2826,7 @@ mountshare, version, monitor, bringfriend, downloadupgradepat, help
|
||||
DS3615xs DS3617xs DS916+ DS918+ DS920+ DS3622xs+ FS6400 DVA3219 DVA3221 DS1621+ DVA1622 DS2422+ RS4021xs+ DS923+ DS1522+ SA6400 FS2500 RS3413xs+ DS1019+ DS1520+ DS1621xs+ DS723+
|
||||
|
||||
Valid Options : realmac , keeps the real mac of interface eth0
|
||||
realmac <ethernet interface>, realmac eth2
|
||||
|
||||
- identifyusb :
|
||||
Tries to identify your loader usb stick VID:PID and updates the user_config.json file
|
||||
|
Reference in New Issue
Block a user