FPGAwars / Alhambra-II-FPGA

:star2: Alhambra II FPGA board
GNU Lesser General Public License v3.0
84 stars 26 forks source link

Alhambra ADC example #3

Closed drtrigon closed 6 years ago

drtrigon commented 6 years ago

Is an ADC example for Alhambra 2 available? May be one using picorv32?

I only found one for "MCP300x A/D controller (SPI master)" but as I understand is this the wrong chip and interface (SPI instead of I2C).

drtrigon commented 6 years ago

Icezum Alhambra ADC: https://groups.google.com/forum/m/#!topic/fpga-wars-explorando-el-lado-libre/4_vHakcwXdQ

https://github.com/kaibran/printbot

Obijuan commented 6 years ago

You can find a simple example here:

https://github.com/Obijuan/CTIF-Madrid-2018-FPGAs-Libres/tree/master/Colecciones/CTIF-MadridCap-6/examples/03-ADC

It just reads the AD channel 0 and show its value in the leds, at rate of 4Hz. The example is for the Alhambra I board, but the connection for the Alhambra II are the same

i am attaching here the example for the Alhambra II board

I am in the process of documenting everything. But in the meanwhile that example may help a little bit. The Alhambra II ADC converter is connected to the FPGA by the I2C bus

05-adc0-leds.zip

drtrigon commented 6 years ago

Thanks a lot! That is very helpful!

(Now have to merge picorv32 with this... ;))

drtrigon commented 6 years ago

grafik