mirror of
https://github.com/ISpillMyDrink/OpenSuperClone.git
synced 2026-09-28 13:05:33 +00:00
59 lines
1.2 KiB
Plaintext
59 lines
1.2 KiB
Plaintext
# Seagate F3 Spin Up
|
|
# Sends the spin up command to a Seagate F3 drive.
|
|
# Changes to level 2 and issues the U command.
|
|
# Default baud: 38400, 8N1, no flow control.
|
|
#
|
|
# Use after spin down (Z) to restart the spindle motor.
|
|
# The drive should respond with "SpinUp" or similar
|
|
# confirmation before becoming ready for further commands.
|
|
|
|
echo "============================================"
|
|
echo " Seagate F3 Spin Up"
|
|
echo "============================================"
|
|
|
|
if $gui_mode = 0
|
|
serialopen /dev/ttyUSB0 38400
|
|
else
|
|
serialopen
|
|
endif
|
|
usleep 200000
|
|
|
|
echo "Waking terminal (Ctrl+Z)..."
|
|
serialsend \x1a
|
|
usleep 500000
|
|
|
|
echo "--- Terminal Banner ---"
|
|
buffersize 1024
|
|
serialread 1024
|
|
printbuffer 0 1024
|
|
|
|
echo ""
|
|
echo "Changing to level 2..."
|
|
serialsend \x2f\x32\x0d
|
|
usleep 200000
|
|
|
|
echo "--- Level Change ---"
|
|
serialread 1024
|
|
printbuffer 0 1024
|
|
|
|
echo ""
|
|
echo "=== Spinning Up (U) ==="
|
|
serialsend \x55\x0d
|
|
usleep 2000000
|
|
|
|
echo "--- Spin Up Response ---"
|
|
serialread 2048
|
|
printbuffer 0 2048
|
|
|
|
echo ""
|
|
echo "============================================"
|
|
echo " Spin up command sent."
|
|
echo " Drive should be ready for operation."
|
|
echo "============================================"
|
|
|
|
if $gui_mode = 0
|
|
serialclose
|
|
endif
|
|
echo "=== Done ==="
|
|
end
|