initiate a single SPI output cycle)Watch the BF bit in SSPSTAT until it goes to 1.(This sez that the send
2019-07-18 15:10
嗨,我使用数据表中的示例代码来使用DMA读取4个ADC通道。代码看起来很好,我正在寻找我正在寻找的样本。问题是,它们处于错误的缓冲区。我把电压设置在引脚2-5上,这应该对应于ADC通道AN2-5。但是当我在引脚2(AN2)上加上电压时,在通道4上得到样本。与销3同上,它在通道5上出现噘嘴。接下来的两个别针什么也不做。下面是我的设置代码:我正在调试调试模式中的DMA缓冲区。这仅仅是我不理解某事的一个例子吗?例如,我假设AD1CSL中的位对应于ANX信道一一对应。所以当我说“0x00 3C”时,它会扫描通道2-5,谢谢! 以上来自于百度翻译 以下为原文 Hi,I used the example code out of the datasheet to read 4 ADC channels using DMA. The code seems to work fine and I am getting the samples I am looking for. The problem is they are in the wrong buffers. I am putting voltage on pins 2-5 which is supposed to correspond to ADC channels AN2-5. But when I put a voltage on pin 2 (AN2) I get samples on channel 4. Ditto with pin 3; it comes pout on channel 5. The next two pins do nothing. Here is my set up code:AD1CON1bits.FORM = 0; // Data Output Format: Integer AD1CON1bits.SSRC = 2; // Sample Clock Source: GP Timer starts conversion AD1CON1bits.ASAM = 1; // ADC Sample Control: Sampling begins immediately after conversion AD1CON1bits.AD12B = 1; // 12-bit ADC operation AD1CON1bits.SIMSAM = 0; // Samples multiple channels individually in sequence AD1CON2bits.BUFM = 0; AD1CON2bits.CSCNA = 1; // Scan Input Selections for CH0+ during Sample A bit AD1CON2bits.CHPS = 0; // Converts CH0 AD1CON3bits.ADRC = 0; // ADC Clock is derived from Systems Clock AD1CON3bits.ADCS = 63; // ADC Conversion Clock //AD1CHS0: A/D Input Select Register AD1CHS0bits.CH0SA = 0; // MUXA +ve input selection (AIN0) for CH0 AD1CHS0bits.CH0NA = 0; // MUXA -ve input selection (Vref-) for CH0 //AD1CHS123: A/D Input Select Register AD1CHS123bits.CH123SA = 0; // MUXA +ve input selection (AIN0) for CH1 AD1CHS123bits.CH123NA = 0; // MUXA -ve input selection (Vref-) for CH1 //AD1CSSH/AD1CSSL: A/D Input Scan Selection Register //AD1CSSH = 0x0000; AD1CSSL = 0x003C; // Scan AIN2, AIN3, AIN4, AIN5 inputs AD1CON1bits.ADDMABM = 0; // DMA buffers are built in scatter/gather mode AD1CON2bits.SMPI = 3; // 4 ADC buffers AD1CON4bits.DMABL = 3; // Each buffer contains 8 words IFS0bits.AD1IF = 0; // Clear the A/D interrupt flag bit IEC0bits.AD1IE = 0; // Do Not Enable A/D interrupt AD1CON1bits.ADON = 1; // Turn on the A/D converterI am looking at the DMA buffers in debug mode. Is this simply a case me not understanding something? For example I assume the bits in AD1CSSL correspond to the ANx channels one-to-one. So when I say "0x003C" it scans channels 2-5. Thanks!
2019-04-19 13:14
大家好,我有相同的代码和相同的电路,但是PIC18F25K80I/SS项目不能正常工作。有人知道什么信息吗?我已经测试了300件,所有的作品都是一样的。采用PIC18F25K80 I/O,操作十分完善。我的项目使用CAN总线。 以上来自于百度翻译 以下为原文 Hello guys,I have the same code and the same circuit, but with the PIC18f25k80 i/ss the project does not work correctly. Anyone for any information? I already test 300 pieces, and all the pieces worked the same. With the PIC18f25k80 i/so the operation is perfect. My project use the CAN bus.
2018-11-01 10:18
提供各类半导体二手设备(前道和后道)!公司主页: www.justinbdnl.com www.surplushere.com ( tour to our facility pictures )Justin BD&L.,Inc can offer a full range of Front-end / Back-end semiconductors processing equipment.Also we satisfy our customers by provide our services, such as Modification, Refurbish, Parts provide, Technology support, Repair service and so on. Now we're actively marketing the following Back-End and ATE tools for sale, as below information: 1. Disco DFG840 Back Grinder, 4 sets @U$45,000.00 per system @U$40,000.00 per system for packaged deal of 4 sets/package All tools are located in Korea 2. Disco DFD640 Dicing Saw, 4 sets @U$40,000.00 per system @U$38,000.00 per system for packaged deal of 4 sets/package All tools are located in Korea 3. TSK AWD5000A Dicing Saw, 2 sets @U$40,000.00 per system @U$38,000.00 per system for packaged deal of 2 sets/package All tools are located in Korea 4. Nitto DR8500 Laminator (Taper), 5 sets @U$25,000.00 per system @U$20,000.00 per system for packaged deal of 2 sets/package All tools are located in Korea 5. Nitto HR8500 Tape Remover, 3 sets @U$25,000.00 per system @U$20,000.00 per system for packaged deal of 2 sets/package All tools are located in Korea 6. Takatori ATRM2100 Tape Remover, 2 sets @U$25,000.00 per system @U$20,000.00 per system for packaged deal of 2 sets/package All tools are located in Korea 7. TSK UF200 Probe Station, 1 set @U$18,000.00 per system @U$15,000.00 per system for packaged deal of 10 sets/package of UF200S All tools are located in Korea 8. TSK UF200S Probe Station, 15 sets @U$18,000.00 per system @U$15,000.00 per system for packaged deal of 10 sets/package All tools are located in Korea 9. TSK UF200SA Probe Station, 15 sets @U$19,000.00 per system @U$15,000.00 per system for packaged deal of 10 sets/package All tools are located in Korea 10. TSK A-PM-90A Probe Station, 15 sets @U$6,500.00 per system @U$5,000.00 per system for packaged deal of 10 sets/package All tools are located in Korea 11. TEL P8 Probe Station, 15 sets @U$12,000.00 per system @U$10,000.00 per system for packaged deal of 10 sets/package All tools are located in Korea 12. TEL P8XL Probe Station, 2 sets @U$19,000.00 per system @U$15,000.00 per system for packaged deal of 2 sets/package All tools are located in Korea We also have the following 300mm tools for sale : 1. TSK UF3000 Probe Station for 300mm Wafers Total 6 systems available. Note : 4 systems has chiller (-40'C cooling) Condition : Excellent 2. Advantest T5377 Memory Tester Total 3 systems available Condition : Excellent 3. ESI M9825 Laser Repair System Total 1 system available Condition : Excellent All tools are available for inspection in Korea.Please contact us if you're interested in.Thank you very much !contant email: chris.wang@justinbdnl.com
2009-02-25 13:14