add: agent template

This commit is contained in:
Toolf
2024-02-02 22:51:54 +02:00
commit 1f92b43879
16 changed files with 1749 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
from marshmallow import Schema, fields
class AccelerometerSchema(Schema):
x = fields.Int()
y = fields.Int()
z = fields.Int()

View File

@@ -0,0 +1,9 @@
from marshmallow import Schema, fields
from schema.accelerometer_schema import AccelerometerSchema
from schema.gps_schema import GpsSchema
class AggregatedDataSchema(Schema):
accelerometer = fields.Nested(AccelerometerSchema)
gps = fields.Nested(GpsSchema)
time = fields.DateTime("iso")

View File

@@ -0,0 +1,6 @@
from marshmallow import Schema, fields
class GpsSchema(Schema):
longitude = fields.Number()
latitude = fields.Number()