Raspberry Pi Mini-bots [wiki:PiBotHardware PiBot Hardware] * [https://www.raspberrypi.org/products/pi-zero/ Raspberry Pi Zero] * Install Jessie Lite to your sd card [https://www.raspberrypi.org/downloads/raspbian/ Raspbian Jessie OS] * [https://www.raspberrypi.org/documentation/installation/installing-images/README.md Installation instructions] * [http://blog.gbaman.info/?p=791 Setup for USB connectivity] * Configure your Pi with a fixed MAC address so you don't have to reconfigure windows network sharing every time you connect it. From [https://gist.github.com/Gadgetoid/319ecf8e3c5d3660e298], add the following stanza to the end of your /boot/cmdline.txt file in your Jessie install. Use a unique pair of MAC address for each Pi. Note there is exactly one space between each term, and the whole cmdline.txt file is one line. {{{ g_ether.dev_addr=5a:77:1e:af:8e:9e g_ether.host_addr=72:8d:1f:c4:e8:ca }}} * Install Bonjour Services from Apple. This allows your windows machine to 'just know' the hostname raspberrypi.local. See [https://support.apple.com/downloads/bonjour%2520for%2520windows Bonjour for Windows] * Connect your Pi to the computer via a USB 2.0 port. On the Pi use the usb port for data and power, not the one on the end (which is power, no data). * Wait a while while the Pi boots and your USB drivers for the Pi are installed. Once the light on the Pi should be solid green after a while and the driver is installed, continue. * Set up connection sharing between Windows and the Pi. * Go to Control Panel > Network and Sharing Center > Adapter Settings. * Identify the name of the network corresponding to the Pi--Its a Unidentified Network, USB Ethernet/RNDIS Gadget. Its probably something generic like "Ethernet 3". * Right click on your main ethernet card. Pick Properties > Sharing Tab. Check "Allow other network users to connect through this computer's internet connection, and pick the name of the home networking connection identified in the step above. Click OK. * Connect to Pi: {{{ ssh pi@raspberrypi.local }}} (password is raspberry) * Configure Pi * Setup DNS: {{{ sudo nano /etc/resolv.conf }}}. ''Do we need this if we're using Windows Network sharing?'' add: nameserver 8.8.8.8 * sudo raspi-config ''What should be done in this application?'' (If its "expand to use the whole sd card", that forces a reboot, and should probably move to the last step.) * Update to latest software (this will take a while): {{{ sudo apt-get update sudo apt-get upgrade }}} * Install Oracle Java JDK: {{{ sudo apt-get install oracle-java8-jdk }}}. Do not use OpenJDK, its slower. * Install git: {{{ sudo apt-get install git }}} * Install [http://wiringpi.com/ wiringPi]: {{{ mkdir ~/dev;cd ~/dev git clone git://git.drogon.net/wiringPi cd wiringPi ./build }}} Then, test by running "gpio -v" and "man gpio" * Install [http://pi4j.com/ Pi4J] * See: http://www.savagehomeautomation.com/projects/pi4j-connecting-java-to-the-raspberry-pi.html * [https://www.youtube.com/watch?v=grItDpy3TRM video tutorial] * Easy way, type: {{{ cd ~/dev curl -s get.pi4j.com | sudo bash }}} * ''Do we use Maven?'' * Shutdown your pi with 'sudo halt', disconnect it and reconnect it again to reboot it fully. You may have to reassign Windows Network Sharing connections one more time since the MAC is now constant, but it should stick after that. Ultrasonic Range Sensor * http://www.modmypi.com/blog/hc-sr04-ultrasonic-range-sensor-on-the-raspberry-pi The Pi Zero has 2 hardware-supported PWM outputs on GPIO18, GPIO19: [http://circuitdigest.com/microcontroller-projects/raspberry-pi-pwm-tutorial Pi PWM Tutorial] [https://www.npmjs.com/package/raspi-pwm PWM via WiringPi] through some clever programming, additional hardware-assisted PWM can be implemented via DMA: [https://pythonhosted.org/RPIO/pwm_py.html PWM via DMA]