<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>
Hello evereybody;<BR>
&nbsp;<BR>
I am very confused and i hope that someone could help me.<BR>
In fact i'm using an ADC 12bit to sample voice and then i encode the data using Speex.<BR>
The problem is when i try to decode and replay the voice samples i got much noise. I think that the pb is iabout the conversion from 12bit unsigned to 16bit signed format which is required by speex codec.<BR>
&nbsp;<BR>
i have used the following code:<BR>
<EM>signed_vakue16 = (unsigned_value12&lt;&lt;4)^0x8000;</EM><BR>
&nbsp;<BR>
also i have tryed to convert the 12bit into 8bit and then transformat it into 16bit signed format:<BR>
<EM>signed_vakue16 = ((unsigned_value12&gt;&gt;4)&lt;&lt;8)^0x8000;</EM><BR>
&nbsp;<BR>
could anyone please give me more clarifiations, thanks<BR>
&nbsp;<BR>
best regards to all<BR>
Seif<BR><br /><hr />Appelez vos amis de PC à PC -- C'EST GRATUIT <a href='http://get.live.com/messenger/overview' target='_new'>Téléchargez Messenger, c'est gratuit !</a></body>
</html>