Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
paulbourelly999 committed Jul 22, 2024
1 parent 5ee6df6 commit 63e0df0
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/tmx/Messages/test/TestTimeSyncMessage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ namespace tmx::messages {
TEST(TestTimeSyncMessage, to_string) {
TimeSyncMessage msg(20, 30);
std::string json = "{ \"timestep\":20, \"seq\":30}";
ASSERT_EQ( json, msg.to_string());
EXPECT_EQ( json, msg.to_string());
}
}
2 changes: 1 addition & 1 deletion src/v2i-hub/CDASimAdapter/scripts/send_timestep_udp.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def generate_time_sync():
count_num += 1
sock.sendto(encoded_msg,host)
print( encoded_msg.decode(encoding= 'UTF-8'), 'was sent to ', host)
time.sleep(5)
time.sleep(.1)
except socket.gaierror:

print ('There an error resolving the host')
Expand Down
3 changes: 3 additions & 0 deletions src/v2i-hub/SpatPlugin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ This plugin has several configuration parameters. Below these are listed out as
**TSC_Remote_SNMP_Port**: The destination port on the Traffic Signal Controller (TSC) for SNMP NTCIP communication."

**SPAT_Mode**: The format of received SPAT from Traffic Signal Controller (TSC). Acceptance values are BINARY and J2735_HEX.
> [!NOTE]
> **J2735_HEX** is a new added SPAT format. If your TSC is able to send UPER SPAT directly to an RSU, this is the format in which it is being sent. Below is a screen shot of J2735_HEX SPaT via TCP Dump
![Alt text](docs/hex_tcpdump.png)

## Design

Expand Down
Binary file added src/v2i-hub/SpatPlugin/docs/hex_tcpdump.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/v2i-hub/SpatPlugin/src/SignalControllerConnection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

namespace SpatPlugin {

SignalControllerConnection::SignalControllerConnection(const std::string &localIp, unsigned int localPort, const std::string &signalGroupMapping, const std::string &scIp, unsigned int scSNMPPort, const std::string &intersectionName, unsigned int intersectionId) : spatPacketReceiver(std::make_unique<tmx::utils::UdpServer>(localIp, localPort)) ,scSNMPClient(std::make_unique<tmx::utils::snmp_client>(scIp, scSNMPPort ,"administrator", "", "", "")), signalGroupMapping(signalGroupMapping), intersectionName(intersectionName), intersectionId(intersectionId) {
SignalControllerConnection::SignalControllerConnection(const std::string &localIp, unsigned int localPort, const std::string &signalGroupMapping, const std::string &scIp, unsigned int scSNMPPort, const std::string &intersectionName, unsigned int intersectionId) : spatPacketReceiver(std::make_shared<tmx::utils::UdpServer>(localIp, localPort)) ,scSNMPClient(std::make_shared<tmx::utils::snmp_client>(scIp, scSNMPPort ,"administrator", "", "", "")), signalGroupMapping(signalGroupMapping), intersectionName(intersectionName), intersectionId(intersectionId) {

};
bool SignalControllerConnection::initializeSignalControllerConnection() const {
Expand Down

0 comments on commit 63e0df0

Please sign in to comment.