split resources, fix format

This commit is contained in:
DrZlo13
2020-11-17 07:39:48 +10:00
parent c17f4c9d38
commit 1abc98086e
7 changed files with 11 additions and 2 deletions

View File

@@ -17,7 +17,7 @@ public:
app = parent_app;
// TODO open record
GpioPin one_wire_pin = {iBTN_GPIO_Port, iBTN_Pin};
GpioPin one_wire_pin = ibutton_gpio;
GpioPin* one_wire_pin_record = &one_wire_pin;
onewire_slave = new OneWireGpioSlave(one_wire_pin_record);
};

View File

@@ -17,7 +17,7 @@ public:
app = parent_app;
// TODO open record
GpioPin one_wire_pin = {iBTN_GPIO_Port, iBTN_Pin};
GpioPin one_wire_pin = ibutton_gpio;
GpioPin* one_wire_pin_record = &one_wire_pin;
onewire = new OneWireGpio(one_wire_pin_record);
};

View File

@@ -394,6 +394,11 @@ void music_player(void* p) {
MusicDemoContext context = {.state_mutex = &state_mutex, .event_queue = event_queue};
osThreadId_t player = osThreadNew(music_player_thread, &context, &player_attr);
if(player == NULL) {
printf("cannot create player thread\n");
furiac_exit(NULL);
}
MusicDemoEvent event;
while(1) {
osStatus_t event_status = osMessageQueueGet(event_queue, &event, NULL, 100);