KSDK1.2/PE/Flexbus - Getting hardware fault on first access

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

KSDK1.2/PE/Flexbus - Getting hardware fault on first access

Jump to solution
1,223 Views
larrykoos
Contributor III

Hi,

I'm using KDS 3.0, KSDK 1.2, and MQX_KSDK on a K64. I'm trying to use the Flexbus to interface to a bunch of memory-mapped registers in an FPGA. The first time my code tries to access a register in the FPGA, it throws a hard fault interrupt. While I have tried multiple base addresses based on the system memory map as described in the reference manual, I'm currently trying to use 0xa0000000 as the base address into a 64K address space using CS2. Using the Memory Browser, I readback FB_CSAR2 = 0xA0000000, FB_CSMR2 = 0x00000001, and FB_CSCR2 = 0x004C0180. I believe the only bit in the control register that's important at this stage is the AA bit which is set so that an access to a valid address space should auto-generate an acknowledge to prevent a hardware fault.

Is there an error in my configuration? Is there something else I need to configure to prevent the hardware fault (maybe in the MPU)? Is there a known problem with this component in PE?

Thanks for your help,

Larry

0 Kudos
Reply
1 Solution
888 Views
DavidS
NXP Employee
NXP Employee

Hi Larry,

I believe you are bitten by the Global Chip Select (CS0) default capability.

Please try to enable and disable CS0 which will disable the global chip select feature to allow the CS2 to operate correctly.

Please let us know if this resolves the issue or not.

Regards,

David

View solution in original post

0 Kudos
Reply
3 Replies
889 Views
DavidS
NXP Employee
NXP Employee

Hi Larry,

I believe you are bitten by the Global Chip Select (CS0) default capability.

Please try to enable and disable CS0 which will disable the global chip select feature to allow the CS2 to operate correctly.

Please let us know if this resolves the issue or not.

Regards,

David

0 Kudos
Reply
888 Views
larrykoos
Contributor III

David,

Thanks for your quick response. That corrected the problem.

0 Kudos
Reply
888 Views
DavidS
NXP Employee
NXP Employee

Awesome.  Thanks for update.

Regards,

David

0 Kudos
Reply