rcbench
Servo and ESC test bench: panel, IOmcu and shared C
Loading...
Searching...
No Matches
panel_art.c File Reference

The board's drawing: fetched from the IOmcu a slice of a poll at a time on the control task, kept in flash a sector a pass on a safe bench, and published for the picker on the UI task. More...

#include <stdatomic.h>
#include <string.h>
#include "esp_heap_caps.h"
#include "esp_log.h"
#include "freertos/FreeRTOS.h"
#include "freertos/semphr.h"
#include "arming.h"
#include "art_fetch.h"
#include "art_store.h"
#include "flash_gate.h"
#include "link_host.h"
#include "link_pages.h"
#include "outputs.h"
#include "panel.h"
#include "picker_screen.h"

Macros

#define ART_SLICE_MS   15u

Functions

static void draw_publish (uint16_t board, const uint8_t *src, uint32_t bytes)
void drawing_for_picker (uint16_t board)
void drawing_follow (void)
static void art_keep_end (void)
void art_keep_service (void)
void art_stop (const char *why)
static bool art_link_read (void *ctx, uint8_t page, uint8_t count, uint16_t *regs)
static bool art_link_write (void *ctx, uint8_t page, uint8_t reg, uint16_t value)
void art_begin (uint16_t board)
static void art_finish (void)
void art_slice (void)

Variables

static const char * TAG = "rcbench"
const art_flash_t * s_artflash
static art_fetch_t s_artfetch
static uint8_t * s_artbuf
static uint16_t s_artboard
bool s_artbusy
static uint8_t * s_keepbuf
static art_entry_t s_keepentry
static art_keep_t s_keep
atomic_bool s_keeping
static bool s_keep_waited
SemaphoreHandle_t s_draw_lock
uint8_t * s_drawpub
static uint32_t s_drawpub_bytes
static uint16_t s_drawpub_board
static atomic_uint s_draw_gen
uint8_t * s_drawshow
static unsigned s_draw_seen
static const art_transport_t s_art_link

Detailed Description

The board's drawing: fetched from the IOmcu a slice of a poll at a time on the control task, kept in flash a sector a pass on a safe bench, and published for the picker on the UI task.

SPDX-License-Identifier: MIT

Variable Documentation

◆ s_art_link

const art_transport_t s_art_link
static
Initial value:
= {
art_link_read, art_link_write, NULL,
}