-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Yboichuk/app/radio controller #71
base: main
Are you sure you want to change the base?
Conversation
e17861d
to
d9904e9
Compare
|
||
// TODO: add support for ibus, CRSF and other | ||
|
||
bfs::SbusTx sbus_tx(&Serial2, -1, 12, false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Потрібно десь при запуску програми або в якомусь меню "Інформація" відображати інфо про те, який пін задіяний. Або може навіть варто створити нову сторінку в нашій документації, де описувати мануали всіх програм, які ми пишемо для Кіри
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Буде додано в конфігурацію
} | ||
|
||
bool RadioControllApp::readSettings() { | ||
FILE* file = fopen("/sd/RadioContollSetting.csv", "r"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Добре б якусь коротшу назву, щоб вміщалась в браузері файлів і не скролилась, наприклад rc_config.csv
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Хочу реалізувати якось щоб можна було обирати файл з SD карти з якого брати конфіги. Також "куди зберігати конфіг" добавлю
|
||
int lineNum = 0; | ||
char line[100]; | ||
while (fgets(line, sizeof(line), file)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можна використати ArduinoJson
, він в нас вже є в залежностях. Приклад:
#include "utils/json.h" |
JsonDocument data(&spiRamAllocator); |
DeserializationError error = deserializeJson(data, http.getString()); |
float temp, wind; |
lilka/firmware/keira/src/apps/weather/weather.cpp
Lines 201 to 203 in b237890
temp = data["current"]["temperature_2m"]; | |
wind = data["current"]["wind_speed_10m"]; | |
uint8_t code = data["current"]["weather_code"]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMHO: Треба дати майбутнім розробникам можливість обирати те що їм зручніше. Тому має сенс щоб було і те і те.
4563cc8
to
14a952c
Compare
App for controll some thing like rc drone, car, plane, ship, etc. via lilka with SBUS. Just need transiver and reciever with SBUS