Skip to content

Commit

Permalink
fix: modbus serial
Browse files Browse the repository at this point in the history
  • Loading branch information
rise0chen committed Nov 19, 2024
1 parent 60cbecb commit f9397bc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modbus_rtu_slave/web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<body>
<form>
串口号<br>
<select id="serial"></select>
<input type="number" id="serial">
<br>
波特率<br>
<input type="text" id="baud_rate">
Expand Down Expand Up @@ -121,6 +121,7 @@
if (options.length == 0) {
document.getElementById("serial").outerHTML = `<input type="number" id="serial">`;
} else {
document.getElementById("serial").outerHTML = `<select id="serial"></select>`;
document.getElementById("serial").innerHTML = options;
}
}
Expand Down

0 comments on commit f9397bc

Please sign in to comment.