10.07.2015 Views

CF2 API Reference (PDF) - Persistor Instruments Inc

CF2 API Reference (PDF) - Persistor Instruments Inc

CF2 API Reference (PDF) - Persistor Instruments Inc

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>CF2</strong> <strong>API</strong> <strong>Reference</strong>Prototype:Inputs:Notes:void TPUHostSequenceSelect(ushort tpuch, short hsq);tpuch is the TPU channel number (1 to 15).hsq is the host sequence value appropriate for the particular TPU function.See TPURefManual_tpurmad.pdf and the specific TPU function document for more informationthe function dependent context and values for the host sequence bits.TPUHostServiceCheckComplete – Check the host service status and optionally waitDescription:Prototype:Inputs:Returns:This function returns true if the TPU has completed the last host service request. It will wait forthe TPU to complete if argument waitstatus is true, otherwise it will just return with the status.bool TPUHostServiceCheckComplete(ushort tpuch, bool waitstatus);tpuch is the TPU channel number (1 to 15).waitstatus should be set to true to wait or false to return immediately.true if the TPU completed the service request, false if not.TPUGetTCR1Clock – Get the TCR1 clock rate in HzDescription:Prototype:Returns:Notes:This function returns the current frequency of the TCR1 clock which varies with the system clockfrequency and the TCR1 divider.rettype TPUGetTCR1Clock(void);The TCR1 clock frequency in Hz.The TCR1 divider is contained in a write-once register that must be written by PicoDOS to startthe TPU and TLC. The default is divide-by-one which yields 4MHz for the default 16MHz systemclock because of the built in divide-by-four from the TPU hardware. You can change the defaultusing the SYS.TCR1P persistent environment variable using the SET command from PicoDOS orVEE <strong>API</strong> calls with the following alternates:"0"= divide-by-1, "1"= divide-by-2, "2"= divide-by-4, "3"= divide-by-8See also: TPUDisableInterrupt – Disable interrupts for the specified TPU channelDescription:Prototype:This inline macro disables interrupt for the specified channelvoid TPUDisableInterrupt(ushort tch);Inputs: tch is the TPU channel number (1 to 15).TPUEnableInterrupt – Enable interrupts for the specified TPU channelDescription:Prototype:This inline macro disables interrupt for the specified channelvoid TPUEnableInterrupt(ushort tch);Inputs: tch is the TPU channel number (1 to 15).PERSISTOR<strong>Instruments</strong> <strong>Inc</strong>.67 of 84<strong>CF2</strong> <strong>API</strong> <strong>Reference</strong>7/19/2005

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!