Sending the value of a variable from the xbee to the xig

I need some help to send a value from the xbee to the connectport x4 gateway
them upload it as stream data on idigi.

I am using the XIG but the only thing I have uploaded to the idigi was the IO pins
I need to send the value of one variable.

I have tried


xbee_transparent_serial(&env1);

sending the data with full information

env1.length = sprintf(buffer1, “names=var2” “&values= %d “”&units=/n”,saiuBtoA);


dia/channel/00000000-00000000-00409DFF-FF44B81D/XBee_40666497/saiuAtoB

created this data stream on idigi thinking that the xig would read the var saiuAtoB

using the phyton call back on idigi i thought that maybe I could read the information but I don’t know where am I supposed to write the value

those are just some little thing I’ve tried to do please help me I’m stuck
Any doubt I would be happy to answer.

I know that this topic is repeted but as nobody answered me on the other I am starting a new one.

I changed it again to make it easier to understand.

void main(void)
{

wpan_envelope_t env;
uint32_t now, before;

wpan_envelope_create(&env, &xdev.wpan_dev, WPAN_IEEE_ADDR_COORDINATOR,
WPAN_NET_ADDR_UNDEFINED);
env.payload = buffer;

sys_hw_init();
sys_xbee_init();
sys_app_banner();

for (;:wink: {

now = rtc_get_uptime();

if (before < now-20) {
before = now;
/* Construct and send the message… */
env.length = sprintf(buffer, “idigi_data:”
“names=var1, var2”
“&values=%d,%d”
"&units=C
,RH%
",saiuBtoA,saiuAtoB);
xbee_transparent_serial(&env);

}
sys_watchdog_reset();

sys_xbee_tick();
}
}