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   

KEYPAD_BEEP

KEYPAD_BEEP

Type

Constant

Return Value

Integer

Description

The name of a keypad property that causes the buzzer to sound when a key is pressed.  The KEYPAD_BEEP property for all keypads is set to GUI_TRUE by Initialize_GUI.

Usage

Set_Property(GUI_KEYPAD0, KEYPAD_BEEP, GUI_TRUE);

GUI_KEYPAD0 KEYPAD_BEEP GUI_TRUE Set_Property

Library

library.c

library.4th

KEYPAD_BEEP_DURATION

KEYPAD_BEEP_DURATION

Type

Constant

Return Value

Integer

Description

The name of a keypad property that sets the length of the beep when a key is pressed.  The units for the KEYPAD_BEEP_DURATION property is in timeslice counts or 5 millisecond intervals.  The KEYPAD_BEEP_DURATION property is different from the BEEP_TIME property of the GUI_BUZZER object.  This allows you to set different beep times for each keypad and use the GUI_BUZZER for alarms or notifications.  The KEYPAD_BEEP_DURATION property for all keypads is set to 1 (5 milliseconds) by Initialize_GUI.

Usage

// Set the keypad beep to 10 ms.

Set_Property(GUI_KEYPAD0, KEYPAD_BEEP_DURATION, (long) 2);

\ Set the keypad beep to 10ms.

GUI_KEYPAD0 KEYPAD_BEEP_DURATION 2 u>d Set_Property

Library

library.c

library.4th

See Also

BEEP_TIME, GUI_BUZZER

KEY_CODE

KEY_CDOE

Type

Constant

Return Value

Integer

Description

The name of a read only keypad property that contains the key code from the most recently pressed data entry key.  The key code is based on the SHIFT_STATE (SHIFT_UP, SHIFT_DOWN, or SHIFT_NEUTRAL), KEY_POSITION (0 to 15 or 20 to 34), and PRESS_NUMBER for an overloaded data entry key.  Valid key codes are from 1 to 255.  The key code is a reference to a glyph of a font that is rendered into a textbox and shown on the display.  For examle, key code 65 refers to the glyph of an upper case A where as key code 247 refers to the glyph of a divide sign in the default font.

Usage

keycode = Get_Property(GUI_KEYPAD0, KEY_CODE);

GUI_KEYPAD0 KEY_CODE Get_Property keycode 2!

Library

library.c

library.4th

See Also

KEY_POSITION, PRESS_NUMBER, PRIOR_KEY_CODE, SHIFT_STATE

KEY_EVENT

KEY_EVENT

Type

Constant

Return Value

Integer

Description

The name of a read only keypad property that contains the most recent keypad event.  Valid keypad events are PRESS_EVENT, HOLD_EVENT, RELEASE_EVENT, and NO_EVENT.

Usage

event = Get_Property(GUI_KEYPAD0, KEY_EVENT);

GUI_KEYPAD0 KEY_EVENT Get_Property event 2!

Library

library.c

library.4th

See Also

PRIOR_KEY_EVENT, PRESS_EVENT, HOLD_EVENT, RELEASE_EVENT, NO_EVENT

KEY_POSITION

KEY_POSITION

Type

Constant

Return Value

Integer

Description

The name of a read only keypad property that contains the position of the most recently pressed key.  Valid key positions are from 0 to 15 and 20 to 34 which correspond to the phyical location of the keys on the keypad as shown in the table for Insert_Key.

Usage

position = Get_Property(GUI_KEYPAD0, KEY_POSITION);

GUI_KEYPAD0 KEY_POSITION Get_Property position 2!

Library

library.c

library.4th

See Also

Insert_Key, PRIOR_KEY_POS

KEY_POS_OUT_OF_RANGE

KEY_POS_OUT_OF_RANGE

Type

Constant

Return Value

Integer

Description

The name of an error that indicates the key position is not valid i.e. the key position is not between 0 and 15 or 20 and 34.

Usage

Insert_Key(GUI_KEYPAD0, actionkeyStop, 16);

If (Read_Error() == KEY_POS_OUT_OF_RANGE)

{

  printf(“The key position is out of range.\n”);

  Clear_Error();

}

GUI_KEYPAD0 actionkeyStop @ 16 Insert_Key

Read_Error KEY_POS_OUT_OF_RANGE =

if

  cr .” The key position is out of range.”

  Clear_Error

endif

Library

library.c

library.4th

KEY_TYPE

KEY_TYPE

Type

Constant

Return Value

Integer

Description

The name of a read only keypad property that contains the type of the most recently pressed key.  Valid key types are ACTION_KEY, DATA_ENTRY_KEY, SHIFT_KEY, and NO_KEY.

Usage

keytype = Get_Property(GUI_KEYPAD0, KEY_TYPE);

GUI_KEYPAD0 KEY_TYPE Get_Property keytype 2!

Library

library.c

library.4th

See Also

ACTION_KEY, DATA_ENTRY_KEY, SHIFT_KEY, NO_KEY, PRIOR_KEY_TYPE

<< 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