2019年11月13日 星期三

DEBUGGING ARDUINO SKETCHES WITH ATMEL STUDIO 7 (How to install hardware debug tool for ATMEL Studion 7)









Refer to :
1. http://www.solutions-cubed.com/electronic-design-blog/debugging-arduino-sketches-with-atmel-studio-7/

Arduino IDE (Windows app version vs conventional version)

1. The Arduino IDE from Windows app store do not have conventional directory. It's directory is on
   Windows hides windows store apps in c:/users/YourUserName/AppData(hidden folder)/Local/Packages
2. App version of Arduino IDE is not good to translate Arduino sketch file(*.ino) to ATMEL Studio 7 (*.cpp).
3. Suggestion: Removed app version of Arduino IDE and install conventional Arduino IDE from https://www.arduino.cc/en/main/software

2019年9月24日 星期二

AC6 STM32 Eclipse


Run System Workbench for STM32
1. load workspace
    PS: You may delete workspace if you need.

2. Open Projects from File System

3. Import Projects From File System or Archive


4. Build Code to check project is OK or not.



2019年6月24日 星期一

VT-x is not available for VirtualBox in Windows 10

1. rum cmd as administrator
2. cmd: bcdedit /set hypervisorlaunchtype off
3. cmd: dism.exe /Online /Disable-Feature:Microsoft-Hyper-V
4. cmd: Dism /Online /Cleanup-Image /RestoreHealth
5. cmd: sfc /scannow
6. Close cmd
7. run PowerShell as Administrator
8. PowerShell: Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V-All
9. Restart














Refer to:
1. https://ugetfix.com/ask/how-to-disable-hyper-v-in-windows-10/




2019年3月15日 星期五

Passwordless SSH access

1. Check for existing SSH keys

# ls ~/.ssh


2. Generate new SSH keys

# ssh-keygen


3. Check for SSH keys

# ls ~/.ssh


4. Copy your pulic key to server

# ssh-copy-id <username>@<ip-address>

or

# cat ~/.ssh/id_rsa.pub | ssh <username>@<ip-address> 'mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys' 



Refer to:
1. https://www.raspberrypi.org/documentation/remote-access/ssh/passwordless.md
2. https://askubuntu.com/questions/46930/how-can-i-set-up-password-less-ssh-login

2019年3月7日 星期四

2019年3月4日 星期一

The default password of root for Centos 7.


There is no password. Password-based login as "root" is initially disabled. You need to login to to your default (admin) account using SSH and your key, and then run "sudo passwd root" to set a password on the "root" account. Otherwise you have to reset root password during reboot.

2019年2月25日 星期一

Linux dd command usages


dd 指令教學與實用範例,備份與回復資料的小工具 
Refer to: https://blog.gtwang.org/linux/dd-command-examples/
備份整顆硬碟
將 /dev/sda 所有的資料寫入 /dev/sdb:
sudo dd if=/dev/sda of=/dev/sdb conv=noerror,sync

建立硬碟的備份影像檔
sudo dd if=/dev/hda of=~/hdadisk.img

從備份影像檔回復硬碟資料
sudo dd if=hdadisk.img of=/dev/hdb

備份磁碟分割區
sudo dd if=/dev/hda1 of=~/partition1.img

兩個磁碟分割區對拷:
sudo dd if=/dev/sda1 of=/dev/sdb1 bs=4096 conv=noerror,sync

備份 CD/DVD 光碟
sudo dd if=/dev/cdrom of=tgsservice.iso bs=2048

備份 CD/DVD 光碟, 壓縮資料
sudo dd if=/dev/sda | gzip > sdadisk.img.gz

從壓縮過的影像檔回復資料
sudo gzip -dc sdadisk.img.gz | dd of=/dev/sda

Linux 使用 dd 指令將 ISO 檔製作成 Live USB 隨身碟
Refer to: https://blog.gtwang.org/linux/linux-dd-command-write-iso-to-usb-flash-drive/
umount /media/pi/disk
卸載後再次確認一下卸載的 USB 隨身碟是否正確:
lsblk
用 dd 指令將 Linux 的 ISO 映像檔寫入 USB 隨身碟
sudo dd if=ubuntu-16.10-desktop-amd64.iso of=/dev/sdc bs=1M