View Single Post
  #1   Spotlight this post!  
Unread 09-02-2005, 21:59
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Question Double calls of OpenADC()?

Tonight, I found something interesting relating to the gyro code and Get_Analog_Value().

The initialization of the gyro code (Initialize_Gyro()) calls OpenADC(), but there is no call to CloseADC(), so that the ADC remains open. Get_Analog_Value() calls OpenADC() and CloseADC(). If you call Get_Analog_Value() after calling Initialize_Gyro(), it will call OpenADC() before the last call was closed. There are no handles to these, so I assume that if you close one, you close all.

Does anyone know if this causes a problem? Or is it ok?