Shop OBEX P1 Docs P2 Docs Learn Events
uM-FPU v3.1 Fpu Object definition? — Parallax Forums

uM-FPU v3.1 Fpu Object definition?

ramman345ramman345 Posts: 24
edited 2007-08-29 01:55 in General Discussion
Just starting playing with a new micromega uM-FPU v3.1. Using their latest stable release of the FPU IDE (1.3 I think) you can set the target to be a Javelin and it generates Javelin code that you just copy and paste into the Javelin IDE - simple enough. However the generated code uses and "Fpu" object that is never defined. I'm assuming that if I simply copy and paste this into JIDE it won't compile. It seems to be that there should be a library or class file that defines the "Fpu" class and that I should also have to instantiate one and assign pin #'s for the communications. I've search the documentation from micromega with no luck. Any help is greatly appreciated.

Comments

  • ramman345ramman345 Posts: 24
    edited 2007-08-24 02:24
    btw, here's an example of the generated code to add to registers and store to a third.

    //
    Generated Code
    // F1 = F2 + F3
    Fpu.startWrite();
    Fpu.write(Fpu.SELECTA, 1, Fpu.FSET, 2);
    Fpu.write(Fpu.FADD, 3);
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-08-24 02:34
  • ramman345ramman345 Posts: 24
    edited 2007-08-24 02:46
    Right, but that is all V2 stuff. I have a V3.1.
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-08-24 03:13
    Send an email to
    info@micromegacorp.com

    to findout if a v3.1 update is in the make.
    Ask if the v2 FPU object can be used with v3.1
    (for the v2 features anyway)

    Or create your own·using the v3.1 opcodes

    http://www.micromegacorp.com/downloads/software/uMFPU-V3-opcodes.zip

    regards peter
    ·
  • camtcamt Posts: 45
    edited 2007-08-24 14:26
    I've attached a zip file that contains a package for interfacing the Javelin to the uM-FPU V3.1 chip using an SPI connection. The folder v3_spi should be copied to ~\lib\com\micromegacorp\math\. A simple demo routine called Graph.java file is also included.

    I'll create some more examples next week and update the Javelin support page on the Micromega website located at:
    http://www.micromegacorp.com/javelin.html

    Regards,
    Cam

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cam Thompson
    Micromega Corporation
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-08-24 14:48
    Thanks Cam.
    One thing, the text at the start of Int32.java is identical to the text of Float32.java
    (both describing the class: * This class provides support for 32-bit floating point numbers)

    I think the text for Int32.java should be different as Int32.java supports 32bit integers.

    regards peter
  • camtcamt Posts: 45
    edited 2007-08-24 16:35
    Hi Peter,

    Thanks for picking that up (the joys of copy-and-paste to start a new file!) I'll fix the comments when I do additional postings next week.

    Regards,
    Cam

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cam Thompson
    Micromega Corporation
  • camtcamt Posts: 45
    edited 2007-08-29 01:55
    Documentation and new support software for using uM-FPU V3.1 with the Javelin Stamp has been posted to the Micromega website:
    http://www.micromegacorp.com/javelin.html

    Regards,
    Cam

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cam Thompson
    Micromega Corporation
Sign In or Register to comment.