Skip to content

Commit

Permalink
#117 glitch fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
mvladic committed Apr 28, 2017
1 parent 4cc6b9e commit ae69dae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 0 additions & 2 deletions eez_psu_sketch/list.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,6 @@ void executionStart(Channel &channel) {
g_execution[channel.index - 1].it = -1;
g_execution[channel.index - 1].counter = g_channelsLists[channel.index - 1].count;
g_active = true;
channel_dispatcher::setVoltage(channel, 0);
channel_dispatcher::setCurrent(channel, 0);
}

int maxListsSize(Channel &channel) {
Expand Down
10 changes: 7 additions & 3 deletions eez_psu_sketch/trigger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -276,17 +276,21 @@ int startImmediately() {
Channel& channel = Channel::get(i);

if (i == 0 || !(channel_dispatcher::isCoupled() || channel_dispatcher::isTracked())) {
if (channel.getVoltageTriggerMode() != TRIGGER_MODE_FIXED) {
if (channel.getVoltageTriggerMode() == TRIGGER_MODE_LIST) {
channel_dispatcher::setVoltage(channel, 0);
channel_dispatcher::setCurrent(channel, 0);

channel_dispatcher::outputEnable(channel, channel_dispatcher::getTriggerOutputState(channel));
}

if (channel.getVoltageTriggerMode() == TRIGGER_MODE_LIST) {
list::executionStart(channel);
} else {
if (channel.getVoltageTriggerMode() == TRIGGER_MODE_STEP) {
channel_dispatcher::setVoltage(channel, g_levels[i].u);
channel_dispatcher::setCurrent(channel, g_levels[i].i);

channel_dispatcher::outputEnable(channel, channel_dispatcher::getTriggerOutputState(channel));
}

setTriggerFinished(channel);
}
}
Expand Down

0 comments on commit ae69dae

Please sign in to comment.