X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=hantek_6022bl.c;h=a380ad08dc1a34d078004f22d867a2391462c038;hb=be6d306de12082c887c30e364dcf66438acc6183;hp=99e43c97218382f104172250f795be03ae059cd4;hpb=3968bbfb63b0946841e4f2d78339523a55ef9124;p=sigrok-firmware-fx2lafw.git diff --git a/hantek_6022bl.c b/hantek_6022bl.c index 99e43c97..a380ad08 100644 --- a/hantek_6022bl.c +++ b/hantek_6022bl.c @@ -24,6 +24,8 @@ #include #include +#define SET_ANALOG_MODE() PA7 = 1 + /* Change to support as many interfaces as you need. */ static BYTE altiface = 0; @@ -165,8 +167,7 @@ static void start_sampling(void) { int i; - /* Set analog mode. */ - PA7 = 1; + SET_ANALOG_MODE(); clear_fifo(); @@ -393,8 +394,7 @@ static void init(void) EP4CFG = 0; EP8CFG = 0; - /* Set analog mode. */ - PA7 = 1; + SET_ANALOG_MODE(); /* In idle mode tristate all outputs. */ GPIFIDLECTL = 0x00; /* Don't enable CTL0-5 outputs. */