This commit is contained in:
Diego Freitas 2025-07-16 13:47:56 -03:00
parent fa60088811
commit a7eb0287ed
50 changed files with 196 additions and 185 deletions

Binary file not shown.

View File

@ -316,7 +316,7 @@ namespace AgroBase.Models
// Ajustar o ponto médio com o deslocamento lateral
var anguloEntrePontos = CalcularOrientacao(P1, P2); // Angulo entre os dois pontos
var anguloPerpendicular = anguloEntrePontos + 90; // Perpendicular à direção da rua
var anguloPerpendicular = anguloEntrePontos - 90; // Perpendicular à direção da rua
// Aplicar deslocamento lateral
return MoverPonto(pontoMedio, deslocamentoLateralGPS, anguloPerpendicular);

View File

@ -9,6 +9,7 @@ using System.Data;
using static AgroBase.Services.LoRaEspService;
using System.Windows.Forms;
using AgroBase.Services.Operadores;
using AgroBase.Models.Operadores;
namespace AgroBase.Models.Modules
{
@ -1996,6 +1997,9 @@ namespace AgroBase.Models.Modules
private void AtualizaComponentesIniciados()
{
AtualizarStatusComponentes();
return;
DateTime Agora = DateTime.Now;
bool modConectado = DadosLeitura.UltimoComandoRespondido.AddMilliseconds(TempoLimiteConexao) > Agora;
if (!modConectado && DadosLeitura.Conectado)
@ -2020,6 +2024,73 @@ namespace AgroBase.Models.Modules
}
}
public void AtualizarStatusComponentes()
{
var StatusSaudaveis = new List<StatusModulo>() { StatusModulo.Desconectado, StatusModulo.Falha };
var saudeSen = RedisService.GetField<ManagerWorkerMessageResponseModulosPendentesSaudeModel>(RedisService.ModKey(T_Code.Sen), "saude");
DadosLeitura.Conectado = !StatusSaudaveis.Contains(saudeSen?.status ?? StatusModulo.Desconectado);
if (DadosLeitura.Conectado)
{
var objetos =
Sensores
.Select(x => new
{
Chave = "sensores",
Componente = x.Componente,
ID_Num = x.ID_Num
})
.Union(Servos
.Select(x => new
{
Chave = "servos",
Componente = x.Componente,
ID_Num = x.ID_Num
}))
.ToList();
foreach (var sensor in objetos)
{
string chave = sensor.Chave;
int tipo = (int)sensor.Componente;
int id = sensor.ID_Num;
string basePath = $"{chave}.{tipo}.{id}";
var saude = RedisService.GetField<ManagerWorkerMessageResponseModulosPendentesSaudeModel>(RedisService.ModKey(T_Code.Sen), $"{basePath}.saude");
bool inicializado = !StatusSaudaveis.Contains(saude?.status ?? StatusModulo.Desconectado);
switch (chave)
{
case "sensores":
Sensores.FirstOrDefault(x => x.ID_Num == sensor.ID_Num).Inicializado = inicializado;
break;
case "servos":
Servos.FirstOrDefault(x => x.ID_Num == sensor.ID_Num).Inicializado = inicializado;
break;
}
}
}
else
{
foreach (var led in Sinaleiros.Where(x => x.Inicializado))
{
led.Inicializado = false;
}
foreach (var rele in Reles.Where(x => x.Inicializado))
{
rele.Inicializado = false;
}
foreach (var servo in Servos.Where(x => x.Inicializado))
{
servo.Inicializado = false;
}
foreach (var sensor in Sensores.Where(x => x.Inicializado))
{
sensor.Inicializado = false;
}
}
}
}
public class SensorModel

View File

@ -645,7 +645,8 @@ namespace AgroBase.Models
// Calcula o deslocamento lateral do GPS
double larguraTotal = VariaveisEquipamento.LarguraEsquerda + VariaveisEquipamento.LarguraDireita; // Largura total do robô
double deslocamentoLateralGPS = ((VariaveisEquipamento.LarguraEsquerda - VariaveisEquipamento.LarguraDireita) / larguraTotal) / 2.0;
double deslocamentoLateralGPSpercentual = ((Math.Abs(VariaveisEquipamento.LarguraEsquerda - VariaveisEquipamento.LarguraDireita) / larguraTotal) / 2.0);
double deslocamentoLateralGPSmetros = (LarguraCorredorPadrao * deslocamentoLateralGPSpercentual);
if (Variaveis.OperacaoEmAndamento.Mapa.TipoMapa == TipoMapaOperacao.Corredores)
{
@ -688,8 +689,8 @@ namespace AgroBase.Models
//var pontoMedioInicial = GPSUtils.PontoMedio(ponto1Rua1, ponto1Rua2);
//var pontoMedioFinal = GPSUtils.PontoMedio(ponto2Rua1, ponto2Rua2);
var pontoMedioInicial = GPSUtils.PontoMedioComOffset(ponto1Rua1, ponto1Rua2, deslocamentoLateralGPS);
var pontoMedioFinal = GPSUtils.PontoMedioComOffset(ponto2Rua1, ponto2Rua2, deslocamentoLateralGPS);
var pontoMedioInicial = GPSUtils.PontoMedioComOffset(ponto1Rua1, ponto1Rua2, deslocamentoLateralGPSmetros);
var pontoMedioFinal = GPSUtils.PontoMedioComOffset(ponto2Rua1, ponto2Rua2, deslocamentoLateralGPSmetros);
var distancia = GPSUtils.DistanciaEntrePontos(pontoMedioInicial, pontoMedioFinal);
if (EspacamentoPrimeirosPontosProjecao && j == 0)

View File

@ -91,10 +91,10 @@ namespace AgroBase.Models
public static class VariaveisEquipamento
{
public static double LarguraEsquerda { get; } = 62.0;
public static double LarguraDireita { get; } = 22.0;
public static double ComprimentoFrente { get; } = 7.0;
public static double ComprimentoTras { get; } = 107.0;
public static double LarguraEsquerda { get; } = 44.0; // 62
public static double LarguraDireita { get; } = 44.0; // 22
public static double ComprimentoFrente { get; } = 7.0; // 7
public static double ComprimentoTras { get; } = 107.0; // 107
public static double DistanciaEntreEixos { get; } = 92.0;
public static double LarguraEquipamentoMm
{

View File

@ -1,3 +1,8 @@
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:37 Widget Closed: StatusBubble
0:03:45 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
@ -10,8 +15,60 @@
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:17 Widget Closed: StatusBubble
0:37:43 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:03:54 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:06:58 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:23 Widget Closed: StatusBubble
0:05:00 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:07:03 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:03:26 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
@ -25,119 +82,4 @@
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:26 Widget Closed: StatusBubble
1:06:55 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:21 Widget Closed: StatusBubble
0:05:18 Widget Closed: StatusBubble
0:08:17 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
3:37:51 Widget Closed: StatusBubble
6:54:19 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:30:02 Widget Closed: StatusBubble
1:24:04 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:41 Widget Closed: StatusBubble
0:02:00 Widget Closed: StatusBubble
0:06:37 Widget Closed: StatusBubble
4:46:27 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:05:25 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:22 Widget Closed: StatusBubble
0:03:52 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:10 Widget Closed: StatusBubble
0:03:06 Widget Closed: StatusBubble
0:16:21 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:00:00 Startup
0:00:00 Microsoft.DeleteProfileHelper.CleanUpEphemeralProfiles
0:00:00 Microsoft.DeleteProfileHelper.CleanUpDeletedProfiles
0:00:00 Microsoft.NewBrowser_Popup
0:00:00 Microsoft.BrowserList.AddBrowser
0:00:00 Browser1 Insert active Tab1 at 0
0:00:00 Tab1 StartNav1 #auto_toplevel
0:00:00 Tab1 StartNav2 #typed
0:00:00 Tab1 FinishNav1
0:00:00 Tab1 PageLoad
0:00:00 Tab1 FinishNav2
0:00:00 Tab1 PageLoad
0:00:36 Widget Closed: StatusBubble
0:04:19 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp
0:04:32 Microsoft.UnloadController.IsUnclosableApp_IsNotWebApp

View File

@ -1,12 +1,5 @@
{
"epochs": [ {
"calculation_time": "13394567869286013",
"config_version": 0,
"model_version": "0",
"padded_top_topics_start_index": 0,
"taxonomy_version": 0,
"top_topics_and_observing_domains": [ ]
}, {
"calculation_time": "13395172669289149",
"config_version": 0,
"model_version": "0",
@ -29,5 +22,5 @@
"top_topics_and_observing_domains": [ ]
} ],
"hex_encoded_hmac_key": "40F346D3248C3AFDF2BEE1FE496DBD32F7CED6E5AE98B881ABC421AA7E7B5642",
"next_scheduled_calculation_time": "13397222167014715"
"next_scheduled_calculation_time": "13397222167015122"
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

View File

@ -1,3 +1,3 @@
2025/07/11-13:13:55.663 6de4 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/MANIFEST-000001
2025/07/11-13:13:55.671 6de4 Recovering log #3
2025/07/11-13:13:55.675 6de4 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/000003.log
2025/07/15-10:59:35.513 20f8 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/MANIFEST-000001
2025/07/15-10:59:35.519 20f8 Recovering log #3
2025/07/15-10:59:35.522 20f8 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/000003.log

View File

@ -1,3 +1,3 @@
2025/07/11-12:34:04.813 7d74 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/MANIFEST-000001
2025/07/11-12:34:04.820 7d74 Recovering log #3
2025/07/11-12:34:04.824 7d74 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/000003.log
2025/07/15-10:55:59.616 7650 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/MANIFEST-000001
2025/07/15-10:55:59.621 7650 Recovering log #3
2025/07/15-10:55:59.624 7650 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Local Storage\leveldb/000003.log

View File

@ -1 +1 @@
{"net":{"http_server_properties":{"servers":[{"alternative_service":[{"advertised_alpns":["h3"],"expiration":"13396810500919879","port":443,"protocol_str":"quic"}],"anonymization":["DAAAAAcAAABmaWxlOi8vAA==",false,0],"network_stats":{"srtt":6500},"server":"https://tile.openstreetmap.org","supports_spdy":true}],"supports_quic":{"address":"2804:d78:60b:6f00:1cb:7dd5:9647:ea0","used_quic":true},"version":5},"network_qualities":{"CAASABiAgICA+P////8B":"4G","CAESABiAgICA+P////8B":"4G","CAISABiAgICA+P////8B":"4G","CAYSABiAgICA+P////8B":"Offline"}}}
{"net":{"http_server_properties":{"servers":[{"alternative_service":[{"advertised_alpns":["h3"],"expiration":"13397147980670604","port":443,"protocol_str":"quic"}],"anonymization":["DAAAAAcAAABmaWxlOi8vAA==",false,0],"network_stats":{"srtt":16322},"server":"https://tile.openstreetmap.org","supports_spdy":true}],"supports_quic":{"address":"2804:d78:69a:2400:148f:27bb:6ddf:e76e","used_quic":true},"version":5},"network_qualities":{"CAASABiAgICA+P////8B":"4G","CAESABiAgICA+P////8B":"4G","CAISABiAgICA+P////8B":"4G","CAYSABiAgICA+P////8B":"Offline"}}}

View File

@ -1 +1 @@
{"sts":[{"expiry":1783786447.236962,"host":"bWGAftl61rqoc0YzqPncsLvQQh/iC2Bdp3ejUeGC83w=","mode":"force-https","sts_include_subdomains":true,"sts_observed":1752250447.236964}],"version":2}
{"sts":[{"expiry":1784123980.089538,"host":"bWGAftl61rqoc0YzqPncsLvQQh/iC2Bdp3ejUeGC83w=","mode":"force-https","sts_include_subdomains":true,"sts_observed":1752587980.089546}],"version":2}

File diff suppressed because one or more lines are too long

View File

@ -1,3 +1,3 @@
2025/07/11-13:18:15.006 6de4 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/MANIFEST-000001
2025/07/11-13:18:15.007 6de4 Recovering log #3
2025/07/11-13:18:15.010 6de4 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/000003.log
2025/07/15-11:04:07.980 20f8 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/MANIFEST-000001
2025/07/15-11:04:07.981 20f8 Recovering log #3
2025/07/15-11:04:07.984 20f8 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/000003.log

View File

@ -1,3 +1,3 @@
2025/07/11-12:50:26.119 7d74 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/MANIFEST-000001
2025/07/11-12:50:26.121 7d74 Recovering log #3
2025/07/11-12:50:26.124 7d74 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/000003.log
2025/07/15-10:59:26.291 7650 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/MANIFEST-000001
2025/07/15-10:59:26.292 7650 Recovering log #3
2025/07/15-10:59:26.296 7650 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Session Storage/000003.log

View File

@ -1,3 +1,3 @@
2025/07/11-13:13:55.583 58ac Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/MANIFEST-000001
2025/07/11-13:13:55.584 58ac Recovering log #3
2025/07/11-13:13:55.585 58ac Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/000003.log
2025/07/15-10:59:35.436 c94 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/MANIFEST-000001
2025/07/15-10:59:35.438 c94 Recovering log #3
2025/07/15-10:59:35.438 c94 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/000003.log

View File

@ -1,3 +1,3 @@
2025/07/11-12:34:04.743 6ec0 Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/MANIFEST-000001
2025/07/11-12:34:04.744 6ec0 Recovering log #3
2025/07/11-12:34:04.745 6ec0 Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/000003.log
2025/07/15-10:55:59.540 289c Reusing MANIFEST C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/MANIFEST-000001
2025/07/15-10:55:59.542 289c Recovering log #3
2025/07/15-10:55:59.542 289c Reusing old log C:\ZendionInc\agrobot_base\AgroBase\AgroBase\bin\x64\Debug\AgroBase.exe.WebView2\EBWebView\Default\Site Characteristics Database/000003.log

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -17,7 +17,7 @@
<meta name="viewport" content="width=device-width,
initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<style>
#map_39d27959b1fc1cb5cb3c6de500d93c6d {
#map_b39f02e9c9b5efc4d911abcf4156d114 {
position: relative;
width: 100.0%;
height: 100.0%;
@ -54,14 +54,14 @@
<body>
<div class="folium-map" id="map_39d27959b1fc1cb5cb3c6de500d93c6d" ></div>
<div class="folium-map" id="map_b39f02e9c9b5efc4d911abcf4156d114" ></div>
</body>
<script>
var map_39d27959b1fc1cb5cb3c6de500d93c6d = L.map(
"map_39d27959b1fc1cb5cb3c6de500d93c6d",
var map_b39f02e9c9b5efc4d911abcf4156d114 = L.map(
"map_b39f02e9c9b5efc4d911abcf4156d114",
{
center: [-22.172636164916668, -47.395186322185666],
crs: L.CRS.EPSG3857,
@ -78,7 +78,7 @@
var tile_layer_50ab02404f84c21185caef2ccb107aa7 = L.tileLayer(
var tile_layer_1a1c03b051431c7d8998396727e78894 = L.tileLayer(
"https://tile.openstreetmap.org/{z}/{x}/{y}.png",
{
"minZoom": 0,
@ -95,7 +95,7 @@
);
tile_layer_50ab02404f84c21185caef2ccb107aa7.addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
tile_layer_1a1c03b051431c7d8998396727e78894.addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
@ -111,7 +111,7 @@
}*/
});
}
function geo_json_c03a7237de315e7e5f491adbe62a9542_onEachFeature(feature, layer) {
function geo_json_e5fd83afc4f062d8fa93135e69bddab5_onEachFeature(feature, layer) {
layer.on({
@ -148,23 +148,23 @@
}*/
});
};
var geo_json_c03a7237de315e7e5f491adbe62a9542 = L.geoJson(null, {
onEachFeature: geo_json_c03a7237de315e7e5f491adbe62a9542_onEachFeature,
var geo_json_e5fd83afc4f062d8fa93135e69bddab5 = L.geoJson(null, {
onEachFeature: geo_json_e5fd83afc4f062d8fa93135e69bddab5_onEachFeature,
...{
}
});
function geo_json_c03a7237de315e7e5f491adbe62a9542_add (data) {
geo_json_c03a7237de315e7e5f491adbe62a9542
function geo_json_e5fd83afc4f062d8fa93135e69bddab5_add (data) {
geo_json_e5fd83afc4f062d8fa93135e69bddab5
.addData(data);
}
geo_json_c03a7237de315e7e5f491adbe62a9542_add({"features": [{"geometry": {"coordinates": [[-47.395205344, -22.172559531333334], [-47.395212610166666, -22.172614638833334], [-47.395219157, -22.172656417833334], [-47.395223544833335, -22.1726892105], [-47.39522414098443, -22.17269369161165], [-47.395225326538004, -22.172702654611555]], "id": null, "type": "LineString"}, "id": 0, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "1", "Length": 14.558011415731592, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.39521090233333, -22.172708800833334], [-47.395206943666665, -22.172679811], [-47.395202420666664, -22.1726491015], [-47.395198865666664, -22.172615782833333], [-47.395193255833334, -22.172577132833332], [-47.395192610024395, -22.17257265769541], [-47.395191325698136, -22.172563706509337]], "id": null, "type": "LineString"}, "id": 1, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "2", "Length": 14.771318274761821, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.3951762925, -22.172561603], [-47.395180824166665, -22.172591686166665], [-47.395185745333336, -22.172623080166666], [-47.395190433, -22.172656367166667], [-47.395195199, -22.172693641833334], [-47.39519576904436, -22.172698125891035], [-47.39519690267159, -22.172707094716973]], "id": null, "type": "LineString"}, "id": 2, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "3", "Length": 14.827915524386164, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.39518293216667, -22.1727127985], [-47.39517819266667, -22.172680514833335], [-47.3951732595, -22.172646752833334], [-47.39516880516667, -22.1726149155], [-47.39516381233334, -22.172581167166665], [-47.39516315429932, -22.172576693573966], [-47.39516184565584, -22.172567745443878]], "id": null, "type": "LineString"}, "id": 3, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "4", "Length": 14.785159385903514, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.395147317833334, -22.172566031], [-47.395151503166666, -22.172595452333333], [-47.3951561855, -22.172628011166665], [-47.39516159866667, -22.172663757333332], [-47.39516672716667, -22.172697770833334], [-47.395167397572706, -22.172702242832194], [-47.39516873082615, -22.17271118781009]], "id": null, "type": "LineString"}, "id": 4, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "5", "Length": 14.80117692191233, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}], "type": "FeatureCollection"});
geo_json_c03a7237de315e7e5f491adbe62a9542.setStyle(function(feature) {return feature.properties.style;});
geo_json_e5fd83afc4f062d8fa93135e69bddab5_add({"features": [{"geometry": {"coordinates": [[-47.395205344, -22.172559531333334], [-47.395212610166666, -22.172614638833334], [-47.395219157, -22.172656417833334], [-47.395223544833335, -22.1726892105], [-47.39522414098443, -22.17269369161165], [-47.395225326538004, -22.172702654611555]], "id": null, "type": "LineString"}, "id": 0, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "1", "Length": 14.558011415731592, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.39521090233333, -22.172708800833334], [-47.395206943666665, -22.172679811], [-47.395202420666664, -22.1726491015], [-47.395198865666664, -22.172615782833333], [-47.395193255833334, -22.172577132833332], [-47.395192610024395, -22.17257265769541], [-47.395191325698136, -22.172563706509337]], "id": null, "type": "LineString"}, "id": 1, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "2", "Length": 14.771318274761821, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.3951762925, -22.172561603], [-47.395180824166665, -22.172591686166665], [-47.395185745333336, -22.172623080166666], [-47.395190433, -22.172656367166667], [-47.395195199, -22.172693641833334], [-47.39519576904436, -22.172698125891035], [-47.39519690267159, -22.172707094716973]], "id": null, "type": "LineString"}, "id": 2, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "3", "Length": 14.827915524386164, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.39518293216667, -22.1727127985], [-47.39517819266667, -22.172680514833335], [-47.3951732595, -22.172646752833334], [-47.39516880516667, -22.1726149155], [-47.39516381233334, -22.172581167166665], [-47.39516315429932, -22.172576693573966], [-47.39516184565584, -22.172567745443878]], "id": null, "type": "LineString"}, "id": 3, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "4", "Length": 14.785159385903514, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}, {"geometry": {"coordinates": [[-47.395147317833334, -22.172566031], [-47.395151503166666, -22.172595452333333], [-47.3951561855, -22.172628011166665], [-47.39516159866667, -22.172663757333332], [-47.39516672716667, -22.172697770833334], [-47.395167397572706, -22.172702242832194], [-47.39516873082615, -22.17271118781009]], "id": null, "type": "LineString"}, "id": 4, "properties": {"Dist1": 14.558011415731592, "Dist2": 0.0, "Id": "5", "Length": 14.80117692191233, "Name": "CidadeJardimTerreno2"}, "type": "Feature"}], "type": "FeatureCollection"});
geo_json_e5fd83afc4f062d8fa93135e69bddab5.setStyle(function(feature) {return feature.properties.style;});
geo_json_c03a7237de315e7e5f491adbe62a9542.addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
geo_json_e5fd83afc4f062d8fa93135e69bddab5.addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
</script>
@ -185,7 +185,7 @@
}
trajeto_json_add({"features": []});
trajeto_json.addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
trajeto_json.addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
function adicionarGeometria(novaGeometria) {
trajeto_json.addData(novaGeometria);
@ -243,7 +243,7 @@
}
trajeto_dinamico_json_add({"features": []});
trajeto_dinamico_json.addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
trajeto_dinamico_json.addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
function adicionarGeometriaDinamica(novaGeometria) {
trajeto_dinamico_json.addData(novaGeometria);
@ -296,9 +296,9 @@
var marcadorEquipamento = L.marker([0, 0], {
icon: customIcon
}).addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
}).addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
var marcadorBase = L.marker([0, 0], {}).addTo(map_39d27959b1fc1cb5cb3c6de500d93c6d);
var marcadorBase = L.marker([0, 0], {}).addTo(map_b39f02e9c9b5efc4d911abcf4156d114);
var icon = L.AwesomeMarkers.icon(
{"extraClasses": "fa-rotate-0", "icon": "info-sign", "iconColor": "white", "markerColor": "red", "prefix": "glyphicon"}
);
@ -380,7 +380,7 @@
}
if (foco) {
map_39d27959b1fc1cb5cb3c6de500d93c6d.setView(novaPosicao, map_39d27959b1fc1cb5cb3c6de500d93c6d.getZoom());
map_b39f02e9c9b5efc4d911abcf4156d114.setView(novaPosicao, map_b39f02e9c9b5efc4d911abcf4156d114.getZoom());
}
}
@ -397,7 +397,7 @@
function atualizarSelecaoRuas(selecionadas) {
selecionadas = JSON.parse(selecionadas);
RuasSelecionadas = Array.isArray(selecionadas) ? [...selecionadas] : [];
geo_json_c03a7237de315e7e5f491adbe62a9542.eachLayer(function (layer) {
geo_json_e5fd83afc4f062d8fa93135e69bddab5.eachLayer(function (layer) {
if (RuasSelecionadas.includes(parseInt(layer.feature.id))) {
layer.setStyle({ color: 'blue' });
} else {

View File

@ -1031,13 +1031,15 @@ class ControladorMPC:
try:
agora = time.time()
self.dt = 0.25 if self.ultima_atualizacao is None else agora - self.ultima_atualizacao
self.dt = max(min(self.dt, 0.4), 0.1)
#self.dt = max(min(self.dt, 0.4), 0.1)
_dt = self.dt
freq_tick = 1.0 / _dt
self.dt = 0.5
self.ultima_atualizacao = agora
comando = self._processar_mpc_receding(contexto, comando_anterior)
t_exec = max((time.time() - self.ultima_atualizacao), 1e-3)
mostrar_log(f"🧭 Direcional MPC | Parada: {comando['parada_necessaria']} | Movimento: {TipoMovimentoDirecional(comando['tipo']).name} | Ângulo: {comando['angulo']}° | Horizonte: {len(comando['simulacao'])} | dt: {self.dt:.2f} s | freq = {(1.0 / self.dt):.2f} Hz | t_exec: {t_exec:.2} s | f_exec: {(1.0 / t_exec):.2f} Hz")
mostrar_log(f"🧭 Direcional MPC | Parada: {comando['parada_necessaria']} | Movimento: {TipoMovimentoDirecional(comando['tipo']).name} | Ângulo: {comando['angulo']}° | Horizonte: {len(comando['simulacao'])} | dt: {_dt:.2f} s | freq = {(freq_tick):.2f} Hz | t_exec: {t_exec:.2} s | f_exec: {(1.0 / t_exec):.2f} Hz")
return comando
except Exception as e:
@ -1101,7 +1103,7 @@ class ControladorMPC:
def simular_e_gerar(candidato, tipo, angulo):
try:
custo, sim, valido = self._simular_passo(x_atual, y_atual, theta_atual, tipo, angulo, custos_candidatos, cmd_anterior, contexto, deepcopy(visitados))
print(f"{tipo.name} | angulo: {np.degrees(angulo):.2f} : Custo: {custo}")
#print(f"{tipo.name} | angulo: {np.degrees(angulo):.2f} : Custo: {custo}")
x_f, y_f, theta_f = sim[-1]
if valido:
return {
@ -1129,12 +1131,12 @@ class ControladorMPC:
# Filtro opcional: limitar para os N melhores candidatos
candidatos_ativos = self._selecionar_melhores(novos_candidatos, N=5)
candidatos_ativos = self._filtrar_por_margem_angular(candidatos_ativos, margem_graus=2.0)
print("Melhores candidatos filtrados:")
#print("Melhores candidatos filtrados:")
for i, c in enumerate(candidatos_ativos):
comando = c["comandos"][-1] if c["comandos"] else ("-", 0)
tipo = comando[0]
angulo = np.degrees(comando[1])
print(f"{i+1}. Tipo: {tipo.name if hasattr(tipo, 'name') else tipo}, Angulo: {round(angulo, 2)}, Custo: {round(c['custo'], 4)}")
#print(f"{i+1}. Tipo: {tipo.name if hasattr(tipo, 'name') else tipo}, Angulo: {round(angulo, 2)}, Custo: {round(c['custo'], 4)}")
t5 = time.time()
#print(f"Passo {passo} simulado em {t5 - t1} segundos")
@ -1187,8 +1189,10 @@ class ControladorMPC:
if manobrando or status in [ StatusCarroMapa.EntrandoRua, StatusCarroMapa.SaindoRua, StatusCarroMapa.Manobrando ]:
tipos_validos = [ TipoMovimentoDirecional.MovimentoArco ]
else:
elif np.degrees(delta_theta) > 10.0:
tipos_validos = [ TipoMovimentoDirecional.RodasDianteiras, TipoMovimentoDirecional.MovimentoArco ]
else:
tipos_validos = [ TipoMovimentoDirecional.RodasDianteiras ]
com_matriz_custo = contexto.get("VisualWorker", {}).get("Operante", False)
angulos_raw = self._gerar_candidatos_brutos(angulo_ideal_deg, com_matriz_custo)

View File

@ -23,7 +23,7 @@ class SegmentacaoManager:
self.classes = None
self.color_map = None
self.carregado = False
self.use_mock = True
self.use_mock = False
self.img_mock = "C:\\ZendionInc\\agrobot_base\\Treinamento\\models\\ruas\\dataset\\images\\55.jpeg"
self._carregar_modelo()

Binary file not shown.