avr-gcc-list
[
Top
][
All Lists
]
Advanced
[
Date Prev
][
Date Next
][
Thread Prev
][
Thread Next
][
Date Index
][
Thread Index
]
Re: [avr-gcc-list] Operation problem
From
:
Gerard Marull Paretas
Subject
:
Re: [avr-gcc-list] Operation problem
Date
:
Sat, 11 Aug 2007 23:50:09 +0200
Hi Dave.
You've just solved my problem :). Casting the two members of the multiplication to uint32_t solves the problem. I had tried to cast the whole multiplication, but not each member. Another thing learned.
So the code now looks like this:
currentsong.length = ((uint32_t)currentsong.frames * (uint32_t)currentsong.samples_per_frame) / currentsong.samples_per_sec;
Thanks! Gerard.
reply via email to
[
Prev in Thread
]
Current Thread
[Next in Thread]
[avr-gcc-list] Operation problem
,
Gerard Marull Paretas
,
2007/08/09
RE: [avr-gcc-list] Operation problem
,
Eric Weddington
,
2007/08/09
Re: [avr-gcc-list] Operation problem
,
Paulo Marques
,
2007/08/10
Re: [avr-gcc-list] Operation problem
,
Gerard Marull Paretas
,
2007/08/10
Re: [avr-gcc-list] Operation problem
,
Gerard Marull Paretas
,
2007/08/10
Re: [avr-gcc-list] Operation problem
,
Dave Hansen
,
2007/08/11
Re: [avr-gcc-list] Operation problem
,
Gerard Marull Paretas
<=
Prev by Date:
Re: [avr-gcc-list] Operation problem
Next by Date:
Re: [avr-gcc-list] Inserting code before context save in an ISR (fornested interrupts)
Previous by thread:
Re: [avr-gcc-list] Operation problem
Next by thread:
[avr-gcc-list] I have met a problem.....
Index(es):
Date
Thread