sw_test.sh 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. #!/bin/bash
  2. # Creates a random Amiga ADF, writes the first three cylinders of a disk,
  3. # dumps those cylinders back, and checks against original ADF.
  4. # Write SCP, Read SCP
  5. dd if=/dev/urandom of=a.adf bs=512 count=1760
  6. disk-analyse -e 2 a.adf b.adf
  7. disk-analyse a.adf a.scp
  8. python3 gw.py write --ecyl=2 a.scp
  9. python3 gw.py read --revs=1 --ecyl=2 b.scp
  10. disk-analyse -e 2 b.scp c.adf
  11. diff b.adf c.adf
  12. md5sum b.adf c.adf
  13. rm -f a.adf b.adf c.adf a.scp b.scp
  14. # Write IPF, Read HFE
  15. dd if=/dev/urandom of=a.adf bs=512 count=1760
  16. disk-analyse -e 2 a.adf b.adf
  17. disk-analyse a.adf a.ipf
  18. python3 gw.py write --ecyl=2 a.ipf
  19. python3 gw.py read --revs=1 --ecyl=2 b.hfe
  20. disk-analyse -e 2 b.hfe c.adf
  21. diff b.adf c.adf
  22. md5sum b.adf c.adf
  23. rm -f a.adf b.adf c.adf a.ipf b.hfe
  24. # Write HFE, Read HFE
  25. dd if=/dev/urandom of=a.adf bs=512 count=1760
  26. disk-analyse -e 2 a.adf b.adf
  27. disk-analyse a.adf a.hfe
  28. python3 gw.py write --ecyl=2 a.hfe
  29. python3 gw.py read --revs=1 --ecyl=2 b.hfe
  30. disk-analyse -e 2 b.hfe c.adf
  31. diff b.adf c.adf
  32. md5sum b.adf c.adf
  33. rm -f a.adf b.adf c.adf a.hfe b.hfe