Announcement

Collapse
No announcement yet.

bounce with UOLED 160-G2

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • darbyvet
    replied
    Thanks Paul

    Leave a comment:


  • pauleilio
    replied
    Hi,

    Yes thats correct, it won't ddelay the frame using this method. If you find the playback too fast then you could always use pause(ms); to slow it down in your playback loop.

    Best regards

    Paul

    Leave a comment:


  • darbyvet
    replied
    Thanks Paul.That is a simple solution. I do have another question.In the object inspector when you load a video there is a number called delay.I assume this number is used to determine the fps the video clip is played? However, since I am using the media_videoframe function I assume the delay value doesnt do anything? I did try changing the value and nothing changed in the image display rate.

    Carl

    Leave a comment:


  • pauleilio
    replied
    Hi,

    Depending on what the effect of the bounce is, you could set variable and when the button is pressed it is loaded with a value say 15 which gets decremented until 0 on each frame and in the button checking routine you could ignore a check if this variable is greater than 0 eg,

    Code:
    var BounceDelay;
    
    if(BounceDelay == 0)
      if(button1)
        // do button1 code
        BounceDelay := 15;
      endif
      if(button2)
        // do button2 code
        BounceDelay := 15;
      endif
      if(button3)
        // do button3 code
        BounceDelay := 15;
      endif
    endif
    
    if(BounceDelay > 0) BounceDelay --;
    I'm not sure how well this would work out but might be worth a try and avoids using a delay

    Best regards

    Paul

    Leave a comment:


  • darbyvet
    started a topic bounce with UOLED 160-G2

    bounce with UOLED 160-G2

    So I am continuing on my tricorder project.I now have the screen playing a selection of video clips using 3 buttons to determine the clip played. I am seeing some bounce from the switches. I dont really want to put a delay in the software because I have it set up to play the video clips frame by frame. Is there a debounce function with the GPU or could I use a Logiswtich LS118 debouncer in the button circuitry to eliminate the bounce?
Working...
X