floating point suddenly not working

Khairul Nizam <[email protected]>
Newsgroups gmane.comp.hardware.motorola.microcontrollers
Message-ID <[email protected]>
hi anyone
   
  i have problem with my program.my floating point culculation was not working since i migrate from CW6.6 to CW8.1.even a simple program like below.iam working with cme555 board.
   
  can anyone help, how was this thing possibly heappens.is there any setting i have to change in the current CW8.1 that iam using?
   
  #include <stdio.h>
  asm void disIEEE(void)
{
  mfmsr r3;
  ori r3,r3,0x2002;      //enable fp
  mtmsr r3;
    mtfsb1 29;     //disable IEEE FP
}
   
   
  void main()
{
 
    
 int i;
 double a;
 double b;
 double c;
   
  disIEEE();
  
 i=0;
 a=0.0;
 b=2.5;
 c=2;
   a=b/c;
 
 
 
 while (1) { i++; } // loop forever
}
   

			
---------------------------------
 Yahoo! Mail - Helps protect you from nasty viruses.

[Non-text portions of this message have been removed]



-----------------------------------------------------------
To learn more about Freescale Microcontrollers, please visit
http://www.freescale.com/mcu


 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/MPC500/

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.