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
Table of Contents

Introduction

Specifications

Hardware

Flash Card

Connecting To the Wildcard Bus

Selecting the Wildcard Address

Installing the CF Card

CF Card Software Package User Guide and Glossary

How To Install the CF Software

Using the Driver Code with C

Using the Driver Code with Forth

CF Card Software

Categorized List of Functions and Constants

ATA Failure Codes

ATA Primitives

CF Card Information

Directory

File Access and Position Modes

File I/O

File Processing

File System Error Handling

Initialization

Overview of Glossary Notation

Using the File System Functions

Commonly Used Terms

String Parameters and the Use of THIS_PAGE

Access Privileges

Root Directory Only and File Name Restrictions

File Position Indicator

Error Handling

Real-Time Clock on the Host Computer Enables Time/Date Marking of Files 12

Initialization

Automatic Initialization and File Processing

Upgrade note for former Memory Interface Board (MIB) Users

How To Create and Use an AUTOEXEC.QED File

Compile a Program into Flash Memory

Create a Set of Image Files

Transfer the Image File Contents into Memory

Restrictions on Software Upgrades

Recovering from Buggy AUTOSTART.QED Files

Compact Flash Card Software Package Main Glossary

Upgrade Notice for Prior Users of the Memory Interface Board

Sample FILEDEMO.C File (pdf)

Sample FILEDEMO.4th File (pdf)

CF Wildcard Hardware Schematic

The Compact-Flash Wildcard and
CF Card Software Package User Guide

<< Previous | Next>>

CF Card Software Package User Guide and Glossary

Introduction

The rest of this document describes the Compact Flash (CF) Card Software Package. This package is shipped as a kernel extension that is easily loaded onto the host controller. The software enables a product containing a host controller and a CF Wildcard to read from and write to vast amounts of flash memory on convenient removable media. The software supports the standard DOS/Windows "FAT" file system, allowing files to be created on a PC and read by the host controler, or visa versa. An automated file processing facility facilitates software upgrades or data exchanges.

Flash is a state of the art memory technology that is programmable yet nonvolatile: it maintains its contents even in the absence of power. Widely available Compact Flash Cards can be read or written from most laptop computers with a low-cost PCMCIA form-factor adapter. They adhere to the ATA standard for disk drives, a widespread software and hardware interface. "ATA" stands for "AT Attachment", an interface developed for the IBM PC AT. ATA Flash cards can be operated in a "true IDE" mode that makes them behave as a standard IDE hard drive such as those found in every PC.

How To Install the CF Software

The CR Card device driver software is provided as a pre-coded modular runtime library, known as a "kernel extension" because it enhances the on-board kernel's capabilities. The library functions are accessible from C and Forth.

Mosaic Industries can provide you with a web site link that will enable you to create a packaged kernel extension that has drivers for all of the hardware that you have on your system. In this way the software drivers are customized to your needs, and you can generate whatever combination of drivers you need. Make sure to specify the CF Wildcard Driver in the list of kernel extensions you want to generate, and download the resulting "packages.zip" file to your hard drive.

For convenience, a separate pre-generated kernel extension for the CF Wildcard is available from Mosaic Industries on the Demo and Drivers media (diskette or CD). Look in the Drivers directory, in the subdirectory corresponding to your hardware (your Mosaic controller), in the CF_Wildcard folder.

The kernel extension is shipped as a "zipped" file named "packages.zip". Unzipping it (using, for example, winzip or pkzip) extracts the following files:

  • readme.txt - Provides summary documentation about the library.
  • install.txt - The installation file, to be loaded to COLD-started Mosaic embedded controller.
  • library.4th - Forth name headers and utilities; prepend to Forth programs.
  • library.c - C callers for all functions in library; #include in C code.
  • library.h - C prototypes for all functions; #include in extra C files.

Library.c and library.h are only needed if you are programming in C. Library.4th is only needed if you are programming in Forth. The uses of all of these files are explained below.

We recommend that you move the relevant files to the same directory that contains your application source code.

To use the kernel extension, the runtime kernel extension code contained in the install.txt file must first be loaded into the flash memory of the Mosaic controller. Start the Mosaic Terminal software with the Mosaic embedded controller connected to the serial port and turned on. If you have not yet tested your Mosaic controller and terminal software, please refer to the documentation provided with the Mosaic Terminal software. Once you can hit enter and see the 'ok' prompt returned in the terminal window, type
COLD
to ensure that the board is ready to accept the kernel extension install file. Use the "Send File" menu item of the terminal to download the install.txt to the Mosaic Controller.

Now, type
COLD
again and the kernel has been extended! Once install.txt has been loaded, it need not be reloaded each time that you revise your source code.

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