Bladeren bron

PDB -> PDBS

The PD Buddy Sink code should define PDBS macros, not PDB macros.
Clara Hobbs 6 jaren geleden
bovenliggende
commit
805613a71d
6 gewijzigde bestanden met toevoegingen van 20 en 20 verwijderingen
  1. 3
    3
      src/config.h
  2. 3
    3
      src/device_policy_manager.h
  3. 3
    3
      src/shell.c
  4. 5
    5
      src/shell.h
  5. 3
    3
      src/stm32f072_bootloader.h
  6. 3
    3
      src/usbcfg.h

+ 3
- 3
src/config.h Bestand weergeven

@@ -16,8 +16,8 @@
16 16
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
17 17
  */
18 18
 
19
-#ifndef PDB_CONFIG_H
20
-#define PDB_CONFIG_H
19
+#ifndef PDBS_CONFIG_H
20
+#define PDBS_CONFIG_H
21 21
 
22 22
 #include <stdint.h>
23 23
 
@@ -111,4 +111,4 @@ void pdbs_config_flash_update(const struct pdbs_config *cfg);
111 111
 struct pdbs_config *pdbs_config_flash_read(void);
112 112
 
113 113
 
114
-#endif /* PDB_CONFIG_H */
114
+#endif /* PDBS_CONFIG_H */

+ 3
- 3
src/device_policy_manager.h Bestand weergeven

@@ -16,8 +16,8 @@
16 16
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
17 17
  */
18 18
 
19
-#ifndef PDB_DEVICE_POLICY_MANAGER_H
20
-#define PDB_DEVICE_POLICY_MANAGER_H
19
+#ifndef PDBS_DEVICE_POLICY_MANAGER_H
20
+#define PDBS_DEVICE_POLICY_MANAGER_H
21 21
 
22 22
 #include <stdbool.h>
23 23
 
@@ -101,4 +101,4 @@ void pdbs_dpm_transition_standby(struct pdb_config *cfg);
101 101
 void pdbs_dpm_transition_requested(struct pdb_config *cfg);
102 102
 
103 103
 
104
-#endif /* PDB_DEVICE_POLICY_MANAGER_H */
104
+#endif /* PDBS_DEVICE_POLICY_MANAGER_H */

+ 3
- 3
src/shell.c Bestand weergeven

@@ -585,8 +585,8 @@ void pdbs_shell(struct pdb_config *cfg)
585 585
     int n;
586 586
     BaseSequentialStream *chp = shell_cfg.io;
587 587
     const struct pdbs_shell_cmd *scp = shell_cfg.commands;
588
-    char *lp, *cmd, *tokp, line[PDB_SHELL_MAX_LINE_LENGTH];
589
-    char *args[PDB_SHELL_MAX_ARGUMENTS + 1];
588
+    char *lp, *cmd, *tokp, line[PDBS_SHELL_MAX_LINE_LENGTH];
589
+    char *args[PDBS_SHELL_MAX_ARGUMENTS + 1];
590 590
 
591 591
     pdb_config = cfg;
592 592
     pdbs_dpm_data = cfg->dpm_data;
@@ -608,7 +608,7 @@ void pdbs_shell(struct pdb_config *cfg)
608 608
         n = 0;
609 609
         while ((lp = _strtok(NULL, " \t", &tokp)) != NULL) {
610 610
             /* If we have too many tokens, abort */
611
-            if (n >= PDB_SHELL_MAX_ARGUMENTS) {
611
+            if (n >= PDBS_SHELL_MAX_ARGUMENTS) {
612 612
                 chprintf(chp, "too many arguments\r\n");
613 613
                 cmd = NULL;
614 614
                 break;

+ 5
- 5
src/shell.h Bestand weergeven

@@ -32,15 +32,15 @@
32 32
     limitations under the License.
33 33
 */
34 34
 
35
-#ifndef PDB_SHELL_H
36
-#define PDB_SHELL_H
35
+#ifndef PDBS_SHELL_H
36
+#define PDBS_SHELL_H
37 37
 
38 38
 #include <ch.h>
39 39
 
40 40
 #include <pdb.h>
41 41
 
42
-#define PDB_SHELL_MAX_LINE_LENGTH 64
43
-#define PDB_SHELL_MAX_ARGUMENTS 2
42
+#define PDBS_SHELL_MAX_LINE_LENGTH 64
43
+#define PDBS_SHELL_MAX_ARGUMENTS 2
44 44
 
45 45
 
46 46
 /* Structure for PD Buddy shell commands */
@@ -62,4 +62,4 @@ void pdbs_shell(struct pdb_config *cfg);
62 62
 bool shellGetLine(BaseSequentialStream *chp, char *line, unsigned size);
63 63
 
64 64
 
65
-#endif /* PDB_SHELL_H */
65
+#endif /* PDBS_SHELL_H */

+ 3
- 3
src/stm32f072_bootloader.h Bestand weergeven

@@ -16,8 +16,8 @@
16 16
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
17 17
  */
18 18
 
19
-#ifndef PDB_STM32F072_BOOTLOADER_H
20
-#define PDB_STM32F072_BOOTLOADER_H
19
+#ifndef PDBS_STM32F072_BOOTLOADER_H
20
+#define PDBS_STM32F072_BOOTLOADER_H
21 21
 
22 22
 #include <stdint.h>
23 23
 
@@ -42,4 +42,4 @@ extern uint32_t dfu_reset_to_bootloader_magic;
42 42
 void dfu_run_bootloader(void);
43 43
 
44 44
 
45
-#endif /* PDB_STM32F072_BOOTLOADER_H */
45
+#endif /* PDBS_STM32F072_BOOTLOADER_H */

+ 3
- 3
src/usbcfg.h Bestand weergeven

@@ -32,8 +32,8 @@
32 32
     limitations under the License.
33 33
 */
34 34
 
35
-#ifndef PDB_USBCFG_H
36
-#define PDB_USBCFG_H
35
+#ifndef PDBS_USBCFG_H
36
+#define PDBS_USBCFG_H
37 37
 
38 38
 #include <hal.h>
39 39
 
@@ -43,4 +43,4 @@ extern const SerialUSBConfig serusbcfg;
43 43
 extern SerialUSBDriver SDU1;
44 44
 
45 45
 
46
-#endif  /* PDB_USBCFG_H */
46
+#endif  /* PDBS_USBCFG_H */

Laden…
Annuleren
Opslaan