Updating to latest simapi. Updating arduino sketches. Creating simlinks to simdata accordingly.
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
#include <FastLED.h>
|
#include <FastLED.h>
|
||||||
#include "../../monocoque/simulatorapi/simdata.h"
|
#include "simdata.h"
|
||||||
|
|
||||||
#define BYTE_SIZE sizeof(SimData)
|
#define SIMDATA_SIZE sizeof(SimData)
|
||||||
|
|
||||||
#define LED_PIN 7
|
#define LED_PIN 7
|
||||||
#define NUM_LEDS 6
|
#define NUM_LEDS 6
|
||||||
@@ -39,12 +39,12 @@ void setup()
|
|||||||
void loop()
|
void loop()
|
||||||
{
|
{
|
||||||
int l = 0;
|
int l = 0;
|
||||||
char buff[BYTE_SIZE];
|
char buff[SIMDATA_SIZE];
|
||||||
|
|
||||||
if (Serial.available() >= BYTE_SIZE)
|
if (Serial.available() >= SIMDATA_SIZE)
|
||||||
{
|
{
|
||||||
Serial.readBytes(buff, BYTE_SIZE);
|
Serial.readBytes(buff, SIMDATA_SIZE);
|
||||||
memcpy(&sd, &buff, BYTE_SIZE);
|
memcpy(&sd, &buff, SIMDATA_SIZE);
|
||||||
rpm = sd.rpms;
|
rpm = sd.rpms;
|
||||||
maxrpm = sd.maxrpm;
|
maxrpm = sd.maxrpm;
|
||||||
|
|
||||||
+1
@@ -0,0 +1 @@
|
|||||||
|
../../monocoque/simulatorapi/simapi/simapi/simdata.h
|
||||||
Symlink
+1
@@ -0,0 +1 @@
|
|||||||
|
../../monocoque/simulatorapi/simapi/simapi/simdata.h
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
#include <Adafruit_MotorShield.h>
|
#include <Adafruit_MotorShield.h>
|
||||||
#include "../../monocoque/simulatorapi/simdata.h"
|
#include "simdata.h"
|
||||||
|
|
||||||
#define BYTE_SIZE sizeof(SimData)
|
#define BYTE_SIZE sizeof(SimData)
|
||||||
#define KPHTOMPH .621317
|
#define KPHTOMPH .621317
|
||||||
|
|||||||
Submodule src/monocoque/simulatorapi/simapi updated: dca612c174...ee41c498ee
Reference in New Issue
Block a user