02.03.2014 Views

BSP Developer's Guide

BSP Developer's Guide

BSP Developer's Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

4<br />

Hardware <strong>Guide</strong>lines<br />

4.4.13 Parallel Ports<br />

VxWorks provides simple support of parallel ports. Refer to directory<br />

target/src/drv/parallel for supported devices and capabilities.<br />

4<br />

4.5 Enabling the Virtual Memory Library<br />

Before proceeding with this section, review the vmBaseLib and vmLib reference<br />

entries and the VxWorks Programmer’s <strong>Guide</strong>: Virtual Memory Interface.<br />

The vmBaseLib (the base virtual memory support library) and the vmLib (the<br />

VxVMI Option) have similar <strong>BSP</strong> requirements. Because vmBaseLib is bundled<br />

with VxWorks, <strong>BSP</strong>s are written to include it by default. If the VxVMI Option is<br />

installed, the end user need only change INCLUDE_MMU_BASIC to<br />

INCLUDE_MMU_FULL in target/config/bspname/config.h to include the unbundled<br />

library in future builds.<br />

The rest of this section describes the changes you must make in the sysLib.c file<br />

and the config.h file for all supported targets with MMUs, and additional changes<br />

you must make for SPARC targets.<br />

! CAUTION: Due to a limitation in the current implementation of VxWorks, virtual<br />

addresses must equal physical addresses when using 68K MMUs.<br />

4.5.1 Changes to sysLib.c<br />

Virtual memory support has two requirements:<br />

■<br />

Add a physical memory description. This requires the inclusion of one header<br />

file and the definition of two variables. Start with the code example shown in<br />

Example 4-1, and change it as appropriate.<br />

– Local RAM is valid, writable, and cacheable. ROM is valid, read-only, and<br />

often non-cached. I/O devices are valid, writable, and non-cached. If<br />

applicable, VMEbus regions are valid, writable, and usually non-cached.<br />

Flash ROM is usually writable and non-cached if it can be written directly<br />

from the CPU.<br />

83

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

Saved successfully!

Ooh no, something went wrong!