cancel
Showing results for 
Search instead for 
Did you mean: 

Nucleo H745ZI_Q board Cann't able to work ADC and Ethernet together in CM7

SA  V.1
Associate III

Hello team, i have a Nucleo H745ZI_Q  board  in this am working  Differential ADC  and Ethernet (using FreeRTOS ) in cortex M7 .  ADC is working fine in indivisual code  And Ethernet also working fine in indivisual code when going to integrate both in a single code  which pheripheral initializing first thats working 

1.if i initialize ADC first thats working fine but ethernet is not working 

2.if i initialize ehternet first thats working fine but when going to initialize ADC ethernet will not working 

am working both ADC and Ethernet in M7 only in ADC not using any RTOS for ethernet using FREE RTOS 

What's the issue happening am fail to understand Any help ??

 

6 REPLIES 6
FBL
ST Employee

Hello @sa  V.1 

 

Have you tried without any RTOS ? 

Providing more details about the issue would help to investigate further... I suggest using ethernet and ADC examples from CubeH7. 

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

TDK
Guru

Ethernet and ADC are independent peripherals and don't directly affect each other. What could be happening is a lack of resources, perhaps you are running too many conversions, or the callback is too slow. Reduce ADC conversion rate by a factor of 100x and try again. If it still doesn't work, provide more detail into what exactly is going on.

If you feel a post has answered your question, please click "Accept as Solution".
SA  V.1
Associate III

Now trying Ethernet without RTOS .Can you specify the examples pathsinCubeH7.

Bellow main file is attached . after line number 450 program counter stops going further while debuggig . In this code ADC working  ethernet ping fails (Destination host unreachable). thank you .

 

TDK
Guru

> hadc3.Init.ContinuousConvMode = ENABLE;

>  sConfig.SamplingTime = ADC_SAMPLETIME_1CYCLE_5;

You're swamping the system with interrupts. Increase sample time to max or otherwise decrease the amount of ADC DMA calls that are being produced. Doesn't look like you use the DMA interrupts, so they could be disabled entirely.

If you feel a post has answered your question, please click "Accept as Solution".
SA  V.1
Associate III

hadc3.Init.ContinuousConvMode = ENABLE;

sConfig.SamplingTime = ADC_SAMPLETIME_1CYCLE_5;    

i Checked  by increasing and Decreasing SamplingTime  But the problem not resolved . Yes sir am not used DMA interrupts is it must to use DMA interrupts ? or i can achive in this method also ...?

// if (HAL_ADC_Init(&hadc3) != HAL_OK)
// {
// Error_Handler();
// }
by commenting  this function ethernet will ping  .if this function is enabled ADC works but ethernet will not ping  i need both should work  how can i resolve this sir ?? 

Hello Sir ,Any reply could be very helpfull ...thanks in advance ..