Code Monkey home page Code Monkey logo

robertalab-nao-ba's Introduction

robertalab-nao

Introduction

Make a connection between robertalab and NAO possible and allow the robertalab to generate python code for NAO.

Folder nao python files

These python files are made to run on a NAO. Some will only work as remote module. You need to change the ip in order to make these work on your robot. The structure of the folders reprents the structure that is planned for the implementation of the robot NAO into the Open Roberta Lab.

The playground.py is used to test the qimessaging service.

Folder connection

These files are a first approach to make it possible to establish an connection between the robertalab server and the robot NAO.

This is currently under development. Further information are in the comments in the files.

  • The naoconnect.java file is the latest version. It transfers a token and checks it and afterwards sends a file to NAO and executes it.

  • SitDown.py and StandUp.py are two files that are transferred for testing purposes. They represent the files that contain the code generated by the lab.

  • token.py is transferred to a remote NAO by naoconnect.java and makes NAO say a randomly generated token.

  • hal.py is the file that contains every method for every Block. It must be available on the robot in order to allow the genereated code from the lab to work on the NAO. This file makes it possible to reduce the generated Code to one line of code for every Block and makes it easier to understand the code

  • the following files are deprecated and are considered to document the progress before the project was made available on GitHub

  • fsconnectNew.java is the first version where the ftp and ssh parts are separated in two different methods.

  • FTPconnect.java is a very early version that only allows to transfer files to a remote NAO via ftp.

  • fsToken.java is a late version that allows (transfer) and commands only via SSH. Transfer won't work properly because NAO rejects the RSA fingerprint for security reasons

Testing of the console programm (mainly for developing and testing)

A NAO V4 or V5 is required and you need the latest version of Java. Additionaly these .jar's are required:

If you want to edit the .py files that are made for NAO you also need Python and the latest Python SDK from Softbank Robotics.

To try it out:

Clone the repository: git clone https://github.com/OpenRoberta/robertalab-nao.git

Open naoconnect.java in your favourite editor. Edit the configuration parameters(ip,port,...) to fit your needs. You need the additional .jar's mentioned above in the same path as your naoconnect.java file.

  • Compile it: javac -cp commons-net-3.1.jar;jsch-0.1.54.jar naoconnect.java
  • Execute it: java -cp commons-net-3.1.jar;jsch-0.1.54.jar;. naoconnect

OLD TODO

  • informations (server, user, password) should be obtained from robotconfiguration
  • make the connection compatible to robertalab
  • test if transfer and commands are possible with SFTP
  • add useful error messages DONE
  • improve the random token generation NOT NECESSARY?
  • add a hal file for methods that would otherwise generate more than one line of code DONE
  • transfer the hal file to the robot DONE
  • edit the hal file to represent a method for every Block DONE
  • The transferred files should be checked. (Maybe via MD5) Method is implemented but not used yet. An additional file needs to be transferred on the robot to do this. Implement this with a switch to disable it. DONE
  • The transfer can be done via SSH. The ftp part is not necessary and should therefore be deleted. The method 'sshcommand' has to be extended. DONE
  • String for file copying over SSH/SCP should be generated out of variables DONE
  • rename/translate the python files and folders DONE

robertalab-nao-ba's People

Contributors

janism91 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.