![]() ![]() Images made in Fritzing and Illustrator CS.įigure 2. Finally, the MCP3008’s grounds all connect to ground on the Pi (pin 3 on the right) and Voltage in connects to the Pi’s 3.3V out (pin 1 on the left). The Pi’s CE0 pin (pin 12 on the right) is connected to the MCP3008’s chip select, pin 10. The clocks on both boards are connected that’s pin 12 on the right for the Pi, and pin 13 for the MCP3008. The Pi’s SDI pin (pin 11 on the right) connects to the MCP3008’s data out (SDO) pin, pin 12. The SPI lines are connected to each other in a standard fashion: the Pi’s SDO pin (pin 10 on the left, counting down from the SD card slot) connects to the MCP3008’s Data in (SDI) pin (pin 11). The MCP3008 datasheet has more information if you need it. pins 1 through 8 are the ADC channels 0 through 7.Counting pins in a u-pattern from top left to bottom left, then across to bottom right and up to top right, the pins are as follows: The pin diagram is shown in Figure 1 below. The code can be found in this repository. Each channel has 10-bit resolution, so it’s a perfect ADC for use with the Pi or a BeagleBone or other embedded board. The MCP3008 is an inexpensive analog-to-digital converter that has an SPI interface. View the Project on GitHub tigoe/PiRecipes MCP3008 Analog-to-Digital Converter ![]() A collection of ways to do things on a Raspberry Pi ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |