GithubHelp home page GithubHelp logo

hapticinterfaceproject's Introduction

WPI RBE 595 Haptic and Robotic Interaction

Prof. Jing Xiao | Fall 2022

The goal of this project is to develop a simulated environment where a user-controlled haptic interface point (HIP) interacts with arbitrary objects. We based this work based off Zilles and Salisbury's Constraint-based method:

https://ieeexplore.ieee.org/document/525876

We render the environment in PyGame using PyOpenGL to draw our object, god-object, and HIP. Numpy is required for a lot of the god-object calculations.

TO RUN:

Open main.py and choose the model you would like to test against. Make sure the HIP vertex is initialized outside the object, failing to do so will cause stability issues and break the simulation.

To control the HIP, the keyboard arrow keys are used: up and down for Y-axis motion, left and right for X-axis motion, and the right shift and return key for Z-axis motion.

To control the camera, the mouse can be used to rotate the view. Also, the w and s keys will zoom in and out, respectively.

RESULTS:

For a concave object, here a triangular prism:

Alt text

And for a convex object, here a dodecahedron:

Alt text

Notes:

The simulation is not perfect, at times a collision with the object is not detected. In this situation, the god-object will be allowed to cross to a position where it should not be. At this point, you have two options: restart the simulation OR attempt another collision until it returns to the correct state.

The render module contains all the PyOpenGL and PyGame information and initializations. The HapticInterfacePoint module contains all the god calculations and handles updating the position of the HIP and god-object, updating the constraints, and calculating the forces. The checker module just contains the line and point tests required to detect collision and update constraints.

Reach out for any questions.

hapticinterfaceproject's People

Contributors

hylander2126 avatar

Stargazers

 avatar  avatar

Watchers

James Cloos avatar  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.