manufacturer of I/O-rich SBCs, operator interfaces, handheld instruments, and development tools for embedded control low cost single board computers, embedded controllers, and operator interfaces for scientific instruments & industrial control development tools for embedded control order our low cost I/O-rich embedded control products embedded controller manufacturer profile single board computers & embedded controllers development tools & starter kits for your embedded design operator interfaces with touchscreens and graphical user interface plug-in expansion modules for digital & analog I/O C language & Forth language integrated development tools, IDE single board and embedded computer accessories embedded controller enclosures, bezels, environmental gaskets

The C Programmer’s Guide to the Mosaic Handheld

Table of Contents

PART 1 GETTING STARTED

Introduction. How to Use This Manual

Chapter 1: Getting to Know Your Handheld Instrument

Chapter 2: Powering Your Handheld

PART 2 PROGRAMMING THE MOSAIC HANDHELD

Chapter 3: Your First Program

Chapter 4: The IDE: Writing, Compiling, Downloading and Debugging Programs

Chapter 5: Making Effective Use of Memory

Chapter 6: Real Time Programming

Chapter 7: Failure and Run-Time Error Recovery

Chapter 8: Programming the Graphical User Interface

PART 3 COMMUNICATIONS, MEASUREMENT, AND CONTROL

Chapter 9: Digital and Timer-Controlled I/O

Chapter 10: Data Acquisition

Chapter 11: Serial Communications

Chapter 12: The Battery-Backed Real Time Clock

Chapter 13: Customizing the Handheld's I/O

PART 4: REFERENCE DATA

Appendix A: GUI Function Reference

Appendix B: Handheld Schematics

Glossary

<< Previous | Next >>

A     B     C     DF    G     H     I     K     LM    N     P     R     S    T    UVWXY   

HEAP_FULL

HEAP_FULL

Type

Constant

Return Value

Integer

Description

The name of an error that indicates the heap of the GUI Toolkit is full.  No new objects can be created and existing objects can not be resized.

Usage

graphicStop = New_Object( GRAPHIC );

If(Read_Error() == HEAP_FULL)

{

  printf(“Can’t create new object, heap is full.\n”);

  Clear_Error();

}

GRAPHIC New_Object graphicStop !

Read_Error HEAP_FULL =

if

  cr .” Can’t create new object, heap is full”

  Clear_Error

endif

 

Library

library.c

library.4th

HEIGHT_IN_PIXELS

HEIGHT_IN_PIXELS

Type

Constant

Return Value

Integer

Description

The name of a property that contains the height in pixels of an object.

Usage

longHeight = Get_Property(GUI_DISPLAY, HEIGHT_IN_PIXELS);

GUI_DISPLAY HEIGHT_IN_PIXELS Get_Property height 2!

Library

library.c

library.4th

See Also

WIDTH_IN_PIXELS

HEIGHT_OUT_OF_RANGE

HIGHT_OUT_OF_RANGE

Type

Constant

Return Value

Integer

Description

The name of an error that indicates the height passed to Set_Property when changing the height of a plot, creates a plot taller than the screen.  If the error occurs, Set_Property recovers from the error by setting the height of the plot equal to the height of the screen.  An unchecked error occurs when a plot that is already loaded into a screen is resized beyond the height of the screen.

Usage

Set_Property(plotVoltage, HEIGHT_IN_PIXELS, (ulong) 500);

If(Read_Error() == HEIGHT_OUT_OF_RANGE)

{

  printf(“Height of the plot is greater than the height of screen.\n”);

  Clear_Error();

}

plotVoltage @ HEIGHT_IN_PIXELS 500 u>d Set_Property

Read_Error HEIGHT_OUT_OF_RANGE =

if

  cr .” Height of the plot is greater than the height of the screen.”

  Clear_Error

endif

Library

library.c

library.4th

HOLD_EVENT

HOLD_EVENT

Type

Constant

Return Value

Long

Description

The name of a value of a keypad property KEY_EVENT or PRIOR_KEY_EVENT that indicates a user has pressed a key and continues to hold it down.

Usage

If ( Get_Property ( GUI_KEYPAD0, KEY_EVENT ) == HOLD_EVENT )

{

  printf(“Last keypad event was a hold event.\n”);

}

GUI_KEYPAD0 KEY_EVENT Get_Property HOLD_EVENT d=

if

  cr .” Last keypad event was a hold event.”

endif

Library

library.c

library.4th

See Also

PRESS_EVENT, RELEASE_EVENT, NO_EVENT

HOLD_EVENT_PROCEDURE

HOLD_EVENT_PROCEDURE

Type

Constant

Return Value

Integer

Description

The name of an action key property that contains the xcfa (extended code field address) of a user defined hold event procedure.  The hold event procedure is repeatedly called when an action key is held down. Hold event procedures can not take or return any parameters, but they can modify variables.  The HOLD_EVENT_PROCEDURE property is uninitialized when an action key is instantiated.

Usage

Set_Property ( keyInc, HOLD_EVENT_PROCEDURE, (long) inc_count_ptr )

keyInc @ HOLD_EVENT_PROCEDURE cfa.for Increment_Count Set_Property

Library

library.c

library.4th

See Also

PRESS_EVENT_PROCEDURE, RELEASE_EVENT_PROCEDURE

HORIZONTAL_SNAP_TO_GRID

HORIZONTAL_SNAP_TO_GRID

Type

Constant

Return Value

Integer

Description

The name of a property of the GUI Toolkit that aligns objects loaded onto a screen onto an 8 pixel horizontal grid.  For speed purposes, this property can not be changed so all objects must be loaded onto 8 pixel boundaries.  The only possible value of this property is the boolean GUI_TRUE.

Usage

longFlag = Get_Property(GUI_TOOLKIT, HORIZONTAL_SNAP_TO_GRID);

GUI_TOOLKIT HORIZONTAL_SNAP_TO_GRID Get_Property flag 2!

Library

library.c

library.4th

See Also

VERTICAL_SNAP_TO_GRID

<< Previous | Next >>


Home|Site Map|Products|Manuals|Resources|Order|About Us
Copyright (c) 2006 Mosaic Industries, Inc.
Your source for single board computers, embedded controllers, and operator interfaces for instruments and automation