User`s guide

isreadable
family and 2
16
for the C5xxx series. W h en the function identi es an
illegal address, it returns an error message stating that the address
values are out of range.
Note isreadable relies on the memory map optio n in CCS IDE. If
you did not properly dene the memory map for the processor in CC S
IDE,
isreadable does not produce useful results. Refer to your Texas
Instruments’ C ode Composer Studio documen t a t ion f or information on
conguring m emory maps.
Examples When you write scripts to run models in the M ATLAB environment and
CCS IDE, the
isreadable function is very useful. Use isreadable
to check that the channel from which you are reading is congured
properly.
cc = ticcs;
rx = cc.rtdx;
% Define read and write channels to the processor linked by cc.
open(rx,'ichannel','r');s
open(rx,'ochannel','w');
enable(rx,'ochannel');
enable(rx,'ichannel');
isreadable(rx,'ochannel')
ans=
0
isreadable(rx,'ichannel')
ans=
1
Now that your script knows that it can read from ichannel, it proceeds
to read messages as required.
See Also hex2dec, iswritable, read
7-71