Added VPADSetTPCalibrationParam, VPADGetTPCalibrationParam, VPADGetTPCalibratedPoint and VPADGetTPCalibratedPointEx.
The VPADData struct is filled completely, no unknown sections are left.
OSScreenPutPixelEx will draw a pixel of a certain color to the specified coordinates. This just writes the input u32 to the target location in the framebuffer, nothing is done with the data already stored in the framebuffer.
These are the two warnings that I fixed:
/src/dynamic_libs/os_functions.c: In function '_os_find_export':
/src/dynamic_libs/os_functions.c:171:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (i = 0; i < sizeof(a) - 1; i++)
^
/src/dynamic_libs/os_functions.c:177:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (i = 0; i < sizeof(b) - 1; i++)
^
gyro.x = Rotation speed around X (horizontal) axis
gyro.y = Rotation speed around Y (depth) axis
gyro.z = Rotation speed around Z (vertical) axis
angle.x = Rotation around X (horizontal) axis
angle.y = Rotation around Y (depth) axis
angle.z = Rotation around Z (vertical) axis
OSAllocFromSystem allocates a physically contiguous area of memory, and
returns a pointer to it as a virtual address in the calling process's
address space. OSFreeToSystem is the corresponding free function.
This brought the file size of os_functions.o (compiled at -O2, not stripped)
from 15K to 9.7K. Section sizes changed in the following ways:
.text .rela.text .data .rodata.str1.4 .syntab .strtab .shstrtab
before 5660 2928 276 3111 1264 1255 89
after 2860 2376 276 1175 1296 1294 89
The most obvious win is due to not including two strings per imported function
("OSFoo" and "Function OSFoo is NULL") in the .rodata section anymore, but
outlining the error-handling code also reduced the size of .text significantly.