hello everyone,
I made a program in mikroc compiler that reads hid buffer values and write that values to the 7 segment display. I copied below ipcready.lua file into fsx modules folder, that file writes air speed values to hid buffer. but com.writefeature is not working i think.
Vendor = 0x1234
Product = 0x0001
Device = 0
Report = 0
dev, rd, wrf, wr, init = com.openhid(Vendor, Product, Device, Report)
if dev == 0 then
ipc.log("Could not open HID")
ipc.exit()
end
-- Finish HID Connect
function call_speed (offset, value)
com.write(dev,tostring(value), wr)
end
event.offset (0x07E2, "UW", "call_speed") -- aircraft speed
In mikroc program im reading buffer and put values into 7 segment display like below:
while(1)
{
if(HID_Read() != 0) {
AsciiToChar(&readbuff);
SevenSegmentPrint(ss,(int)atoi(readbuff));
}
SetADCInputToUSBBuffer();
}
can anyone help how can i resolve the issue?