POWERSHELL 27
Collect_sd_card_information.sh Guest on 25th June 2020 03:53:20 AM
  1. #!/bin/sh
  2. echo "Hardware revision:$(grep Revision /proc/cpuinfo  | cut -d : -f2)"
  3. echo "NOR bootloader: $(strings /dev/mtd0 | egrep "^(U-Boot|Qi) ")"
  4. echo "NAND bootloader: $(strings /dev/mtd1 | egrep "^(U-Boot|Qi) ")"
  5. echo "Linux version: $(cat /proc/version)"
  6. echo "Linux cmdline: $(cat /proc/cmdline)"
  7. echo "MMC size: $(dmesg | grep "mmcblk0: mmc")"
  8. echo "MMC date: $(cat /sys/block/mmcblk0/device/date)"
  9. echo "MMC fwrev: $(cat /sys/block/mmcblk0/device/fwrev)"
  10. echo "MMC hwrev: $(cat /sys/block/mmcblk0/device/hwrev)"
  11. echo "MMC manfid: $(cat /sys/block/mmcblk0/device/manfid)"
  12. echo "MMC name: $(cat /sys/block/mmcblk0/device/name)"
  13. echo "MMC oemid: $(cat /sys/block/mmcblk0/device/oemid)"
  14. echo "first 2 bytes of MMC serial number: $(cut --bytes=3-6 /sys/block/mmcblk0/device/serial)"
  15.  
  16. sync
  17. echo 3 > /proc/sys/vm/drop_caches
  18. start=$(date +%s)
  19. dd if=/dev/mmcblk0 of=/dev/null bs=1M count=64 2> /dev/null
  20. end=$(date +%s)
  21. echo "MMC sequential read of 64M: $(expr $end - $start) s"

Paste is for source code and general debugging text.

Login or Register to edit, delete and keep track of your pastes and more.

Raw Paste

Login or Register to edit or fork this paste. It's free.