Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement vibratory haptics #104

Open
brettfiedler opened this issue Mar 29, 2022 · 9 comments
Open

Implement vibratory haptics #104

brettfiedler opened this issue Mar 29, 2022 · 9 comments

Comments

@brettfiedler
Copy link
Contributor

brettfiedler commented Mar 29, 2022

Bryan and Jen from SLU came up with a first pass design of vibratory haptics for non-visual access.

Google Doc linked here.

We'll use this as our guide for initial implementation of vibratory haptics for the Quad sim.

Let's look over the design and prioritize specific parts for implementation during our meeting on 4/5/22.

@brettfiedler
Copy link
Contributor Author

We've decided to implement the 4 cases found under the Dynamic haptic design.

(pasted from design, not necessarily most up to date)

Dynamic Simulation Haptics

Case 1: Quad corner is dragged

Pattern: Pulsing vibration (0.2s – 300bpm)
Repeat: While user continues to have finger on corner
Intensity: 1.0

Case 2: Quad side is dragged

Pattern: Pulsing vibration (0.4s – 150bpm)
Repeat: While user continues to have finger on side
Intensity: 1.0

Case 3: Physical limitation point is reached

Pattern: Fast double buzz, “no-no”
Repeat: No repeat
Intensity: 1.0

Case 4: Screen limitation point is reached

Pattern: Ramping global intensity
Repeat: Continuous
Intensity: 0.25-1.0

(Possible pick up vibrations)

Cases 3 and 4 require model changes from issue #117

@jessegreenberg
Copy link
Contributor

jessegreenberg commented Apr 5, 2022

@jbphet and I had two questions about the above design:

  1. We weren't sure how case 4 would trigger. Is it continuous while dragging along the edge? Does it continue to vibrate if the object is left along the boundary?
  2. Confirming the "pause" request that was mentioned today. We think that refers to disabling input so that user can trace the shape and feel vibratory feedback that way. Is that correct? "Pause" has a very particular meaning in sims for play/pause, can we rename this feature to something else such as "locked" or "frozen"?

@brettfiedler
Copy link
Contributor Author

In response to Question 1 in the previous comment: Update to Design (see doc for latest which might contradict this later!)

Case 1: Quad corner is dragged
Pattern: Pulsing vibration (0.2s – 300bpm)
Repeat: While user continues to have finger on corner
Intensity: 1.0
Case 2: Quad side is dragged
Pattern: Pulsing vibration (0.4s – 150bpm)
Repeat: While user continues to have finger on side
Intensity: 1.0
Case 3: Physical limitation point is reached
Pattern: Fast double buzz, “no-no”
Repeat: No repeat
Intensity: 1.0
Case 4b: Screen limitation point is reached
Pattern: Fast buzz/“bump”
Repeat: No repeat
Intensity: 1.0

@brettfiedler
Copy link
Contributor Author

  1. Confirming the "pause" request that was mentioned today. We think that refers to disabling input so that user can trace the shape and feel vibratory feedback that way. Is that correct? "Pause" has a very particular meaning in sims for play/pause, can we rename this feature to something else such as "locked" or "frozen"?

Discussed in Slack, but we'll likely use language around "locked" as suggested. First haptic design will focus on the dynamic sim before adding a "locked" mode. Priority will be given in a separate issue for implementing the locked state.

@jessegreenberg
Copy link
Contributor

jessegreenberg commented Apr 26, 2022

@jbphet and I added vibration for Case 1 and Case 2. We are still working on the other cases and the issues that are blocking that part.

But if you would like to review case 1 and case 2 on an Android device you can do so here: https://phet-dev.colorado.edu/html/quadrilateral/1.0.0-dev.28/phet/quadrilateral_en_phet.html

Assigning to @BLFiedler so you are aware. I shared this link with Jen over slack.

@jbphet
Copy link
Contributor

jbphet commented May 16, 2022

In the 5/10/2022 review meeting it was requested that we modify the vertex vibration pattern from [100ms on, 100ms off] to [75ms on, 75 ms off].

@jbphet jbphet changed the title Implement vibratory haptics for Android app Implement vibratory haptics Jul 1, 2022
@jbphet
Copy link
Contributor

jbphet commented Jul 1, 2022

I modified the title for this issue, since we are no longer focusing on the Android app for this. The main reason for the change to using an HTML5 version instead is that many of the Android devices don't actually support vibration intensity even though the Android API does. Thus, there isn't really much to be gained from doing it as an Android app, and doing it in HTML5 is significantly easier.

@jessegreenberg
Copy link
Contributor

The sim has been reporting this error in the console because of phetsims/tappi#17

image

I am going to comment out the vibration features for now until we return to this.

@brettfiedler
Copy link
Contributor Author

This feature is on hold until we're able to return to it pending time/funding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants