uwcms / cms-calo-layer1

Xilinx Microblaze Projects for RCT Upgrade
2 stars 8 forks source link

caen::write() does not do what we think #12

Closed ekfriis closed 11 years ago

ekfriis commented 11 years ago

It is only used for writing a single word. We need to implement something which calls the block write [1], and update all calls to read/write.

Also, OrscEmulator [2] does not emulate the behavior or read/write correctly and should be changed (which will break the tests).

        CAENVME_BLTWriteCycle
        -----------------------------------------------------------------------------
        Parameters:
                [in]  Handle    : The handle that identifies the device.
                [in]  Address   : The VME bus address.
                [in]  Buffer    : The data to be written to the VME bus.
                [in]  Size      : The size of the transfer in bytes.
                [in]  AM        : The address modifier (see CVAddressModifier enum).
                [in]  DW        : The data width.(see CVDataWidth enum).
                [out] count     : The number of bytes transferred.
        -----------------------------------------------------------------------------
        Returns:
                An error code about the execution of the function.
        -----------------------------------------------------------------------------
        Description:
                The function performs a VME block transfer write cycle.

[1] http://jazz.physik.unibas.ch/~tikorost/work/TAPSelectronics/Software/vmelib/CAENVMElib.h [2] https://github.com/uwcms/cms-calo-layer1/blob/master/VMEStream/src/vmestream/OrscEmulator.cc#L67

dabelknap commented 11 years ago

See PR #14

ekfriis commented 11 years ago

Awesome. I have a PR with an improved test of vme2fd coming, I will merge the two.

On Thu, Oct 3, 2013 at 2:44 PM, Austin Belknap notifications@github.comwrote:

See PR #14 https://github.com/uwcms/cms-calo-layer1/pull/14

— Reply to this email directly or view it on GitHubhttps://github.com/uwcms/cms-calo-layer1/issues/12#issuecomment-25617171 .