61 lines
1.3 KiB
Plaintext
61 lines
1.3 KiB
Plaintext
|
P7_SENDEXE(3)
|
||
|
=============
|
||
|
Thomas "Cakeisalie5" Touhey
|
||
|
:Email: thomas@touhey.fr
|
||
|
:man source: libp7
|
||
|
:man manual: libp7 manual
|
||
|
|
||
|
NAME
|
||
|
----
|
||
|
p7_sendexe - send an update.exe to the calculator
|
||
|
|
||
|
SYNOPSIS
|
||
|
--------
|
||
|
[source,c]
|
||
|
----
|
||
|
#include <libp7.h>
|
||
|
|
||
|
int p7_sendexe(p7_handle_t *handle, p7_buffer_t *buffer,
|
||
|
p7uint_t loadaddr, p7uint_t straddr,
|
||
|
void (*disp)());
|
||
|
int p7_sendexe_file(p7_handle_t *handle, FILE *file,
|
||
|
p7uint_t loadaddr, p7uint_t straddr,
|
||
|
void (*disp)());
|
||
|
|
||
|
p7_sendexe_file(handle, update_exe, 0x88030000, 0x88030000);
|
||
|
----
|
||
|
|
||
|
DESCRIPTION
|
||
|
-----------
|
||
|
These functions send a program to execute -- called "UpdateExe" as this command
|
||
|
is mainly used by CASIO for updating the OS. *p7_sendexe* uses the libp7
|
||
|
buffer interface, see *p7_buffer*(3) to read more about it.
|
||
|
*Do not used this function if you're not sure about what you're doing.*
|
||
|
|
||
|
The *disp* parameter is only there if you want to display a loading bar. It
|
||
|
should have this prototype:
|
||
|
|
||
|
[source,c]
|
||
|
----
|
||
|
void my_display(p7ushort_t id, p7ushort_t total);
|
||
|
----
|
||
|
|
||
|
If it is non-null, it is first called with *id* > *total* to initialize display.
|
||
|
|
||
|
Read more info about update.exe-s in the *p7os*(1) and subprojects' sources.
|
||
|
|
||
|
RETURN VALUE
|
||
|
------------
|
||
|
This function returns zero if everything went well, and the error code
|
||
|
otherwise.
|
||
|
|
||
|
ERRORS
|
||
|
------
|
||
|
See *p7_error*(3).
|
||
|
|
||
|
SEE ALSO
|
||
|
--------
|
||
|
*libp7*(3),
|
||
|
*p7_error*(3),
|
||
|
*p7os*(3)
|