Skip to content

Commit

Permalink
Retrigger every line to support Sega Master System
Browse files Browse the repository at this point in the history
  • Loading branch information
charcole committed Aug 4, 2018
1 parent 44ee7c6 commit 67a8b36
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Firmware/main/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -979,7 +979,7 @@ int IRAM_ATTR SetupLine(uint32_t Bank, const int *StartingLine)
{
SourcePlayer = LastActivePlayer;
}
if (CurrentLine == StartingLine[SourcePlayer] + ARRAY_NUM(ReticuleSizeLookup[0])/2)
if (CurrentLine == StartingLine[SourcePlayer])
{
int Channel = RMT_TRIGGER_CHANNEL + Player;
int DelayChannel = RMT_DELAY_TRIGGER_CHANNEL + Player;
Expand All @@ -996,6 +996,10 @@ int IRAM_ATTR SetupLine(uint32_t Bank, const int *StartingLine)
RMTMEM.chan[DelayChannel].data32[1].val = EndTerminator.val;
Active |= (2 << Player);
}
else if (CurrentLine > StartingLine[SourcePlayer] && CurrentLine < StartingLine[SourcePlayer] + ARRAY_NUM(ReticuleSizeLookup[0]))
{
Active |= (2 << Player);
}
}

return Active;
Expand Down

0 comments on commit 67a8b36

Please sign in to comment.