Created
July 25, 2018 13:46
-
-
Save KKostya/b2e5e73ede74833d8a4349805365bf38 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let one_step state = | |
match state.incoming with None -> state | Some in_msg -> | |
let state = { state with incoming = None; outgoing = None } in | |
match in_msg with | |
| Sensor laserScan -> | |
let min_range, min_direction = get_min_and_direction laserScan in | |
process_sensor_message state min_range min_direction | |
| Clock _ -> process_clock_message state |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment