deploymentview.aadl 73.7 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131
PACKAGE deploymentview::DV
PUBLIC
WITH Deployment;
WITH Taste;

WITH interfaceview::IV;

WITH ocarina_buses;
WITH ocarina_drivers;
WITH ocarina_processors_leon;
WITH ocarina_processors_x86;
 
---------------------------------------------------
-- TASTE Deployement View 
---------------------------------------------------

  ----------------------
  -- ProcessorBoards --
  ----------------------

  SYSTEM linuxboard_obj80
    FEATURES
      obj256_link : requires bus access ocarina_buses::serial.generic
        { Taste::Coordinates => "82 83"; };
  END linuxboard_obj80;

  PROCESS mypartlinuxnative_obj168
  END mypartlinuxnative_obj168;

  PROCESS IMPLEMENTATION mypartlinuxnative_obj168.others
  END mypartlinuxnative_obj168.others;

  MEMORY ram_obj212
  END ram_obj212;

  MEMORY IMPLEMENTATION ram_obj212.others
  END ram_obj212.others;

  DEVICE serialdriversender_obj256 EXTENDS ocarina_drivers::generic_serial
    PROPERTIES
      Taste::Coordinates => "82 83" applies to link;
      Taste::Interface_Coordinates => "87 112" applies to link;
      Deployment::Configuration => "{devname ""/dev/ttyS0"", speed b38400}";
  END serialdriversender_obj256;

  DEVICE IMPLEMENTATION serialdriversender_obj256.others EXTENDS ocarina_drivers::generic_serial.raw_sender
  END serialdriversender_obj256.others;

  SYSTEM IMPLEMENTATION linuxboard_obj80.others
    SUBCOMPONENTS
      mypartlinuxnative_obj168 : PROCESS mypartlinuxnative_obj168.others
        { Taste::Coordinates => "10 17 79 45";
           Deployment::Port_Number => 0;};
      pinger_obj355 : SYSTEM interfaceview::IV::pinger
        { Taste::Coordinates => "12 24 72 40" ;};
      linuxnative_obj124 : PROCESSOR ocarina_processors_x86::x86.native
        { Taste::Coordinates => "7 9 83 49"; };
      ram_obj212 : MEMORY ram_obj212.others
        { Taste::Coordinates => "7 51 83 64"; };
      serialdriversender_obj256 : DEVICE serialdriversender_obj256.others
        { Taste::Coordinates => "8 67 84 83";};

    CONNECTIONS
      --  The bus connections
      BUS ACCESS obj256_link -> serialdriversender_obj256.link;

    PROPERTIES
      -- Connexion des CPUs aux process/drivers
      Actual_Processor_Binding => (reference (linuxnative_obj124)) applies to mypartlinuxnative_obj168;
      Taste::APLC_Binding => (reference(mypartlinuxnative_obj168)) APPLIES TO pinger_obj355;
      Actual_Processor_Binding => (reference (linuxnative_obj124)) applies to serialdriversender_obj256;
      Actual_Memory_Binding => (reference (ram_obj212)) applies to mypartlinuxnative_obj168;
  END linuxboard_obj80.others;

  --{ leoncentral_obj91 obj591 142 10 
  --This board runs with the FPGA.
  --Should have spw addr 22
  --}

  SYSTEM leoncentral_obj91
    FEATURES
      obj267_link : requires bus access ocarina_buses::serial.generic
        { Taste::Coordinates => "116 75"; };
      obj278_link : requires bus access ocarina_buses::spacewire.generic
        { Taste::Coordinates => "171 94"; };
  END leoncentral_obj91;

  PROCESS mypartleoncentral_obj179
  END mypartleoncentral_obj179;

  PROCESS IMPLEMENTATION mypartleoncentral_obj179.others
  END mypartleoncentral_obj179.others;

  MEMORY ram_obj223
  END ram_obj223;

  MEMORY IMPLEMENTATION ram_obj223.others
  END ram_obj223.others;

  DEVICE serial_obj267 EXTENDS ocarina_drivers::rasta_serial
    PROPERTIES
      Taste::Coordinates => "116 75" applies to link;
      Taste::Interface_Coordinates => "112 112" applies to link;
      Deployment::Configuration => "{devname ""/dev/apburasta0"", speed b38400}";
  END serial_obj267;

  DEVICE IMPLEMENTATION serial_obj267.others EXTENDS ocarina_drivers::rasta_serial.raw
  END serial_obj267.others;

  DEVICE spw_obj278 EXTENDS ocarina_drivers::rasta_spacewire
    PROPERTIES
      Taste::Coordinates => "171 94" applies to link;
      Taste::Interface_Coordinates => "169 114" applies to link;
      Deployment::Configuration => "{devname ""/dev/grspwrasta0"", nodeaddr 22, corefreq 30000, clockdiv 0}";
  END spw_obj278;

  DEVICE IMPLEMENTATION spw_obj278.others EXTENDS ocarina_drivers::rasta_spacewire.pohic
  END spw_obj278.others;

  --{ leoncentral_obj91 obj591 142 10 
  --This board runs with the FPGA.
  --Should have spw addr 22
  --}

  SYSTEM IMPLEMENTATION leoncentral_obj91.others
    SUBCOMPONENTS
      mypartleoncentral_obj179 : PROCESS mypartleoncentral_obj179.others
        { Taste::Coordinates => "118 20 172 42";
           Deployment::Port_Number => 0;};
      pingee1_obj366 : SYSTEM interfaceview::IV::pingee1
        { Taste::Coordinates => "123 28 167 38" ;};
132
      leoncpu_obj135 : PROCESSOR ocarina_processors_leon::leon.rtems_posix
133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211
        { Taste::Coordinates => "113 14 178 46"; };
      ram_obj223 : MEMORY ram_obj223.others
        { Taste::Coordinates => "115 51 177 67"; };
      serial_obj267 : DEVICE serial_obj267.others
        { Taste::Coordinates => "116 70 177 82";};
      spw_obj278 : DEVICE spw_obj278.others
        { Taste::Coordinates => "120 85 180 94";};

    CONNECTIONS
      --  The bus connections
      BUS ACCESS obj267_link -> serial_obj267.link;
      BUS ACCESS obj278_link -> spw_obj278.link;

    PROPERTIES
      -- Connexion des CPUs aux process/drivers
      Actual_Processor_Binding => (reference (leoncpu_obj135)) applies to mypartleoncentral_obj179;
      Taste::APLC_Binding => (reference(mypartleoncentral_obj179)) APPLIES TO pingee1_obj366;
      Actual_Processor_Binding => (reference (leoncpu_obj135)) applies to serial_obj267;
      Actual_Processor_Binding => (reference (leoncpu_obj135)) applies to spw_obj278;
      Actual_Memory_Binding => (reference (ram_obj223)) applies to mypartleoncentral_obj179;
  END leoncentral_obj91.others;

  --{ leonfinal_obj102 obj602 242 10 
  --This is the single board without FPGA, should 
  --have spw address 10
  --}

  SYSTEM leonfinal_obj102
    FEATURES
      obj289_link : requires bus access ocarina_buses::spacewire.generic
        { Taste::Coordinates => "210 78"; };
      obj300_link : requires bus access ocarina_buses::serial.generic
        { Taste::Coordinates => "267 104"; };
  END leonfinal_obj102;

  PROCESS mypartleoncpu_obj190
  END mypartleoncpu_obj190;

  PROCESS IMPLEMENTATION mypartleoncpu_obj190.others
  END mypartleoncpu_obj190.others;

  MEMORY ram_obj234
  END ram_obj234;

  MEMORY IMPLEMENTATION ram_obj234.others
  END ram_obj234.others;

  DEVICE spw_obj289 EXTENDS ocarina_drivers::rasta_spacewire
    PROPERTIES
      Taste::Coordinates => "210 78" applies to link;
      Taste::Interface_Coordinates => "219 114" applies to link;
      Deployment::Configuration => "{devname ""/dev/grspwrasta0"", nodeaddr 10, corefreq 30000, clockdiv 0}";
  END spw_obj289;

  DEVICE IMPLEMENTATION spw_obj289.others EXTENDS ocarina_drivers::rasta_spacewire.pohic
  END spw_obj289.others;

  DEVICE serialleon_obj300 EXTENDS ocarina_drivers::rasta_serial
    PROPERTIES
      Taste::Coordinates => "267 104" applies to link;
      Taste::Interface_Coordinates => "274 143" applies to link;
      Deployment::Configuration => "{devname ""/dev/apburasta0"", speed b38400}";
  END serialleon_obj300;

  DEVICE IMPLEMENTATION serialleon_obj300.others EXTENDS ocarina_drivers::rasta_serial.raw
  END serialleon_obj300.others;

  --{ leonfinal_obj102 obj602 242 10 
  --This is the single board without FPGA, should 
  --have spw address 10
  --}

  SYSTEM IMPLEMENTATION leonfinal_obj102.others
    SUBCOMPONENTS
      mypartleoncpu_obj190 : PROCESS mypartleoncpu_obj190.others
        { Taste::Coordinates => "213 19 269 39";
           Deployment::Port_Number => 0;};
      pingee2_obj377 : SYSTEM interfaceview::IV::pingee2
        { Taste::Coordinates => "216 25 266 36" ;};
212
      leoncpu_obj146 : PROCESSOR ocarina_processors_leon::leon.rtems_posix
213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477
        { Taste::Coordinates => "209 12 278 51"; };
      ram_obj234 : MEMORY ram_obj234.others
        { Taste::Coordinates => "209 53 277 70"; };
      spw_obj289 : DEVICE spw_obj289.others
        { Taste::Coordinates => "210 73 277 89";};
      serialleon_obj300 : DEVICE serialleon_obj300.others
        { Taste::Coordinates => "210 93 278 104";};

    CONNECTIONS
      --  The bus connections
      BUS ACCESS obj289_link -> spw_obj289.link;
      BUS ACCESS obj300_link -> serialleon_obj300.link;

    PROPERTIES
      -- Connexion des CPUs aux process/drivers
      Actual_Processor_Binding => (reference (leoncpu_obj146)) applies to mypartleoncpu_obj190;
      Taste::APLC_Binding => (reference(mypartleoncpu_obj190)) APPLIES TO pingee2_obj377;
      Actual_Processor_Binding => (reference (leoncpu_obj146)) applies to spw_obj289;
      Actual_Processor_Binding => (reference (leoncpu_obj146)) applies to serialleon_obj300;
      Actual_Memory_Binding => (reference (ram_obj234)) applies to mypartleoncpu_obj190;
  END leonfinal_obj102.others;

  SYSTEM x86finalpingee_obj113
    FEATURES
      obj311_link : requires bus access ocarina_buses::serial.generic
        { Taste::Coordinates => "348 93"; };
  END x86finalpingee_obj113;

  PROCESS finalpart_obj201
  END finalpart_obj201;

  PROCESS IMPLEMENTATION finalpart_obj201.others
  END finalpart_obj201.others;

  MEMORY obj531_obj245
  END obj531_obj245;

  MEMORY IMPLEMENTATION obj531_obj245.others
  END obj531_obj245.others;

  DEVICE seriallinuxreceiver_obj311 EXTENDS ocarina_drivers::generic_serial
    PROPERTIES
      Taste::Coordinates => "348 93" applies to link;
      Taste::Interface_Coordinates => "342 143" applies to link;
      Deployment::Configuration => "{devname ""/dev/ttyUSB0"", speed b38400}";
  END seriallinuxreceiver_obj311;

  DEVICE IMPLEMENTATION seriallinuxreceiver_obj311.others EXTENDS ocarina_drivers::generic_serial.raw_receiver
  END seriallinuxreceiver_obj311.others;

  SYSTEM IMPLEMENTATION x86finalpingee_obj113.others
    SUBCOMPONENTS
      finalpart_obj201 : PROCESS finalpart_obj201.others
        { Taste::Coordinates => "320 20 376 39";
           Deployment::Port_Number => 0;};
      finalpingee_obj388 : SYSTEM interfaceview::IV::finalpingee
        { Taste::Coordinates => "326 29 371 38" ;};
      mylinux_obj157 : PROCESSOR ocarina_processors_x86::x86.native
        { Taste::Coordinates => "314 13 401 43"; };
      obj531_obj245 : MEMORY obj531_obj245.others
        { Taste::Coordinates => "316 47 396 66"; };
      seriallinuxreceiver_obj311 : DEVICE seriallinuxreceiver_obj311.others
        { Taste::Coordinates => "317 71 396 93";};

    CONNECTIONS
      --  The bus connections
      BUS ACCESS obj311_link -> seriallinuxreceiver_obj311.link;

    PROPERTIES
      -- Connexion des CPUs aux process/drivers
      Actual_Processor_Binding => (reference (mylinux_obj157)) applies to finalpart_obj201;
      Taste::APLC_Binding => (reference(finalpart_obj201)) APPLIES TO finalpingee_obj388;
      Actual_Processor_Binding => (reference (mylinux_obj157)) applies to seriallinuxreceiver_obj311;
      Actual_Memory_Binding => (reference (obj531_obj245)) applies to finalpart_obj201;
  END x86finalpingee_obj113.others;

  --------------
  -- Devices--
  --------------

  -----------
  -- Buses --
  -----------

  -----------------
  -- Root System --
  -----------------

  SYSTEM deploymentview
  END deploymentview;

  SYSTEM IMPLEMENTATION deploymentview.others
    SUBCOMPONENTS
      --  The processor boards
      linuxboard_obj80 : SYSTEM linuxboard_obj80.others
        { Taste::Coordinates => "5 3 88 93"; };
      leoncentral_obj91 : SYSTEM leoncentral_obj91.others
        { Taste::Coordinates => "109 8 183 98"; };
      leonfinal_obj102 : SYSTEM leonfinal_obj102.others
        { Taste::Coordinates => "205 4 284 109"; };
      x86finalpingee_obj113 : SYSTEM x86finalpingee_obj113.others
        { Taste::Coordinates => "311 5 408 99"; };
      --  The devices
      --  The buses
      serial_obj322 : BUS ocarina_buses::serial.generic
        { Taste::Coordinates => "66 112 138 136";};
      spw_obj333 : BUS ocarina_buses::spacewire.generic
        { Taste::Coordinates => "159 114 237 134";};
      serial2_obj344 : BUS ocarina_buses::serial.generic
        { Taste::Coordinates => "264 143 367 163";};
      --  The IV systems
        interfaceview_obj963 : SYSTEM interfaceview::IV::interfaceview.others;

    CONNECTIONS
      --  The bus connections
      obj827 :BUS ACCESS serial_obj322 -> linuxboard_obj80.obj256_link
        { Taste::Coordinates => "83 83 83 98 88 98 88 112"; };
      obj648 :BUS ACCESS serial_obj322 -> leoncentral_obj91.obj267_link
        { Taste::Coordinates => "116 76 113 76 113 112"; };
      obj7839 :BUS ACCESS spw_obj333 -> leoncentral_obj91.obj278_link
        { Taste::Coordinates => "172 94 172 104 170 104 170 114"; };
      obj7928 :BUS ACCESS spw_obj333 -> leonfinal_obj102.obj289_link
        { Taste::Coordinates => "210 79 205 79 205 111 220 111 220 114"; };
      obj1477 :BUS ACCESS serial2_obj344 -> leonfinal_obj102.obj300_link
        { Taste::Coordinates => "268 104 268 114 275 114 275 143"; };
      obj1009 :BUS ACCESS serial2_obj344 -> x86finalpingee_obj113.obj311_link
        { Taste::Coordinates => "348 93 348 118 342 118 342 143"; };

    PROPERTIES
      --  The bus connection bindings
      Actual_Connection_Binding => (reference (serial_obj322)) applies to interfaceview_obj963.obj282;
      Actual_Connection_Binding => (reference (spw_obj333)) applies to interfaceview_obj963.obj521;
      Actual_Connection_Binding => (reference (serial2_obj344)) applies to interfaceview_obj963.obj1232;

  END deploymentview.others;


PROPERTIES
  Taste::Coordinates => "0 0 594 420";
  Taste::interfaceView => "interfaceview.aadl";

END deploymentview::DV;
 


---------------------------------------
-- copied aadl libraries
-- TASTE requirement
-- Do not edit below this line
---------------------------------------

package ocarina_buses

public

bus generic_bus
end generic_bus;

bus implementation generic_bus.i
end generic_bus.i;

bus dummy_bus
end dummy_bus;

bus implementation dummy_bus.i
end dummy_bus.i;

bus ip
end ip;

bus implementation ip.pohic
end ip.pohic;

bus implementation ip.i
subcomponents
   asn      : virtual bus asn1.i;
   pohic    : virtual bus pohi.c;
   pohiada  : virtual bus pohi.ada;
end ip.i;

bus implementation ip.pohiada
end ip.pohiada;

bus spacewire
end spacewire;

bus implementation spacewire.generic
end spacewire.generic;

bus serial
end serial;

bus implementation serial.generic
end serial.generic;


----------------------
--  Virtual buses  --
----------------------

virtual bus raw
end raw;

virtual bus implementation raw.i
end raw.i;

virtual bus asn1
end asn1;

virtual bus implementation asn1.i
end asn1.i;

virtual bus pohi
end pohi;

virtual bus implementation pohi.c
end pohi.c;

virtual bus implementation pohi.ada
end pohi.ada;

end ocarina_buses;
package ocarina_drivers
public

  with deployment;

  with ocarina_buses;

  with Data_Model;
  with Base_Types;

  with ocarina_drivers_leon_serial;

  with ocarina_drivers_rasta_1553;
  with ocarina_drivers_rasta_serial;
  with ocarina_drivers_rasta_spacewire;
  with ocarina_drivers_rtems_ne2000;

  with ocarina_drivers_star_dundee_spacewire_brick;

  with ocarina_drivers_udp_exarm;
  with ocarina_drivers_serial;

  with ocarina_drivers_ip_pohic;

  with ocarina_drivers_exarm_ni_6071e_analog;
  with ocarina_drivers_exarm_ni_6071e_digital;

  with ocarina_drivers_generic_keyboard;

  with GRUART;
  with GRSPW;
  with Native_UART;
  with TCP_IP_Protocol;

  ------------------------
  -- Configuration Type --
  ------------------------

   data configuration_type_ip
   properties
      Type_Source_Name                 => "IP-Conf-T";
      Deployment::ASN1_Module_Name     => "POHICDRIVER-IP";
      Source_Language                  => ASN1;
478
      Source_Text                      => ("~/tool-inst/include/ocarina/runtime/polyorb-hi-c/src/drivers/configuration/ip.asn" , "drivers/configuration/ip.h");
479 480 481 482 483 484 485
   end configuration_type_ip;

   data configuration_type_serial
   properties
      Type_Source_Name              => "Serial-Conf-T";
      Deployment::ASN1_Module_Name  => "POHICDRIVER-UART";
      Source_Language               => ASN1;
486
      Source_Text                   => ("~/tool-inst/include/ocarina/runtime/polyorb-hi-c/src/drivers/configuration/serial.asn", "drivers/configuration/serial.h");
487 488 489 490 491 492 493
   end configuration_type_serial;

   data configuration_type_spacewire
   properties
      Type_Source_Name              => "Spacewire-Conf-T";
      Deployment::ASN1_Module_Name  => "POHICDRIVER-SPACEWIRE";
      Source_Language               => ASN1;
494
      Source_Text                   => ("~/tool-inst/include/ocarina/runtime/polyorb-hi-c/src/drivers/configuration/spacewire.asn", "drivers/configuration/spacewire.h");
495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538
   end configuration_type_spacewire;

  --------------
  -- Keyboard --
  --------------

  device generic_keyboard
  features
    key_pressed  : out data port Base_Types::Character;
  properties
    Deployment::Driver_Name    => "generic_keyboard";
    Device_Driver              => classifier (ocarina_drivers_generic_keyboard::generic_keyboard_driver.i);
    Initialize_Entrypoint      => classifier (ocarina_drivers_generic_keyboard::spg_generic_keyboard_init);
  end generic_keyboard;

  device implementation generic_keyboard.linux
  end generic_keyboard.linux;


  -------------------
  -- LEON ETHERNET --
  -------------------

  device leon_ethernet
  features
    link : requires bus access ocarina_buses::ip.i;
  end leon_ethernet;

  device implementation leon_ethernet.raw
  properties
    Deployment::Driver_Name    => "eth_leon";
    Device_Driver              => classifier (ocarina_drivers_leon_eth::eth_driver.leon);
    Initialize_Entrypoint      => classifier (ocarina_drivers_leon_eth::spg_leon_eth_init);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end leon_ethernet.raw;


  ------------------
  -- RASTA SERIAL --
  ------------------

  device leon_serial
  features
    link : requires bus access ocarina_buses::serial.generic;
  end leon_serial;

  device implementation leon_serial.raw
  properties
    Deployment::Driver_Name    => "serial_leon";
    Device_Driver              => classifier (ocarina_drivers_leon_serial::serial_driver.leon);
    Initialize_Entrypoint      => classifier (ocarina_drivers_leon_serial::spg_serial_init_leon);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::raw.i));
  end leon_serial.raw;

  device implementation leon_serial.raw_sender
  properties
    Deployment::Driver_Name    => "serial_leon_sender";
    Device_Driver              => classifier (ocarina_drivers_leon_serial::serial_driver.leon_sender);
    Initialize_Entrypoint      => classifier (ocarina_drivers_leon_serial::spg_serial_init_leon_sender);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::raw.i));
  end leon_serial.raw_sender;

  ----------------
  -- RASTA 1553 --
  ----------------

  device rasta_1553
  end rasta_1553;

  device implementation rasta_1553.terminal
  properties
    Deployment::Driver_Name    => "1553_rasta";
    Device_Driver              => classifier (ocarina_drivers_rasta_1553::if1553_driver.rasta_terminal);
    Initialize_Entrypoint      => classifier (ocarina_drivers_rasta_1553::spg_1553_init_rasta_terminal);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::pohi.c));
  end rasta_1553.terminal;

  device implementation rasta_1553.controller_sender_only
  properties
    Deployment::Driver_Name    => "1553_rasta";
    Device_Driver              => classifier (ocarina_drivers_rasta_1553::if1553_driver.rasta_controller_sender_only);
    Initialize_Entrypoint      => classifier (ocarina_drivers_rasta_1553::spg_1553_init_rasta_controller);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::pohi.c));
  end rasta_1553.controller_sender_only;

  ------------------
  -- RASTA SERIAL --
  ------------------

  device rasta_serial
  features
    link : requires bus access ocarina_buses::serial.generic;
  end rasta_serial;

  device implementation rasta_serial.raw
  properties
    Deployment::Driver_Name    => "serial_rasta";
    Device_Driver              => classifier (ocarina_drivers_rasta_serial::serial_driver.rasta);
    Initialize_Entrypoint      => classifier (ocarina_drivers_rasta_serial::spg_serial_init_rasta);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::raw.i));
  end rasta_serial.raw;

  device implementation rasta_serial.pohiada
  properties
    Deployment::Driver_Name    => "serial_rasta";
    Implemented_As =>  classifier (GRUART::Driver_GRUART_Protocol.impl);
    Initialize_Entrypoint => classifier (GRUART::Initialize);
    Provided_Virtual_Bus_Class => (classifier (ocarina_buses::raw.i));
  end rasta_serial.pohiada;

  --------------------------------------------------
  -- USB BRICK (STAR DUNDEE) DEVICE FOR SPACEWIRE --
  --------------------------------------------------

  device usb_brick_spacewire
  features
    link : requires bus access ocarina_buses::spacewire.generic;
  end usb_brick_spacewire;

  device implementation usb_brick_spacewire.pohic
  properties
    Deployment::Driver_Name       => "spacewire_usb_brick";
    Device_Driver                 => classifier (ocarina_drivers_star_dundee_spacewire_brick::driver.usb_brick);
    Initialize_Entrypoint         => classifier (ocarina_drivers_star_dundee_spacewire_brick::spg_init);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end usb_brick_spacewire.pohic;

  ---------------------
  -- RASTA SPACEWIRE --
  ---------------------

  device rasta_spacewire
  features
    link : requires bus access ocarina_buses::spacewire.generic;
  end rasta_spacewire;

  device implementation rasta_spacewire.pohic
  properties
    Deployment::Driver_Name       => "spacewire_rasta";
    Device_Driver                 => classifier (ocarina_drivers_rasta_spacewire::spacewire_driver.rasta);
    Initialize_Entrypoint         => classifier (ocarina_drivers_rasta_spacewire::spg_spacewire_init_rasta);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end rasta_spacewire.pohic;

  device implementation rasta_spacewire.pohiada
  properties
    Deployment::Driver_Name       => "spacewire_rasta";
    Implemented_As =>  classifier (GRSPW::Driver_GRSPW_Protocol.impl);
    Initialize_Entrypoint => classifier (GRSPW::Initialize);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end rasta_spacewire.pohiada;

  ---------------------------
  -- Generic serial driver --
  ---------------------------

  device generic_serial
  features
    link : requires bus access ocarina_buses::serial.generic;
  end generic_serial;

  device implementation generic_serial.raw
  properties
    Deployment::Driver_Name       => "serial_linux";
    Device_Driver                 => classifier (ocarina_drivers_serial::serial_driver.linux);
    Initialize_Entrypoint         => classifier (ocarina_drivers_serial::spg_serial_init_linux);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::raw.i));
  end generic_serial.raw;

  device implementation generic_serial.pohiada
  properties
    Deployment::Driver_Name       => "serial_linux";
    Implemented_As =>
         classifier (Native_UART::Driver_Native_UART_Protocol.impl);
    Initialize_Entrypoint => classifier (Native_UART::Initialize);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::raw.i));
  end generic_serial.pohiada;

  device implementation generic_serial.raw_sender
  properties
    Deployment::Driver_Name       => "serial_linux_sender";
    Device_Driver                 => classifier (ocarina_drivers_serial::serial_driver.linux_sender);
    Initialize_Entrypoint         => classifier (ocarina_drivers_serial::spg_serial_init_linux_sender);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::raw.i));
  end generic_serial.raw_sender;

  device implementation generic_serial.raw_receiver
  properties
    Deployment::Driver_Name       => "serial_linux_receiver";
    Device_Driver                 => classifier (ocarina_drivers_serial::serial_driver.linux_receiver);
    Initialize_Entrypoint         => classifier (ocarina_drivers_serial::spg_serial_init_linux_receiver);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::raw.i));
  end generic_serial.raw_receiver;

  -------------------------------
  -- Generic sockets/ip driver --
  -------------------------------

  device generic_sockets_ip
  features
    link : requires bus access ocarina_buses::ip.i;
  end generic_sockets_ip;

  device implementation generic_sockets_ip.pohic
  properties
    Deployment::Driver_Name       => "sockets";
    Device_Driver                 => classifier (ocarina_drivers_ip_pohic::sockets_impl.i);
    Initialize_Entrypoint         => classifier (ocarina_drivers_ip_pohic::spg_sockets_init);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end generic_sockets_ip.pohic;

  device implementation generic_sockets_ip.pohiada
  properties
    Deployment::Driver_Name       => "socketsnew";
    Implemented_As => classifier (TCP_IP_Protocol::Driver_TCP_IP_Protocol.impl);
    Device_Driver => classifier (TCP_IP_Protocol::Driver_TCP_IP_Protocol.impl);
    Initialize_Entrypoint => classifier (TCP_IP_Protocol::Initialize);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end generic_sockets_ip.pohiada;

  ------------------
  -- RTEMS NE2000 --
  ------------------

  device rtems_ne2000
  features
    link : requires bus access ocarina_buses::ip.i;
  end rtems_ne2000;

  device implementation rtems_ne2000.ip_pohic
  properties
    Deployment::Driver_Name       => "rtems_ne2000_sockets";
    Device_Driver                 => classifier (ocarina_drivers_rtems_ne2000::driver.i);
    Initialize_Entrypoint         => classifier (ocarina_drivers_rtems_ne2000::init);
    Provided_Virtual_Bus_Class    => (classifier (ocarina_buses::pohi.c));
  end rtems_ne2000.ip_pohic;

  ------------------------------------------
  --            Exarm UDP driver          --
  ------------------------------------------
  --  This driver is used to communicate  --
  --  with the exarm robot and also       --
  --  the Matlab simulator.               --
  ------------------------------------------

  device exarm_ip
  features
    link : requires bus access ocarina_buses::ip.i;
  end exarm_ip;

  device implementation exarm_ip.vr_udp
  properties
    Deployment::Driver_Name    => "exarm";
    Device_Driver              => classifier (ocarina_drivers_udp_exarm::driver.i);
    Initialize_Entrypoint      => classifier (ocarina_drivers_udp_exarm::init);
  end exarm_ip.vr_udp;

  data exarm_protocol_data
  end exarm_protocol_data;

  data implementation exarm_protocol_data.vr extends ocarina_drivers_udp_exarm::protocol.vr
  properties
    Data_Model::Data_Representation => Struct;
  end exarm_protocol_data.vr;

  data implementation exarm_protocol_data.robot extends ocarina_drivers_udp_exarm::protocol.robot
  properties
    Data_Model::Data_Representation => Struct;
  end exarm_protocol_data.robot;

  ---------------------------------------
  --   Devices for the Exo skeleton    --
  --  National Instruments PCI-6071E   --
  ---------------------------------------
  --  This device is used to make data --
  --  acquisition of the EXARM robot.  --
  ---------------------------------------

  device exarm_ni_6071e_analog
  features
    data1  : out data port Base_Types::Float_64;
    data2  : out data port Base_Types::Float_64;
    data3  : out data port Base_Types::Float_64;
    data4  : out data port Base_Types::Float_64;
    data5  : out data port Base_Types::Float_64;
    data6  : out data port Base_Types::Float_64;
    data7  : out data port Base_Types::Float_64;
    data8  : out data port Base_Types::Float_64;
    data9  : out data port Base_Types::Float_64;
    data10 : out data port Base_Types::Float_64;
    data11 : out data port Base_Types::Float_64;
    data12 : out data port Base_Types::Float_64;
    data13 : out data port Base_Types::Float_64;
    data14 : out data port Base_Types::Float_64;
    data15 : out data port Base_Types::Float_64;
    data16 : out data port Base_Types::Float_64;
  end exarm_ni_6071e_analog;

  device implementation exarm_ni_6071e_analog.i
  properties
    Deployment::Driver_Name    => "exarm_ni_6071e_analog";
    Device_Driver              => classifier (ocarina_drivers_exarm_ni_6071e_analog::driver.i);
    Initialize_Entrypoint      => classifier (ocarina_drivers_exarm_ni_6071e_analog::spg_init);
  end exarm_ni_6071e_analog.i;

  device exarm_ni_6071e_digital
  features
    data1  : out data port Base_Types::Unsigned_8;
    data2  : out data port Base_Types::Unsigned_8;
  end exarm_ni_6071e_digital;

  device implementation exarm_ni_6071e_digital.i
  properties
    Deployment::Driver_Name    => "exarm_ni_6071e_digital";
    Device_Driver              => classifier (ocarina_drivers_exarm_ni_6071e_digital::driver.i);
    Initialize_Entrypoint      => classifier (ocarina_drivers_exarm_ni_6071e_digital::spg_init);
  end exarm_ni_6071e_digital.i;

end ocarina_drivers;

package ocarina_types

public

with Data_Model;

data integer
end integer;

data implementation integer.i
properties
   Data_Model::Data_Representation => integer;
end integer.i;

data float
end float;

data implementation float.i
properties
   Data_Model::Data_Representation => float;
end float.i;

data boolean
end boolean;

data implementation boolean.i
properties
   Data_Model::Data_Representation => boolean;
end boolean.i;

end ocarina_types;
package ocarina_drivers_exarm_ni_6071e_analog

public

with Base_Types;
with Deployment;

subprogram spg_init
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_c_driver_exarm_ni_6071e_analog_init";
end spg_init;


subprogram spg_poller
features
   data1  : out parameter Base_Types::Float_64;
   data2  : out parameter Base_Types::Float_64;
   data3  : out parameter Base_Types::Float_64;
   data4  : out parameter Base_Types::Float_64;
   data5  : out parameter Base_Types::Float_64;
   data6  : out parameter Base_Types::Float_64;
   data7  : out parameter Base_Types::Float_64;
   data8  : out parameter Base_Types::Float_64;
   data9  : out parameter Base_Types::Float_64;
   data10 : out parameter Base_Types::Float_64;
   data11 : out parameter Base_Types::Float_64;
   data12 : out parameter Base_Types::Float_64;
   data13 : out parameter Base_Types::Float_64;
   data14 : out parameter Base_Types::Float_64;
   data15 : out parameter Base_Types::Float_64;
   data16 : out parameter Base_Types::Float_64;
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_c_driver_exarm_ni_6071e_analog_poller";
end spg_poller;


thread thr_poller
features
   data1  : out data port Base_Types::Float_64;
   data2  : out data port Base_Types::Float_64;
   data3  : out data port Base_Types::Float_64;
   data4  : out data port Base_Types::Float_64;
   data5  : out data port Base_Types::Float_64;
   data6  : out data port Base_Types::Float_64;
   data7  : out data port Base_Types::Float_64;
   data8  : out data port Base_Types::Float_64;
   data9  : out data port Base_Types::Float_64;
   data10 : out data port Base_Types::Float_64;
   data11 : out data port Base_Types::Float_64;
   data12 : out data port Base_Types::Float_64;
   data13 : out data port Base_Types::Float_64;
   data14 : out data port Base_Types::Float_64;
   data15 : out data port Base_Types::Float_64;
   data16 : out data port Base_Types::Float_64;
end thr_poller;

thread implementation thr_poller.i
calls
	mycall : {
	  pspg : subprogram spg_poller;
	};
connections
   parameter pspg.data1 -> data1;   
   parameter pspg.data2 -> data2;   
   parameter pspg.data3 -> data3;   
   parameter pspg.data4 -> data4;   
   parameter pspg.data5 -> data5;   
   parameter pspg.data6 -> data6;   
   parameter pspg.data7 -> data7;   
   parameter pspg.data8 -> data8;   
   parameter pspg.data9 -> data9;   
   parameter pspg.data10 -> data10;   
   parameter pspg.data11 -> data11;   
   parameter pspg.data12 -> data12;   
   parameter pspg.data13 -> data13;   
   parameter pspg.data14 -> data14;   
   parameter pspg.data15 -> data15;   
   parameter pspg.data16 -> data16; 
properties
   Period => 100 ms;
   Dispatch_Protocol => Periodic;
end thr_poller.i;


abstract driver
features
   data1  : out data port Base_Types::Float_64;
   data2  : out data port Base_Types::Float_64;
   data3  : out data port Base_Types::Float_64;
   data4  : out data port Base_Types::Float_64;
   data5  : out data port Base_Types::Float_64;
   data6  : out data port Base_Types::Float_64;
   data7  : out data port Base_Types::Float_64;
   data8  : out data port Base_Types::Float_64;
   data9  : out data port Base_Types::Float_64;
   data10 : out data port Base_Types::Float_64;
   data11 : out data port Base_Types::Float_64;
   data12 : out data port Base_Types::Float_64;
   data13 : out data port Base_Types::Float_64;
   data14 : out data port Base_Types::Float_64;
   data15 : out data port Base_Types::Float_64;
   data16 : out data port Base_Types::Float_64;
end driver;

abstract implementation driver.i
subcomponents
   ni6071e_analog_poller : thread thr_poller.i;
connections
   port ni6071e_analog_poller.data1 -> data1;   
   port ni6071e_analog_poller.data2 -> data2;   
   port ni6071e_analog_poller.data3 -> data3;   
   port ni6071e_analog_poller.data4 -> data4;   
   port ni6071e_analog_poller.data5 -> data5;   
   port ni6071e_analog_poller.data6 -> data6;   
   port ni6071e_analog_poller.data7 -> data7;   
   port ni6071e_analog_poller.data8 -> data8;   
   port ni6071e_analog_poller.data9 -> data9;   
   port ni6071e_analog_poller.data10 -> data10;   
   port ni6071e_analog_poller.data11 -> data11;   
   port ni6071e_analog_poller.data12 -> data12;   
   port ni6071e_analog_poller.data13 -> data13;   
   port ni6071e_analog_poller.data14 -> data14;   
   port ni6071e_analog_poller.data15 -> data15;   
   port ni6071e_analog_poller.data16 -> data16; 
end driver.i;

end ocarina_drivers_exarm_ni_6071e_analog;
package ocarina_drivers_exarm_ni_6071e_digital

public

with Base_Types;
with Deployment;

subprogram spg_init
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_c_driver_exarm_ni_6071e_digital_init";
end spg_init;


subprogram spg_poller
features
   data1 : out parameter Base_Types::Unsigned_32;
   data2 : out parameter Base_Types::Unsigned_32;
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_c_driver_exarm_ni_6071e_digital_poller";
end spg_poller;


thread thr_poller
features
   data1 : out data port Base_Types::Unsigned_32;
   data2 : out data port Base_Types::Unsigned_32;
end thr_poller;

thread implementation thr_poller.i
calls
	mycall : {
	  pspg : subprogram spg_poller;
	};
connections
   parameter pspg.data1 -> data1;   
   parameter pspg.data2 -> data2;   
properties
   Period => 100 ms;
   Dispatch_Protocol => Periodic;
end thr_poller.i;


abstract driver
features
   data1 : out data port Base_Types::Unsigned_32;
   data2 : out data port Base_Types::Unsigned_32;
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end driver;

abstract implementation driver.i
subcomponents
   ni6071e_digital_poller : thread thr_poller.i;
connections
   port ni6071e_digital_poller.data1 -> data1; 
   port ni6071e_digital_poller.data2 -> data2; 
end driver.i;

end ocarina_drivers_exarm_ni_6071e_digital;
package Generic_Bus
public

  ---------
  -- BUS --
  ---------

  -- Generic bus to model connections between processors and
  -- devices. It is not used by the code generation process, so it is
  -- made fully generic.

  bus Generic_Bus
  end Generic_Bus;

  bus implementation Generic_Bus.impl
  end Generic_Bus.impl;

end Generic_Bus;
package ocarina_drivers_generic_keyboard

public

with Base_Types;
with Deployment;

subprogram spg_generic_keyboard_init
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_generic_keyboard_init";
end spg_generic_keyboard_init;


thread keyboard_poller
features
   key_pressed : out data port Base_Types::Integer;
end keyboard_poller;

thread implementation keyboard_poller.i
calls
	mycall : {
	  pspg : subprogram spg_generic_keyboard_poller;
	};
connections
   parameter pspg.key_pressed -> key_pressed;
properties
   Period => 100ms;
   Dispatch_Protocol => Periodic;
end keyboard_poller.i;


subprogram spg_generic_keyboard_poller
features
   key_pressed : out parameter Base_Types::Integer;
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_generic_keyboard_poller";
end spg_generic_keyboard_poller;

abstract generic_keyboard_driver
features
   key_pressed : out data port Base_Types::Integer;
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end generic_keyboard_driver;


abstract implementation generic_keyboard_driver.i
subcomponents
   keyboard_receiver : thread       keyboard_poller.i;
connections
   port keyboard_receiver.key_pressed -> key_pressed;
end generic_keyboard_driver.i;


end ocarina_drivers_generic_keyboard;
package Generic_Native

-- This package models a generic native platform with one generic bus. 
--
-- Native platforms are GNU/Linux variants, MacOS X, Solaris, Windows,
-- ...

public
  with Deployment;
  with Generic_Bus;

  ---------------
  -- PROCESSOR --
  ---------------

  -- Generic_Processor is the basic description of a processor with
  -- one bus to connect an ethernet adapter. This ethernet adapter is
  -- used through the TCP_IP_Device defined in TCP_IP_Protocol
  -- package.

  processor Generic_Processor
  features
    eth0_tcp_ip : requires bus access Generic_Bus::Generic_Bus.impl;
    -- One ethernet card, connected to the processor. It is assumed
    -- later that it is used through a TCP/IP stack

  end Generic_Processor;

  processor implementation Generic_Processor.impl
  properties
    Deployment::Execution_Platform => Native;
    Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
    Priority_Range => 0 .. 255;
  end Generic_Processor.impl;

  ------------
  -- MEMORY --
  ------------

  memory Memory_Segment
  end Memory_Segment;

  memory implementation Memory_Segment.impl
  end Memory_Segment.impl;

end Generic_Native;
package GR_CPCI_X4CV

-- This package models the GR-Rasta GR-CPCI-XC4V LEON Compact-PCI
-- Development board by AEROFlex Gaisler.

public
  with Deployment;
  with Generic_Bus;
  
  ---------------
  -- PROCESSOR --
  ---------------

  -- The Rasta board has one LEON2 processor, 3 SpW cores and several
  -- UARTS.  
  -- 
  -- SpaceWire cores and UARTS are connected to separate bus, of type
  -- Generic_Bus.impl.

  processor LEON2
  features
    spw_core_1 : requires bus access Generic_Bus::Generic_Bus.impl;
    spw_core_2 : requires bus access Generic_Bus::Generic_Bus.impl;
    spw_core_3 : requires bus access Generic_Bus::Generic_Bus.impl;
    -- Three SpaceWire cores

    -- XXX Add UARTS
  end LEON2;

  processor implementation LEON2.impl
  properties
    Deployment::Execution_Platform => LEON_ORK;  -- for using GNATforLEON

    -- Information on the scheduler used by GNATforLEON

    Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
    Priority_Range => 0 .. 255;
  end LEON2.impl;

  ------------
  -- MEMORY --
  ------------

  memory Memory_Segment
  end Memory_Segment;

  memory implementation Memory_Segment.impl
  end Memory_Segment.impl;

end GR_CPCI_X4CV;
package GRSPW

-- This package models a SpaceWire-based protocol layer for the
-- PolyORB-HI/Ada AADL runtime, based on the GRSPW chipset from
-- AEROFlex Gaisler. It defines the subprograms and threads to be
-- integrated with the runtime low level interface.
--
-- To configure this interface, you should use the
-- Deployment::Configuration property with the following format:
--     "spacewire Sender_Core_id Receiver_Core_Id"
--
-- e.g.
--
--     spw : device GRSPW::GRSPW_Device
--            {Deployment::Configuration => "spacewire 1 2"};
--

public

   with Deployment;
   with GR_CPCI_X4CV;
   with Generic_Bus;

   ------------
   -- DEVICE --
   ------------

   -- The main entrypoint for this package is this device, it relies
   -- on the 'Implement_As' feature that defines its full
   -- specification.

   device GRSPW_Device
   features
      LVDS_Wire : requires bus access Generic_Bus::Generic_Bus.impl;
      -- Connection to the remote node

   end GRSPW_Device;

   device implementation GRSPW_Device.impl
   properties
      Implemented_As =>
         classifier (GRSPW::Driver_GRSPW_Protocol.impl);
      Initialize_Entrypoint => classifier (GRSPW::Initialize);
   end GRSPW_Device.impl;

   ------------
   -- DRIVER --
   ------------

   -- In AADLv2, we can model the actual implementation of a driver
   -- using an abstract component.

   abstract Driver_GRSPW_Protocol
   properties
      Deployment::Version  => "0.1beta";
      Deployment::Help     => "Write your ASN.1 configuration here";
      Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_spacewire);
   end Driver_GRSPW_Protocol;

   abstract implementation Driver_GRSPW_Protocol.impl
   subcomponents
      receiver : thread Driver_GRSPW_Protocol_thread_receiver.impl;
      sender : subprogram Send;
   end Driver_GRSPW_Protocol.impl;

   -------------
   -- THREADS --
   -------------

   -- This thread handles the execution logic of the protocol
   -- stack. It relies on the previous subprograms to receive
   -- messages.

   thread Driver_GRSPW_Protocol_thread_receiver

      -- This thread is dispatched when an event is detected on the
      -- real hardware. It then calls receive to handle the incoming
      -- event.

   properties
      Dispatch_Protocol => Background;
      Priority          => 12;
   end Driver_GRSPW_Protocol_thread_receiver;

   thread implementation Driver_GRSPW_Protocol_thread_receiver.impl
   calls
      call1 : { pspg : subprogram receive; };
   end Driver_GRSPW_Protocol_thread_receiver.impl;

   -----------------
   -- SUBPROGRAMS --
   -----------------

   -- These subprograms model the high-level view of the SpaceWire
   -- protocol stack. They define an API used by the stack to send and
   -- receive data, and perform node's initialisation.

   subprogram Initialize

     -- Initialize the different internal resources for managing
     -- connections on a node. This subprogram has no formal visible
     -- parameters, but relies on well-known data structures and
     -- variables to configure the stack.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRSPW.Initialize";
      Source_Language => Ada;
   end Initialize;

   -------------

   subprogram Receive

      -- Receive data and dispatch them to the receiving entity. This
      -- program and its sibling (send) share a common protocol, not
      -- defined in the AADL model.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRSPW.Receive";
      Source_Language => Ada;
   end Receive;

   -------------

   subprogram Send

      -- Send data to a remote node. This program and its sibling
      -- (receive) share a common protocol, not defined in the AADL
      -- model.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRSPW.Send";
      Source_Language => Ada;
   end Send;

end GRSPW;
package GRUART

-- This package models a UART-based protocol layer for the
-- PolyORB-HI/Ada AADL runtime, based on the GRUART chipset from
-- AEROFlex Gaisler. It defines the subprograms and threads to be
-- integrated with the runtime low level interface.
--
-- To configure this interface, you should use the
-- Deployment::Configuration property with the following format:
--     "serial DEVICE BAUDS DATA_BITS PARITY STOP_BIT"
--
-- e.g.
--
--     uart : device GRUART::GRUART_Device
--            {Deployment::Configuration => "serial /dev/ttyS0 9600 8 N 1"
--

public

   with Deployment;
   with GR_CPCI_X4CV;
   with Generic_Bus;

   ------------
   -- DEVICE --
   ------------

   -- The main entrypoint for this package is this device, it relies
   -- on the 'Implement_As' feature that defines its full
   -- specification.

   device GRUART_Device
   features
      DB9_Wire : requires bus access Generic_Bus::Generic_Bus.impl;
      -- Connection to the remote node

   end GRUART_Device;

   device implementation GRUART_Device.impl
   properties
      Implemented_As =>
         classifier (GRUART::Driver_GRUART_Protocol.impl);
      Initialize_Entrypoint => classifier (GRUART::Initialize);
   end GRUART_Device.impl;

   ------------
   -- DRIVER --
   ------------

   -- In AADLv2, we can model the actual implementation of a driver
   -- using an abstract component.

   abstract Driver_GRUART_Protocol
   properties
      Deployment::Configuration_Type
        => classifier (ocarina_drivers::configuration_type_serial);
      Deployment::Version  => "0.1beta";
      Deployment::Help     => "Write your ASN.1 configuration here";
   end Driver_GRUART_Protocol;

   abstract implementation Driver_GRUART_Protocol.impl
   subcomponents
      receiver : thread Driver_GRUART_Protocol_thread_receiver.impl;
      sender : subprogram Send;
   end Driver_GRUART_Protocol.impl;

   -------------
   -- THREADS --
   -------------

   -- This thread handles the execution logic of the protocol
   -- stack. It relies on the previous subprograms to receive
   -- messages.

   thread Driver_GRUART_Protocol_thread_receiver

      -- This thread is dispatched when an event is detected on the
      -- real hardware. It then calls receive to handle the incoming
      -- event.

   properties
      Dispatch_Protocol => Background;
      Priority          => 10;
      source_stack_size => 200 KByte;
   end Driver_GRUART_Protocol_thread_receiver;

   thread implementation Driver_GRUART_Protocol_thread_receiver.impl
   calls
      call1 : { pspg : subprogram receive; };
   end Driver_GRUART_Protocol_thread_receiver.impl;

   -----------------
   -- SUBPROGRAMS --
   -----------------

   -- These subprograms model the high-level view of the SpaceWire
   -- protocol stack. They define an API used by the stack to send and
   -- receive data, and perform node's initialisation.

   subprogram Initialize

     -- Initialize the different internal resources for managing
     -- connections on a node. This subprogram has no formal visible
     -- parameters, but relies on well-known data structures and
     -- variables to configure the stack.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRUART.Initialize";
      Source_Language => Ada;
   end Initialize;

   -------------

   subprogram Receive

      -- Receive data and dispatch them to the receiving entity. This
      -- program and its sibling (send) share a common protocol, not
      -- defined in the AADL model.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRUART.Receive";
      Source_Language => Ada;
   end Receive;

   -------------

   subprogram Send

      -- Send data to a remote node. This program and its sibling
      -- (receive) share a common protocol, not defined in the AADL
      -- model.

   properties
      Source_Name => "PolyORB_HI_Drivers_GRUART.Send";
      Source_Language => Ada;
   end Send;

end GRUART;
package ocarina_drivers_leon_eth

public

with Deployment;
with ocarina_buses;
with ocarina_drivers;

subprogram spg_leon_eth_poller
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_eth_leon_poller";
end spg_leon_eth_poller;


subprogram spg_leon_eth_sender
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_eth_leon_sender";
end spg_leon_eth_sender;

subprogram spg_leon_eth_init
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_eth_leon_init";
end spg_leon_eth_init;

thread thr_poller
end thr_poller;


thread implementation thr_poller.i
calls
	mycall : {
	  pspg : subprogram spg_leon_eth_poller;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end thr_poller.i;

abstract eth_driver
properties
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_ip);
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end eth_driver;

abstract implementation eth_driver.leon
subcomponents
   sender                : subprogram spg_leon_eth_sender;
end eth_driver.leon;

abstract implementation eth_driver.leon_sender
subcomponents
   sender                : subprogram spg_leon_eth_sender;
end eth_driver.leon_sender;


end ocarina_drivers_leon_eth;
package ocarina_drivers_leon_serial

public

with Deployment;
with ocarina_buses;
with ocarina_drivers;

subprogram spg_serial_poller_leon
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_leon_poller";
end spg_serial_poller_leon;


subprogram spg_serial_sender_leon
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_leon_sender";
end spg_serial_sender_leon;

subprogram spg_serial_init_leon
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_leon_init";
end spg_serial_init_leon;

subprogram spg_serial_init_leon_sender
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_leon_init_sender";
end spg_serial_init_leon_sender;

thread serial_poller
end serial_poller;


thread implementation serial_poller.leon
calls
	mycall : {
	  pspg : subprogram spg_serial_poller_leon;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end serial_poller.leon;

abstract serial_driver
properties
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_serial);
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end serial_driver;

abstract implementation serial_driver.leon
subcomponents
   receiver_leon_serial  : thread serial_poller.leon;
   sender                : subprogram spg_serial_sender_leon;
end serial_driver.leon;

abstract implementation serial_driver.leon_sender
subcomponents
   sender                : subprogram spg_serial_sender_leon;
end serial_driver.leon_sender;


end ocarina_drivers_leon_serial;
package Native_UART

-- This package models a UART protocol layer for the PolyORB-HI/Ada
-- AADL runtime. It defines the subprograms and threads to be
-- integrated with the runtime low level interface.
--
-- To configure this interface, you should use the
-- Deployment::Configuration property with the following format:
--     "serial DEVICE BAUDS DATA_BITS PARITY STOP_BIT"
--
-- e.g.
--
--     uart : device GRUART::GRUART_Device
--            {Deployment::Configuration => "serial /dev/ttyS0 9600 8 N 1"
--

public

   with Deployment;
   with Generic_Bus;

   ------------
   -- DEVICE --
   ------------

   -- The main entrypoint for this package is this device, it relies
   -- on the 'Implement_As' feature that defines its full
   -- specification.

   device Native_UART_Device
   features
      DB9_Wire : requires bus access Generic_Bus::Generic_Bus.impl;
      -- Connection to the remote node

   end Native_UART_Device;

   device implementation Native_UART_Device.impl
   properties
      Implemented_As =>
         classifier (Native_UART::Driver_Native_UART_Protocol.impl);
      Initialize_Entrypoint => classifier (Native_UART::Initialize);
   end Native_UART_Device.impl;

   ------------
   -- DRIVER --
   ------------

   -- In AADLv2, we can model the actual implementation of a driver
   -- using an abstract component.

   abstract Driver_Native_UART_Protocol
   properties
      Deployment::Configuration_Type
        => classifier (ocarina_drivers::configuration_type_serial);
      Deployment::Version  => "0.1beta";
      Deployment::Help     => "Write your ASN.1 configuration here";
   end Driver_Native_UART_Protocol;

   abstract implementation Driver_Native_UART_Protocol.impl
   subcomponents
      receiver : thread Driver_Native_UART_Protocol_thread_receiver.impl;
      sender : subprogram Send;
   end Driver_Native_UART_Protocol.impl;

   -------------
   -- THREADS --
   -------------

   -- This thread handles the execution logic of the protocol
   -- stack. It relies on the previous subprograms to receive
   -- messages.

   thread Driver_Native_UART_Protocol_thread_receiver

      -- This thread is dispatched when an event is detected on the
      -- real hardware. It then calls receive to handle the incoming
      -- event.

   properties
      Dispatch_Protocol => Background;
      Priority          => 10;
      source_stack_size => 200 KByte;
   end Driver_Native_UART_Protocol_thread_receiver;

   thread implementation Driver_Native_UART_Protocol_thread_receiver.impl
   calls
      call1 : { pspg : subprogram receive; };
   end Driver_Native_UART_Protocol_thread_receiver.impl;

   -----------------
   -- SUBPROGRAMS --
   -----------------

   -- These subprograms model the high-level view of the SpaceWire
   -- protocol stack. They define an API used by the stack to send and
   -- receive data, and perform node's initialisation.

   subprogram Initialize

     -- Initialize the different internal resources for managing
     -- connections on a node. This subprogram has no formal visible
     -- parameters, but relies on well-known data structures and
     -- variables to configure the stack.

   properties
      Source_Name => "PolyORB_HI_Drivers_Native_UART.Initialize";
      Source_Language => Ada;
   end Initialize;

   -------------

   subprogram Receive

      -- Receive data and dispatch them to the receiving entity. This
      -- program and its sibling (send) share a common protocol, not
      -- defined in the AADL model.

   properties
      Source_Name => "PolyORB_HI_Drivers_Native_UART.Receive";
      Source_Language => Ada;
   end Receive;

   -------------

   subprogram Send

      -- Send data to a remote node. This program and its sibling
      -- (receive) share a common protocol, not defined in the AADL
      -- model.

   properties
      Source_Name => "PolyORB_HI_Drivers_Native_UART.Send";
      Source_Language => Ada;
   end Send;

end Native_UART;
package ocarina_drivers_rasta_1553

public
with Deployment;

subprogram spg_1553_controller_rasta
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_controller";
end spg_1553_controller_rasta;

subprogram spg_1553_poller_rasta_terminal
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_terminal_poller";
end spg_1553_poller_rasta_terminal;

subprogram spg_1553_sender_rasta_controller
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_sender_controller";
end spg_1553_sender_rasta_controller;

subprogram spg_1553_sender_rasta_terminal
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_sender_terminal";
end spg_1553_sender_rasta_terminal;


subprogram spg_1553_init_rasta_controller
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_init_controller";
end spg_1553_init_rasta_controller;


subprogram spg_1553_init_rasta_terminal
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_c_driver_1553_rasta_init_terminal";
end spg_1553_init_rasta_terminal;



thread if1553_poller
end if1553_poller;

thread implementation if1553_poller.rasta_terminal
calls
	mycall : {
	  pspg : subprogram spg_1553_poller_rasta_terminal;
	};
properties
   Period => 2000ms;
   Dispatch_Protocol => Periodic;
end if1553_poller.rasta_terminal;

thread if1553_controller
end if1553_controller;

thread implementation if1553_controller.rasta
calls
	mycall : {
	  pspg : subprogram spg_1553_controller_rasta;
	};
properties
   Period => 4000ms;
   Dispatch_Protocol => Periodic;
end if1553_controller.rasta;



abstract if1553_driver
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end if1553_driver;

abstract implementation if1553_driver.rasta_terminal
subcomponents
   receiver_rasta_1553 : thread       if1553_poller.rasta_terminal;
   sender              : subprogram   spg_1553_sender_rasta_terminal;
end if1553_driver.rasta_terminal;

abstract implementation if1553_driver.rasta_controller_sender_only
subcomponents
--   controller  : thread       if1553_controller.rasta;
--   This thread (controller) should be a poller thread that
--   gives orders to the terminal nodes to send/receive data.
--   It should also specify the communication policy (when a terminal
--   is authorized to send/receive data).

--   We don't specify poller and receiver since this controller
--   is just a node that sends data to a single other node.

   sender      : subprogram   spg_1553_sender_rasta_controller;
end if1553_driver.rasta_controller_sender_only;


end ocarina_drivers_rasta_1553;
package ocarina_drivers_rasta_serial

public

with Deployment;
with ocarina_buses;
with ocarina_drivers;

subprogram spg_serial_poller_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_rasta_poller";
end spg_serial_poller_rasta;


subprogram spg_serial_sender_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_rasta_sender";
end spg_serial_sender_rasta;




subprogram spg_serial_init_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_rasta_init";
end spg_serial_init_rasta;


thread serial_poller
end serial_poller;


thread implementation serial_poller.rasta
calls
	mycall : {
	  pspg : subprogram spg_serial_poller_rasta;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end serial_poller.rasta;

abstract serial_driver
properties
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_serial);
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end serial_driver;

abstract implementation serial_driver.rasta
subcomponents
   receiver_rasta_serial : thread serial_poller.rasta;
   sender                : subprogram spg_serial_sender_rasta;
end serial_driver.rasta;

end ocarina_drivers_rasta_serial;
package ocarina_drivers_rasta_spacewire

public

with ocarina_buses;
with Deployment;

subprogram spg_spacewire_poller_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spacewire_rasta_poller";
end spg_spacewire_poller_rasta;

subprogram spg_spacewire_sender_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spacewire_rasta_sender";
end spg_spacewire_sender_rasta;

subprogram spg_spacewire_init_rasta
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spacewire_rasta_init";
end spg_spacewire_init_rasta;


thread spacewire_poller
end spacewire_poller;

thread implementation spacewire_poller.rasta
calls
	mycall : {
	  pspg : subprogram spg_spacewire_poller_rasta;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end spacewire_poller.rasta;


abstract spacewire_driver
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_spacewire);
end spacewire_driver;

abstract implementation spacewire_driver.rasta
subcomponents
   receiver_rasta_spacewire : thread spacewire_poller.rasta;
   sender                   : subprogram spg_spacewire_sender_rasta;
end spacewire_driver.rasta;

end ocarina_drivers_rasta_spacewire;
package ocarina_drivers_star_dundee_spacewire_brick
public

with ocarina_buses;
with Deployment;

subprogram spg_poller
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spw_usb_brick_poller";
end spg_poller;

subprogram spg_sender
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spw_usb_brick_sender";
end spg_sender;

subprogram spg_init
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_spw_usb_brick_init";
end spg_init;


thread thr_poller
end thr_poller;

thread implementation thr_poller.i
calls
	mycall : {
	  pspg : subprogram spg_poller;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end thr_poller.i;


abstract driver
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_spacewire);
end driver;

abstract implementation driver.usb_brick
subcomponents
   receiver_rasta_spacewire : thread thr_poller.i;
   sender                   : subprogram spg_sender;
end driver.usb_brick;

end ocarina_drivers_star_dundee_spacewire_brick;
package ocarina_drivers_serial

public

with Deployment;
with ocarina_drivers;

subprogram spg_serial_poller_linux
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_linux_poller";
end spg_serial_poller_linux;


subprogram spg_serial_sender_linux
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_linux_sender";
end spg_serial_sender_linux;


subprogram spg_serial_init_linux
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_linux_init";
end spg_serial_init_linux;

subprogram spg_serial_init_linux_sender
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_linux_init_sender";
end spg_serial_init_linux_sender;

subprogram spg_serial_init_linux_receiver
properties
	Source_Language => C;
	Source_Name => "__po_hi_c_driver_serial_linux_init_receiver";
end spg_serial_init_linux_receiver;

thread serial_poller
end serial_poller;

thread implementation serial_poller.linux
calls
	mycall : {
	  pspg : subprogram spg_serial_poller_linux;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end serial_poller.linux;


abstract serial_driver
properties
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_serial);
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end serial_driver;

abstract implementation serial_driver.linux
subcomponents
   serial_linux_receiver : thread serial_poller.linux;
   sender                : subprogram spg_serial_sender_linux;
end serial_driver.linux;

abstract implementation serial_driver.linux_sender
subcomponents
   sender                : subprogram spg_serial_sender_linux;
end serial_driver.linux_sender;


abstract implementation serial_driver.linux_receiver
subcomponents
   serial_linux_receiver : thread serial_poller.linux;
end serial_driver.linux_receiver;

end ocarina_drivers_serial;
package ocarina_drivers_ip_pohic

public
with Deployment;
with ocarina_drivers;

subprogram spg_sockets_init
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_sockets_init";
end spg_sockets_init;


subprogram spg_eth_linux_sender
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_sockets_send";
end spg_eth_linux_sender;

subprogram implementation spg_eth_linux_sender.i
end spg_eth_linux_sender.i;

abstract sockets_impl
properties
   Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_ip);
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end sockets_impl;

abstract implementation sockets_impl.i
subcomponents
   sender   : subprogram   spg_eth_linux_sender.i;
end sockets_impl.i;

end ocarina_drivers_ip_pohic;
package ocarina_drivers_rtems_ne2000

public

with Deployment;

subprogram init
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_rtems_ne2000_init";
end init;

thread poller
end poller;

thread implementation poller.i
calls
	mycall : {
	  pspg : subprogram spg_poller;
	};
properties
   Period => 1000ms;
   Dispatch_Protocol => Periodic;
end poller.i;


subprogram spg_poller
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_rtems_ne2000_poller";
end spg_poller;


subprogram spg_sender
properties
	Source_Language   => C;
	Source_Name       => "__po_hi_driver_sockets_send";
end spg_sender;


abstract driver
properties
   Deployment::Version  => "0.1beta";
   Deployment::Help     => "Write your ASN.1 configuration here";
end driver;


abstract implementation driver.i
subcomponents
--  receiver : thread       eth_sockets_ne2000_rtems_poller.i;
   sender   : subprogram   spg_sender;
end driver.i;

end ocarina_drivers_rtems_ne2000;
package TCP_IP_Protocol

-- This package models a TCP/IP based protocol layer for the
-- PolyORB-HI/Ada AADL runtime. It defines the subprograms and threads
-- to be integrated with the runtime low level interface.
--
-- To configure this interface, you should use the
-- Deployment::Configuration property with the following format:
--     "ip <ipv4_addresse> <ipv4_port>"
--
-- e.g.
--
--     netif : device TCP_IP_Protocol::TCP_IP_Device
--            {Deployment::Configuration => "ip 192.168.0.10 45678";}:

public

   with Generic_Bus;
   with Deployment;

   ------------
   -- DEVICE --
   ------------

   -- The main entrypoint for this package is this device, it relies
   -- on the 'Implement_As' feature that defines its full
   -- specification.

   device TCP_IP_Device
   features
      Ethernet_Wire : requires bus access Generic_Bus::Generic_Bus.impl;
      -- Connection to the remote node

   end TCP_IP_Device;

   device implementation TCP_IP_Device.impl
   properties
      Implemented_As =>
         classifier (TCP_IP_Protocol::Driver_TCP_IP_Protocol.impl);
      Initialize_Entrypoint => classifier (TCP_IP_Protocol::Initialize);
   end TCP_IP_Device.impl;

   ------------
   -- DRIVER --
   ------------

   -- In AADLv2, we can model the actual implementation of a driver
   -- using an abstract component.

   abstract Driver_TCP_IP_Protocol
   properties
      Deployment::Configuration_Type => classifier (ocarina_drivers::configuration_type_ip);
      Deployment::Version  => "0.1beta";
      Deployment::Help     => "Write your ASN.1 configuration here";
   end Driver_TCP_IP_Protocol;

   abstract implementation Driver_TCP_IP_Protocol.impl
   subcomponents
      receiver : thread Driver_TCP_IP_Protocol_thread_receiver.impl;
      sender : subprogram Send;
   end Driver_TCP_IP_Protocol.impl;

   -------------
   -- THREADS --
   -------------

   -- This thread handles the execution logic of the protocol
   -- stack. It relies on the previous subprograms to receive
   -- messages.

   thread Driver_TCP_IP_Protocol_thread_receiver

      -- This thread is dispatched when an event is detected on the
      -- real hardware. It then calls receive to handle the incoming
      -- event.

   properties
      -- Initialize_Entrypoint
      --    => classifier (TCP_IP_Protocol::Initialize_Receiver);
      Dispatch_Protocol => Background;
   end Driver_TCP_IP_Protocol_thread_receiver;

   thread implementation Driver_TCP_IP_Protocol_thread_receiver.impl
   calls
      call1 : { pspg : subprogram receive; };
   end Driver_TCP_IP_Protocol_thread_receiver.impl;

   -----------------
   -- SUBPROGRAMS --
   -----------------

   -- These subprograms model the high-level view of the TCP/IP
   -- protocol stack. They define an API used by the stack to send and
   -- receive data, and perform node's initialisation.

   subprogram Initialize

     -- Initialize the different internal resources for managing
     -- connections on a node. This subprogram has no formal visible
     -- parameters, but relies on well-known data structures and
     -- variables to configure the stack.

   properties
      Source_Name => "POlyORB_HI_Drivers_Native_TCP_IP.Initialize";
      Source_Language => Ada;
   end Initialize;

   -------------

   subprogram Initialize_Receiver

     -- Initialize the receiver thread

   properties
      Source_Name => "POlyORB_HI_Drivers_Native_TCP_IP.Initialize_Receiver";
      Source_Language => Ada;
   end Initialize_Receiver;

   -------------

   subprogram Receive

      -- Receive data and dispatch them to the receiving entity. This
      -- program and its sibling (send) share a common protocol, not
      -- defined in the AADL model.

   properties
      Source_Name => "POlyORB_HI_Drivers_Native_TCP_IP.Receive";
      Source_Language => Ada;
   end Receive;

   -------------

   subprogram Send

      -- Send data to a remote node. This program and its sibling
      -- (receive) share a common protocol, not defined in the AADL
      -- model.

   properties
      Source_Name => "POlyORB_HI_Drivers_Native_TCP_IP.Send";
      Source_Language => Ada;
   end Send;

end TCP_IP_Protocol;
package ocarina_drivers_udp_exarm

public

with Data_Model;
with Base_Types;

data protocol
properties
   Data_Model::Data_Representation => Struct;
end protocol;

data implementation protocol.robot
subcomponents
   cmd   : data Base_Types::Unsigned_32;
   pktid : data Base_Types::Unsigned_32;
   X1    : data Base_Types::Float_32;
   X2    : data Base_Types::Float_32;
   X3    : data Base_Types::Float_32;
   Y1    : data Base_Types::Float_32;
   Y2    : data Base_Types::Float_32;
   Y3    : data Base_Types::Float_32;
   Z1    : data Base_Types::Float_32;
   Z2    : data Base_Types::Float_32;
   Z3    : data Base_Types::Float_32;
   P1    : data Base_Types::Float_32;
   P2    : data Base_Types::Float_32;
   P3    : data Base_Types::Float_32;
   J1    : data Base_Types::Float_32;
   J2    : data Base_Types::Float_32;
   J3    : data Base_Types::Float_32;
   J4    : data Base_Types::Float_32;
   J5    : data Base_Types::Float_32;
   J6    : data Base_Types::Float_32;
   J7    : data Base_Types::Float_32;
   Elbow : data Base_Types::Float_32;
end protocol.robot;


data implementation protocol.vr
subcomponents
   J1    : data Base_Types::Float_64;
   J2    : data Base_Types::Float_64;
   J3    : data Base_Types::Float_64;
   J4    : data Base_Types::Float_64;
   J5    : data Base_Types::Float_64;
   J6    : data Base_Types::Float_64;
   J7    : data Base_Types::Float_64;
   J8    : data Base_Types::Float_64;
   J9    : data Base_Types::Float_64;
   J10    : data Base_Types::Float_64;
   J11    : data Base_Types::Float_64;
   J12    : data Base_Types::Float_64;
   J13    : data Base_Types::Float_64;
   J14    : data Base_Types::Float_64;
   J15    : data Base_Types::Float_64;
   J16    : data Base_Types::Float_64;
   P1    : data Base_Types::Float_64;
   P2    : data Base_Types::Float_64;
   P3    : data Base_Types::Float_64;
   X1    : data Base_Types::Float_64;
   X2    : data Base_Types::Float_64;
   X3    : data Base_Types::Float_64;
   Y1    : data Base_Types::Float_64;
   Y2    : data Base_Types::Float_64;
   Y3    : data Base_Types::Float_64;
   Z1    : data Base_Types::Float_64;
   Z2    : data Base_Types::Float_64;
   Z3    : data Base_Types::Float_64;
end protocol.vr;


subprogram init
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_driver_exarm_init";
end init;

subprogram spg_sender
properties
   Source_Language   => C;
   Source_Name       => "__po_hi_driver_exarm_send";
end spg_sender;

abstract driver
end driver;

abstract implementation driver.i
subcomponents
   sender : subprogram spg_sender;
end driver.i;

end ocarina_drivers_udp_exarm;
package ocarina_processors_arm

public

with Deployment;
with Cheddar_Properties;

processor arm
end arm;

processor nds extends arm
end nds;

processor implementation nds.rtems
properties
   Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
   Priority_Range => 0 .. 255;
   Cheddar_Properties::Scheduler_Quantum => 0 Ms;
   Cheddar_Properties::Preemptive_Scheduler => true;
   Deployment::Execution_Platform => NDS_RTEMS;
end nds.rtems;


processor gumstix extends arm
end gumstix;

processor implementation gumstix.rtems
properties
   Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
   Priority_Range => 0 .. 255;
   Cheddar_Properties::Scheduler_Quantum => 0 Ms;
   Cheddar_Properties::Preemptive_Scheduler => true;
   Deployment::Execution_Platform => GUMSTIX_RTEMS;
end gumstix.rtems;

end ocarina_processors_arm;
package ocarina_processors_leon

public

with Deployment;
with ARINC653;
with Cheddar_Properties;

processor leon
end leon;

processor implementation leon.rtems
properties
   Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
   Priority_Range => 0 .. 255;
   Cheddar_Properties::Scheduler_Quantum => 0 Ms;
   Cheddar_Properties::Preemptive_Scheduler => true;
   Deployment::Execution_Platform => LEON_RTEMS;
end leon.rtems;

processor implementation leon.rtems_posix
properties
   Scheduling_Protocol => (Posix_1003_Highest_Priority_First_Protocol);
   Priority_Range => 0 .. 255;
   Cheddar_Properties::Scheduler_Quantum => 0 Ms;
   Cheddar_Properties::Preemptive_Scheduler => true;
   Deployment::Execution_Platform => LEON_RTEMS_POSIX;
end leon.rtems_posix;


processor implementation leon.ork
properties
   Deployment::Execution_Platform => LEON_ORK;
end leon.ork;

processor leon3
end leon3;

virtual processor xtratum_partition
end xtratum_partition;

virtual processor implementation xtratum_partition.generic
end xtratum_partition.generic;

processor implementation leon3.xtratum
properties
   Deployment::Execution_Platform => LEON3_XTRATUM;
end leon3.xtratum;

processor implementation leon3.xtratum_2partitions extends leon3.xtratum
subcomponents
	part1 : virtual processor xtratum_partition.generic
      { Deployment::Execution_Platform => LEON3_XM3;};
	part2 : virtual processor xtratum_partition.generic
      { Deployment::Execution_Platform => LEON3_XM3;};
properties
   ARINC653::Partition_Slots => (500ms, 500ms);
   ARINC653::Slots_Allocation => (reference (part1), reference (part2));
	ARINC653::Module_Major_Frame => 1000ms;
end leon3.xtratum_2partitions;

end ocarina_processors_leon;
package ocarina_processors_x86

public

with Deployment;

processor x86
properties
   Scheduling_Protocol => (RATE_MONOTONIC_PROTOCOL);
   Deployment::Execution_Platform => Native;
end x86;

processor implementation x86.linux
properties
   Deployment::Execution_Platform => Native;
end x86.linux;

processor implementation x86.linux_bench
properties
   Scheduling_Protocol => (RATE_MONOTONIC_PROTOCOL);
   Deployment::Execution_Platform => bench;
end x86.linux_bench;

2539
processor implementation x86.native
2540 2541
properties
   Deployment::Execution_Platform => Linux32;
2542
end x86.native;
2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579

processor implementation x86.linux64
properties
   Deployment::Execution_Platform => Linux64;
end x86.linux64;

processor implementation x86.native
properties
   Deployment::Execution_Platform => Native;
end x86.native;

processor implementation x86.native_compcert
properties
   Deployment::Execution_Platform => Native_Compcert;
end x86.native_compcert;

processor implementation x86.rtems
properties
   Deployment::Execution_Platform => X86_RTEMS;
end x86.rtems;

processor implementation x86.rtems_posix
properties
   Deployment::Execution_Platform => X86_RTEMS_POSIX;
end x86.rtems_posix;

processor implementation x86.xenomai_posix
properties
   Deployment::Execution_Platform => linux32_xenomai_posix;
end x86.xenomai_posix;

processor implementation x86.xenomai_native
properties
   Deployment::Execution_Platform => linux32_xenomai_native;
end x86.xenomai_native;

end ocarina_processors_x86;