Skip to content
Snippets Groups Projects
Commit 7e80a1ea authored by Paulus Kruger's avatar Paulus Kruger
Browse files

ADC test

parent c0e6a93e
No related branches found
No related tags found
No related merge requests found
......@@ -745,7 +745,8 @@ methods:
- RCU_ADC_shutdown : [1,1,1]
# - IO3.GPIO1: 0xD5 #ADC_SDIO=high, clk=low, DTH_EN=high
# - IO3.GPIO2: 0xC7 #ADC SC=high, DTH_SDA=high, DTH_EN=high
- WAIT: 100 #ms to wait
- RCU_PWR_3V3: Update
# - WAIT: 100 #ms to wait
- RCU_ADC_shutdown : [1,1,0]
- WAIT: 100 #ms to wait
- RCU_ADC_shutdown : [1,0,0]
......@@ -755,7 +756,7 @@ methods:
# - IO3.GPIO2: 0x47 #enable ADC 2
# - RCU_DTH_on: Update #check dither while giving ADCs some time to lock
# - WAIT: 500 #ms to wait
- RCU_PWR_3V3: Update_background
# - RCU_PWR_3V3: Update_background
- RCU_PWR_1V8: Update_background
- RCU_PWR_2V5: Update_background
- RCU_ADC_locked: Update_background #disabled for testing
......
from test_common import *
connect()
name="RCU_ADC_test"
#RCU=[0];
RCU=[0];
RCU=[x for x in range(32)]
#Att=[15,15,15]
#RCU=[0,1,2,3,16,17,18,19];
#Att=[4,4,4]
Att=[0x6]*3 #+full scale
setAntmask(RCU)
att=get_debug_value(name+"_R")
print("Att old:",att[:15])
for r in RCU:
att[3*r:3*r+3]=Att
print("Att set:",att[:15])
set_debug_value(name+"_RW",att)
call_debug_method("ADC1_on")
time.sleep(0.5)
att=get_debug_value(name+"_R")
print("Att new:",att[:15])
disconnect()
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment