1 dual-port ram communications – SENA HD1200 User Manual

Page 30

Advertising
background image

Starter Kit and User Manual for the HelloDevice 1200

27

6.1 Dual-Port RAM Communications

the HelloDevice has 2 Kbytes of Dual-Port RAM, the address of which is from 0x000 ~ 0x7FF. The first 2032-

bytes of the memory area is for user’s data, whereas the last 16-bytes is the registers for interrupt-based

communication. Your device may receive interrupt from the HelloDevice or can generate interrupt to the

HelloDevice, by using these registers. Figure 6.2 shows the HelloDevice memory map of Dual-Port RAM area.

Figure 6.2. the HelloDevice Dual-Port RAM memory map

As you can see 2032-bytes of user data area in the Figure 6.2, there’s no specified memory area mapping scheme

such as write area, read area, message box and so on. Various memory-map can be applied to this memory area,

based on your communication design scheme. Thus, you should be careful in implementation of communication

routines, since the memory mapping rule should be reflected in the memory-based communication routines.

For example, you may reserve the 1016-bytes of the memory area as InBox, from which the HelloDevice can

read data. The address of this area may be from 0x000 to 0x3F7. You may also reserve the rest of the data area

(0x3F8 ~ 0x7EF), as OutBox from which your device can read data.

In this case, you will have to implement the host-side application to read data from this InBox area. You can read

device information to make your device write device-specific data to this area. If interrupt-based communication

is required, interrupt control registers will be used in the communication.

Typically, there are two cases that users use interrupt-registers in the communication.

A. the HelloDevice requests your device to read data from its Dual-Port RAM area

This interrupt is used when the HelloDevice want to inform the your device of the fact that it has updated the

Data Area

0x000

0x7EF

IN

AddrMSB

Reserved

Reserved

IN

AddrLSB

IN

LenMSB

IN

LenLSB

Reserved

Reserved

OUT

AddrMSB

OUT

AddrLSB

OUT

LenMSB

OUT

LenLSB

Reserved Reserved INTR_R

INTR_L

0x7F0 0x7F1 0x7F2 0x7F3 0x7F4 0x7F5 0x7F6 0x7F7 0x7F8 0x7F9 0x7FA 0x7FB 0x7FC 0x7FD 0x7FE 0x7FF

Advertising