Hook up disconnect to UI button
This commit is contained in:
parent
0c41a85733
commit
0c270ee199
1 changed files with 2 additions and 2 deletions
|
@ -5,7 +5,7 @@ import Select from "react-select";
|
||||||
import SerialPort from "serialport";
|
import SerialPort from "serialport";
|
||||||
import KnobSection from "./Components/KnobSection";
|
import KnobSection from "./Components/KnobSection";
|
||||||
import { useAppDispatch } from "./redux/hooks";
|
import { useAppDispatch } from "./redux/hooks";
|
||||||
import { connect, setSerialPort } from "./redux/slices/serialConnectionSlice";
|
import { connect, disconnect, setSerialPort } from "./redux/slices/serialConnectionSlice";
|
||||||
|
|
||||||
const GlobalStyle = createGlobalStyle`
|
const GlobalStyle = createGlobalStyle`
|
||||||
html {
|
html {
|
||||||
|
@ -53,7 +53,7 @@ const App = () => {
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
// dispatch(disconnect());
|
dispatch(disconnect());
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
disconnect
|
disconnect
|
||||||
|
|
Reference in a new issue