Files
incp2/doc/examples/OBC+TTC/subsystems/OBC/main.c
2025-11-07 15:57:11 +00:00

44 lines
780 B
C

#include <assert.h>
#include "../../shared/incp/service.h"
#include "../../shared/incp/asn1/out/incp_generated.h"
#include "../../shared/bus/bus.h"
//In this example, OBC will only ping and then request a variable from TTC
int main()
{
incp_async_ping(INCP_ENDPOINT_TTC, NULL);
incp_async_datareq(INCP_ENDPOINT_TTC, ttcRxTotal_PRESENT);
for (;;);
return 1;
}
// === SUBSYSTEM SPECIFIC INCP IMPLEMENTATIONS ===
err_t impl_transmit(endpoint_t destination, void *buf, size_t size)
{
bus_send(destination, buf, size);
}
err_t impl_populate_dataret(AnyData *data)
{
//LATER: Populate or deny
}
void impl_callback_dataret(endpoint_t source, AnyData *data)
{
//LATER: Do whatever
}
void impl_callback_pong(endpoint_t source, PingMsg *pong)
{
//LATER: Do whatever
}