Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PAnTHer
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
puma
client
PAnTHer
Commits
b3ba1e7c
Commit
b3ba1e7c
authored
3 months ago
by
Lucio Zambon
Browse files
Options
Downloads
Patches
Plain Diff
Add new file
parent
ef56b5ad
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
door.php
+41
-0
41 additions, 0 deletions
door.php
with
41 additions
and
0 deletions
door.php
0 → 100644
+
41
−
0
View file @
b3ba1e7c
<?php
$debug
=
false
;
if
(
!
isset
(
$_REQUEST
[
'debug'
]))
header
(
'Content-type: application/json; charset=utf-8'
);
$machine
=
empty
(
$_REQUEST
[
'machine'
])
?
'elettra'
:
$_REQUEST
[
'machine'
];
if
(
isset
(
$_REQUEST
[
'src'
])
&&
strpos
(
$machine
,
'elettra'
)
!==
false
)
die
(
'{"sr":["A2","A3","E4","E5","T1", "I2D", "DR_BRG"],'
.
'"booster":["","","","A1","DR_A4.1","DR_A5.1","DR_A6.1","DR_A6.2","A0","DR_CS4.2","DR_CS4.1","DR_A10.1","DR_A8.1","DR_A12.1","DR_R3.1","DR_R3.2","DR_BSA3.1","DR_BSA4.1","DR_BSA1.1","DR_R"]}'
);
$src
=
"srv-tango-sre-01.ecs.elettra.trieste.it:20000/sr/accessi/pss"
;
$bsrc
=
"srv-tango-sre-01.ecs.elettra.trieste.it:20000/booster/accessi/plc_accessi"
;
$d
=
file_get_contents
(
"http://puma-01.elettra.eu/rchan.php?json&valueOnly&src=
$src
/Doors_all"
);
$old
=
file_get_contents
(
"http://puma-01.elettra.eu/rchan.php?json&valueOnly&src=
$src
/old_Doors_all"
);
$bd
=
file_get_contents
(
"http://puma-01.elettra.eu/rchan.php?json&valueOnly&src=
$bsrc
/Doors_all"
);
$bold
=
file_get_contents
(
"http://puma-01.elettra.eu/rchan.php?json&valueOnly&src=
$bsrc
/old_Doors_all"
);
if
(
$debug
)
{
$de
=
json_decode
(
$d
,
true
);
$de
[
$debug
]
=
0
;
$d
=
json_encode
(
$de
);}
die
(
'{"sr":{"door":'
.
$d
.
',"hold":'
.
$old
.
'},"booster":{"door":'
.
$bd
.
',"hold":'
.
$bold
.
'}}'
);
/*
booster
08 - A0
03 - A1
19 - DR_R
yard
18 - DR_BSA1.1
16 - DR_BSA3.1
17 - DR_BSA4.1
roof
15 - DR_R3.2
left
09 - DR_CS4.2
04 - DR_A4.1
05 - DR_A5.1
07 - DR_A6.2
06 - DR_A6.1
12 - DR_A8.1
11 - DR_A10.1
right
10 - DR_CS4.1
13 - DR_A12.1
15 - DR_R3.2
14 - DR_R3.1
*/
?>
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment