xiaoxiang781216 commented on code in PR #3696:
URL: https://github.com/apache/nuttx-apps/pull/3696#discussion_r3709073590


##########
wireless/lora_pkt_fwd/lora_main.c:
##########
@@ -0,0 +1,653 @@
+/****************************************************************************
+ * apps/wireless/lora_pkt_fwd/lora_main.c
+ *
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ ****************************************************************************/
+
+/* The "lora" command, the equivalent of the AT command set of the vendor
+ * gateway firmware:
+ *
+ *   lora sys     full system configuration        (AT+SYS)
+ *   lora ver     firmware version                 (AT+VER)
+ *   lora status  concentrator and forwarder state
+ *   lora ch      show or change the channel plan  (AT+CH)
+ *   lora server  show or change the server        (AT+PKTFWD)
+ *   lora ip      network configuration            (AT+IP)
+ *   lora mac     Ethernet address and gateway id  (AT+MAC)
+ *   lora reset   restart the concentrator         (AT+RESET)
+ *   lora tx      transmit one packet, for bring-up
+ *   lora start   start the packet forwarder
+ *   lora stop    stop the packet forwarder
+ */
+
+/****************************************************************************
+ * Included Files
+ ****************************************************************************/
+
+#include <nuttx/config.h>
+
+#include <errno.h>
+#include <fcntl.h>
+#include <inttypes.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+
+#include <arpa/inet.h>
+#include <net/if.h>
+#include <sys/ioctl.h>
+
+#include <nuttx/version.h>
+#include <nuttx/wireless/lpwan/sx1301.h>

Review Comment:
   could we abstract the common ioctl for lora driver?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to