DMA with AES

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

DMA with AES

2,382 次查看
Jgeorge
Contributor I

Hi,

I am trying to Run AES using DMA.

I  tried for last three days, but could not proceed further.

How I did?

1.I too sample code of DMA Memory to Memory from SDK

2.Added the AES header and Driver file in it.

3.Changed the AES configuration accordingly w.r.t DMA.

4.Then compiled and execute but code is stuck in while loop.

Please can anyone tell is this correct way of doing?

I read there are some trigger and input source for DMA request but couldn't find any example how to do it.

Can anyone share the pseudo code?

 

 

标签 (1)
0 项奖励
回复
9 回复数

2,374 次查看
Jgeorge
Contributor I

No I haven't used trigger source but yes I read about it in UM ,can you please tell me any reference in demo code for trigger source or do I have to create my own.

yes I am using AES module of LPC55s69.I am using software key for AES.

0 项奖励
回复

2,333 次查看
Jgeorge
Contributor I

Hi Alice_Yang,

Sure,Please see the code i have done.You can also run the code at your side.Waiting for your reply.

0 项奖励
回复

2,329 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Jgeorge,

So what's your problem now? I think you can debug with breakpoint or step by step first confirm the detail

issue.

 

BR

Alice

0 项奖励
回复

2,326 次查看
Jgeorge
Contributor I

Hi Alice_Yang,

Thanks for your code suggestion.

The code which i shared is not complete.

I have completed the code now and could debug with breakpoint step by step also.

The DMA transfer is  working fine but the encrypted data from the output/DIGEST register is coming incorrect.

I am having doubt in giving the user key that is  userkey should be loaded after the DMA transfer or before transfer?

I am doing before DMA transfer.

please suggest if there is any other way for getting output/DIGEST register.

Note:I am just a beginner !

0 项奖励
回复

2,307 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Jgeorge,

Yes, giving user key before DMA transfer is no problem.

It seems your code disable the use key and other AES encrypt related code.

Recommend first development base on hashcypt demo under SDK, change it to your request, and confirm the AES work well , the DIGEST data is right.  then add DMA request on it.

 

BR

Alice

0 项奖励
回复

2,302 次查看
Jgeorge
Contributor I

Hi Alice_Yang

 

Sure.Thanks for your suggestion

Regards,

Jacob

0 项奖励
回复

2,361 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Jgeorge,

Please refer to "Configure the DMA as follows: ..." in UM to config DMA, 

and the SDK demo with DAM, for example "usart_dma_transfer".

 

BR

Alice

0 项奖励
回复

2,355 次查看
Jgeorge
Contributor I

Hi Alice_Yang,

Yes thanks for the information.

I have started exploring UART DMA code ,it's understandable now.

According to that only I am configuring for AES.

Sure I will share my complete code once I configure all the registers by tomorrow EOD.

Please see to it and looking forward for your feedback

0 项奖励
回复

2,377 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Jgeorge,

Could you please show more information about your application.

The trigger Source of DMA ?

And do you use AES module of LPC55 or just software AES?

 

BR

Alice