Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions reference/FederatedBlinking.lf
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"
import LSM6DS33 from "./LSM6DS33.lf"

reactor SensorNode(id: int = 0) {
preamble {=
#define ORIENTATION_TO_TIME 12566.0f
#define OFFSET_ANGLE 12.566f // 2 * pi, to avoid division by zero
=}
led = new Led();
led = new LedController();
lsm6ds33 = new LSM6DS33();

logical action blink: int;
Expand Down
4 changes: 2 additions & 2 deletions reference/HelloUc.lf
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"

main reactor {
led = new Led();
led = new LedController();

timer t(10msec, 500msec)

Expand Down
2 changes: 1 addition & 1 deletion reference/Led.lf → reference/LedController.lf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ preamble {=
#include "led.h"
=}

reactor Led {
reactor LedController {
input toggle: int;
input set_state: bool;

Expand Down
4 changes: 2 additions & 2 deletions reference/Sensor.lf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"
import LSM6DS33 from "./LSM6DS33.lf"

preamble {=
Expand All @@ -10,7 +10,7 @@ preamble {=

@timeout(10s)
main reactor {
led = new Led();
led = new LedController();
lsm6ds33 = new LSM6DS33();

logical action blink: int;
Expand Down
4 changes: 2 additions & 2 deletions src/FederatedBlinking.lf
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"
import LSM6DS33 from "./LSM6DS33.lf"

reactor SensorNode(id: int = 0) {
preamble {=
#define ORIENTATION_TO_TIME 12566.0f
#define OFFSET_ANGLE 12.566f // 2 * pi, to avoid division by zero
=}
led = new Led();
led = new LedController();
lsm6ds33 = new LSM6DS33();

logical action blink: int;
Expand Down
4 changes: 2 additions & 2 deletions src/HelloUc.lf
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"

main reactor {
led = new Led();
led = new LedController();

timer t(10msec, 500msec)

Expand Down
2 changes: 1 addition & 1 deletion src/Led.lf → src/LedController.lf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ preamble {=
#include "led.h"
=}

reactor Led {
reactor LedController {
input toggle: int;
input set_state: bool;

Expand Down
4 changes: 2 additions & 2 deletions src/Sensor.lf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
target uC

import Led from "./Led.lf"
import LedController from "./LedController.lf"
import LSM6DS33 from "./LSM6DS33.lf"

preamble {=
Expand All @@ -9,7 +9,7 @@ preamble {=
=}

main reactor {
led = new Led();
led = new LedController();
lsm6ds33 = new LSM6DS33();

logical action blink: int;
Expand Down
Loading