Skip to content

Commit

Permalink
#37: include the client SSID in the status page
Browse files Browse the repository at this point in the history
  • Loading branch information
andreas committed Mar 21, 2024
1 parent bfc6af1 commit efd23b0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -410,14 +410,15 @@ class StatusRequest : public GwRequestMessage
protected:
virtual void processRequest()
{
GwJsonDocument status(300 +
GwJsonDocument status(305 +
countNMEA2KIn.getJsonSize()+
countNMEA2KOut.getJsonSize() +
channels.getJsonSize()+
userCodeHandler.getJsonSize()
);
status["version"] = VERSION;
status["wifiConnected"] = gwWifi.clientConnected();
status["wifiSSID"] = config.getString(GwConfigDefinitions::wifiSSID);
status["clientIP"] = WiFi.localIP().toString();
status["apIp"] = gwWifi.apIP();
size_t bsize=2*sizeof(unsigned long)+1;
Expand Down
2 changes: 1 addition & 1 deletion web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ <h1 id="headline">NMEA 2000 Gateway </h1>
</div>
<div class="row ">
<span class="label">wifi client connected</span>
<span class="value" id="wifiConnected">---</span>
<span class="value" id="wifiConnected">---</span>&nbsp;[<span class="value" id="wifiSSID">---</span>]
</div>
<div class="row even">
<span class="label">wifi client IP</span>
Expand Down

0 comments on commit efd23b0

Please sign in to comment.