DSPRelated.com
Forums

AM binary encoding attempt

Started by meower December 18, 2011
I don't have any experience with DSP and my math is very out of shape, so
I'm trying to squeeze a lot of info in a very short period.
I've been reading on modulation (Amplitude and Frequency) and I'm trying to
use an AM to encode binary data, without a carrier wave (or is it a carrier
wave of 0?).
I think I'm getting the picture wrong, what I'm trying to do is play sound
(discrete samples) at 22.0khz with a sample rate of 44.1khz, when amplitude
1000 is the on bit (1) and 0 is the off bit (0).
I seem to get a very inconsistent wave when I'm trying to record it
(Windows' Stereo Mix so there aren't any interferences), tried to use
someone's advice to use more then 1 sample for each bit, still the same
wave comes out.
This is a screenshot from GoldWave that shows my wave's shape
http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed by
16 zero's then another four ones and again 16 zero's and four ones.

Any idea on what I'm doing wrong? did I get it completely off?
I tried to ask on stackoverflow.com but seem like my problem is not with my
code but my theory, here's the link to the discussion
http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence


On 12/18/2011 2:32 PM, meower wrote:
> I don't have any experience with DSP and my math is very out of shape, so > I'm trying to squeeze a lot of info in a very short period. > I've been reading on modulation (Amplitude and Frequency) and I'm trying to > use an AM to encode binary data, without a carrier wave (or is it a carrier > wave of 0?). > I think I'm getting the picture wrong, what I'm trying to do is play sound > (discrete samples) at 22.0khz with a sample rate of 44.1khz, when amplitude > 1000 is the on bit (1) and 0 is the off bit (0). > I seem to get a very inconsistent wave when I'm trying to record it > (Windows' Stereo Mix so there aren't any interferences), tried to use > someone's advice to use more then 1 sample for each bit, still the same > wave comes out. > This is a screenshot from GoldWave that shows my wave's shape > http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed by > 16 zero's then another four ones and again 16 zero's and four ones. > > Any idea on what I'm doing wrong? did I get it completely off? > I tried to ask on stackoverflow.com but seem like my problem is not with my > code but my theory, here's the link to the discussion > http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
OOF! I have lots of questions. do you mean 22.05 KHz? You wrote 22.0 If it's samples at 22KHz or thereabouts, what do you gain by playing at 44.1? What do you mean by "amplitude 1000 is the on bit"? I see many amplitudes in your plots. Many samples per bit? usually there as many bits per sample as the ADC supplies. Do we have a language problem? Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������
>On 12/18/2011 2:32 PM, meower wrote: >> I don't have any experience with DSP and my math is very out of shape,
so
>> I'm trying to squeeze a lot of info in a very short period. >> I've been reading on modulation (Amplitude and Frequency) and I'm trying
to
>> use an AM to encode binary data, without a carrier wave (or is it a
carrier
>> wave of 0?). >> I think I'm getting the picture wrong, what I'm trying to do is play
sound
>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when
amplitude
>> 1000 is the on bit (1) and 0 is the off bit (0). >> I seem to get a very inconsistent wave when I'm trying to record it >> (Windows' Stereo Mix so there aren't any interferences), tried to use >> someone's advice to use more then 1 sample for each bit, still the same >> wave comes out. >> This is a screenshot from GoldWave that shows my wave's shape >> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed
by
>> 16 zero's then another four ones and again 16 zero's and four ones. >> >> Any idea on what I'm doing wrong? did I get it completely off? >> I tried to ask on stackoverflow.com but seem like my problem is not with
my
>> code but my theory, here's the link to the discussion >>
http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
> >OOF! I have lots of questions. > >do you mean 22.05 KHz? You wrote 22.0 > >If it's samples at 22KHz or thereabouts, what do you gain by playing at >44.1? > >What do you mean by "amplitude 1000 is the on bit"? I see many >amplitudes in your plots. > >Many samples per bit? usually there as many bits per sample as the ADC >supplies. > >Do we have a language problem? > >Jerry >-- >Engineering is the art of making what you want from things you can get.
Hey, thank you for replying. It's not a language issue, rather then a lack of general knowledge in DSP. It's just 22kHz I just wrote .0 to make sure no one thinks I left the . out for no reason heh, guess it turned out the other way around ;) I'm using Windows' built in PCM format, I was told that the sample rate should be at least twice as much as the frequency I'm playing, can't remember why (its 6am and no sleep :p). By amplitude 1000 I mean that when the current sample's amplitude is 1000 I interpret it as binary 1, that way I could encode data over the wave (0 for 0 obviously). I'm using 32bits per samples, since the original code had that, I tried to change it to fewer than 8, but no sound played. I didn't really get how the amount of bits per samples change the way my wave looks. Also, what is ADC? Sorry if my questions are trivial, I'm new to this (started two weeks ago ;) Could it be that my theory is correct but I'm not using the PCM format properly in my code? -Regards
On 12/18/2011 10:54 PM, meower wrote:
>> On 12/18/2011 2:32 PM, meower wrote: >>> I don't have any experience with DSP and my math is very out of shape, > so >>> I'm trying to squeeze a lot of info in a very short period. >>> I've been reading on modulation (Amplitude and Frequency) and I'm trying > to >>> use an AM to encode binary data, without a carrier wave (or is it a > carrier >>> wave of 0?). >>> I think I'm getting the picture wrong, what I'm trying to do is play > sound >>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when > amplitude >>> 1000 is the on bit (1) and 0 is the off bit (0). >>> I seem to get a very inconsistent wave when I'm trying to record it >>> (Windows' Stereo Mix so there aren't any interferences), tried to use >>> someone's advice to use more then 1 sample for each bit, still the same >>> wave comes out. >>> This is a screenshot from GoldWave that shows my wave's shape >>> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed > by >>> 16 zero's then another four ones and again 16 zero's and four ones. >>> >>> Any idea on what I'm doing wrong? did I get it completely off? >>> I tried to ask on stackoverflow.com but seem like my problem is not with > my >>> code but my theory, here's the link to the discussion >>> > http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence >> >> OOF! I have lots of questions. >> >> do you mean 22.05 KHz? You wrote 22.0 >> >> If it's samples at 22KHz or thereabouts, what do you gain by playing at >> 44.1? >> >> What do you mean by "amplitude 1000 is the on bit"? I see many >> amplitudes in your plots. >> >> Many samples per bit? usually there as many bits per sample as the ADC >> supplies. >> >> Do we have a language problem? >> >> Jerry >> -- >> Engineering is the art of making what you want from things you can get. > > Hey, thank you for replying. It's not a language issue, rather then a lack > of general knowledge in DSP. > It's just 22kHz I just wrote .0 to make sure no one thinks I left the . out > for no reason heh, guess it turned out the other way around ;) > > I'm using Windows' built in PCM format, I was told that the sample rate > should be at least twice as much as the frequency I'm playing, can't > remember why (its 6am and no sleep :p). > > By amplitude 1000 I mean that when the current sample's amplitude is 1000 I > interpret it as binary 1, that way I could encode data over the wave (0 for > 0 obviously). > > I'm using 32bits per samples, since the original code had that, I tried to > change it to fewer than 8, but no sound played. I didn't really get how the > amount of bits per samples change the way my wave looks.
The amplitudes of digital signals are represented by numbers. The number of bits in the number determines how many different values it can represent. The fewer the bits, the "blockier" the signal will look.
> Also, what is ADC?
Analog-to0digital converter. You aren't using one. My error.
> Sorry if my questions are trivial, I'm new to this (started two weeks ago > ;)
Trivial questions are welcome, but we could suggest some reading material. What have you read already? See if www.dspguide.com/ helps.
> Could it be that my theory is correct but I'm not using the PCM format > properly in my code?
Probably both are a bit off the mark. Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������
>On 12/18/2011 10:54 PM, meower wrote: >>> On 12/18/2011 2:32 PM, meower wrote: >>>> I don't have any experience with DSP and my math is very out of
shape,
>> so >>>> I'm trying to squeeze a lot of info in a very short period. >>>> I've been reading on modulation (Amplitude and Frequency) and I'm
trying
>> to >>>> use an AM to encode binary data, without a carrier wave (or is it a >> carrier >>>> wave of 0?). >>>> I think I'm getting the picture wrong, what I'm trying to do is play >> sound >>>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when >> amplitude >>>> 1000 is the on bit (1) and 0 is the off bit (0). >>>> I seem to get a very inconsistent wave when I'm trying to record it >>>> (Windows' Stereo Mix so there aren't any interferences), tried to use >>>> someone's advice to use more then 1 sample for each bit, still the
same
>>>> wave comes out. >>>> This is a screenshot from GoldWave that shows my wave's shape >>>> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111
followed
>> by >>>> 16 zero's then another four ones and again 16 zero's and four ones. >>>> >>>> Any idea on what I'm doing wrong? did I get it completely off? >>>> I tried to ask on stackoverflow.com but seem like my problem is not
with
>> my >>>> code but my theory, here's the link to the discussion >>>> >>
http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
>>> >>> OOF! I have lots of questions. >>> >>> do you mean 22.05 KHz? You wrote 22.0 >>> >>> If it's samples at 22KHz or thereabouts, what do you gain by playing
at
>>> 44.1? >>> >>> What do you mean by "amplitude 1000 is the on bit"? I see many >>> amplitudes in your plots. >>> >>> Many samples per bit? usually there as many bits per sample as the ADC >>> supplies. >>> >>> Do we have a language problem? >>> >>> Jerry >>> -- >>> Engineering is the art of making what you want from things you can
get.
>> >> Hey, thank you for replying. It's not a language issue, rather then a
lack
>> of general knowledge in DSP. >> It's just 22kHz I just wrote .0 to make sure no one thinks I left the .
out
>> for no reason heh, guess it turned out the other way around ;) >> >> I'm using Windows' built in PCM format, I was told that the sample rate >> should be at least twice as much as the frequency I'm playing, can't >> remember why (its 6am and no sleep :p). >> >> By amplitude 1000 I mean that when the current sample's amplitude is
1000 I
>> interpret it as binary 1, that way I could encode data over the wave (0
for
>> 0 obviously). >> >> I'm using 32bits per samples, since the original code had that, I tried
to
>> change it to fewer than 8, but no sound played. I didn't really get how
the
>> amount of bits per samples change the way my wave looks. > >The amplitudes of digital signals are represented by numbers. The number >of bits in the number determines how many different values it can >represent. The fewer the bits, the "blockier" the signal will look. > >> Also, what is ADC? > >Analog-to0digital converter. You aren't using one. My error. > >> Sorry if my questions are trivial, I'm new to this (started two weeks
ago
>> ;) > >Trivial questions are welcome, but we could suggest some reading >material. What have you read already? See if www.dspguide.com/ helps. > >> Could it be that my theory is correct but I'm not using the PCM format >> properly in my code? > >Probably both are a bit off the mark. > >Jerry >-- >Engineering is the art of making what you want from things you can get. >����������������������������������������������������������������������� >
Hey, I've read parts from the dspguide book (mostly about FFT) to figure out how the waves work. Can't read the whole book since I need to get this done for work as soon as possible :p Is there any change you could refer me to specific chapters in it that would help? I think I got the theory right, I'm trying to create a simple wave (least bits possible) to get 1's and 0's but I seem to fail to understand how to implement it with PCM output.
On 12/19/2011 6:57 AM, meower wrote:

   ...

> I've read parts from the dspguide book (mostly about FFT) to figure out how > the waves work. Can't read the whole book since I need to get this done for > work as soon as possible :p > Is there any change you could refer me to specific chapters in it that > would help? > > I think I got the theory right, I'm trying to create a simple wave (least > bits possible) to get 1's and 0's but I seem to fail to understand how to > implement it with PCM output.
Read the chapters on sampling. Understand what a sample is -- at present, you don't. Understand how to count in binary, and how two's complement represents negative numbers. (The samples are two's-complement numbers that describe the waveform's amplitude at the instant of sampling.) The sample rate being twice the highest frequency you wish to reproduce is a theoretical minimum not achievable in practice. If you're good at this, 2.5 will suffice. Do you intend to listen to the result? For most purposes, a reconstruction filter is then needed. If you need to have something working before you could finish the relevant parts of the book, both you and your boss have unrealistic expectations. Jerry -- "But Mommy, I don't want to go to Europe." "Shut up and keep swimming."
meower wrote:
> I don't have any experience with DSP and my math is very out of shape, so > I'm trying to squeeze a lot of info in a very short period. > I've been reading on modulation (Amplitude and Frequency) and I'm trying to > use an AM to encode binary data, without a carrier wave (or is it a carrier > wave of 0?). > I think I'm getting the picture wrong, what I'm trying to do is play sound > (discrete samples) at 22.0khz with a sample rate of 44.1khz, when amplitude > 1000 is the on bit (1) and 0 is the off bit (0). > I seem to get a very inconsistent wave when I'm trying to record it > (Windows' Stereo Mix so there aren't any interferences), tried to use > someone's advice to use more then 1 sample for each bit, still the same > wave comes out. > This is a screenshot from GoldWave that shows my wave's shape > http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed by > 16 zero's then another four ones and again 16 zero's and four ones. > > Any idea on what I'm doing wrong? did I get it completely off? > I tried to ask on stackoverflow.com but seem like my problem is not with my > code but my theory, here's the link to the discussion > http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
Hi, Some excellent advice was given on Stackoverflow.com: "Your bit time needs to be much longer than the period of your carrier (sine) frequency, and the sample rate also needs to be more than 2X the carrier frequency. So your sample generation loop may need to be much much longer." ---- Indeed, in your code, only _one_ sample is generated for each input bit: for I := 1 to Length(BinaryString) do begin { Discrete Time } Vol := StrToInt(BinaryString[I]) * 1000; Samples[I] := vol * sin(omega * dt * I); end; That doesn't make sense, and there is no way to demodulate the audio at a later stage. You need to decide on how many FULL cycles of the carrier wave will represent one bit length. Cheers - Dirk
>meower wrote: >> I don't have any experience with DSP and my math is very out of shape,
so
>> I'm trying to squeeze a lot of info in a very short period. >> I've been reading on modulation (Amplitude and Frequency) and I'm trying
to
>> use an AM to encode binary data, without a carrier wave (or is it a
carrier
>> wave of 0?). >> I think I'm getting the picture wrong, what I'm trying to do is play
sound
>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when
amplitude
>> 1000 is the on bit (1) and 0 is the off bit (0). >> I seem to get a very inconsistent wave when I'm trying to record it >> (Windows' Stereo Mix so there aren't any interferences), tried to use >> someone's advice to use more then 1 sample for each bit, still the same >> wave comes out. >> This is a screenshot from GoldWave that shows my wave's shape >> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed
by
>> 16 zero's then another four ones and again 16 zero's and four ones. >> >> Any idea on what I'm doing wrong? did I get it completely off? >> I tried to ask on stackoverflow.com but seem like my problem is not with
my
>> code but my theory, here's the link to the discussion >>
http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
> > >Hi, > >Some excellent advice was given on Stackoverflow.com: > >"Your bit time needs to be much longer than the period of your carrier >(sine) frequency, and the sample rate also needs to be more than 2X the >carrier frequency. So your sample generation loop may need to be much >much longer." >---- > >Indeed, in your code, only _one_ sample is generated for each input >bit: > >for I := 1 to Length(BinaryString) do > begin > { Discrete Time } > Vol := StrToInt(BinaryString[I]) * 1000; > Samples[I] := vol * sin(omega * dt * I); > end; > >That doesn't make sense, and there is no way to demodulate the audio at >a later stage. You need to decide on how many FULL cycles of the >carrier wave will represent one bit length. > >Cheers - Dirk > > >
Hey, thanks for replying. I tried more than one samples for a bit (i think i tried 6 at most) could this not be enough? according to the advice given there it should be, but I expected my wave to be consistent but it still was not.
meower wrote:
>> meower wrote: >>> I don't have any experience with DSP and my math is very out of shape, so >>> I'm trying to squeeze a lot of info in a very short period. >>> I've been reading on modulation (Amplitude and Frequency) and I'm trying to >>> use an AM to encode binary data, without a carrier wave (or is it a carrier >>> wave of 0?). >>> I think I'm getting the picture wrong, what I'm trying to do is play sound >>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when amplitude >>> 1000 is the on bit (1) and 0 is the off bit (0). >>> I seem to get a very inconsistent wave when I'm trying to record it >>> (Windows' Stereo Mix so there aren't any interferences), tried to use >>> someone's advice to use more then 1 sample for each bit, still the same >>> wave comes out. >>> This is a screenshot from GoldWave that shows my wave's shape >>> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111 followed by >>> 16 zero's then another four ones and again 16 zero's and four ones. >>> >>> Any idea on what I'm doing wrong? did I get it completely off? >>> I tried to ask on stackoverflow.com but seem like my problem is not with my >>> code but my theory, here's the link to the discussion >>> http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence >> >> >> Hi, >> >> Some excellent advice was given on Stackoverflow.com: >> >> "Your bit time needs to be much longer than the period of your carrier >> (sine) frequency, and the sample rate also needs to be more than 2X the >> carrier frequency. So your sample generation loop may need to be much >> much longer." >> ---- >> >> Indeed, in your code, only _one_ sample is generated for each input >> bit: >> >> for I := 1 to Length(BinaryString) do >> begin >> { Discrete Time } >> Vol := StrToInt(BinaryString[I]) * 1000; >> Samples[I] := vol * sin(omega * dt * I); >> end; >> >> That doesn't make sense, and there is no way to demodulate the audio at >> a later stage. You need to decide on how many FULL cycles of the >> carrier wave will represent one bit length. >> >> Cheers - Dirk >> >> >> > > Hey, thanks for replying. > > I tried more than one samples for a bit (i think i tried 6 at most) could > this not be enough? according to the advice given there it should be, but I > expected my wave to be consistent but it still was not.
Hi, There must be errors in your code then. Below is one way of doing it. It's just a simple self-contained static procedure but it works. To visualize the output you will need to put a Line Chart on the form with X-length 3000, and Y scale -1..1. Cheers - Dirk //----------------------------- procedure TForm1.GenSamples; const TheBits = '1010110100101110001100111010001111'; Fs = 22050; // sample freq. FOsc = 2000.00; // oscillator freq. SPB: integer = 5 * Round(Fs/FOsc); // samples per bit OscInc : double = (FOsc * 2 * Pi)/Fs; // increment/sample var Osc : double; // primary oscillator value O_Sin: array[1..3000] of double; // sample output Amp : double; // amplitude i, BitPos: integer; begin Osc := 0; BitPos := 1; Amp := StrToInt(TheBits[BitPos]); // set amplitude for first bit for i := 1 to Length(O_Sin) do begin Osc := Osc + OscInc; if Osc > 2*pi then Osc := - 2* pi; O_Sin[i] := Amp * Sin(Osc); if i MOD SPB = 0 then // next bit... begin inc(BitPos); if BitPos <= Length(TheBits) then Amp := StrToInt(TheBits[BitPos]) else Amp := 0.25 // oops,no more bits, freeze at some value... end; end; Chart.Series[0].Clear; // show output on chart for i := 1 to Length(O_Sin) do Chart.Series[0].AddXY(i,O_Sin[i]); end;
>meower wrote: >>> meower wrote: >>>> I don't have any experience with DSP and my math is very out of shape,
so
>>>> I'm trying to squeeze a lot of info in a very short period. >>>> I've been reading on modulation (Amplitude and Frequency) and I'm
trying to
>>>> use an AM to encode binary data, without a carrier wave (or is it a
carrier
>>>> wave of 0?). >>>> I think I'm getting the picture wrong, what I'm trying to do is play
sound
>>>> (discrete samples) at 22.0khz with a sample rate of 44.1khz, when
amplitude
>>>> 1000 is the on bit (1) and 0 is the off bit (0). >>>> I seem to get a very inconsistent wave when I'm trying to record it >>>> (Windows' Stereo Mix so there aren't any interferences), tried to use >>>> someone's advice to use more then 1 sample for each bit, still the
same
>>>> wave comes out. >>>> This is a screenshot from GoldWave that shows my wave's shape >>>> http://i41.tinypic.com/vn303n.png this is supposed to be a 1111
followed by
>>>> 16 zero's then another four ones and again 16 zero's and four ones. >>>> >>>> Any idea on what I'm doing wrong? did I get it completely off? >>>> I tried to ask on stackoverflow.com but seem like my problem is not
with my
>>>> code but my theory, here's the link to the discussion >>>>
http://stackoverflow.com/questions/8490090/delphi-and-discrete-signals-getting-a-fixed-volume-signal-with-fixed-silence
>>> >>> >>> Hi, >>> >>> Some excellent advice was given on Stackoverflow.com: >>> >>> "Your bit time needs to be much longer than the period of your carrier
>>> (sine) frequency, and the sample rate also needs to be more than 2X the
>>> carrier frequency. So your sample generation loop may need to be much >>> much longer." >>> ---- >>> >>> Indeed, in your code, only _one_ sample is generated for each input >>> bit: >>> >>> for I := 1 to Length(BinaryString) do >>> begin >>> { Discrete Time } >>> Vol := StrToInt(BinaryString[I]) * 1000; >>> Samples[I] := vol * sin(omega * dt * I); >>> end; >>> >>> That doesn't make sense, and there is no way to demodulate the audio at
>>> a later stage. You need to decide on how many FULL cycles of the >>> carrier wave will represent one bit length. >>> >>> Cheers - Dirk >>> >>> >>> >> >> Hey, thanks for replying. >> >> I tried more than one samples for a bit (i think i tried 6 at most)
could
>> this not be enough? according to the advice given there it should be,
but I
>> expected my wave to be consistent but it still was not. > >Hi, > >There must be errors in your code then. >Below is one way of doing it. It's just a simple self-contained static >procedure but it works. To visualize the output you will need to put a >Line Chart on the form with X-length 3000, and Y scale -1..1. > > >Cheers - Dirk > >//----------------------------- >procedure TForm1.GenSamples; >const > TheBits = '1010110100101110001100111010001111'; > Fs = 22050; // sample freq. > FOsc = 2000.00; // oscillator freq. > SPB: integer = 5 * Round(Fs/FOsc); // samples per bit > OscInc : double = (FOsc * 2 * Pi)/Fs; // increment/sample > >var > Osc : double; // primary oscillator value > O_Sin: array[1..3000] of double; // sample output > Amp : double; // amplitude > i, BitPos: integer; > >begin > Osc := 0; > BitPos := 1; > Amp := StrToInt(TheBits[BitPos]); // set amplitude for first bit > > for i := 1 to Length(O_Sin) do > begin > Osc := Osc + OscInc; > if Osc > 2*pi then > Osc := - 2* pi; > O_Sin[i] := Amp * Sin(Osc); > > if i MOD SPB = 0 then // next bit... > begin > inc(BitPos); > if BitPos <= Length(TheBits) then > Amp := StrToInt(TheBits[BitPos]) > else > Amp := 0.25 // oops,no more bits, freeze at some value... > end; > end; > > Chart.Series[0].Clear; // show output on chart > for i := 1 to Length(O_Sin) do > Chart.Series[0].AddXY(i,O_Sin[i]); > >end; > > >
This is great, thank you. I will give this a try hoping I could see what was wrong in my code so I would understand this. Again, thank you.