Record buffer audio zero problem

Hello

I write a j2me application where I save an audio stream and treat it in real time. I access the audio buffer every two seconds, take the data stored in the byte array and reset the buffer (ByteArrayOutputStream). Even if I reset the buffer combined Blackberry ignors command and reset the buffer data are accumilated (I use JDE 4.5). Can you get it someone please let me know how to fix this problem.

Thank you

I tried this on a BlackBerry 8700 running 4.5.0.81 and has not been able to reproduce.  The stream is being reset.

You could wrap your timer code in a synchronized block synchronized on the ByteArrayOutputStream.  It might be that the record and timer thread is accessing the variable at the same time.

Tags: BlackBerry Developers

Similar Questions

  • Recording and audio playback problem

    I have windows 7 and I have problems with the audio recording and playback.  If I record something myself, or just play something on the internet, the "stretch" sound in places as the person talking is now on a particular letter; for example, they might say, "" Hi, theeeeeeeeeere. "» or "I'm nnnnnnnot a joke." How to return to nice, audio cleanup?

    Hello

    Welcome to the Microsoft Community Forum.

    I understand that you have a problem with the playback of the sounds and audio recording in Windows 7. I appreciate your efforts to solve this problem, I'll probably help you with that.

    To solve your problem, I'll give you some troubleshooting steps.

    Method 1

    Run the tool of Windows troubleshooting audio in your Windows 7.

    See the following Microsoft Help article and run the Audio troubleshooter and check if it helps. This is a built-in convenience store that helps you solve common problems with Audio.

    http://Windows.Microsoft.com/en-us/Windows7/open-the-playing-audio-Troubleshooter

    Method 2

    Try installing the latest audio drivers and check if the problem persists. This is to check if the problem is caused due to not install the drivers the most recent or not.

    http://Windows.Microsoft.com/en-us/Windows/Update-driver-hardware-ISN

    You can also view the following Microsoft Help article below:

    http://Windows.Microsoft.com/en-us/Windows/no-sound-help#no-sound=Windows-7&V1H=win8tab1&V2H=win7tab4&V3H=winvistatab1&v4h=winxptab1

    Try the above steps and get back to us if the problem persists.

    Thank you

  • Problem reading recorded in audio

    Hello

    The following code is what I used to read the audio recorded.

    Private Sub sayHello()

    {

    int i = 0;

    data Byte [] = null;

    Audio AudioRecorderThread = new AudioRecorderThread ("gsm");

    audio. Start();

    Try

    {

    Thread.Sleep (5000);

    }

    catch (InterruptedException e)

    {

    e.printStackTrace ();

    }

    audio. Stop();

    System.out.println ("recording stopped");

    data = audio.getAudioBuffer ();

    ByteArrayInputStream IStream = new ByteArrayInputStream (buff, 0, data.length);

    Try

    {

    A player = Manager.createPlayer (istream, audio.getContentType ());

    Player.Realize ();

    Player.prefetch ();

    player.setLoopCount (1);

    player.addPlayerListener (this);

    VolumeControl vc = player.getControl ("VolumeControl") (VolumeControl);

    If (vc! = null) vc.setLevel (100);

    System.out.println ("player Staring");

    Player.Start ();

    Thread.Sleep (6000);

    System.out.println ("judgment of the reader");

    Player.Close ();

    IStream.Close ();

    }

    catch (System.Exception e)

    {

    System.out.println (e.getMessage ());

    }

    }

    The code for AudionRecorderThread is as follows,

    public void run()

    {

    Try

    {

    Create a player who live audio recordings.

    _player = Manager.createPlayer ("capture://audio?encoding=" + contentType);

    _player. Realize();

    Get the RecordControl, configure the flow of record,

    _rcontrol = (RecordControl) _player.getControl ("RecordControl");

    contentType = _rcontrol.getContentType ();

    Create a ByteArrayOutputStream to record the audio stream.

    _output = new ByteArrayOutputStream();

    _rcontrol.setRecordStream (_output);

    _rcontrol.startRecord ();

    _player. Start();

    }

    catch (System.exception final e)

    {

    UiApplication.getUiApplication () .invokeAndWait (new Runnable()

    {

    public void run()

    {

    Dialog.Inform (try ());

    }

    });

    }

    }

    public void stop()

    {

    Try

    {

    System.out.println ("slaughter recording");

    Stop recording, record data of the OutputStream,

    closing the OutputStream and player.

    _rcontrol.commit ();

    _data = _output.toByteArray ();

    _output. Close();

    _player. Close();

    }

    catch (System.Exception e)

    {

    synchronized (UiApplication.getEventLock ())

    {

    Dialog.Inform (try ());

    }

    }

    }

    The code above works file when encoding is gsm, but is unable to work with the regime pcm encoding.

    With PCM, it gives error "not a snd file.

    I tried putting the header before the captured data. But then it gives error Audiomanager:IOException and media.

    [0,0] VM:NCICv = 56 [0,0] VM:NMACv = 11

    [0,0] AR: remove the source 11

    [0,0] AR: setAudioMode 32

    [0,0] stopped recording

    [0,0] [-683785997] SMP: _ss = 1799

    [0,0] MN: init0 (0, 0, 5) = 0

    [0,0] MN: charge 0

    [0,0] VM:NCICv = 10

    [0,0] VM:NMACv = 25

    [0,0] AUDIOMANAGER: IOException

    [0,0] MP: h = 0, s = LG: + mErr

    [0,0] MP: h = 0, s = LG: + unlC

    [0,0] MN: finalize0 (0)

    [0,0] MP: h = 0, s = LG :-> UD

    [0,0] MP: h = 0, s = UD:-unlC

    [0,0] MP: h = 0, s = UD: mErr.

    [0,0] MP: h = 0, s = UD: LOAD ERR

    [0,0] MP: h = 0, s = UD: + UNLD

    [0,0] MP: h = 0, s = UD: UNLD.

    [0,0] Media: e:MdEr:9

    [0,0] of media initialization error.

    Help, please

    Thank you

    For PCM, it would be wise to add a wave header.

  • Is T410 - possible to record system audio (via Camtasia)?

    Hi all, can't seem to find the option to record the audio system (what you hear through speakers) when trying to capture video on my laptop, because I'm only given the opportunity to record via internal microphone. In addition to a loop/patch my headphone to mic jacks, is this possible to do?  I read that the sound card Connexant or Windows 7 can not allow this option.

    Thanks in advance.

    Thank you, previous poster.

    Fortunately, I found a solution!  7 Camtasia!  Enables the system to record audio without problem!

    TY, Camtasia!

    See you soon

  • I just installed Prime Minister 11 items and when I save a project, it is only to record the audio.

    I just installed Prime Minister 11 items and when I save a project, it is only to record the audio. I made sure that export audio and video boxes are checked in the advanced Panel, but still only audio. When I went to save it, I got a pop up that says something in mircosoft wanting to make changes to my computer and I clicked on is not to think that they were related (and), but only audio get exported. I have quick time installed, but still nothing. Help, please!

    Amandaw

    There may be an explanation for what you are experiencing.

    On what computer operating system is your first items 11 running? Windows 8 or 8.1? And you are exporting to a file MPEG2.mpg and playback on Windows Media Player? If this is the case, please download and install the VLC Player

    VideoLAN - official page for VLC media player, the video frame Open Source!

    and let us know if export plays back video and audio on this drive.

    If that's the problem known Microsoft MPEG2 Windows Media Player, and then explore publish them + share/computer/possibilities other than MPEG or use VLC instead of Windows Media Player player for playback of MPEG2.mpg exports.

    Please let us know the result.

    Thank you.

    RTA

  • Audio export problem

    An audio clip on my time line is not exported with the rest of the video. It has synchronized audio to an audio recorder and this is the only clip that comes out of the silence. Other audio is rendered. The clip shows up on the time line and normally reads on the time line. Someone had this problem? Is there a solution?

    I have "fixed" the issue by exporting to the hearing and recording an audio extract file. He seems to have recognized it. In a test report.

    I got errors 'Master clip' whenever I opened the project and the same audio clip should not any audio in it. I have to copy the audio track to another project and paste in this timeline of projects and it worked for a while until her SOUL would not export the clip said. I tried to dissociate and restoring links the file without result.

    I also have issues when I open the project none of the media seems to load, his perpetually showing 'media pending' to fix this I then re - enable and disable all clips that brings media partners in the time line.

  • Audio sync problems

    I am a wedding videographer who has a few months ago, from FCP to the PrPro CS5. I am currently working on a wedding ceremony where I have some audio synchronization problems. I filmed the wedding with 3 cameras high definition. The video was filmed all HDV 29.97, with 32-bit audio 48000khz. In addition, I used microphones tie for the spouse and the officer, each record to a device in the WMA format. I used "free mp3 wma converter" (which may be part of the problem!) to convert the WMA in 480000khz 32-bit WAV files. After using HDV Split to ensure that there are no breaks, I have imported/captured everything in first CS5. Once I dropped everything in the timeline panel, I find the part in every audio layer where the officate said thank you, "you can be sitting." I created markers not numbered to the exact frame that starts and all the video layers 3 and 5 audio layers becomes synchronized. However, when I scroll further down the timeline, something badly screwed up and I don't know if it's the video w / audio layers, or if this is WMA files that I have converted to WAV. Any help would be great!

    There are several discussions on the use of a separate Audio recorder and the OOS issues. Much discussion was provided by a few of us "old-timers," who bemoaned how things were to be, when the movie camera was attached to the Nagra, and could be configured to provide synchronization of Crystal, but that does not seem possible today with our great digital equipment. Should be easy, but it is a difference in "clocks".

    Hope just to get this straight, as I blew it away last wire - one single user with Zoom Audio recorder has found that the Audio derived from 100.3%, used if just the Stretch tool w / maintain Pitch to address that. It took experimentation, but when he found the % correct, it fixed everything.

    For questions of a general nature OOS, this ARTICLE could offer some advice, but in the end, I think finding the % of drift, will fix everything for you and with this same equipment, will still work. Test now will be dividend in the future.

    For some additional information, I search on this forum for 'sync' and maybe filter the_wine_snob (me), or Jim Simon and read. Jim is the user who found the exact % that was disabled, as well as sound equipment made of marriages.

    Good luck

    Hunt

    PS - just ignore the elders moaning in our drool cups.

  • HP Pavilion HauppaugeWinTV HVR 1290 and Windows 7 - Audio stuttering problem

    Hi all

    I have the WinTV HVR 1290 card installed in a new building.  Window7 Media Center does a great job, support the DVR functions.

    I searched for the latest drivers that HP has on Windows7/64 Bit support.  The current problem is that the recovery of a sleep almost always ends with an Audio stuttering problem.  A reboot clears the stuttering.

    HP probably has some drivers of Windows7 pre-release for sold third party hardware integrated into the Media Center PC.

    Any help would be appreciated.

    Thank you

    Roy

    Open Device Manager and look under sound, video and game controllers to see what sound card you have.

    If you have X-Fi Xtreme Audio choose your template from here.

    Scroll down.

    http://support.creative.com/kb/showarticle.aspx?SID=61105

    If you have Realtek use this driver.

    check accept and next. install the updated Vista driver.

    http://www.Realtek.com.tw/downloads/downloadsCheck.aspx?langid=1 & PNid = 14 & PFid = 24 & Level = 4 & Conn = 3 & DownTypeID = 3 & getdown = false

  • Sony XBR-55X850D audio sync problem with Xbox One S

    Recently bought a new Sony X850D 55 '' TV, it's my 3rd Sony TV the past 10 years, and the first I had a problem with.

    I use the TV mostly for games on my Xbox One S, but have found that there is some dramatic audio synchronization problems. The sound coming out behind what is displayed on the screen (IE. Close door, sound audible is later). Xbox is connected to the TV via HDMI to input 1. I also have a bar of his (CT380) connected via HDMI output HDMI-4 ARC.

    I tried with and without the Soundbar without result. 3 different cords HDMI do nothing. Using my old Xbox One compared to the new One S has no difference. Question was not present on my old Sony TV. Tried with ClearAudio on and out, no change. I can't find all the parameters of sound synchronization in both of the TV, bar, or Xbox.

    Running Version 5.1.1

    Thank you

    Jerome,

    I could solve my problem using HDMI from the Xbox to the sound bar HDMI then another sound to the TV bar.

    Thanks for the good help!

  • Satellite L300 17L - audio driver problems

    Audio driver problems, I use Windows XP SP2, I installed the MS patches, but still there is no sound.

    And in the control panel in the sound section says that there is no audio driver installed.

    I need help please!

    Hello!

    It s a known issue and when you search a bit in the forum you will find a large number of publications on this subject.

    Remove the sound card from the Device Manager and the high definition Audio Controller from Device Manager.
    And then update Windows with KB835221 & KB888111 patch, reboot several times, and then you can install the driver from Realtek but download and install Realtek driver directly.

    Good bye

  • Audio Glitch problem when the playback/record on Satellite A100

    Hello world

    I have an audio glitch issue with my Toshiba laptop.

    When you play any audio file off the coast of the HD I mean glitches.

    I play audio with the media player through the integrated sound card and...
    A Firewire Interface Audio FF400 RME. (which works fine on other computers).
    A USB Alesis Photon x 25 USB 1.1 Audio Interface. (which works fine on other computers).

    but all still produce this annoying glitch.

    Other forums (see below) seem to think it's the fan.

    But what anything what is the solution to solve this?

    Someone on one of the other forums (see below)

    Said that they could not fix it and sold their laptop, I hope I don't have to do that too.

    A reply as soon as possible to support Toshiba or anyone with ideas please give your contribution.

    concerning

    A.

    Satellite A100-998
    Main features
    -Numtxpackets® Centrinoa® Duo Mobile technology Numtxpackets® Corea? ¢ 2 duo Processor T5500
    -Windows® genuine XP Media Center Edition
    -Hard drive 200 GB
    -2 048 (1, 024 + 1, 024) MB of RAM DDR2 (533 MHz)
    -15.4 "screen Toshiba Trubritea® WXGA TFT display
    -Drive DVD Super Multi (Double Layer)

    Hello

    I had the same problem with my Satellite Pro A100 - basically whenever the fan kicks inside or outside, there was a glitch in the audio that pretty much unusable laptop for music.

    At the end of the day, I followed the advice of Nelucard and changed to MPS Multiprocessor PC ACPI processor/computer on Device Manager driver. I then had to reinstall most of my drivers, but once this is done, the fan has been all the time, so there are no glitches more - at least not once the laptop has heated up to... at the beginning, the fan still comes in and out, but after 3-4 minutes, that's all the time. I can live with that.

    It's far from ideal, but in my case it worked and I can now use Reaper, audio streaming and use a load of plug-ins with no problems. I hope Toshiba will come back with a better solution via a BIOS update in the future, but I think that this problem has been known for 7-8 months and nothing has been done so far...

    In any case, good luck and I hope this is of some use.

    See you soon.

  • Record Audio USB problem

    During the recording of music from a tape usb drive, I have a land low humming noise in the background. This occurs by using different and all bands using Quick Time Player or Audacity in OS X El Capitan.

    You can pick up the noise of the rollers or the Ribbon can be a headache of reading (distorted rolls)

    If it's a new tape player I return it and try a new brand of one or the other. You can see the web page developers to see if they or other users are aware.

    If the QT AND daring is both pick up the common denominator is the cassette player.

  • Unable to adapt "record level" for the sound recorder. Audio system works very well. Cannot find a software which allows the change to the record level of mic.

    I want to increase the logging level for my sound recorder and cannot find anything in the Windows 7 software that will allow me to do. I know that it's there somewhere because I put it at 50% during a recent troubleshooting session when he was at zero. Now, I find that the screen to increase it even more.

    Hello

    Welcome to Microsoft Windows 7 answers Forum!

    You can try the steps below and check if the problem is resolved.

    To adjust the record volume, follow these steps before you register:

    1. click on Start

    The collapse of this top this i, and then click Control Panel.

    2. click on hardware and sound.

    3. under his, click manage audio devices.

    4. click on the recording tab.

    5. click on the microphone device and then click Properties.

    6. click on the tab levels move the slider to increase or decrease the volume.

    If you find difficulties in following the above steps then you must follow the link below.

    The volume of the audio recorded by sound recorder in Windows Vista or in Windows 7 is lower than that of Windows XP.

    http://support.Microsoft.com/kb/973446

    Thank you, and in what concerns:

    Suresh Kumar-Microsoft Support.

    Visit our http://social.answers.microsoft.com/Forums/en-US/answersfeedback/threads/ Microsoft answers feedback Forum and let us know what you think.

  • Satellite C855-22U - quality audio output problem

    Hello

    I have a Toshiba Satellite C855-22U (OS Windows 8) Audio Output is really bad, not only music, but also record something (through the software like Audacity, for example and listening to the result on the other PC)

    How can I solve this problem?
    What settings I change?

    Thank you very much

    >... Audio output is really bad
    Is this notable with only internal speakers? Have you tested with headphones or external speakers?

  • WVC210 records sound/audio

    Have my WVC210 wireless camera all set up. I can see the video and hear the audio, but when I read my records there is no sound! It is imperative that I get audio when I playback!

    I have the latest software and firmware, and spin it on Vista. Help!

    I have been back with the help of Cisco since a few days, and we finally found the solution! In the main Console, you click on the calendar to define. From there on, you double click on the camera (in the box of planning). THEN you get the box that has the command for "audio recording". Enough hidden... I hope that Cisco will check this by default OR make it easier to find!

    Problem solved! Thanks for your help!

Maybe you are looking for