Skip to content

Commit

Permalink
multiple improvements done in longer period of time,
Browse files Browse the repository at this point in the history
refactored usb subsystem, removed cdc usb profile from bios
added usb remote control application which simulates keystrokes over usb serial link
new font, memory viewer application
addressable leds - support for 4 channel leds
  • Loading branch information
Gabriel committed Nov 7, 2019
1 parent 9f7d88a commit 1504daa
Show file tree
Hide file tree
Showing 142 changed files with 9,919 additions and 8,650 deletions.
2 changes: 1 addition & 1 deletion system/apps/test15_charmap/CharMap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ void DrawBig(int _x, int _y, int s, int ch)
ui8* pData;
if (1)
{
pData = (ui8*)BIOS::PRIVATE::GetCharRom();
pData = (ui8*)BIOS::PRIVATE::GetInternal(BIOS::PRIVATE::EInternal::CharRom);
pData += ch*14;
} else {
pData = GetBiosChar(ch);
Expand Down
7 changes: 6 additions & 1 deletion system/apps/test63_ws2812/source/colorspace.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ typedef struct RgbColor
unsigned char r;
unsigned char g;
unsigned char b;
unsigned char w;
} RgbColor;

typedef struct HsvColor
{
unsigned char h;
unsigned char s;
unsigned char v;
unsigned char w;
} HsvColor;

RgbColor HsvToRgb(HsvColor hsv)
Expand All @@ -25,6 +27,7 @@ RgbColor HsvToRgb(HsvColor hsv)
rgb.r = hsv.v;
rgb.g = hsv.v;
rgb.b = hsv.v;
rgb.w = hsv.v;
return rgb;
}

Expand All @@ -35,6 +38,7 @@ RgbColor HsvToRgb(HsvColor hsv)
q = (hsv.v * (255 - ((hsv.s * remainder) >> 8))) >> 8;
t = (hsv.v * (255 - ((hsv.s * (255 - remainder)) >> 8))) >> 8;

rgb.w = hsv.w;
switch (region)
{
case 0:
Expand Down Expand Up @@ -68,6 +72,7 @@ HsvColor RgbToHsv(RgbColor rgb)
rgbMin = rgb.r < rgb.g ? (rgb.r < rgb.b ? rgb.r : rgb.b) : (rgb.g < rgb.b ? rgb.g : rgb.b);
rgbMax = rgb.r > rgb.g ? (rgb.r > rgb.b ? rgb.r : rgb.b) : (rgb.g > rgb.b ? rgb.g : rgb.b);

hsv.w = rgb.w;
hsv.v = rgbMax;
if (hsv.v == 0)
{
Expand All @@ -93,4 +98,4 @@ HsvColor RgbToHsv(RgbColor rgb)
return hsv;
}

}
}
Loading

0 comments on commit 1504daa

Please sign in to comment.