Userspace Arduino

From eLinux.org
Revision as of 06:44, 18 May 2013 by Anujdeshpande (talk | contribs) (ssh/scp/sftp)
Jump to: navigation, search

this page is to document some research on creating a userspace executable using the wiring and processing language used with Arduino.


Transfer Options

Netcat

  • GNU Netcat networking tool http://netcat.sourceforge.net/
  • Can create a connection using nc -w 1 192.168.7.2 1114 < new.zip on the server (in this case the machine running the Energia IDE), and nc -lp 1114 > n.zip on the Beaglebone. 1114 is a random port number which has to be the same on client as well as server side.
  • Some issue with sending .bin files directly. Mostly it was with how the file ends, not sure. So zip the file, use netcat to send and then unzip it on the Beaglebone.
  • Requires no authentication

ssh/scp/sftp

  • Needs authentication.
  • scp/sftp is built over ssh i.e. they use ssh for authentication and copying
  • To enter the password and execute the program after copying one will have to use a tool like expect (http://www.nist.gov/el/msid/expect.cfm)or sshpass (http://www.debianadmin.com/sshpass-non-interactive-ssh-password-authentication.html). Both of these tools usually don't ship with any Linux distribution.
  • sshpass is slightly less complicated than expect. But some issues are there with using sshpass and sftp to upload the binary to the bone. Executing the binary encountered no issues.
  • In case the user has set his own password and/or username, the IDE can contain a simple form to accept the same.

arduino bootloader over usb

  • requires application running on usb gadget