Koheron / koheron-sdk

SDK for FPGA / Linux Instruments
https://www.koheron.com/software-development-kit/
Other
101 stars 41 forks source link

adc-bram alpha250-4 #581

Closed elhaouati closed 1 year ago

elhaouati commented 1 year ago

Hi

int main(){
int fd;
uint32_t count0, count1, count2, count3;
void* cfg0;
char* name"/dev/mem";
int L0,L1,L2,L3;
if(( fd = open(name,O_RDWR) ) < 0 ){
      perror("open");
      return 1; }

cfg0 = mmap(NULL, sysconf(_SC_PAGESIZE), PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0x40000000);

count0 = *((uint32_t *)(cfg0 + 0));
L0 = ((count0 >> 16) - 32768) % 65536 - 32768;
count1 = *((uint32_t *)(cfg0 + 4));
L1 = ((count1 >> 16) - 32768) % 65536 - 32768;
count2 = *((uint32_t *)(cfg0 + 8));
L2 = ((count2 >> 16) - 32768) % 65536 - 32768;
count3 = *((uint32_t *)(cfg0 + 12));
L3 = ((count3 >> 16) - 32768) % 65536 - 32768;

munmap(cfg0, sysconf(_SC_PAGESIZE));

return 0; }

GetImage

I'm working on the adc-bram example. (L0,L1,L2,L3) contain the informations I need and I want to use AXI GPIO IP to communicate these values with other fpga blocks but I can't connect it using (run connection automation ), it returns this message error: [xilinx.com:ip:axi_gpio:2.0-1] /axi_gpio_0 Automation rule cannot be applied because reference IP /ctl/axi_ctl_register/S_AXI is not connected to expected interconnect.

So I connected it mannually and I assigned to it an adress manually in adress editor the error message is "this pin will not be connected to the GPIO interface because the connection is overridden by the user"

Thank you in advance