mirror of
https://github.com/cesanta/mongoose.git
synced 2024-12-28 07:28:13 +08:00
remove references to MIP in examples (comments)
This commit is contained in:
parent
21dbfd79d8
commit
33a3fe9bbd
@ -9,7 +9,7 @@ struct mg_tcpip_spi spi = {
|
||||
[](void *) { digitalWrite(SS_PIN, HIGH); }, // end transaction
|
||||
[](void *, uint8_t c) { return SPI.transfer(c); }, // execute transaction
|
||||
};
|
||||
struct mg_tcpip_if mif = {.mac = {2, 0, 1, 2, 3, 5}}; // MIP network interface
|
||||
struct mg_tcpip_if mif = {.mac = {2, 0, 1, 2, 3, 5}}; // network interface
|
||||
|
||||
void setup() {
|
||||
Serial.begin(115200);
|
||||
|
@ -24,10 +24,10 @@ int main(void) {
|
||||
stdio_init_all();
|
||||
|
||||
struct mg_mgr mgr; // Initialise Mongoose event manager
|
||||
mg_mgr_init(&mgr); // and attach it to the MIP interface
|
||||
mg_mgr_init(&mgr); // and attach it to the interface
|
||||
mg_log_set(MG_LL_DEBUG); // Set log level
|
||||
|
||||
MG_INFO(("Init MIP"));
|
||||
MG_INFO(("Init TCP/IP"));
|
||||
// Initialise Mongoose network stack and specific driver
|
||||
// Set consecutive GPIOs for RMII (tx and rx) and SMI function groups
|
||||
struct mg_tcpip_driver_rp2040_rmii_data driver_data = {
|
||||
|
@ -53,7 +53,7 @@ int main(void) {
|
||||
stdio_init_all();
|
||||
|
||||
struct mg_mgr mgr; // Initialise Mongoose event manager
|
||||
mg_mgr_init(&mgr); // and attach it to the MIP interface
|
||||
mg_mgr_init(&mgr); // and attach it to the interface
|
||||
mg_timer_add(&mgr, 500, MG_TIMER_REPEAT, blink_cb, &mgr);
|
||||
|
||||
struct mg_tcpip_driver driver = {.tx = usb_tx, .up = usb_up};
|
||||
|
@ -45,7 +45,7 @@ static void ethernet_init(void) {
|
||||
|
||||
static void server(void *args) {
|
||||
struct mg_mgr mgr; // Initialise Mongoose event manager
|
||||
mg_mgr_init(&mgr); // and attach it to the MIP interface
|
||||
mg_mgr_init(&mgr); // and attach it to the interface
|
||||
mg_log_set(MG_LL_DEBUG); // Set log level
|
||||
|
||||
// Initialise Mongoose network stack
|
||||
|
@ -45,7 +45,7 @@ static void ethernet_init(void) {
|
||||
|
||||
static void server(void *args) {
|
||||
struct mg_mgr mgr; // Initialise Mongoose event manager
|
||||
mg_mgr_init(&mgr); // and attach it to the MIP interface
|
||||
mg_mgr_init(&mgr); // and attach it to the interface
|
||||
mg_log_set(MG_LL_DEBUG); // Set log level
|
||||
|
||||
// Initialise Mongoose network stack
|
||||
|
@ -1,47 +1 @@
|
||||
# Baremetal webserver on EK-TM4C1294XL
|
||||
|
||||
This firmware uses experimental TCP/IP stack of the Mongoose Network Library,
|
||||
which implements the following:
|
||||
|
||||
- A complete [HTTP device dashboard](../../device-dashboard) with:
|
||||
- User authentication
|
||||
- Real-time device data graph
|
||||
- Coninfiguration display and update
|
||||
- MQTT communication with a remote MQTT server
|
||||
- No dependencies: no HAL, no CMSIS, no RTOS
|
||||
- Hand-written [mcu.h](mcu.h) header based on the [datasheet](https://www.ti.com/lit/pdf/spms433)
|
||||
- Interrupt-driven Ethernet driver
|
||||
- LED blinky, based on SysTick interrupt
|
||||
- User button handler, turns off/on an LED, based on GPIO IRQs (interrupt-driven)
|
||||
- HardFault handler alternate blinks LEDs
|
||||
- Debug log on UART0 (ICDI)
|
||||
|
||||
## Requirements
|
||||
|
||||
- [GNU make](http://mongoose.ws/tutorials/tools/#gnu-make)
|
||||
- [ARM GCC](http://mongoose.ws/tutorials/tools/#arm-gcc)
|
||||
- [Uniflash](https://mongoose.ws/tutorials/ti/ek-tm4c1294xl-baremetal/#build-and-run) for flashing
|
||||
|
||||
The links above will send you to tutorials on how to install each of those tools in your workstation for Linux, Mac, and Windows.
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
Plugin your board into USB, and attach an Ethernet cable.
|
||||
To build:
|
||||
|
||||
```sh
|
||||
$ make clean build
|
||||
```
|
||||
|
||||
To flash: use Uniflash
|
||||
|
||||
To see debug log, use any serial monitor program like `picocom` at 115200 bps and configure it to insert carriage returns after line feeds:
|
||||
|
||||
```sh
|
||||
$ picocom /dev/ttyACM0 -i -b 115200 --imap=lfcrlf
|
||||
```
|
||||
|
||||
There is also a [detailed tutorial on this example](https://mongoose.ws/tutorials/ti/ek-tm4c1294xl-baremetal/)
|
||||
|
||||
For more details and benchmark data on MIP, check the [F746ZG example](../../stm32/nucleo-f746zg-baremetal/)
|
||||
See detailed tutorial at https://mongoose.ws/tutorials/ti/ek-tm4c1294xl-baremetal/
|
||||
|
@ -48,7 +48,7 @@ static void ethernet_init(void) {
|
||||
|
||||
static void server(void *args) {
|
||||
struct mg_mgr mgr; // Initialise Mongoose event manager
|
||||
mg_mgr_init(&mgr); // and attach it to the MIP interface
|
||||
mg_mgr_init(&mgr); // and attach it to the interface
|
||||
mg_log_set(MG_LL_DEBUG); // Set log level
|
||||
|
||||
// Initialise Mongoose network stack
|
||||
|
Loading…
x
Reference in New Issue
Block a user