22 strcpy(
name,
"AppScope");
32 uint16_t y_last_scope;
33 uint16_t y_last_scope_ch2;
42 for (int16_t i=0;i<
w;i++){
47 f = ((v * 0.000030517578125) + 1.0) * 0.5;
48 ch1 =
y + (uint16_t)(f *
h);
49 if (i > 0)
draw->drawLine(
x + i-1,y_last_scope,
x + i,ch1,ILI9341_ORANGE);
52 f = ((v * 0.000030517578125) + 1.0) * 0.5;
53 ch2 =
y + (uint16_t)(f *
h);
54 if (i > 0)
draw->drawLine(
x + i-1,y_last_scope_ch2,
x + i,ch2,ILI9341_GREEN);
56 if (i > 0)
draw->drawLine(y_last_scope_ch2,y_last_scope,ch2,ch1,ILI9341_GREENYELLOW);
58 y_last_scope_ch2 = ch2;
63 draw->print(
"scale: ");
65 draw->setCursor(
x+
w - 100,
y+20);
66 draw->print(
"hdiv: ");
69 draw->drawRoundRect(
x,
y,
w,
h,4,ILI9341_MAGENTA);
101 if (t_x >
x && t_x < (
x +
w) && t_y >
y && t_y < (
y +
h)){
void requestPopUp(bool exclusive=false)
request popup from the AppManager will be activated by the next render loop applications in popup m...
void releasePopUp()
gives up popup
char name[MAX_NAME_LENGTH]
base class definition / implementation from which all app classes will be derived and override
void onFocus()
Event handler called when the app gains focus.
void onTouch(uint16_t t_x, uint16_t t_y)
Event handler called on touch.
erisAudioAnalyzeScope * scope
void onTouchRelease(uint16_t x, uint16_t y)
Event handler for touch release.
void onFocusLost()
Event handler called when the app loses focus.
Basic Oscilloscope Applicaiton.
AudioStream * getAudioStreamObjByName(const char *AudioStreamObjName)
bool update(const char *key, int32_t val, uint32_t *owner)
update the value of an owned record creates a new record if one does not exist and initializes its ...
int16_t read(int8_t channel, uint16_t mem_index)