Last active
January 1, 2019 16:06
-
-
Save thomasvanta/29e26ae05237e3f87cd3eea1211145af to your computer and use it in GitHub Desktop.
Revisions
-
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 7 additions and 7 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -8,7 +8,7 @@ export QEMU=$(which qemu-system-arm) brew install wget ``` #### *get stretch kernel, device tree and raspbian image* ``` wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch @@ -17,9 +17,9 @@ wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-1 unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img ``` #### *Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions.* #### *Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards* ``` $QEMU \ -kernel $RPI_KERNEL \ @@ -30,13 +30,13 @@ $QEMU \ -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" ``` #### *So at this point you should get the emulator window and a terminal you can add the following commands in.* ``` sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab ``` #### *Exit that and the next command will start the actual raspberry pi emulation.* # *Emulate Raspberry Pi* ``` @@ -49,9 +49,9 @@ $QEMU \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" \ -net user,hostfwd=tcp::5022-:22 -net nic ``` #### *Available over network with this SSH command.* #### **Login to Raspberry Pi** ``` ssh -p 5022 pi@localhost ``` -
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 9 additions and 9 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ # Install QEMU OSX port with ARM support ``` /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" @@ -8,7 +8,7 @@ export QEMU=$(which qemu-system-arm) brew install wget ``` ## *get stretch kernel, device tree and raspbian image* ``` wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch @@ -17,9 +17,9 @@ wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-1 unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img ``` ## *Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions.* ## *Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards* ``` $QEMU \ -kernel $RPI_KERNEL \ @@ -30,15 +30,15 @@ $QEMU \ -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" ``` ## *So at this point you should get the emulator window and a terminal you can add the following commands in.* ``` sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab ``` ## *Exit that and the next command will start the actual raspberry pi emulation.* # *Emulate Raspberry Pi* ``` $QEMU \ -kernel $RPI_KERNEL \ @@ -49,9 +49,9 @@ $QEMU \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" \ -net user,hostfwd=tcp::5022-:22 -net nic ``` ## *Available over network with this SSH command.* ## **Login to Raspberry Pi** ``` ssh -p 5022 pi@localhost ``` -
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 17 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ #Install QEMU OSX port with ARM support ``` /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" @@ -21,7 +21,14 @@ export RPI_FS=./2018-11-13-raspbian-stretch.img ##*Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards*## ``` $QEMU \ -kernel $RPI_KERNEL \ -cpu arm1176 -m 256 \ -dtb versatile-pb.dtb \ -M versatilepb \ -no-reboot -serial stdio \ -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" ``` ##*So at this point you should get the emulator window and a terminal you can add the following commands in.*## ``` @@ -33,7 +40,14 @@ sed -i -e 's/^/#/' /etc/fstab #**Emulate Raspberry Pi**# ``` $QEMU \ -kernel $RPI_KERNEL \ -cpu arm1176 -m 256 \ -dtb versatile-pb.dtb -M versatilepb \ -no-reboot -serial stdio \ -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" \ -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" \ -net user,hostfwd=tcp::5022-:22 -net nic ``` ##*Available over network with this SSH command.*## -
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 22 additions and 19 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,40 +1,43 @@ #**Install QEMU OSX port with ARM support**# ``` /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && brew update && brew install qemu export QEMU=$(which qemu-system-arm) brew install wget ``` ##*get stretch kernel, device tree and raspbian image*## ``` wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/versatile-pb.dtb wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-11-13-raspbian-stretch.zip unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img ``` ##*Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions.*## ##*Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards*## ``` $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" ``` ##*So at this point you should get the emulator window and a terminal you can add the following commands in.*## ``` sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab ``` ##*Exit that and the next command will start the actual raspberry pi emulation.*## #**Emulate Raspberry Pi**# ``` $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" -net user,hostfwd=tcp::5022-:22 -net nic ``` ##*Available over network with this SSH command.*## ##**Login to Raspberry Pi**## ``` ssh -p 5022 pi@localhost ``` -
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 11 additions and 11 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,12 +1,12 @@ #**Install QEMU OSX port with ARM support** /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && brew update && brew install qemu export QEMU=$(which qemu-system-arm) brew install wget ##*get stretch kernel, device tree and raspbian image* wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch @@ -15,26 +15,26 @@ wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-1 unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img ##*Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions.* ##*Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards* $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" ##*So at this point you should get the emulator window and a terminal you can add the following commands in.* sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab ##*Exit that and the next command will start the actual raspberry pi emulation.* #**Emulate Raspberry Pi** $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" -net user,hostfwd=tcp::5022-:22 -net nic ##*Available over network with this SSH command.* ##**Login to Raspberry Pi** ssh -p 5022 pi@localhost -
thomasvanta revised this gist
Jan 1, 2019 . 1 changed file with 15 additions and 9 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,34 +1,40 @@ **Install QEMU OSX port with ARM support** /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && brew update && brew install qemu export QEMU=$(which qemu-system-arm) brew install wget *get stretch kernel, device tree and raspbian image* wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/versatile-pb.dtb wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-11-13-raspbian-stretch.zip unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img *Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions.* *Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards* $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" *So at this point you should get the emulator window and a terminal you can add the following commands in.* sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab *Exit that and the next command will start the actual raspberry pi emulation.* **Emulate Raspberry Pi** $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" -net user,hostfwd=tcp::5022-:22 -net nic *Available over network with this SSH command.* *Login to Raspberry Pi* ssh -p 5022 pi@localhost -
thomasvanta created this gist
Jan 1, 2019 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,34 @@ **Install QEMU OSX port with ARM support** /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && brew update && brew install qemu export QEMU=$(which qemu-system-arm) brew install wget //get stretch kernel, device tree and raspbian image wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/kernel-qemu-4.9.59-stretch export RPI_KERNEL=./kernel-qemu-4.9.59-stretch wget https://github.com/dhruvvyas90/qemu-rpi-kernel/raw/master/versatile-pb.dtb wget http://downloads.raspberrypi.org/raspbian/images/raspbian-2018-11-15/2018-11-13-raspbian-stretch.zip unzip 2018-11-13-raspbian-stretch.zip export RPI_FS=./2018-11-13-raspbian-stretch.img //Here make sure to reference the .img file in the last EXPORT and not the .zip file as per original instructions. //Tweak filesystem: start qemu with init flag, switch to guest window to execute tweak and close window afterwards $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" //So at this point you should get the emulator window and a terminal you can add the following commands in. sed -i -e 's/^/#/' /etc/ld.so.preload sed -i -e 's/^/#/' /etc/ld.so.conf sed -i -e 's/^/#/' /etc/fstab //Exit that and the next command will start the actual raspberry pi emulation. //Emulate Raspberry Pi $QEMU -kernel $RPI_KERNEL -cpu arm1176 -m 256 -dtb versatile-pb.dtb -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" -drive "file=2018-11-13-raspbian-stretch.img,index=0,media=disk,format=raw" -net user,hostfwd=tcp::5022-:22 -net nic //Available over network with this SSH command. //Login to Raspberry Pi ssh -p 5022 pi@localhost