Skip to content

Commit

Permalink
gp4prog: using --emulate without --voltage is an error.
Browse files Browse the repository at this point in the history
whitequark committed Dec 10, 2016
1 parent 5a73304 commit 268258f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/gp4prog/main.cpp
Original file line number Diff line number Diff line change
@@ -331,6 +331,13 @@ int main(int argc, char* argv[])
return 0;
}

//It makes no sense to emulate without applying any Vdd
if(voltage == 0.0 && !downloadFilename.empty() && !programNvram)
{
LogError("--emulate is specified but --voltage isn't; chip must be powered for emulation\n");
return 1;
}

//It makes no sense to apply vccio to a single-rail part
if(voltage2 != 0.0 && detectedPart != SilegoPart::SLG46621V)
{

0 comments on commit 268258f

Please sign in to comment.