Showing posts with label pi. Show all posts
Showing posts with label pi. Show all posts

Jun 16, 2013

Raspberry Pi serial communication

Since I was tinkering with Pi network settings, sometimes I was loosing SSH connectivity.
Annoying process of hooking Pi to display and keyboard forced me to look for a serial connection option. This way I will just have to switch between two terminal windows, instead of messing with the cables.
I've got a dongle named "USB 2.0 to TTL Uart 5-Pin CP2102 Module Serial Converter", based on reviews it should work in this configuration.

Jun 14, 2013

Raspberry Pi with RT5370 Wireless Adapter

My PI worked flawlessly for some time hooked up to ethernet, but I wanted to move it away from router, and for this I bought some noname wifi dongle. After hooking it up, I run lsusb and it showed up as:
ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
Google told me that it should work out of the box. I used vanilla configuration:

/etc/network/interfaces
auto lo
iface lo inet loopback
iface eth0 inet dhcp
allow-hotplug wlan0
iface wlan0 inet manual
        wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf

iface default inet dhcp

/etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant
update_config=1
network={
        ssid="MYSSID"
        scan_ssid=1
        mode=0
        proto=WPA2
        auth_alg=OPEN
        pairwise=CCMP
        group=CCMP
        key_mgmt=WPA-PSK
        psk="MYPASSWORD"
}
The system behaved weirdly, it worked for some time with very sluggish connection speed, but most of the times, ssh connections where just timing out. People complaining about unstable performance, where told to hook it through powered USB hub, since it is possible that power supply on Raspberry cannot produce enough power.

Mar 24, 2013

Raspberry Pi emulator on OSX

I've ordered Raspberry Pi computer, but it didn't arrive yet, so I decided to try out the OS image provided from their site: http://www.raspberrypi.org/downloads.

I've found multiple articles on the net on how to do it on OSX, they all boil down to:

Get yourself qemu ARM software (in my case: sudo port install qemu +target_arm)
Get qemu ARM kernel from here.
Get wheezy image from raspberry site.
Launch:
qemu-system-arm -kernel kernel-qemu -cpu arm1176 -m 256 -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 rootfstype=ext4 elevator=deadline rootwait panic=1" -hda 2013-02-09-wheezy-raspbian.img -redir tcp:5022::22

On my system with qemu 1.4.0 this image hangs after printing few SCSI timeout erros.
Commenting out /etc/ld.so.preload did not help, instead of SCSI errors i got kernel panic.
But soft-float image: 2012-08-08-wheezy-armel.zip.torrent works as expected.

After booting, you can access shell with ssh localhost -p 5022.