Positron Compiler Documentation

Creating variables in Y RAM

Positron16 · Revision 1.1.3.5 · PDF page 442

dsPIC33® devices have an extra area of RAM dedicated to DSP operations. It resides at the top of the X RAM area and is named Y RAM. All DSP operations involving the accumulators must use Y RAM, otherwise the microcontroller will create an exception.

Adding the text YRAM at the end of a variable's declaration will cause it to be created in the Y RAM section:

Dim MyArray[10] As Word YRAM = 1, 2, 3, 4, 5, 6, 7

Each dsPIC33® family has differing amounts of Y RAM, so the compiler will produce an error message if the limit is exceeded.

View original PDF page 442Open page in PDFOriginal PDF page 442