This commit is contained in:
2026-04-17 14:55:32 -04:00
commit bc3ac1d4c9
18017 changed files with 4371742 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
using CANFDApiProxy.Messages;
namespace CANFDApiProxy.Requests
{
public class CANConfigRequest
{
public config config { get; set; }
public string Status { get; set; }
public override string ToString()
{
return $"config: {config}, Status: {Status}";
}
}
public class config
{
public CanConfigItem can1 { get; set; }
public CanConfigItem can2 { get; set; }
public CanConfigItem can3 { get; set; }
public CanConfigItem can4 { get; set; }
public override string ToString()
{
return $"can1: {can1}, can2: {can2}, can3: {can3}, can4: {can4}";
}
}
}

View File

@@ -0,0 +1,27 @@
namespace CANFDApiProxy.Requests
{
public class CanConfigItem
{
public CanConfigItem(int base_or_arb_bitrate, int base_or_arb_sjw, int data_bitrate, int data_sjw, string filetype, bool included, bool is_fd)
{
this.base_or_arb_bitrate = base_or_arb_bitrate;
this.base_or_arb_sjw = base_or_arb_sjw;
this.data_bitrate = data_bitrate;
this.data_sjw = data_sjw;
this.filetype = filetype;
this.included = included;
this.is_fd = is_fd;
}
public int base_or_arb_bitrate { get; set; }
public int base_or_arb_sjw { get; set; }
public int data_bitrate { get; set; }
public int data_sjw { get; set; }
public string filetype { get; set; }
public bool included { get; set; }
public bool is_fd { get; set; }
public override string ToString()
{
return $"baseBR: {base_or_arb_bitrate}, baseSJW: {base_or_arb_sjw}, br: {data_bitrate}, sjw: {data_sjw}, ft: {filetype}, inc: {included}, fd: {is_fd}";
}
}
}

View File

@@ -0,0 +1,7 @@
namespace CANFDApiProxy.Requests
{
internal class CanPostRequest
{
public string cmd { get; set; }
}
}

View File

@@ -0,0 +1,8 @@
namespace CANFDApiProxy.Requests
{
internal class ClocksRequest
{
public string cmd { get; set; }
public string time { get; set; }
}
}

View File

@@ -0,0 +1,8 @@
namespace CANFDApiProxy.Requests
{
internal class FileRequest
{
public string cmd { get; set; }
public string path { get; set; }
}
}

View File

@@ -0,0 +1,28 @@
namespace CANFDApiProxy.Requests
{
public class LEDsRequest
{
public string led { get; set; }
public string cmd { get; set; }
public string color { get; set; }
}
public enum LedColor
{
red,
green,
blue
}
public enum LedCmd
{
on,
off,
}
public enum LedName
{
can1, can2, can3, can4, pwr, sts, status
}
}

View File

@@ -0,0 +1,9 @@
namespace CANFDApiProxy.Requests
{
public class NetworkRequest
{
public bool dhcp { get; set; }
public string set_address { get; set; }
}
}

View File

@@ -0,0 +1,7 @@
namespace CANFDApiProxy.Requests
{
public class SerialRequest
{
public string serial { get; set; }
}
}