From e12bd4e9832f25a66baa759c092c4bb7b1986ea2 Mon Sep 17 00:00:00 2001 From: David Date: Wed, 22 Feb 2017 22:22:12 +0000 Subject: [PATCH] test --- src/testflockfev.bzz | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/testflockfev.bzz b/src/testflockfev.bzz index 7454517..dd2ea87 100644 --- a/src/testflockfev.bzz +++ b/src/testflockfev.bzz @@ -13,7 +13,7 @@ neighbors.broadcast(updated, update_no) } TARGET_ALTITUDE = 5.0 -CURSTATE = TURNEDOFF +CURSTATE = "TURNEDOFF" # Lennard-Jones parameters TARGET = 10.0 #0.000001001 @@ -37,7 +37,7 @@ function lj_sum(rid, data, accum) { # Calculates and actuates the flocking interaction function hexagon() { statef=hexagon - CURSTATE=HEXAGON + CURSTATE = "HEXAGON" # Calculate accumulator var accum = neighbors.map(lj_vector).reduce(lj_sum, math.vec2.new(0.0, 0.0)) if(neighbors.count() > 0) @@ -91,7 +91,7 @@ function barrier_wait(threshold, transf) { function idle() { statef=idle -CURSTATE=IDLE +CURSTATE = "IDLE" neighbors.listen("cmd", function(vid, value, rid) { print("Got (", vid, ",", value, ") from robot #", rid) @@ -132,7 +132,7 @@ function land() { # Executed once at init time. function init() { statef=idle - CURSTATE=IDLE + CURSTATE = "IDLE" } # Executed at each time step. @@ -142,14 +142,14 @@ function step() { log("cmd 22") flight.rc_cmd=0 statef = takeoff - CURSTATE = TAKEOFF + CURSTATE = "TAKEOFF" neighbors.broadcast("cmd", 22) } else if(flight.rc_cmd==21) { log("cmd 21") log("To land") flight.rc_cmd=0 statef = land - CURSTATE = LAND + CURSTATE = "LAND" neighbors.broadcast("cmd", 21) } else if(flight.rc_cmd==16) { flight.rc_cmd=0