Home AMX User Forum NetLinx Studio
Options

AXB-TEMP

Hello,


I have a project where I would like to use AXB-TEMP sensors from arocom. I just purchased 4 pcs and I would like to test them but i don't have any programming instructions.

Can anybody help me with some pdfs, instructions or some code please?

Thank you!

Comments

  • Options
    Solved, but....hiw can I convert the value from sensor to temperature in celsius?!??!?

    Thank you!
  • Options
    AMXJeffAMXJeff Posts: 450
    Do you have a programming manual on this device, that would be nice?

    The code below is based on our AXC-TEMP Card... Do not know exactly what comes back from the acrocom AXB-TEMP. But hoping something close... But you should be able to get the just of this code.

    Temp card chooses temperature for Fahrenheit and Celsius based on jumper. But I assume you know that... But if you want to get the Celsius temperature based on the level value provided to you by the Temp card when jumper is in Fahrenheit position. Use this function below.

    nLevelTemp = 805; // Equals 80.5 Fahrenheit...
    DEFINE_DEVICE
    dvTemp = 96:1:0
    
    (***********************************************************)
    (*               VARIABLE DEFINITIONS GO BELOW             *)
    (***********************************************************)
    DEFINE_VARIABLE
    nTempLevel
    
    (***********************************************************)
    (*        SUBROUTINE/FUNCTION DEFINITIONS GO BELOW         *)
    (***********************************************************)
    DEFINE_FUNCTION DOUBLE ConvertLevelTempToCelsius(INTEGER nLevelTemp)
    {
    	STACK_VAR FLOAT fFahrenheit;
    	STACK_VAR DOUBLE dCelsius;
    	
    	fFahrenheit = nLevelTemp;
    	
    	fFahrenheit = ((fFahrenheit / 10) - 32);
    	
    	dCelsius = 5 / 9;
    
    	dCelsius = (dCelsius * fFahrenheit);
    	
    	return dCelsius;
    }
    
    (***********************************************************)
    (*                STARTUP CODE GOES BELOW                  *)
    (***********************************************************)
    DEFINE_START
    
    CREATE_LEVEL dvTemp, 1, nTempLevel;
    
    DEFINE_PROGRAM
    
    WAIT 100
    {
    	SEND_STRING 0,"ftoa(ConvertLevelTempToCelsius(nTempLevel))";
    }
    
  • Options
    Thank you!

    It's working. I figure it out the /10 formula :)


    now...how can I send a variable value to the panel? noob question...i'm learning....
  • Options
    AMXJeffAMXJeff Posts: 450
    ^TXT-<BUTTON_ADDRESS>,<BUTTON_STATES>,<TEXT>

    BUTTON_STATE = 0 // ALL_STATES
    BUTTON_ADDRESS = 1-4000 // ASSIGN THIS VALUE USING TPDESIGN 4.

    SEND_COMMAND dvTP,'^TXT-100,0,30.567 CELSIUS'
  • Options
    thanks. it worked
  • Options
    Hello guys,

    I have another problem with this temperature sensors...

    The temperature shown between two readings(1 minute) is different..... sometimes 0.5 diference some other times 4 5 degrees. What's wrong?

    Thank you!
  • Options
    ericmedleyericmedley Posts: 4,177
    cristibad wrote: »
    Hello guys,

    I have another problem with this temperature sensors...

    The temperature shown between two readings(1 minute) is different..... sometimes 0.5 diference some other times 4 5 degrees. What's wrong?

    Thank you!

    It is entirely possible to have that kind of swing in temperatures. There's probably no problem at all.
  • Options
    DHawthorneDHawthorne Posts: 4,584
    It wouldn't surprise me if you were the only person actually using one of those here. It's been some time since AMX offered them. So I think the best we can offer is some general advice ...

    I had a weather station that spit back erratic data like that once upon a time, so I decided I needed to buffer and test output before updating my panel. If data came in that was too different from the last data of the same time, I would throw it away and ask for it again. I would do that three times before I would accept any value more than that amount different from the last. In that case, it was simply an unavoidable quirk in the hardware. I don't know that is the case with your AMX-TEMP though ... it could be that, and it could be defective. Either way, you can't go too wrong if you test the values before displaying them.
  • Options
    jweatherjweather Posts: 320
    cristibad wrote: »
    The temperature shown between two readings(1 minute) is different..... sometimes 0.5 diference some other times 4 5 degrees. What's wrong?

    You could try keeping a rolling average, rather than just displaying the last temperature reading received. Keep the last 5 entries, then display their average. When you get a new reading, throw out your oldest reading and replace it, then show the new average. That way a single reading 4 degrees higher won't make the displayed reading change, but if the temperature really does change drastically, it won't take more than 5 minutes to show the new average. Make sense?
  • Options
    problem solved.

    Array with 5 entries and average value shown as current temperature.
    Works great!
    Thanks!
  • Options
    Cannot receive any event ?

    Hi,

    I also received my AXB-TEMP sensors from Arocom And did not receive any programming instruction neither.

    My problem is that I do not receive any level event from the sensor.

    I tried to create a level, using :
    CREATE_LEVEL dvTempSensor1, 1, nTempLevel;

    but the value of nTempLevel is always 0 and never change.

    Even when I monitor notifications I can not see any level or channel changes.

    The axLink led is blinking every one second --> so connection is OK.
    I get the online and offline events when i plug or unplug the sensor.

    How did you manage to get the sensor send the temperature value ?
    Do I have to do any startup instruction ?

    Can anybody help please ?

    Thanks.
  • Options
    module ?

    I think that there must be an amx module that pulses some channel on the physical device, gets the temperature using output channels and then sends a level event on a virtual device with the right value.

    Is that correct ?

    Does anyone have that module ?

    Thanks.
  • Options
    AXB-TEMP Module

    Does anyone have that module ?
  • Options
    thank you

    thank you. !

    Nabil
Sign In or Register to comment.