beautypg.com

Memcmp_rx (), Memcmp_xx (), Memset_x () – Maxim Integrated 73S12xxF Software User Manual

Page 65: E 65)

background image


UG_12xxF_016

73S12xxF Software User Guide

Rev. 1.50

65

memcmp_rx ()

Purpose

Memory management – use to compare the contents of an XRAM location and a
ROM location.


Synopsis

Signed char memcmp_rx (

Unsigned char code *dst,

Unsigned char xdata *src,

Unsigned integer len );


Parameters

dst: Input parameter
Specifies the starting address of the ROM data to be compared.

src: Input parameter
Specifies the starting address of the XRAM data to compare to.

len: Input parameter
Specifies the length (in bytes) of data to compare.

Return Codes 0 if the compare is successful (data matched).

Non zero if the source and destination data do not match.

memcmp_xx ()

Purpose

Memory management – use to compare the contents of an XRAM location and
another XRAM location.


Synopsis

Signed char memcmp_xx (

Unsigned char xdata *dst,

Unsigned char xdata *src,

Unsigned integer len );


Parameters

dst: Input parameter
Specifies the starting address of the the first XRAM location to be compared.

src: Input parameter
Specifies the starting address of the the XRAM location to compare to.

len: Input parameter
Specifies the length (in bytes) of data to compare.


Return Codes 0 if the compare is successful (data matched).

Non zero if the source and destination data do not match.

memset_x ()

Purpose

Memory management – use to fill the contents of XRAM with a specified value.


Synopsis

void memset_x (

Unsigned char xdata *dst,

Unsigned char s,

Unsigned integer len );


Parameters

dst: Input parameter
Specifies the starting address of the XRAM locations to fill.

src: Input parameter
Specifies the value to fill the XRAM with.

len: Input parameter
Specifies the number of bytes to fill with the specified data.


Return Codes None.