Questions tagged [interruption]

126 questions
1
vote
2 answers

thread is not interruptible

I'm trying to work on the famous dining philosophers and its quite finished but I'm having a quite hard time trying to interrupt threads. so as you know in this problem we have 5 threads (philosophers) and the user set an experiment time at which…
StudentAccount4
  • 186
  • 1
  • 11
1
vote
1 answer

how to continue recording automatically if interrupted by an uialert such as text message, push notifications, or low battery status, etc

I have a voice recording app on iPhone OS 4.1. I notice that the app stops recording (maybe because it loses focus) when any alert such as text message or timer or alarms or push notifications and most importantly, low battery alerts, pop up. …
Anand
  • 153
  • 1
  • 8
1
vote
1 answer

Java Thread - synchronization thread

I have something like this: enter code here public class Main { public static void main(String[] args) throws InterruptedException { StringTask task = new StringTask("A", 100000); System.out.println("Task " + task.getState()); …
Baobao
  • 17
  • 2
1
vote
1 answer

How to stop threads in Java

I'm coding a program that generates a random number in between 1 and 1,000. It then uses a thread pool of three threads to search certain number ranges in the broader 1 to 1,000 range. The threads check each number in their range, and compares it to…
1
vote
1 answer

Arduino Due Timer crash

I am trying to read an analog input (A0) with a speed of 10KHz, using the library Due Timer, but, when I increase the value of the vector it crashs, the goal is to use the vector in a FFT analysis with a 5000 size vector. I have tried to work…
John
  • 11
  • 1
1
vote
1 answer

Handling Interruptions With AVAudioRecorder

I am using an AVAudioRecorder to check the volume level and accordingly update a UIImageView. However, when I hold the home button down for Siri or when the device receives a phone call, the UIImageView is not updated anymore. This is my current…
1
vote
1 answer

Android - Save in app browser state (page + place in page) when app is interrupted

Part of my app is opening the browser in app and sending the user to a dedicated webpage (lets call it "FirstPage"). There the user can navigate throw the web pages. That works great, but when the user is in the webpages and the app gets interrupted…
yoav
  • 23
  • 3
1
vote
2 answers

Is it possible that GUI event interrupts running code from the GUI thread to execute its own event handler method?

I have a weird behavior in my GUI code. If the user produces a lot of events in a short time, it happens that a running event handler method gets interrupted by another event handler method. Since everything runs in the same thread (GUI thread)…
Enyra
  • 17,542
  • 12
  • 35
  • 44
1
vote
1 answer

How to write an *interruptible* recursive(?) descent parser

I have a pretty standard recursive descent parser. The algorithm is straightforward: each function reads characters from a stream and either returns FAIL or calls subsequent parse functions (specified by a corresponding grammar rule): function…
tillda
  • 18,150
  • 16
  • 51
  • 70
1
vote
2 answers

How do big sites like Stackoverflow, change styles and other files without interruption?

I noticed yesterday that there was a new navigation bar on top of this site. And it has also added more features on the nav bar that definately requires server side changes or at least newer queries. Yes it has ver attached to the css as a variable…
Abu Nooh
  • 846
  • 4
  • 12
  • 42
1
vote
2 answers

ncurses interrupts system call when resizing terminal

I have a problem with ncurses and couldn't find a solution on the web, so I've written following little program to demonstrate the problem. You can compile it via: sudo aptitude install ncurses-dev g++ -lncurses -o resize resize.cpp It displays an…
1
vote
1 answer

Restarting MediaPlayer when connection lost

Is the following code is right and sufficient for restarting the MediaPlayer in Android, when getting sudden stops of the HTTP MP3 live stream due to connection to the server lost or Internet connection lost/switching to other type of it? I will to…
1
vote
0 answers

AVAudioSessionDelegate beginInterruption is not called iOS 6.0.1

I am creating an iPhone application with music player. I used AVPlayer for creating music player. The issue is beginInterruption method is not called in iOS 6.0.1 when a phone call arrives. But endInterruptionWithFlags:flags called. In lesser…
Mithuzz
  • 1,091
  • 14
  • 43
1
vote
5 answers

USART receive interrupt stm32

I develop on a map I'm working on STM32 and USART interrupts. After configuring the USART1 and make Enable receive interrupt. The problem that the interruption of reception have no detected????
rhso
  • 41
  • 1
  • 2
  • 6
1
vote
1 answer

play music infinitely until a button is clicked

I'm just trying to play music continuously in an infinite loop until a button is clicked.it works fine but,say for eg: my sound file is 5 sec. after every 5 sec there is a pause and the music plays again.Is there anyway to prevent that and play the…
lakshganga
  • 2,355
  • 6
  • 21
  • 22
1 2 3
8 9