this is working
Code: Select all
config mac
string "mac"
default "{0x00, 0x00, 0x00, 0x00, 0x00, 0x00}"
String is the only datatype working. Is it possible to cast this into uint8_t?
Code: Select all
config mac
string "mac"
default "{0x00, 0x00, 0x00, 0x00, 0x00, 0x00}"
Code: Select all
config MY_CONFIG_OPTION
int "My config option"
range 0 255
default 64
help
Enter the valu which wil be assigned to uint8_t variable
Code: Select all
#include sdkconfig.h
uint8_t myvalue = CONFIG_MY_CONFIG_OPTION
....
Code: Select all
menu "Settings"
config MAC
string "mac"
default "AAAAAAAAAAAA"
help
Enter a value
Code: Select all
#ifndef settings_h
#define settings_h
#define MAC CONFIG_MAC
#endif
Code: Select all
error: 'MAC' was not declared in this scope
where is your library file named "settings.h" `?Saskia wrote:
my library "settings.h" looks like this
At this pont, i get this errorCode: Select all
#ifndef settings_h #define settings_h #define MAC CONFIG_MAC #endif
hwo can i link MAC to a variable, which i can use in main.c (for examle CONFIG_MAC)?Code: Select all
error: 'MAC' was not declared in this scope
Code: Select all
#include "settings.h"
Code: Select all
#include sdkconfig.h
uint8_t myvalue = CONFIG_MY_CONFIG_OPTION
....
Users browsing this forum: EG1966, tahseenabbas52 and 60 guests