Escient Fireball module
Hi
I'm trying to insert fireball module ( original module from escient web site) in my program but it's not work. I tried demo itself and it work very nice. When I compile my program, I don't get error messages, the files tranfert work well, but when I use my touch panel, the led input on master lit but not the led output. I build my code similarely to demo code but I get no succes.
Somebody have an idea ?
I'm trying to insert fireball module ( original module from escient web site) in my program but it's not work. I tried demo itself and it work very nice. When I compile my program, I don't get error messages, the files tranfert work well, but when I use my touch panel, the led input on master lit but not the led output. I build my code similarely to demo code but I get no succes.
Somebody have an idea ?
0
Comments
You might also try taking a break from the code. Work on something else for a little while, then come back to the code and look at it again. I occasionally find that my fingers weren't listening to my brain properly the first time through and my brain just assumes that my fingers followed the orders properly.
<TANGENT> For example, today I was updating a touchpanel that handles some security monitoring for a client and when I originally created the touchpanel files, I had entered the prompt as: "Are you sure you want to active the security lighting?". Well, even the first time I read through this today, my brain was still interpreting active as activate. It wasn't until I was showing the client a change that involved the prompt that my brain recognized active as active, not activate
Jeff
Tanks there is a part of my code
PROGRAM_NAME='J.Babeu' (***********************************************************) (* System Type : NetLinx *) (***********************************************************) (* REV HISTORY: *) (***********************************************************) (***********************************************************) (* DEVICE NUMBER DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_DEVICE //USER INTERFACE // TOUCH PANEL IN SWIMMING POOL dvTP_NAV = 10001:1:0 // TOUCH PANEL NAVIGATION AND ACCESSORIES dvTP_LIGHTS_PISCINE = 10001:2:0 // TOUCH PANEL SWIMMING POOL LIGHTING dvTP_LIGHTS_DINETTE = 10001:3:0 // TOUCH PANEL LUNCH ROOM LIGHTING dvTP_LIGHTS_EXTERIEUR = 10001:4:0 // TOUCH PANEL REAR BALCONY AND TERRACE dvTP_STORES_PISCINE = 10001:5:0 // TOUCH PANEL SWIMMING POOL BLINDS dvTP_STORES_SEJOUR = 10001:6:0 // TOUCH PANEL FAMILY ROOM BLINDS dvTP_ILLICO = 10001:9:0 // TOUCH PANEL ILLICO dvTP_FB1 = 10001:11:0 // TOUCH PANEL ESCIENT // TOUCH PANEL IN KITCHEN dvTPK_NAV = 10002:1:0 // TOUCH PANEL NAVIGATION AND ACCESSORIES dvTPK_LIGHTS_SEJOUR = 10002:2:0 // TOUCH PANEL FAMILY ROOM LIGHTING dvTPK_LIGHTS_CUISINE = 10002:3:0 // TOUCH PANEL KITCHEN LIGHTING dvTPK_LIGHTS_EXTERIEUR = 10002:4:0 // TOUCH PANEL REAR BALCONY AND TERRACE dvTPK_STORES_PISCINE = 10002:5:0 // TOUCH PANEL SWIMMING POOL BLINDS dvTPK_STORES_SEJOUR = 10002:6:0 // TOUCH PANEL FAMILY ROOM BLINDS dvTPK_ILLICO = 10002:9:0 // TOUCH PANEL ILLICO dvTPK_FB1 = 10002:11:0 // TOUCH PANEL ESCIENT //NI3000 SERIAL CONTROLED DEVICE dvVANTAGE = 5001:2:0 // VANTAGE LIGHTING SYSTEM dvFB1_RS232 = 5001:1:0 // ESCIENT MISIC SERVER vdvFB1 = 33004:1:0 // VIRTUAL ESCIENT MUSICK SERVER // SWIMMIMG POOL SHADES CONTROLS dvSTORES_P_1 = 32002:1:0 // RELAY CARD # 1 dvSTORES_P_2 = 32003:1:0 // RELAY CARD # 2 dvSTORES_P_3 = 32004:1:0 // RELAY CARD # 3 dvSTORES_P_4 = 32005:1:0 // RELAY CARD # 4 dvSTORES_P_5 = 32006:1:0 // RELAY CARD # 5 dvSTORES_P_6 = 32007:1:0 // RELAY CARD # 6 // FAMILY ROOM SHADES CONTROL dvSTORES_S_1 = 32008:1:0 // RELAY CARD # 7 dvSTORES_S_2 = 32009:1:0 // RELAY CARD # 8 dvSTORES_S_3 = 32010:1:0 // RELAY CARD # 9 (***********************************************************) (* CONSTANT DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_CONSTANT (***********************************************************) (* DATA TYPE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_TYPE (***********************************************************) (* VARIABLE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_VARIABLE VOLATILE INTEGER nLOAD_STAT [4][4][8] // NUMBER OF ENCLOSURES, MODULES, NUMBER OF LOADS CHAR nCURRENT_ROOM [20] CHAR nCURRENT_MODE [20] CHAR nCURRENT_SOURCE [20] INTEGER nSTORES_PISCINE [6] INTEGER nSTORES_SEJOUR [6] DEVCHAN nMODE_SEL_BUTTONS []= //MODE ROOM SOURCE SELECT { {dvTP_NAV,1},{dvTP_NAV,2},{dvTP_NAV,3},{dvTP_NAV,4},{dvTP_NAV,5}, {dvTP_NAV,6},{dvTP_NAV,7},{dvTP_NAV,9},{dvTP_NAV,10},{dvTP_NAV,11}, {dvTP_NAV,12},{dvTP_NAV,13},{dvTP_NAV,14},{dvTP_NAV,15},{dvTP_NAV,16}, {dvTP_NAV,17},{dvTP_NAV,18} } DEVCHAN nMODE_SEL_BUTTONS_KITCHEN []= //MODE ROOM SOURCE SELECT { {dvTPK_NAV,1},{dvTPK_NAV,2},{dvTPK_NAV,3},{dvTPK_NAV,4},{dvTPK_NAV,5}, {dvTPK_NAV,6},{dvTPK_NAV,7},{dvTPK_NAV,9},{dvTPK_NAV,10},{dvTPK_NAV,11}, {dvTPK_NAV,12},{dvTPK_NAV,13},{dvTPK_NAV,14},{dvTPK_NAV,15},{dvTPK_NAV,16}, {dvTPK_NAV,17},{dvTPK_NAV,18} } (*********************************************************** This demo is setup for 3 FireBall units and 6 touch panels. Delete the variable sets and modules for fewer FireBalls. Copy and paste the variable sets and modules for more FireBalls. If adding more FireBalls, be sure to number the variable and modules accordingly Add or delete FireBall touch panels from the DEFINE_DEVICE section and from the aTP_FB[] array. Notes for the FireBall variables below: 1. iTP_FB[] array size should equal the number of devices in aTP_FB[] 2. FBx_NAME is the name you want to appear on the touch panels 3. FBx_NUMBER is just a sequential number per FireBall unit 4. FBx_TYPE = 0 for E/E2/SE/MP models and 1 for DVDM models 5. FBx_USE_IP_CONNECTION = 1 for Ethernet Control and 0 for RS232 - Ethernet is highly recommeded! ***********************************************************) DEV aTP_FB[] = { dvTP_FB1, dvTPK_FB1 } INTEGER iTP_FB[2] CHAR FB1_NAME[15] = 'FireBall E2-300' INTEGER FB1_NUMBER = 1 INTEGER FB1_TYPE = 0 CHAR FB1_IP_ADDRESS[15] = '192.168.0.104' INTEGER FB1_USE_IP_CONNECTION = 1 INTEGER FB1_LOCAL_PORT = FIRST_LOCAL_PORT (***********************************************************) (* LATCHING DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_LATCHING (***********************************************************) (* MUTUALLY EXCLUSIVE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_MUTUALLY_EXCLUSIVE (***********************************************************) (* SUBROUTINE/FUNCTION DEFINITIONS GO BELOW *) (***********************************************************) (***********************************************************) (* STARTUP CODE GOES BELOW *) (***********************************************************) DEFINE_START COMBINE_DEVICES (vdvFB1,dvFB1_RS232) DEFINE_MODULE 'FireBall Module v5_0_1' FB1_MODULE ( aTP_FB, iTP_FB, FB1_NAME, FB1_NUMBER, FB1_TYPE, FB1_USE_IP_CONNECTION, FB1_IP_ADDRESS, FB1_LOCAL_PORT, dvFB1_RS232 ); (***********************************************************) (* THE EVENTS GO BELOW *) (***********************************************************)//////////////////////////////////Demo code/////////////////////////////////
PROGRAM_NAME='Escient FireBall v5.0.1' (***********************************************************) (* System Type : NetLinx *) (***********************************************************) (* REV HISTORY: *) (***********************************************************) (***********************************************************) (* DEVICE NUMBER DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_DEVICE dvTP1 = 10001:1:0 dvTP2 = 10002:1:0 dvTP3 = 10003:1:0 dvTP4 = 128:1:0 dvTP5 = 130:1:0 dvTP6 = 132:1:0 //FireBall Touch Panel Definitions: //There should be one dvTP_FBx device definition for each touch panel used to control a FireBall unit //All FireBall buttons are on channel and address 11 for TP4 panels dvTP_FB1 = 10002:11:0 //All FireBall button codes and variable text are on device 2 for TP3 panels. dvTP_FB4 = 129:1:0 dvTP_FB5 = 131:1:0 dvTP_FB6 = 133:1:0 //FireBall Serial Port Definitions //There should be one dvFBx_RS232 device for each FireBall in the system being controlled via a serial port //Set these to a virtual device numbers if using IP control dvFB1_RS232 = 5001:1:0 vdvFB1 = 33001:1:0 (***********************************************************) (* CONSTANT DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_CONSTANT (***********************************************************) (* DATA TYPE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_TYPE (***********************************************************) (* VARIABLE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_VARIABLE (*********************************************************** Notes for using the FireBall demo code: This demo is setup for 3 FireBall units and 6 touch panels. Delete the variable sets and modules for fewer FireBalls. Copy and paste the variable sets and modules for more FireBalls. If adding more FireBalls, be sure to number the variable and modules accordingly Add or delete FireBall touch panels from the DEFINE_DEVICE section and from the aTP_FB[] array. Notes for the FireBall variables below: 1. iTP_FB[] array size should equal the number of devices in aTP_FB[] 2. FBx_NAME is the name you want to appear on the touch panels 3. FBx_NUMBER is just a sequential number per FireBall unit 4. FBx_TYPE = 0 for E/E2/SE/MP models and 1 for DVDM models 5. FBx_USE_IP_CONNECTION = 1 for Ethernet Control and 0 for RS232 - Ethernet is highly recommeded! ***********************************************************) DEV aTP_FB[] = { dvTP_FB1, dvTP_FB4, dvTP_FB5, dvTP_FB6 } INTEGER iTP_FB[6] CHAR FB1_NAME[15] = 'FireBall E2-300' INTEGER FB1_NUMBER = 1 INTEGER FB1_TYPE = 0 CHAR FB1_IP_ADDRESS[15] = '192.168.0.104' INTEGER FB1_USE_IP_CONNECTION = 1 INTEGER FB1_LOCAL_PORT = FIRST_LOCAL_PORT (***********************************************************) (* LATCHING DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_LATCHING (***********************************************************) (* MUTUALLY EXCLUSIVE DEFINITIONS GO BELOW *) (***********************************************************) DEFINE_MUTUALLY_EXCLUSIVE (***********************************************************) (* SUBROUTINE/FUNCTION DEFINITIONS GO BELOW *) (***********************************************************) (***********************************************************) (* STARTUP CODE GOES BELOW *) (***********************************************************) DEFINE_START COMBINE_DEVICES (vdvFB1,dvFB1_RS232) DEFINE_MODULE 'FireBall Module v5_0_1' FB1_MODULE ( aTP_FB, iTP_FB, FB1_NAME, FB1_NUMBER, FB1_TYPE, FB1_USE_IP_CONNECTION, FB1_IP_ADDRESS, FB1_LOCAL_PORT, dvFB1_RS232 ); (***********************************************************) (* THE EVENTS GO BELOW *) (***********************************************************) DEFINE_EVENT (***********************************************************) (* THE ACTUAL PROGRAM GOES BELOW *) (***********************************************************) DEFINE_PROGRAM (***********************************************************) (* END OF PROGRAM *) (* DO NOT PUT ANY CODE BELOW THIS COMMENT *) (***********************************************************)Secondly, I would change the address of the dvFB1_RS232 to a virtual device since you appear to be using IP communication.
I am not positive and have no way to test it (but I think I read it in the forums), but my guess is the COMBINE_DEVICES line is causing your problems because as I recall, only the first device in the combined set generates events.
Hope this helps,
Jeff
P.S.
Enclose code in [ c o d e ] and [ / c o d e ] (without spaces) to get:
I used the combine devices, because I believed as it was the solution to rename a device, I did not know if I can to assigne a virtual address directly to a true device.
***********
I removed "combine devices, I renamed FB1_RS232 to a virtual device and I get the same problem.
Earlier to night, I changed ( in the demo) the name, just the name of dvTP1 for dVTP_NAV, as my real program, and my demo as never wors after, either dvTP1 or dvTP1_NAV
Other than that, I can't think of anything else that would cause problems. If you do figure it out, please post your findings because I'd be interested in knowing what I missed.
TKN
The most likely thing is that the IP connection is not being established and maintained. First, make sure the Fireball has a static IP. Second, open up a telnet session to the master, turn "msg on," and be sure there is data going back and forth. Fireballs are very chatty when active, hit the play button and you should see a steady steam of stuff in your telnet session. You are using FIRST_LOCAL_PORT in that code as well - be sure no other device or module is using it too.
I will try telnet communicationtonight and I will give a static adress.
Concerning the local port, if my understanding is well, it is the internal port com of client machine, ( fireball ) and presently I have no other connections on it, except ip connection
Hi
I fixed the ip adress for Fireball and did some test in telnet mode.
In telnet mode, I can ping ip address of Fireball,
If I use the remote (IR) control dirctely on fireball, in telnet I'm monitoring all info from fireball.
If I press play or other on my touch panel with my program, there is no command sent to fireball, and no feedback from fireball but if I use the demo itself, I see all feedback from fireball
If I ask for tcp list, I get only ip for my touch panel, not for fireball
If I ask for show device, there is no pysical adress for device 33001:1:01 ( fireball)
When I ask for program info, all files seem present
If I ask get ip 33001:1:0 I get a Get ip time out
On my NI unit, the red led ( output) don't lit when I press any button on touch panel with my program
I found my problem!
First, I changed local port 1 for local port 3 and the module works fine with every TP names.
2cond, In the TP demo, there is a main page with 3 buttons (with out link to other page) to select wich type of fireball we have, and if we do not include this page in our set up we have to modify code or include a button with channel indicated for this command
I hate that initial button thing about the Escient modules too. I always force it with a DO_PUSH when the device is selected. I also dislike the way they force page flips in code that I don't necessarily want flipped. But beyond that, their module is more robust than the AMX one.
So where is the Duet version?
I just did this and it drove me nuts for like 2 days.
Later
I put a do_push command and It works fine tanks.... Unfortunately I don't tried to re-initialise it..next time.
I'm just terminated my first paying system and I'm proud of it.
Lightning system, audio multi-rooms system, home theater and shade controls, controled by over 4000 lines of code and fireball module! Two CV7 touch panel and a MVP8400 I'm not sure as it's the best one but all work very nice.
Big job for a beginer!