04.01.2015 Views

CR1000 Manual - Campbell Scientific

CR1000 Manual - Campbell Scientific

CR1000 Manual - Campbell Scientific

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

Appendix A. CRBasic Programming Instructions<br />

A.11 Serial Input / Output<br />

MenuPick<br />

Creates a list of selectable options that can be used when editing a MenuItem<br />

value.<br />

Syntax:<br />

MenuPick(Item1, Item2, Item3...)<br />

DisplayValue<br />

Defines the name and associated data‐table value or variable for an item in a<br />

custom menu.<br />

Syntax:<br />

DisplayValue("MenuItemName", Expression)<br />

SubMenu / EndSubMenu<br />

Define the beginning and ending of a second‐level menu for a custom menu.<br />

Syntax:<br />

DisplayMenu("MenuName", 100)<br />

SubMenu("MenuName")<br />

[menu definition]<br />

EndSubMenu<br />

EndMenu<br />

Read More! See Serial I/O (p. 200).<br />

MoveBytes<br />

Moves binary bytes of data into a different memory location when translating<br />

big‐endian to little‐endian data.<br />

Syntax<br />

MoveBytes(Destination, DestOffset, Source, SourceOffset,<br />

NumBytes)<br />

SerialBrk<br />

Sends a break signal with a specified duration to a <strong>CR1000</strong> serial port.<br />

Syntax<br />

SerialBrk(Port, Duration)<br />

SerialClose<br />

Closes a communications port that was previously opened by SerialOpen.<br />

Syntax<br />

SerialClose(ComPort)<br />

SerialFlush<br />

Clears any characters in the serial input buffer.<br />

Syntax<br />

SerialFlush(ComPort)<br />

SerialIn<br />

Sets up a communications port for receiving incoming serial data.<br />

Syntax<br />

SerialIn(Dest, ComPort, TimeOut, TerminationChar,<br />

MaxNumChars)<br />

509

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

Saved successfully!

Ooh no, something went wrong!