Giter Club home page Giter Club logo

robodkdriver's Introduction

RoboDK Robot Driver Boilerplate

You can read the story behind the project here.

What is RoboDK Robot Driver?

RoboDK's explanation on robot drivers can be found over here. Making your own RoboDK robot driver lets you control your own robot mechanisms.

custom robodk robot mechanism

How to use?

  1. Install library

    pip install robodkdriver
    
    
  2. Create a python file in RoboDK driver directory

  3. Import module

    from robodkdriver import RoboDK, RobotSerial
    
    
  4. Extend RobotSerial class

    class MyOneAxisRobot(RobotSerial):
        def run_command(self, cmd: str, args: tuple):
            RoboDK.update_status('working')
    
            if cmd == 'CONNECT':
                connected = self._connect(port=args[0], baud_rate=int(args[1]))
    
                if not connected:
                    return 'connection_problems'
    
                return 'ready'
    
            if cmd == 'DISCONNECT' or cmd == 'STOP':
                disconnected = self._disconnect()
    
                if disconnected:
                    return 'disconnected'
    
                return 'ready'
    
            if cmd == 'MOVJ':
                self._send_message('{cmd} {angle}'.format(cmd=cmd, angle=args[0]))
    
                if self._get_message('DONE'):
                    return 'ready'
    
                return 'error'
    
            if cmd == 'CJNT':
                self._send_message(cmd)
    
                joints = self._get_message()
                RoboDK.update_status(joints)
    
                return 'ready'
                
            ...
    
    

    You need to define how robot should act accordingly to each RoboDK command. You can return:

    • ready: when robot is ready for new command
    • working: when robot starts working
    • waiting: when robot is waiting
    • disconnected: when robot is disconnected
    • not_connected: when robot is not connected
    • connection_problems: when there are connection problems
  5. Start driver

    if __name__ == '__main__':
        RoboDK(MyOneAxisRobot()).run_driver()
    
    
  6. Change configuration on RoboDK robot connection

TODO

  1. RobotSocket Class
  2. Better getting started
  3. More info on how RoboDK driver communicates

robodkdriver's People

Contributors

egehandulger avatar

Stargazers

 avatar Travis Dent avatar Joshua Liu avatar Mark avatar

Watchers

 avatar Alex Silva RoboDK avatar

Forkers

minkione

robodkdriver's Issues

3d cad files

HI Egehan, i hope you are well.

do you have any 3d files available for the arduino braccio?

thanks in advance

JK

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.