AN2263 Freescale Semiconductor / Motorola, AN2263 Datasheet - Page 17

no-image

AN2263

Manufacturer Part Number
AN2263
Description
PC Master Software: Creation of Advanced Control Pages
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
Back to the Example
MOTOROLA
PC Master Software: Creation of Advanced Control Pages
Use the function GetCurrentRecorderData to load the PC master software
recorder series. The function returns the matrix (2-dimensional array) of the
recorder data in the first parameter variable (data), the array of series names
in the second (serNames), time base (if defined) in the third (tbase) and the
error message is the last parameter variable (msg).
To get the bounds of the recorder data matrix use the UBound function.
To put a data into the Excel sheet, first create a SheetData variable. Then use
the ClearContents function of the sheet range object to clear the specified
range contents. Assign the cells Value property to place the data value into the
specified cell.
Use these examples in our workbook now. Open the Visual Basic Editor in
Microsoft Excel. Open the code editor of the ThisWorkbook object. Create a
new module Module1 and open it as well. Create a global declaration of the PC
master software ActiveX object variable pcm and ScheduleTime in Module1.
Public pcm As McbPcm
Public ScheduleTime As Variant
Freescale Semiconductor, Inc.
succ = pcm.GetCurrentRecorderData(data,serNames,tbase,msg)
If succ Then
Else
End If
Dim sht As SheetData
Set sht = Worksheets("Data")
sht.Range("A1:B8").ClearContents
sht.Cells(1,2).Value = someValue
For More Information On This Product,
serCnt = UBound(data, 1)
valCnt = UBound(data, 2)
MsgBox (msg)
Go to: www.freescale.com
Example: Step-by-Step Guide
AN2263/D
17

Related parts for AN2263