Skip to content

Commit

Permalink
Stylistic changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
mitar committed Oct 30, 2010
1 parent 7bd7f63 commit 9550cb1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions lib/Errors.hs
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,5 @@ failNXT msg 0xEF = fail $ msg ++ ": Attempted to access invalid field of a struc
failNXT msg 0xF0 = fail $ msg ++ ": Bad input or output specified"
failNXT msg 0xFB = fail $ msg ++ ": Insufficient memory available"
failNXT msg 0xFF = fail $ msg ++ ": Bad arguments"
failNXT msg 0x00 = fail msg -- Some guard (restriction) failed?
failNXT msg _ = fail msg -- Invalid error code?
failNXT msg 0x00 = fail msg -- some guard (restriction) failed?
failNXT msg _ = fail msg -- invalid error code?
4 changes: 2 additions & 2 deletions lib/NXT.hs
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ resetMotorPosition output reset = do
case reset of
InternalPosition -> do
mid <- getModuleID "Output.mod"
writeIOMap (fromJust mid) ((fromEnum output) * 32 + 18) [0x08] -- Flags field is at offset 18, output block is 32 bytes long, UPDATE_RESET_COUNT is 0x08
writeIOMap (fromJust mid) ((fromEnum output) * 32 + 18) [0x08] -- flags field is at offset 18, output block is 32 bytes long, UPDATE_RESET_COUNT is 0x08
_ -> do
let send = [0x80, 0x0A, fromIntegral . fromEnum $ output, fromIntegral . fromEnum $ reset]
sendData send
Expand Down Expand Up @@ -458,7 +458,7 @@ isBatteryRechargeable = do
stopSoundPlayback :: NXT ()
stopSoundPlayback = stopSoundPlayback' False

--Stops sound playback, but also gets the confirmation
-- Stops sound playback, but also gets the confirmation
stopSoundPlaybackConfirm :: NXT ()
stopSoundPlaybackConfirm = stopSoundPlayback' True

Expand Down
4 changes: 2 additions & 2 deletions remote/remote.nxc
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ task main() {
SysRandomNumber(random);

// We randomly select order so that possible latencies are averaged out
if (random.Result & 1) { // Test one bit for two choices
if (random.Result & 1) { // Tests one bit for two choices
if (ports & OUTPUT_A) reset(OUT_A);
if (ports & OUTPUT_B) reset(OUT_B);
if (ports & OUTPUT_C) reset(OUT_C);
Expand Down Expand Up @@ -120,7 +120,7 @@ task main() {
SysRandomNumber(random);

// We randomly select order so that possible latencies are averaged out
if (random.Result & 1) { // Test one bit for two choices
if (random.Result & 1) { // Tests one bit for two choices
if (ports & OUTPUT_A) output_absolute(OUT_A, power, count, old_count);
if (ports & OUTPUT_B) output_absolute(OUT_B, power, count, old_count);
if (ports & OUTPUT_C) output_absolute(OUT_C, power, count, old_count);
Expand Down

0 comments on commit 9550cb1

Please sign in to comment.