| 123456789101112131415161718192021222324252627282930313233 |
- package com.zksy.lamp.controller;
- import com.zksy.lamp.server.ExecutionServer;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.web.bind.annotation.GetMapping;
- import org.springframework.web.bind.annotation.RequestMapping;
- import org.springframework.web.bind.annotation.RestController;
- /**
- * @author Administrator
- * @version 1.0
- * @project dh-server-micro
- * @description
- * @date 2025/2/10 15:00:46
- */
- @RequestMapping("/test")
- @RestController
- public class TestController {
- @Autowired
- private ExecutionServer server;
- @GetMapping("/a")
- public String test(){
- String data = "AT+STACH1=1\r\n";
- String msg = server.ExecutionData(data);
- return msg;
- }
- @GetMapping("/b")
- public String testb(){
- String data = "AT+STACH1=1\r\n";
- String msg = server.ExecutionData(data);
- return msg;
- }
- }
|