LPC43xx SGPIO Configuration

The LPC43xx SGPIO peripheral is used to move samples between USB and the ADC/DAC chip (MAX5864).

The SGPIO is a peripheral that has a bunch of 32-bit shift registers.

These shift registers can be configured to act as a parallel interface of different widths.

For HackRF, we configure the SGPIO to transfer eight bits at a time.

The SGPIO interface can also accept an external clock, which we use to synchronize transfers with the sample clock.

In the current HackRF design, there is a CPLD which manages the interface between the MAX5864 and the SGPIO interface.

There are four SGPIO signals that control the SGPIO data transfer:

  • Clock: Determines when a value on the SGPIO data bus is transferred.
  • Direction: Determines whether the MAX5864 DA (ADC) data is driven onto the SGPIO lines,
    or if the SGPIO lines drive the data bus with data for the MAX5864 DD (DAC) signals.
  • Data Valid: Indicates a sample on the SGPIO data bus is valid data.
  • Transfer Enable: Allows SGPIO to synchronize with the I/Q data stream.
    The MAX5864 produces/consumes two values (quadrature/complex value) per sample period -- an I value and a Q value.
    These two values are multiplexed on the SGPIO lines. This signal suspends data valid until the I value should be transferred.

Frequently Asked Questions

Why not use GPDMA to transfer samples through SGPIO?

It would be great if we could, as that would free up lots of processor time.

Unfortunately, the GPDMA scheme in the LPC43xx does not seem to support

peripheral-to-memory and memory-to-peripheral transfers with the SGPIO peripheral.

You might observe that the SGPIO peripheral can generate requests from SGPIO14 and SGPIO15,

using an arbitrary bit pattern in the slice shift register.

The pattern in the slice determines the request interval.

That's a good start.

However, how do you specify which SGPIO shadow registers are read/written at each request,

and in which order those registers are transferred with memory?

It turns out you can't.

In fact, it appears that an SGPIO request doesn't cause any transfer at all, if your source or destination is "peripheral".

Instead, the SGPIO request is intended to perform a memory-to-memory transfer synchronized with SGPIO.

But you're on your own as far as getting data to/from the SGPIO shadow registers.

I believe this is why the SGPIO camera example in the user manual describes an SGPIO interrupt doing the SGPIO shadow register transfer,

and the GPDMA doing moves from one block of RAM to another.

Perhaps if we transfer only one SGPIO shadow register, using memory-to-memory?

Then we don't have to worry about the order of SGPIO registers, or which ones need to be transferred.

It turns out that when you switch over to memory-to-memory transfers, you lose peripheral request generation.

So the GPDMA will transfer as fast as possible -- far faster than words are produced/consumed by SGPIO.

I'd really love to be wrong about all this, but all my testing has indicated there's no workable solution

to using GPDMA that's any better than using SGPIO interrupts to transfer samples.

If you want some sample GPDMA code to experiment with, please contact Jared (sharebrained on freenode #hackrf).

LPC43xx SGPIO Configuration -- Why not use GPDMA ?的更多相关文章

  1. LPC43xx SGPIO Experimentation

    LPC4350 SGPIO Experimentation The NXP LPC43xx microcontrollers have an interesting, programmable ser ...

  2. LPC43xx SGPIO I2C Implementation

    I²C SGPIO Configuration SGPIO is a hardware feature of LPC4300 series. There are 16 SGPIO pins calle ...

  3. LPC43xx SGPIO DMA and Interrupts

    The SGPIO output pins SGPIO14 and SGPIO15 can trigger a GPDMA request SGPIO pins SGPIO14 and SGPIO15 ...

  4. LPC43xx SGPIO Slice 示意图

    SGPIO inverted clock qualifier Hi, With bits 6:5 of SGPIO_MUX_CFG the QUALIFIER_MODE is selected (0x ...

  5. LPC43xx SGPIO Camera interface design

    AN11196: Camera interface design using SGPIO

  6. LPC43xx SGPIO Pattern Match Mode

    模式匹配 所有位串均具有模式匹配功能. 该功能可用于检测启动代码等.要使用该功能,则必须用需匹配的模式来对REG_SS 编程 (请注意, POS 达到零时 REG_SS 不会与 REG  交换!) M ...

  7. LPC43xx SGPIO Slice 输入输出连接表

  8. LPC43xx Dual-core or Multi-core configuration and JLink Debug

    Test access port (TAP) JTAG defines a TAP (Test access port). The TAP is a general-purpose port that ...

  9. LPC18xx LPC43xx LPC4370 Bootrom USB DFU FPB - Flash Patch and Breakpoint Unit

    What is the difference between a Bootrom vs bootloader on ARM systems Bootrom Bootrom (or Boot ROM) ...

随机推荐

  1. 第9月第7天 uicollectionview

    1. /** The margins used to lay out content in the section controller. @see `-[UICollectionViewFlowLa ...

  2. Linux释放内存小脚本

    最近发现渣渣ECS内存总是不够用,内存太小一不小心就用完了,用完就用完吧,内存用来做cache是可以快一些,但是内存用完了老是一顿一顿的卡,实在有点受不了,于是就写了释放内存的小脚本,觉得卡了就释放下 ...

  3. 5 THINGS TOP BUG BOUNTY HUNTERS DO DIFFERENTLY

    出处:https://www.hackerone.com/blog/5-things-top-bug-bounty-hunters-do-differently 本周,我们有幸收容了50名比利时科技学 ...

  4. shell expect的简单用法【转】

    用expect实现自动登录的脚本,网上有很多,可是都没有一个明白的说明,初学者一般都是照抄.收藏.可是为什么要这么写却不知其然.本文用一个最短的例子说明脚本的原理. 脚本代码如下:  ######## ...

  5. VMware下centos桥接模式静态ip配置

    声明:本文转载自http://blog.csdn.net/ltr15036900300/article/details/48828207,非原创. 一.配置虚拟机centos网络 备份网络文件 [ro ...

  6. Project Euler Problem1

    Multiples of 3 and 5 Problem 1 If we list all the natural numbers below 10 that are multiples of 3 o ...

  7. 关于sklearn,监督学习几种模型的对比

    # K近邻,适用于小型数据集,是很好的基准模型,容易解释 from sklearn.neighbors import KNeighborsClassifier # 线性模型,非常可靠的首选算法,适用于 ...

  8. 证书(Certificate)与描述文件(Provisioning Profiles)

    在使用脚本xcodebuild自动打包的时候,会用到签名证书和描述文件,我在编译的时候搞了好长时间才搞明白,下面介绍如何得到正确配置. 证书:证书是用来给应用程序签名的,只有经过签名的应用程序才能保证 ...

  9. window10 显示QQ图标

  10. JS实现文本中查找并替换字符

    JS实现文本中查找并替换字符 效果图: 代码如下,复制即可使用: <!DOCTYPE html><html> <head> <style type=" ...