Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
ICBM
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
detectors
DSSC
ICBM
Commits
bfd3e709
Commit
bfd3e709
authored
1 year ago
by
Cyril Danilevski
Browse files
Options
Downloads
Patches
Plain Diff
Initialize SNMP
parent
7ad88faa
Loading
Loading
1 merge request
!2
Initial MPOD feature
Pipeline
#130951
failed
1 year ago
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
esp32_ethernet.cpp
+1
-1
1 addition, 1 deletion
esp32_ethernet.cpp
esp32_ethernet.hpp
+1
-1
1 addition, 1 deletion
esp32_ethernet.hpp
icbm.ino
+6
-4
6 additions, 4 deletions
icbm.ino
with
8 additions
and
6 deletions
esp32_ethernet.cpp
+
1
−
1
View file @
bfd3e709
...
@@ -44,7 +44,7 @@ void EthernetEvent(WiFiEvent_t event)
...
@@ -44,7 +44,7 @@ void EthernetEvent(WiFiEvent_t event)
}
}
}
}
void
connect
Network
()
void
initialize
Network
()
{
{
WiFi
.
onEvent
(
EthernetEvent
);
WiFi
.
onEvent
(
EthernetEvent
);
ETH
.
begin
(
ETH_ADDR
,
ETH_POWER_PIN
,
ETH_MDC_PIN
,
ETH_MDIO_PIN
,
ETH_TYPE
,
ETH_CLK_MODE
);
ETH
.
begin
(
ETH_ADDR
,
ETH_POWER_PIN
,
ETH_MDC_PIN
,
ETH_MDIO_PIN
,
ETH_TYPE
,
ETH_CLK_MODE
);
...
...
This diff is collapsed.
Click to expand it.
esp32_ethernet.hpp
+
1
−
1
View file @
bfd3e709
...
@@ -19,6 +19,6 @@ We use Ethernet, but reuse much of the networking utilities.
...
@@ -19,6 +19,6 @@ We use Ethernet, but reuse much of the networking utilities.
extern
bool
eth_connected
;
extern
bool
eth_connected
;
void
EthernetEvent
(
WiFiEvent_t
event
);
void
EthernetEvent
(
WiFiEvent_t
event
);
void
connect
Network
();
void
initialize
Network
();
#endif
#endif
This diff is collapsed.
Click to expand it.
icbm.ino
+
6
−
4
View file @
bfd3e709
#include
"esp32_ethernet.hpp"
#include
"esp32_ethernet.hpp"
#include
"rest.hpp"
#include
"rest.hpp"
//
#include "mpod.hpp"
#include
"mpod.hpp"
unsigned
long
start
;
unsigned
long
start
;
extern
bool
eth_connected
;
extern
bool
eth_connected
;
//
extern SNMP::Manager snmp;
extern
SNMP
::
Manager
snmp
;
void
setup
()
{
void
setup
()
{
Serial
.
begin
(
115200
);
Serial
.
begin
(
115200
);
connect
Network
();
initialize
Network
();
while
(
!
eth_connected
)
{
while
(
!
eth_connected
)
{
Serial
.
print
(
"-"
);
Serial
.
print
(
"-"
);
delay
(
100
);
delay
(
100
);
...
@@ -18,6 +18,8 @@ void setup() {
...
@@ -18,6 +18,8 @@ void setup() {
initializeRoutes
();
initializeRoutes
();
Serial
.
println
(
"Started REST server"
);
Serial
.
println
(
"Started REST server"
);
initializeSNMP
();
Serial
.
println
(
"Started SNMP server"
);
start
=
millis
();
start
=
millis
();
}
}
...
@@ -47,7 +49,7 @@ void serial_loop() {
...
@@ -47,7 +49,7 @@ void serial_loop() {
void
loop
()
{
void
loop
()
{
// Manager loop function must be called to process incoming messages
// Manager loop function must be called to process incoming messages
//
snmp.loop();
snmp
.
loop
();
restServer
.
handleClient
();
restServer
.
handleClient
();
serial_loop
();
serial_loop
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment