Skip to Content

Ardunote project: Arduino + NanoNote

On Tuxbrain, thanks to the Qi-Hardware , AVRFreaks communities and to the little UBB board, we have successfully flash an Arduino board from Ben NanoNote without need of external power, directly connecting a cable from the NanoNote 8:10 bay to the ICSP header on Arduino, also without need of bootloader in the Atmega328 chip, in fact NanoNote can flash the bootloaders :), and in theory Nanonote can flash whatever  avrdude compatible chip without need of any board (untested yet). Making the little Ben the first AVR microcontroller programmer in the world able to edit the source code, building it, listen music or play Supertux at same time, in same device, not bad for only 99€ ;)
From this starting point, we have founded a project called, in a fit of originality, ArduNote, that has as goal make the NanoNote a (even more) useful tool for Arduino and the rest of the AVR family. Right now is less more than a mission statement but in that wiki page we will try to collect all available information related to interaction between this two free(as freedom) hardware platforms, for now enjoy the video demo , and if you decide to jump in , if you buy a NanoNote and a Arduino we will include for free a UBB board and the components needed (cable, ICSP connector and schottky diode) to make the cable than appears in the video


HOWTO
Get the  Ben Nanonote ready to work with Arduino.

* Update the Nanonote to the latests Openwrt image (2011-02-23)
* Format and mount the data partition (1.5Gb) on NanoNote
* Connect  NanoNote to  Internet through  USB
* open an terminal and:

  #opkg update
  #opkg install make
  #cd /data
  #wget http://downloads.qi-hardware.com/people/xiangfu/packages/avrdude_5.10-2_...
  #opkg install avrdude_5.10-2_xburst.ipk
  #wget http://www.tuxbrain.org/downloads/nanonote/arduino/openwrt/avr_toolchain...
  #wget http://www.tuxbrain.org/downloads/nanonote/arduino/openwrt/arduino_022_l...
  #tar -xjf avr_toolchain_mips_4.3.4-binutils-2.20-libc-1.6.8_avrfreaks_patchs.tar.bz2
  #tar -xjf arduino_022_libs_bootloaders_examples.tar.bz2
  #wget http://www.tuxbrain.org/downloads/nanonote/arduino/openwrt/Makefile
  #rm avrdude_5.10-2_xburst.ipk
  #rm avr_toolchain_mips_4.3.4-binutils-2.20-libc-1.6.8_avrfreaks_patchs.tar.bz2
  #rm wget http://www.tuxbrain.org/downloads/nanonote/arduino/openwrt/arduino_022_l...

Build and upload an Arduino sketch.
To tell Nanonote that we want full control of the 8:10 GPIOs, you should do this every time NanoNote boots and want to mess with 8:10 GPIOs.

 #echo jz4740-mmc.0 >/sys/bus/platform/drivers/jz4740-mmc/unbind

Copy the Makefile to the sketch directory you want to work with:

  #cd <whatever_sketch_path>
  #cp /data/Makefile ./
  #make && make upload

Bootloaders
For now this steps just uploads the sketch binary , erasing the bootloader, meanwhile we are working with NN there will be no problem due we don't need it any more, saving space and speeding up program execution, but if we must return to work trhough USB or serial to flash, we need to reflash the bootloader. Inside the folder

/data/arduino/hardware/arduino/bootloaders  we have all bootloader collection include in the latest Arduino software release, for example to upload the bootloader than is actually shipped with Arduino UNO:

#avrdude -U flash:w:applet/data/arduino/hardware/arduino/bootloaders/optiboot/optiboot_atmega328.hex -V -e -C /etc/avrdude.conf -p atmega328p -c nanonote_ICSP

Update: Here is a video with the tutorial on how to make the cable

Here are the cable schematics

If you already have an NanoNote and/or an Arduino and you want buy the materials to build the cable here is a simple kit at tuxbrain shop