Compare commits
1636 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 123e620f50 | |||
| b5a7720c24 | |||
| 152937ca32 | |||
| 3c85fbef6f | |||
| 4ff8f044c4 | |||
| 22a2095cd7 | |||
| 9c10e4ba53 | |||
| 0529f84511 | |||
| da63ff03d3 | |||
| 141dcb70a3 | |||
| 8625222e36 | |||
| 498652836c | |||
| dbfd4364e3 | |||
| bd049e4fec | |||
| f20b6634ae | |||
| b59472ad2d | |||
| a75b3ba58f | |||
| 8c3d8f46df | |||
| ca29a325f1 | |||
| 61aee1a3e6 | |||
| 162b528385 | |||
| b6e30d25f5 | |||
| db8d7bf0af | |||
| 48d770b271 | |||
| 88d1fc0a5e | |||
| 9769d38897 | |||
| 8be3c30b23 | |||
| 916a8f5dc7 | |||
| 25cc8b16fa | |||
| 67bf8b67dd | |||
| 13dfdbd502 | |||
| e0ae30d40d | |||
| 2c3a0a7ee8 | |||
| f1086df363 | |||
| 6345ee875a | |||
| 69061f9afd | |||
| 3aecb50b47 | |||
| e030578fd8 | |||
| c05fefe71c | |||
| 177b56e8f9 | |||
| aeb7a8afaf | |||
| 0edaa77857 | |||
| c656eebcbc | |||
| e17e78bc18 | |||
| c3235e985f | |||
| 656e0fb485 | |||
| d3dd5270dd | |||
| e588b30c8b | |||
| d3f9aec31c | |||
| ed617c88c9 | |||
| 0b8f4c2414 | |||
| b5449b7404 | |||
| a3c1241f38 | |||
| bbf60ebfed | |||
| 0e9f40bdd5 | |||
| e32897f6b5 | |||
| 6ee4b47d90 | |||
| dac19f62b2 | |||
| 8e6d112729 | |||
| 9e1dc1e3f4 | |||
| 49fb3afc01 | |||
| f3b402fce9 | |||
| ef9a38d7fc | |||
| 67275a7921 | |||
| 0ddaa02414 | |||
| 96d5735164 | |||
| ac32fb9c73 | |||
| 9acc242ff6 | |||
| d8a403c410 | |||
| f1d0acef23 | |||
| 9811572f47 | |||
| 8753e2ddc6 | |||
| f6167c25ca | |||
| cb3894712e | |||
| 995a47e200 | |||
| cde9096018 | |||
| 6c1bd24b92 | |||
| 0c129bc99b | |||
| cbe9bd8211 | |||
| 0293647d0c | |||
| 87d187c3a5 | |||
| 09fbfd9dda | |||
| 74ca631309 | |||
| 03e86e175d | |||
| 1c54525256 | |||
| d49874a666 | |||
| 6d6ba43d81 | |||
| 4914498732 | |||
| 85220734de | |||
| 7531a6638b | |||
| 4088a4d38b | |||
| 1b3d057d33 | |||
| 17e1846afa | |||
| 0407690197 | |||
| 55e8b37f13 | |||
| fb4c0a59e8 | |||
| ea3d146c86 | |||
| cddafdffff | |||
| 05e953d6e2 | |||
| 9b7e960bec | |||
| c3aa2f7178 | |||
| 5b4970d814 | |||
| 46c43afa26 | |||
| 6bcfc74d1a | |||
| 4d920209f7 | |||
| 52f8708905 | |||
| b7024363ee | |||
| 1a6d30606c | |||
| e72698dea3 | |||
| 3100dded42 | |||
| 53584f2b5b | |||
| b2d924228a | |||
| f3de02477d | |||
| 77a2bc2d8f | |||
| c56a07ead8 | |||
| 2e3ca56ece | |||
| b8588393b7 | |||
| ea33b37080 | |||
| ea7815dc64 | |||
| 2340b0e88c | |||
| d05d42415a | |||
| e34db21efd | |||
| f6a1a9fa4e | |||
| a567483ffa | |||
| 9dc0a0109a | |||
| afd9ac1223 | |||
| 30ff3a6d69 | |||
| 50781513dc | |||
| fab091d3ec | |||
| b734f2d44c | |||
| 576c6e5177 | |||
| 70a8640327 | |||
| 72d95dac61 | |||
| 84367ae2d3 | |||
| c06a9a996e | |||
| 699c6d1365 | |||
| cbad40dc5a | |||
| 53afd6dd2f | |||
| 5f12e4b10d | |||
| 28f6c39288 | |||
| ec7bd09b70 | |||
| dc6ac4cf19 | |||
| 15cde79313 | |||
| ac6767f082 | |||
| 4f7c2205b0 | |||
| f576158d38 | |||
| 47fc620923 | |||
| 897270dab4 | |||
| 3becd44444 | |||
| 4bfa35858d | |||
| d6068f8e5c | |||
| 2ea33f0269 | |||
| f9da0bbad4 | |||
| 46bd7e04cf | |||
| e3a04ad8e5 | |||
| 6cfde66c24 | |||
| f9f0aeaf87 | |||
| 1856096cf3 | |||
| eb1b4ddf30 | |||
| e960b0859a | |||
| bcebfaa777 | |||
| 5be3e2ec10 | |||
| 49f2f6b1ea | |||
| 9afe79edfb | |||
| fc67ea915e | |||
| 7b866d025a | |||
| 13864e766a | |||
| ee0ff789f3 | |||
| 7f6a871501 | |||
| d4681171b4 | |||
| 52139ec1b1 | |||
| 9b61eda6c2 | |||
| 142c8c38e1 | |||
| e1acbf5681 | |||
| 0bc5b8bfb8 | |||
| 3e8bbbeaf8 | |||
| 4c88d96928 | |||
| ffeb980a39 | |||
| b0ced97ffb | |||
| 1876714222 | |||
| 075e65604b | |||
| 7dbc090909 | |||
| c95e379cd1 | |||
| 9284cfacfc | |||
| dcced24976 | |||
| 286164a76d | |||
| 51d2e88978 | |||
| 29b73a88ae | |||
| 99f2e53b34 | |||
| 6d14af0e18 | |||
| 43282ac881 | |||
| 67a82d0cb1 | |||
| aec07f750b | |||
| 5c38dd785a | |||
| 46473fbae0 | |||
| cf876bfaf9 | |||
| 2fe991a23b | |||
| b9f8938c0e | |||
| 14129b8b3c | |||
| 502daf7204 | |||
| 3013e88dca | |||
| d37cf0f694 | |||
| 4cf062fb06 | |||
| 4a8e090ff1 | |||
| 576df09f24 | |||
| 3a01d5cc2c | |||
| 165c89e6aa | |||
| 9eaedfc0e5 | |||
| 5eba9eff3a | |||
| b985a09863 | |||
| 68aa82bbd8 | |||
| 6b1c0ca9aa | |||
| d176628edb | |||
| 8548712049 | |||
| bc819082cc | |||
| 64fb0fc78a | |||
| 0a4303dff0 | |||
| caa0bfaf8d | |||
| c6e300bfff | |||
| cf1d92d9ec | |||
| 25796a879d | |||
| f6e8385a8f | |||
| b52ea2fe1e | |||
| 2a6920a3d3 | |||
| fac1427eb6 | |||
| ed13172c92 | |||
| 07ebae4f64 | |||
| 1391ebd695 | |||
| 6cf988a54c | |||
| 76b74b53f9 | |||
| 786991d971 | |||
| c33b46521e | |||
| fc41b62329 | |||
| ab2eeb7f96 | |||
| bc3106fc26 | |||
| f2d404ed60 | |||
| 53038c0c84 | |||
| b835a0136b | |||
| e12102a8a7 | |||
| 728b9ae8bf | |||
| 9f5a6a09de | |||
| d26da674f5 | |||
| b781023863 | |||
| a42f6441fa | |||
| 2c4122bb77 | |||
| a05b81a7b4 | |||
| 2c8cc334e2 | |||
| 59786e995f | |||
| ebc1d29195 | |||
| 2d8d706141 | |||
| eb25a2e674 | |||
| 241ff38555 | |||
| 059bc76536 | |||
| 4678e304ee | |||
| db7d1e1141 | |||
| 218997b6b3 | |||
| f05c37d53e | |||
| 90767f36e5 | |||
| 81b1ff935a | |||
| 0f5f228707 | |||
| f0ea8bfcf5 | |||
| a2f0d62819 | |||
| e238d117a9 | |||
| 82dbe82bd1 | |||
| 8ba6180c8c | |||
| e2d5470b47 | |||
| 2532e703ae | |||
| 10497683c8 | |||
| 53932d4cb3 | |||
| 7b0f5ce687 | |||
| 653c2059e2 | |||
| 5c949be67c | |||
| c73ab1bbd4 | |||
| 083cbb0611 | |||
| f998c01010 | |||
| faf57cba6a | |||
| 83b70de310 | |||
| b4fb63f1e8 | |||
| 832fe1695f | |||
| d6b6b65e5f | |||
| 1698f0b544 | |||
| d10a6d16a8 | |||
| f864acfa26 | |||
| ba7703a772 | |||
| b7739ab42d | |||
| a6208f00d0 | |||
| c53a2d8872 | |||
| 9c69e16046 | |||
| cc57bc47a6 | |||
| b2b07ae05f | |||
| fec9ddcdf8 | |||
| 3eb17d14e6 | |||
| 8ca4eb3812 | |||
| 8341560686 | |||
| 39f39773b8 | |||
| a01c9b9dc0 | |||
| 124ca6ea84 | |||
| befb4f80e2 | |||
| 5a7980dca5 | |||
| 889a3d4147 | |||
| 0245adae4a | |||
| 8b94eaa6dd | |||
| 323dc2cf77 | |||
| e89cd406e4 | |||
| 8de29a213c | |||
| 571edc35aa | |||
| ee04ca568e | |||
| 67ef9adad1 | |||
| 4ec0bb12f7 | |||
| 5f5921e411 | |||
| da6a3f90f9 | |||
| 21135acf32 | |||
| b8e052de0d | |||
| cf33bcba2a | |||
| 45e7e2d5b7 | |||
| 04286e891d | |||
| 2e4720c607 | |||
| 5333cd9c98 | |||
| a116cbfa3e | |||
| bae6a4bce3 | |||
| bc10083c25 | |||
| 6f7cea2590 | |||
| f3c010ebf8 | |||
| ffbdd27df0 | |||
| 4f9fb2b8fb | |||
| f7d2b168d4 | |||
| 5a9a3754e7 | |||
| 97040855af | |||
| 77ee73a878 | |||
| cbd8f96f60 | |||
| 631396c50e | |||
| d25103373e | |||
| 8ddb66393d | |||
| f8d37fcf20 | |||
| a22253e384 | |||
| 116d4cfb76 | |||
| bd070a4ce8 | |||
| 5beb62613f | |||
| e27204bd50 | |||
| 34e9c644c5 | |||
| 74d2024731 | |||
| 7615f141ef | |||
| 38a45cdb1d | |||
| 9623751337 | |||
| dbf25c5712 | |||
| 7b2a51ee24 | |||
| bf57c10785 | |||
| 854e82a198 | |||
| 3107807268 | |||
| dff6c0a9e2 | |||
| 8480f60266 | |||
| 8808490caa | |||
| 59a4d9dafe | |||
| 1d8d987d22 | |||
| 5538e13e69 | |||
| 1b75ccb056 | |||
| 131051e227 | |||
| e0e116b1d1 | |||
| 9a9cf40c74 | |||
| 246052bf9c | |||
| 66229c2821 | |||
| 347259fe7e | |||
| d1b3aa9506 | |||
| 6cdecd9e87 | |||
| 56937a0780 | |||
| cb1ca49985 | |||
| 7e9dfbc4c2 | |||
| d86b008bb1 | |||
| ceac955327 | |||
| 64effd5a02 | |||
| c7d531f0a5 | |||
| 37caa92565 | |||
| 4c04c57728 | |||
| 9bc16f7687 | |||
| e11eae5302 | |||
| 2269a2b4d7 | |||
| 3ffa567f1b | |||
| de4d766ed5 | |||
| 7b5d46edff | |||
| 7399ddce01 | |||
| 7e16a54533 | |||
| 778495a07a | |||
| 527a90f732 | |||
| 4e01c27e8e | |||
| a71e456e81 | |||
| df1c1f9f7e | |||
| 06584e7d1c | |||
| 5ea5b16d89 | |||
| 10e2d12bc2 | |||
| 857388b204 | |||
| 78d788cab2 | |||
| 02185083f5 | |||
| aeca114c5f | |||
| 7b4f2b5828 | |||
| 7b075f40a3 | |||
| 6c68c67f0e | |||
| fd9f0ef321 | |||
| cb44628316 | |||
| 63fd8cf1df | |||
| cc39131466 | |||
| e71e064846 | |||
| 1356a8c8af | |||
| d9b6340f23 | |||
| 2709baf8e8 | |||
| 046fae3617 | |||
| 688868fb48 | |||
| 5967b6ebc6 | |||
| d9e9a2102e | |||
| 065517a7cc | |||
| 0691725819 | |||
| 5954a965dc | |||
| 788aca30ef | |||
| bda30b15b5 | |||
| 32523d6f88 | |||
| 300707871e | |||
| b21bdf57be | |||
| 3067a5eafe | |||
| ec4e48725c | |||
| 8322623699 | |||
| c588d4d377 | |||
| 9e23b67e03 | |||
| 0d4f77d25a | |||
| 0a16b06c78 | |||
| c6b6ff420d | |||
| 221c301739 | |||
| 5355e584a3 | |||
| 9fa2c0eb1a | |||
| 03a1e5a633 | |||
| 968150e9b7 | |||
| ef7484569d | |||
| 9cc483da5a | |||
| eb9609da00 | |||
| ea5c79cd77 | |||
| 4d4a0f5ce3 | |||
| cbeef5d00b | |||
| 433e9d27ec | |||
| 1e039a988a | |||
| 393051bfec | |||
| d0b51aef7a | |||
| c5e6739632 | |||
| b91fdc6d3f | |||
| d62b879a17 | |||
| 31306ee2a9 | |||
| 0346e37e50 | |||
| f004c60964 | |||
| 61c7827d93 | |||
| 4fcb7594d7 | |||
| 4d71181d78 | |||
| ed5e6d82fb | |||
| efc23e1393 | |||
| d8ce4418ae | |||
| fc5cebe638 | |||
| fb7811559b | |||
| a2e7049aa6 | |||
| f9e6fa7ad0 | |||
| e89dbd2f5c | |||
| 0b59913870 | |||
| d2e11c947a | |||
| 8c6968ec05 | |||
| b864235e5c | |||
| bd15523916 | |||
| 2f61a9ce99 | |||
| ed2edccbc1 | |||
| 59dc27dfda | |||
| 1f1b20f92f | |||
| 9a511e0fc1 | |||
| dff4082ea9 | |||
| a4e62ac39e | |||
| e119cfceb8 | |||
| 308d1c6ef3 | |||
| 89cd606529 | |||
| 0ed0c08878 | |||
| f1a3c290e9 | |||
| 47af16a2e2 | |||
| 3f885decac | |||
| fb58112ba7 | |||
| 9928f5281f | |||
| cf2944f651 | |||
| 5cfdec63e2 | |||
| 5defc984c2 | |||
| a0f7eff938 | |||
| 31a2dd0891 | |||
| 67b9a5be85 | |||
| 837bd99e86 | |||
| 507386a231 | |||
| 11b155070d | |||
| 91a9a315e4 | |||
| 85e2f6cf9d | |||
| f3301069ef | |||
| 7c1f558687 | |||
| 448a81bdf7 | |||
| 2712a2fa73 | |||
| 8151053d08 | |||
| 5e8f0af363 | |||
| 006d1c26b3 | |||
| 46f080e642 | |||
| 6088b102f8 | |||
| 7a59623930 | |||
| 4789a32fd4 | |||
| 4b6bea5f41 | |||
| da2b97dcf1 | |||
| 6aee724a7c | |||
| f1765d957c | |||
| 19e760f9cc | |||
| 04c7e8d640 | |||
| 813ef50bf5 | |||
| 8bc43f1bb0 | |||
| 50acc23eb1 | |||
| a26bad68a6 | |||
| f5796e8ac5 | |||
| c862e6790f | |||
| fb43ec6ac3 | |||
| e1aa33e6cb | |||
| fb3060a220 | |||
| be40ac25dc | |||
| 5a29b161ac | |||
| caee6602a8 | |||
| 12c4908881 | |||
| cb0b0fafd0 | |||
| 633b3424e1 | |||
| c75a147392 | |||
| 1e71de284c | |||
| 3bfadb0ea5 | |||
| a22a1aa656 | |||
| ac8f1af1cc | |||
| 42b5edd2bf | |||
| cafa70e740 | |||
| 7ecc6063ac | |||
| 1c5e586bd9 | |||
| 9861067a17 | |||
| 295abacf7c | |||
| 6b5dfcc12a | |||
| 8aab5b5aab | |||
| 776e40b639 | |||
| a97909625d | |||
| 259170af20 | |||
| b929433eef | |||
| b166235c21 | |||
| 37ad0160d0 | |||
| d40891396d | |||
| 4f31028d1a | |||
| 8727b7d2eb | |||
| 39e012de64 | |||
| 48e566dea4 | |||
| 3f617786ef | |||
| 080ca80f2b | |||
| 4875bb271a | |||
| b0ac5bb6e6 | |||
| 8b6a402d47 | |||
| aefb2cffbb | |||
| 6934d858fe | |||
| bc28dedc64 | |||
| 92b81cb47f | |||
| e9b5414ab0 | |||
| d3f6a6521a | |||
| 13efb6c32a | |||
| 18e4cac845 | |||
| f6a474e537 | |||
| 311bbdd809 | |||
| e47cf7c3db | |||
| b27718a30f | |||
| be79bec5e0 | |||
| a551eb1143 | |||
| ddc51481b8 | |||
| d8a567c607 | |||
| 776d8074b1 | |||
| e0f937be45 | |||
| 2d7bbb74aa | |||
| 03367a76cf | |||
| 8fffec3116 | |||
| d7210e3b5a | |||
| 82834f30b0 | |||
| 50fbaa5bc7 | |||
| 696f6447dc | |||
| 60734c69b4 | |||
| ddf22de09b | |||
| e169ed1d44 | |||
| 55759938da | |||
| 45de2e6825 | |||
| 4c0e7e2149 | |||
| b63989ca78 | |||
| c2df81dd3b | |||
| 7d6a0ce845 | |||
| 2c9105eb0a | |||
| 0d705b7d28 | |||
| 266e597e19 | |||
| 92d49c1f93 | |||
| c40adb3b64 | |||
| 44e5f54c50 | |||
| c642325859 | |||
| c3adc55aec | |||
| 8700625d69 | |||
| bc4dcfbe7d | |||
| 43170a4282 | |||
| 3652e19a3d | |||
| 36e6a47472 | |||
| c71c55ecf1 | |||
| 57a5b2b4f5 | |||
| 0da311941b | |||
| 7965a4cc1d | |||
| 551f9de36b | |||
| fa8f0202e9 | |||
| ee35c54dec | |||
| 031b98a6d5 | |||
| 82ab990f0b | |||
| 38774d9201 | |||
| 6845963c8b | |||
| 4e4ce66318 | |||
| 6fe44a536f | |||
| 07272963bf | |||
| 80dbc64452 | |||
| 3a8c5d843a | |||
| bf4baa8200 | |||
| bf2b1b9d3e | |||
| 03391b4fb3 | |||
| 9040e85dbb | |||
| 85021a88b0 | |||
| a5df1c227e | |||
| 8213d9fb19 | |||
| 14c424571a | |||
| 8a94a57843 | |||
| a58f787253 | |||
| 6c839b22d9 | |||
| c086de7cf4 | |||
| 3c5f4d9bb4 | |||
| f3037c7959 | |||
| 5a519d5fb5 | |||
| a16543ee57 | |||
| 9d281ce999 | |||
| d97b3ad6b0 | |||
| cad1763981 | |||
| 092c02940d | |||
| 0a19abd0e8 | |||
| 284cfe6d05 | |||
| 3298b6226b | |||
| dfcaf2d908 | |||
| d517318a67 | |||
| d0aa520329 | |||
| 9a875b8459 | |||
| 73ac2f5c90 | |||
| efcb1132de | |||
| 7492ed161d | |||
| ae7ec2e5ce | |||
| 63fde4bdbc | |||
| 32ccb8838f | |||
| 5b6fd53830 | |||
| 86eef98b13 | |||
| 3fdbfcf39f | |||
| 847ea9f3c0 | |||
| 25bd5b5ebe | |||
| 335fe6a9a4 | |||
| 6a0480613c | |||
| 300fb9a44c | |||
| 4fac2aa380 | |||
| d2ab4c1fe8 | |||
| 6048e10ab7 | |||
| 6bd94e3f73 | |||
| fc302d4c75 | |||
| 26a35a1446 | |||
| 8f2eda7281 | |||
| e26a97a32f | |||
| 5bdb0b04da | |||
| 8f8407601e | |||
| 4c6dbcf98d | |||
| 20ccd5de56 | |||
| 3c3ad8ccc7 | |||
| 1030d6625b | |||
| 326f3eb6b6 | |||
| 9dd7228eb5 | |||
| 59ac6b9909 | |||
| e24ce8e5d5 | |||
| 8720300bfc | |||
| 23fc75a236 | |||
| 80c25267cb | |||
| 81d1aff615 | |||
| 3221fe6492 | |||
| 4ca7d5b681 | |||
| 49677aa5b1 | |||
| bbfef99a65 | |||
| 05f11fd147 | |||
| f0aedf786d | |||
| a12146a479 | |||
| 410bef2e23 | |||
| 17c6a506cb | |||
| 0b9c945aee | |||
| 53ef219d6e | |||
| a14b2480db | |||
| 89368d5352 | |||
| f7903a0a31 | |||
| 56f42d21c5 | |||
| 52a8baad08 | |||
| 7acdbf6e78 | |||
| 393394be6f | |||
| b7f305e378 | |||
| cad8a78164 | |||
| 0c4ebcac79 | |||
| e700657d5d | |||
| ea9fb92d53 | |||
| ba215c7ca9 | |||
| 564dc6e266 | |||
| 86a2e54694 | |||
| 358950bec0 | |||
| de2cb269b7 | |||
| 151e829973 | |||
| 19121b55a7 | |||
| 31f03582a3 | |||
| 0859f6da6d | |||
| 120b7086e5 | |||
| d393872d8c | |||
| 3ab9afdcd3 | |||
| 8812b4c103 | |||
| 4cccced7ac | |||
| 7b3d342be6 | |||
| 97409c88c3 | |||
| 1d675d9d78 | |||
| 1774a255d8 | |||
| 1863016b63 | |||
| 1e89a540a1 | |||
| 5daa67e054 | |||
| 05ce7f7f44 | |||
| 9391c700a1 | |||
| 16c4ecf9f2 | |||
| 7280f76fae | |||
| 3a5d40a5d9 | |||
| 40dd596fef | |||
| 56b240b101 | |||
| bf36103499 | |||
| 477144dc24 | |||
| 0aa45cfedc | |||
| 4691345831 | |||
| 8445f8c263 | |||
| 7176f91a3f | |||
| e37065ce91 | |||
| 2537b76256 | |||
| 59e275c997 | |||
| bfe61896e8 | |||
| 0ad8b13db2 | |||
| 3c8abc04a8 | |||
| a48cf75c90 | |||
| 4f7017d5b2 | |||
| 79f0d57161 | |||
| d76e8e6f3f | |||
| b6147c1fe5 | |||
| 4bbd92127a | |||
| 337c2aef8d | |||
| e943d22a5f | |||
| bceb8b9134 | |||
| 14adc8a768 | |||
| 7c44ad2272 | |||
| c8272dd455 | |||
| cb2aa2126b | |||
| f74a412611 | |||
| f0b92f8578 | |||
| e7cae7dc21 | |||
| 1c41bd7a45 | |||
| a671a4916d | |||
| 15ea1488c9 | |||
| f92dd743ef | |||
| eddbe3980a | |||
| b27df1489b | |||
| dc3f2ee046 | |||
| ba7f03daeb | |||
| 079500faff | |||
| ce0defe5e9 | |||
| 7b1bcd5147 | |||
| 787eb5dce1 | |||
| 9d73fab37e | |||
| 6a833aabee | |||
| e40d0896b8 | |||
| c265eb0118 | |||
| cead3b0b5c | |||
| 238c09befd | |||
| de1867d523 | |||
| 906e02e265 | |||
| 307308825e | |||
| aaf166d187 | |||
| 38ff1f8c2b | |||
| 82f58b3255 | |||
| 31d22f02e1 | |||
| ff1f517af5 | |||
| fb340fbec6 | |||
| e208bfd4d9 | |||
| b9f4967a23 | |||
| 539a388ec4 | |||
| f770ba8783 | |||
| 6d2ef3e106 | |||
| e483c58f10 | |||
| b07c10bb53 | |||
| bb10a463dc | |||
| 93e0db98fc | |||
| 51fc4553a3 | |||
| 5184fe76e7 | |||
| ee264a6f18 | |||
| d290201085 | |||
| 5ab5bdc301 | |||
| de995e2cec | |||
| 81fb68264c | |||
| b05a245cf4 | |||
| f3376a2ab3 | |||
| 48faeeaf1d | |||
| 5560899c94 | |||
| 85e7b34da1 | |||
| 013a2b9ede | |||
| e984572847 | |||
| 591c01bb98 | |||
| 7b053c506e | |||
| e8fcdc18da | |||
| b65ff2383a | |||
| b69e9017bf | |||
| 09a40e1912 | |||
| 6fa630e6e4 | |||
| 95d3c0bbc4 | |||
| 9bf2ab20a8 | |||
| 15a10b2405 | |||
| a4093cdc70 | |||
| 8713d743e1 | |||
| 4d3129782e | |||
| 53ed3f7d6c | |||
| 91d68e665b | |||
| 0bc606c3a8 | |||
| d19b709324 | |||
| 74742ca45b | |||
| 2678b0c02f | |||
| 5576c071c5 | |||
| 27c51a6c54 | |||
| 98c4a62130 | |||
| 7bf8620baf | |||
| 1f742b24df | |||
| 3ac1d77651 | |||
| ae74c4e5cd | |||
| 434be00a44 | |||
| 0b365f098d | |||
| 54e1aab5fc | |||
| 76c8b49553 | |||
| 085d51adcf | |||
| 0b75801ed6 | |||
| eb712ed4bb | |||
| c6f6f4c8f7 | |||
| ab8c29021d | |||
| 62961eeaa4 | |||
| b32c3048d7 | |||
| bc18b12227 | |||
| 28734c52a4 | |||
| cd38d00496 | |||
| e613ae4542 | |||
| 4439a83382 | |||
| 64ef6657be | |||
| 35760ace39 | |||
| 72e6e9acae | |||
| eecc7236ad | |||
| bdb280c029 | |||
| 77b1259bf3 | |||
| 6b9ffacb89 | |||
| 523a98cf8a | |||
| 98db6a0390 | |||
| 164d5209eb | |||
| 4b8a1960dd | |||
| 2e25a129d6 | |||
| 3fc2ccbc6a | |||
| 78853da803 | |||
| 4668654d3c | |||
| 55503b209b | |||
| 0fdd8bf693 | |||
| a6459e4302 | |||
| b256a61876 | |||
| a59c70f75b | |||
| 59f608a4d0 | |||
| 70543a2bd5 | |||
| 7743b6ef62 | |||
| a7f3120fb9 | |||
| 16525b0d19 | |||
| c96b9db716 | |||
| a8bdface95 | |||
| ea8bf21ffd | |||
| 24efe9d896 | |||
| 3ae0520f39 | |||
| 035ca66237 | |||
| 66fd1a5f2f | |||
| ba4a082834 | |||
| ac7b4e8ac3 | |||
| 7e79b2e12c | |||
| 0da686a78b | |||
| 474e3cb8d9 | |||
| e649bd9a25 | |||
| 1f5bf25d16 | |||
| 14cc86bce1 | |||
| 5f636db5ed | |||
| 72c84deb85 | |||
| a0cc1cf228 | |||
| 41b35655a6 | |||
| 68169aed0d | |||
| 645b971b6b | |||
| f669739b4e | |||
| 9f5912c649 | |||
| 8dac9ea12c | |||
| 9f2e6547d2 | |||
| 164be3061d | |||
| f4acbf75d8 | |||
| a3f710f398 | |||
| fdd9ee173c | |||
| 5c581869da | |||
| f1bb7e6217 | |||
| bc553c66af | |||
| 2bb80a06ed | |||
| d44dd996a7 | |||
| 36de918cfc | |||
| 4b45002129 | |||
| 2d23da34c2 | |||
| ff58ec8a1e | |||
| 6ae419b537 | |||
| 96350c19c2 | |||
| ab52989e0e | |||
| 035f01fb0a | |||
| e235fd3adf | |||
| 272d0e423d | |||
| e227b395f9 | |||
| 91d8d1a4d0 | |||
| c5543e777a | |||
| ddfcd11fb4 | |||
| 03ef7ef734 | |||
| 4d84788f51 | |||
| 6d48245d82 | |||
| a2070d1073 | |||
| 40bb5b8e0a | |||
| ac3bee4609 | |||
| 4166c2721c | |||
| 8455fe9422 | |||
| ed3a24a9c9 | |||
| d93464e970 | |||
| 0909855fbb | |||
| dc32d4fb13 | |||
| 36e0be6f9b | |||
| ea5355f413 | |||
| 27960395de | |||
| cdbcb85640 | |||
| db2d8e4217 | |||
| 1b9aedf7a0 | |||
| 1cba7efeeb | |||
| ec7e721fcc | |||
| dcfb390243 | |||
| 2cd7161694 | |||
| a84ec8c438 | |||
| 33805dd480 | |||
| a033919d47 | |||
| 72674329bc | |||
| 6d690d80da | |||
| e607ae50e1 | |||
| 750c13ee00 | |||
| b66a5c1cc5 | |||
| 732ef11d7f | |||
| 1187ead2cf | |||
| c6ddc19fdc | |||
| e864d8fc10 | |||
| 3a0d730c11 | |||
| 773b9f5e48 | |||
| 3218b3a531 | |||
| 658ed58412 | |||
| 9d288dee41 | |||
| e975789be4 | |||
| bf2ef89a7f | |||
| f81aa9a47b | |||
| 2a82ac65e2 | |||
| 6a506898a8 | |||
| 8606e0ca9d | |||
| 5951d1c9e2 | |||
| e741d1b252 | |||
| f85d687a77 | |||
| 142b006c63 | |||
| 5e59e60b4e | |||
| f678680f1d | |||
| 0de37ed924 | |||
| 5f2b3c55bb | |||
| 4a37fa8668 | |||
| f7f5e550c9 | |||
| 24db728a6c | |||
| 1f2ddc7829 | |||
| 77d22be8fa | |||
| 691bd9a10f | |||
| f5165cc78b | |||
| 6cb687d8b6 | |||
| 80dd042021 | |||
| 3b43cd1e74 | |||
| 289b0ad94c | |||
| e1469d96d8 | |||
| 93f106dc30 | |||
| 73913197df | |||
| 4ec017a68f | |||
| 284891f73a | |||
| 5a1b69d29b | |||
| 0699a7edf7 | |||
| 14c21694ec | |||
| 5f95225d00 | |||
| c1b25aa3ef | |||
| 237f6a820c | |||
| 7ba3aa560b | |||
| 405b599562 | |||
| 1dae858671 | |||
| aee139e154 | |||
| b80f977e16 | |||
| e6e8b255ba | |||
| 0aca212f53 | |||
| 7f64e9b9c7 | |||
| 8953c51f9a | |||
| 72d97ad288 | |||
| 43cb1a278b | |||
| ccc1becc87 | |||
| 8b55122225 | |||
| 776fe53178 | |||
| 003b115067 | |||
| bcf682e116 | |||
| ad4fab1aa6 | |||
| 80d89e7b87 | |||
| 46bbbc8ac7 | |||
| cd43385573 | |||
| 63b4c19d67 | |||
| 837055cc29 | |||
| 053718f7f2 | |||
| 9d18f7c67f | |||
| f32ac10e94 | |||
| aaa3f62f62 | |||
| c68f34a48a | |||
| c39075eff8 | |||
| 53c28fed5d | |||
| 112e177928 | |||
| 449201e3ea | |||
| c7c9e75c17 | |||
| 2bdbe91c7e | |||
| 58c3f8fd22 | |||
| ad7063eea2 | |||
| 34b3524533 | |||
| f63d991df4 | |||
| 10a640bac6 | |||
| e4bd49e6ae | |||
| c14d4a9f6b | |||
| 596897ccd7 | |||
| b304f03a7a | |||
| 2c9f467939 | |||
| 31f6c9d43c | |||
| 91e5f2f43f | |||
| f4f5c18a95 | |||
| 08b1bd4ce6 | |||
| 61934cee51 | |||
| ae560e8923 | |||
| d0f1cb5db0 | |||
| 18b1279fe6 | |||
| dd541ef1d0 | |||
| d3c3135775 | |||
| 317305dbcd | |||
| d889aee9df | |||
| 0d2ef231d7 | |||
| 52036a6c4b | |||
| fc44b2be44 | |||
| 48fcbe8de8 | |||
| 8a2bb2a8a4 | |||
| 37480a0c6e | |||
| 332b49de31 | |||
| 3fa9abecd9 | |||
| 25c964ee37 | |||
| 5b471539e9 | |||
| 1739a4ebd2 | |||
| dfde53e893 | |||
| a9066d91fc | |||
| e3aff9e394 | |||
| 68ea183e52 | |||
| 78bafd54f3 | |||
| 429ccd3254 | |||
| 4d181df5b8 | |||
| e8d8b7730e | |||
| 04e649ce0b | |||
| b54d1c3b2b | |||
| ec58058e00 | |||
| a8bc5a22d5 | |||
| ddf5a59ee9 | |||
| 19ed1b1444 | |||
| 0c08992214 | |||
| c48f570877 | |||
| 95dc465f45 | |||
| 65b49cdd11 | |||
| a18cabfa33 | |||
| 9d86f9f1f9 | |||
| adca6987b4 | |||
| cf5d09d0d1 | |||
| b4075c14fd | |||
| 06717ad552 | |||
| e4b4b3e0e5 | |||
| e51a0adf12 | |||
| 3bdba2ad71 | |||
| 89e7935cd6 | |||
| 935e3fea4d | |||
| e1f4c20fd7 | |||
| 226c822fcf | |||
| 7905d25c2f | |||
| 941d508859 | |||
| 2230a78ad1 | |||
| 95ec664c9c | |||
| ef894ae441 | |||
| f887abbf66 | |||
| d51b9839c2 | |||
| fb08b5638d | |||
| c09ec1b3e1 | |||
| b77104baa8 | |||
| 60beceb0a4 | |||
| 36810bbf53 | |||
| 5f62559811 | |||
| bb521437db | |||
| c31bbef8f5 | |||
| ca5203848d | |||
| b6f8ddd041 | |||
| 1e834cfb45 | |||
| e93ac78ccd | |||
| 8a375019f1 | |||
| 3cda19e2d2 | |||
| 95169d0885 | |||
| 96c3b0725b | |||
| b29eef912d | |||
| 7790621b3c | |||
| adf96c3055 | |||
| a99ced845c | |||
| be6681a0fd | |||
| fbcb1f8ddd | |||
| 61cb5a9eed | |||
| 64d32a6386 | |||
| 50e47e75a1 | |||
| 21b7e081e7 | |||
| e53403d11b | |||
| 6ef19dfbdc | |||
| 1c601e57a4 | |||
| 346ff4db00 | |||
| 6900a6f3be | |||
| 08c3c19219 | |||
| 828d5301e7 | |||
| 4ffbcba8cf | |||
| 0290a178ee | |||
| 4723ec9d5b | |||
| 4b908677a9 | |||
| 24b7699520 | |||
| 6a2bba3119 | |||
| 4a2af94b31 | |||
| 77719e3713 | |||
| 94776b0171 | |||
| 5c4c08fc97 | |||
| 1d58fe359b | |||
| a50849882e | |||
| 89a474f509 | |||
| 4cc1d01c6a | |||
| 703d6bcb69 | |||
| a0cf6389aa | |||
| 7cf77afab3 | |||
| ec36764750 | |||
| e1186901e9 | |||
| 82d1b90542 | |||
| 1c2b3ac07c | |||
| 5d545d6acf | |||
| abacf8b977 | |||
| e7fb10be20 | |||
| 9eac85a5d3 | |||
| c2a4d4ddac | |||
| c64b19bbb4 | |||
| f8569c15bc | |||
| 1b0d50eeaf | |||
| e681c0a2b0 | |||
| 6dcb7173d5 | |||
| ee8165d4b9 | |||
| 0539ffbd23 | |||
| 4bc2364e07 | |||
| fbff4b2985 | |||
| 6031a35461 | |||
| b55b521d06 | |||
| 8303c80326 | |||
| 1a196b20da | |||
| aa2e813fb1 | |||
| 92ef9e44d6 | |||
| d840e63ac1 | |||
| 345bbf7f21 | |||
| e728e0b520 | |||
| be70e455d7 | |||
| 7a92fe8f86 | |||
| bbcda86272 | |||
| 148b3a4bd3 | |||
| dc0267427f | |||
| fa71a8535d | |||
| 15d7e94082 | |||
| d571d1ea98 | |||
| ca2cef61a4 | |||
| 5957b60680 | |||
| 37e9931c5a | |||
| 837e9f4029 | |||
| 020746027d | |||
| f170f9ab0d | |||
| 44bab26192 | |||
| 042b15f787 | |||
| 4d95438e20 | |||
| 94fd12b436 | |||
| d9d12321b7 | |||
| 73ab6505ca | |||
| 7f1cd7437c | |||
| 0e40bc0deb | |||
| 51a46e0f4d | |||
| 9ffe4e2965 | |||
| d4551a83e6 | |||
| fbd4699246 | |||
| bfc8242ee6 | |||
| 68598cc9d0 | |||
| c87ff74add | |||
| fcb9ca34a1 | |||
| 43e19870b2 | |||
| 365b272e91 | |||
| 56ad82e481 | |||
| 110940e898 | |||
| f58557d785 | |||
| 5a0d3e5026 | |||
| 357e30d8af | |||
| c3b633a207 | |||
| daef46eecc | |||
| 140add3754 | |||
| 540a6a3d2a | |||
| a7e337cf96 | |||
| a6cf807b08 | |||
| b87b5c4f2f | |||
| cb1497d434 | |||
| 01d104c81c | |||
| d716f396b4 | |||
| c683e0261c | |||
| 4d1ed89e40 | |||
| 7769de7174 | |||
| 99a2fb27df | |||
| 45f96605d9 | |||
| fb7b75b02d | |||
| 101c03b19e | |||
| 17fa54c979 | |||
| 35f610001f | |||
| 1f57e7d2de | |||
| 3fad139bc5 | |||
| ba3888f523 | |||
| 9751ef2529 | |||
| b69b46a78c | |||
| 88979fe511 | |||
| 7d2fc57b77 | |||
| 71c30babea | |||
| c4996a3e2d | |||
| 7a71bbb995 | |||
| 45b00acc8b | |||
| 0728f77d31 | |||
| 3c2bec7d02 | |||
| bf1669c0f0 | |||
| b1e17a1115 | |||
| 3814e51585 | |||
| f7f5c3abc6 | |||
| 9cac8694c0 | |||
| e63af33723 | |||
| fcbda78a46 | |||
| e7cdc676cf | |||
| c2bd1e9780 | |||
| 2fab159ba8 | |||
| 1e41629f49 | |||
| 18c32c7e64 | |||
| e8aac9bd81 | |||
| 263ba0581b | |||
| db943ee144 | |||
| afb3da7942 | |||
| 34fe7564ba | |||
| eef87b3881 | |||
| d606b2c7e9 | |||
| 495aa8bbc5 | |||
| f12185f853 | |||
| a2d3ac3138 | |||
| e4d34f886a | |||
| ca946c1cd1 | |||
| 26737e0a11 | |||
| fc86bc9dd3 | |||
| c115de0bf0 | |||
| da9e8493b7 | |||
| 02a94ff271 | |||
| 7a06c05343 | |||
| 16eafe918a | |||
| 397cc1c50c | |||
| d8ac537fba | |||
| dbe5257f3a | |||
| 7437c17f84 | |||
| 520e710aae | |||
| 49888e73bb | |||
| 78db3a0122 | |||
| cad6f00f2d | |||
| 0139bfa17d | |||
| fa87ba98c5 | |||
| f296b7a2c4 | |||
| c41e366758 | |||
| c241a1ea16 | |||
| 0bc9f8f4e3 | |||
| 55a35e662c | |||
| d386613e55 | |||
| e8b365c966 | |||
| e8a6546e54 | |||
| 10bf24e490 | |||
| ad4d0fcf0a | |||
| f4a339d55e | |||
| 74c0d60b2f | |||
| 5e56c37511 | |||
| 5a5d934a46 | |||
| ddc606a9bd | |||
| 70ee55c5a0 | |||
| 8179ce47d1 | |||
| a6e240cd52 | |||
| dc87af411a | |||
| c1363da184 | |||
| 58970cb3c3 | |||
| fc83f4f227 | |||
| f16bbccd69 | |||
| b0430fc05e | |||
| 754d07a06c | |||
| 05fa80faa2 | |||
| 3fa823b193 | |||
| 3b661d6dc2 | |||
| 9c7b9e44a1 | |||
| b30c3108b7 | |||
| 1bc1a4e982 | |||
| d36f5c3b38 | |||
| 8427271eb0 | |||
| 01a2c6e8cd | |||
| 409ca3dd06 | |||
| 80f3b65c83 | |||
| f6269fd244 | |||
| 9f02fee658 | |||
| 92a76e834f | |||
| 28b8b8ce9d | |||
| b0ef493774 | |||
| 01c11fabec | |||
| 6a57a8b107 | |||
| 64c24bf496 | |||
| ceab949ff1 | |||
| 7be310f4e7 | |||
| d64dff8e04 | |||
| ec55140718 | |||
| 69b32f6a1c | |||
| 38cd245907 | |||
| c1ced5f9ff | |||
| cc437b89e9 | |||
| 794c74c629 | |||
| 83db25142d | |||
| c4484d3cc1 | |||
| f9a5d8b093 | |||
| 5b3c3f40e6 | |||
| 8f2e2d5465 | |||
| 8e182ceb29 | |||
| fc10503cdd | |||
| a2296d1822 | |||
| 66b57372cb | |||
| 1e5299034f | |||
| 82afe90a60 | |||
| a0ca72082e | |||
| 22e52e46ff | |||
| 20820648ad | |||
| f41790fff2 | |||
| fe4977c08d | |||
| e12dd54f2a | |||
| 7d4de8c0bc | |||
| 2bd5a3849f | |||
| 0e7b9462c1 | |||
| b14d4da555 | |||
| b61647e504 | |||
| 728ce5b19d | |||
| d11b9cdbe2 | |||
| 149e092181 | |||
| f5de72ad41 | |||
| 6fa2d4310b | |||
| eb76f57688 | |||
| 096bb72eb1 | |||
| 10407d1529 | |||
| ae67ac3355 | |||
| 5eba8169c6 | |||
| e299a6e01d | |||
| 3ea4c0a147 | |||
| 8b1cee29b1 | |||
| c8cac98df6 | |||
| e0f811c706 | |||
| 7254bd8c07 | |||
| c8b527c99a | |||
| 629088602a | |||
| bdc1e1bf9e | |||
| e88368e4f5 | |||
| df40ab38bc | |||
| a115eb69d0 | |||
| 57f84f4ebd | |||
| 2cf42f3f66 | |||
| 6d585f6a74 | |||
| 7525795ac8 | |||
| ba66c00010 | |||
| 7a9f66a1ae | |||
| 488d955fcd | |||
| 4064fc3396 | |||
| b731bd2faf | |||
| 1d5e6feafe | |||
| 12e00174d2 | |||
| a381517458 | |||
| 54611577ba | |||
| 450572ad8f | |||
| 877adc39df | |||
| 9feb2ea1e6 | |||
| afc7ae2cb5 | |||
| 4d7ce9fba4 | |||
| 6254b23b3a | |||
| 9ac6c643b3 | |||
| e7d7e6993d | |||
| b2393e88fa | |||
| 57738442d7 | |||
| 2126e2ffa6 | |||
| 0ed4a20505 | |||
| a3c00d0a6e | |||
| 1f00996142 | |||
| 56093efb5a | |||
| e0c7786752 | |||
| 8ba667bbb8 | |||
| 7661d230f1 | |||
| 577eaaef56 | |||
| b64719acea | |||
| 7e6050e721 | |||
| ca3c31d7f5 | |||
| c89e493e67 | |||
| a856cdc7d2 | |||
| 76cdf969a5 | |||
| 48c85a4389 | |||
| 992bc26ff1 | |||
| b5aa10a8b5 | |||
| b5eec41f36 | |||
| 2fb8faefbd | |||
| bcd144d265 | |||
| be1e961c2e | |||
| 6832bdfff6 | |||
| 98aeea5f76 | |||
| 85ff9dc965 | |||
| c650618e48 | |||
| 882d87e522 | |||
| 80a7847e67 | |||
| 86f2a3b7f1 | |||
| a735a613d6 | |||
| 666725a5f0 | |||
| 89fb479591 | |||
| 5c7dc68e12 | |||
| 8a5afab22f | |||
| 589357b800 | |||
| 3ea2f423cc | |||
| 150187c1f5 | |||
| ac1f2524f4 | |||
| 72a000f0ff | |||
| 89b8f3fbdf | |||
| 2518fac529 | |||
| 447913d970 | |||
| a3c65a76a1 | |||
| 3e3ed17693 | |||
| 60a79e4d63 | |||
| bf99c38328 | |||
| 5a336e92de | |||
| f495369097 | |||
| 8bd9149406 | |||
| c143fca1dd | |||
| 4be39160cb | |||
| 2d32cdca79 | |||
| fe23291b22 | |||
| f9640eca33 | |||
| a1b77848ef | |||
| 5f45be8ae6 | |||
| 4007c2f55d | |||
| afe3d87d80 | |||
| d59346a05e | |||
| 627ba46781 | |||
| 6586df1ccf | |||
| de4f3a6d93 | |||
| e7512a6896 | |||
| 030eb4234b | |||
| 8b551f91a4 | |||
| f5f8673d93 | |||
| 4344429fbf | |||
| f5aa6f44c1 | |||
| eb61856009 | |||
| 3282e85635 | |||
| fc50f62678 | |||
| 8c0d3f6873 | |||
| b1028cb2da | |||
| 3074e7e3be | |||
| 0416b66ace | |||
| 03ccd3de8a | |||
| 6a048e4caf | |||
| 0eb27aebc8 | |||
| acc2ca6f41 | |||
| bf03fcce62 | |||
| aca289cb6c | |||
| ca2296fd1b | |||
| f5e43575e0 | |||
| 666da6629e | |||
| 63b21353d5 | |||
| 70818392bc | |||
| 4620798382 | |||
| 809ba648ff | |||
| 0901616b39 | |||
| 5c07352e4c | |||
| 7f3e15cb46 | |||
| 64926f8aa9 | |||
| fcf3e4bc17 | |||
| 00809b9022 | |||
| 0192c63ad3 | |||
| 60db87b8ec | |||
| 9b7571ddbf | |||
| 8861b0480e | |||
| d54827dfdd | |||
| 0999a45f5e | |||
| 887b046409 | |||
| 4337d81951 | |||
| 7fdb0f6e5f | |||
| 263053a500 | |||
| a8360e94a2 | |||
| 5f01c568fd | |||
| 6214b33965 | |||
| 2bf1f9dc62 | |||
| fc26383fa1 | |||
| a3e1d5f983 | |||
| d69ea4978a | |||
| fca331fefa | |||
| 5b43b36596 | |||
| 2e9d534ffe | |||
| 0eb128ff48 | |||
| aae2fb0591 | |||
| b63c01f25b | |||
| d82bfa77ff | |||
| 33ca96b15a | |||
| 1c2659c0fc | |||
| 3d43bbf501 | |||
| 42bef16cbe | |||
| 1a172d5bde | |||
| caea8ceb06 | |||
| ff4a3fdb5e | |||
| e9d27886ed | |||
| 759f7dbc72 | |||
| 646abd4d4a | |||
| 2a0fade480 | |||
| 23e85a173d | |||
| d6cc1124c8 | |||
| c4c303a948 | |||
| cd06b0fc5e | |||
| d7344acdac | |||
| 418b89848e | |||
| 0641b6c79c | |||
| ff5cb3ddc7 | |||
| 305de3891d | |||
| 37ebae07c0 | |||
| 10ba95e53c | |||
| 7cf0c3070e | |||
| 3d1089bdaf | |||
| d6582b9da8 | |||
| b6aaad5ffd | |||
| 950f411b7f | |||
| 7f4eafc61f | |||
| 82540de425 | |||
| 3ce500735a | |||
| 2b0ebbd911 | |||
| 4461df12fb | |||
| 8171d940a8 | |||
| 667ef30a86 | |||
| 40e621ca26 | |||
| 5227af8c97 | |||
| 3ce57243aa | |||
| 21c0bb59c3 | |||
| 457030989a | |||
| f8653b3749 | |||
| 33b2aaf46e | |||
| 7af2a69e8f | |||
| f3195f2111 | |||
| 568d2f7938 | |||
| a1cc97df35 | |||
| b47c43466b | |||
| 48e92df901 | |||
| f581156c9a | |||
| d1ced61993 | |||
| a055479140 | |||
| a2c48bd8dc | |||
| 6d274cddee | |||
| 6c640de827 | |||
| caaf15a835 | |||
| 5fa4f3564f | |||
| e3dc39f1aa | |||
| c12bf4dccd | |||
| 040e7fc0d1 | |||
| 54e97545dc | |||
| 68ff23df61 | |||
| 2fd95dac35 | |||
| ea23cf7f6e | |||
| 0ff285882e | |||
| dfc135392f | |||
| b1ddee7c0b | |||
| e68552b740 | |||
| 812e35c6c1 | |||
| 2d4cf408f9 | |||
| 750d4ad449 | |||
| 34b0b6af46 | |||
| f55d1d161d | |||
| 2d8a5bd4fb | |||
| 1152ea3960 | |||
| 1fae6abb15 | |||
| bb643cc79f | |||
| cad336db0e | |||
| 1d15c7d7cd | |||
| fb3f2860ea | |||
| 6568045f46 | |||
| 6892bcf21e | |||
| 47aa461598 | |||
| f25fb340a9 | |||
| 7a37647d72 | |||
| b2509ac5d9 | |||
| 6e351e9dce | |||
| ad1e401476 | |||
| a3894ca51d | |||
| 81127d81fe | |||
| 277bd7dcfb | |||
| 321bc497aa | |||
| 88abb662d1 | |||
| 6fa0a142fe | |||
| b192fbb0e1 | |||
| 6438180082 | |||
| 3ae7000718 | |||
| 178c982acb | |||
| 3507b6d1d0 | |||
| 5045681045 | |||
| b4dd7f0f30 | |||
| 272a66ee0c | |||
| 4c61710ae7 | |||
| c9872a6ce9 | |||
| db9d36046a | |||
| f3dc2d9923 | |||
| 5e58a2ba02 | |||
| c8c6c82c0b | |||
| a31c33540e | |||
| 45dc14e181 | |||
| b086410846 | |||
| 67e280004b | |||
| 3b5c24311d | |||
| b75d54ce46 | |||
| 0a90afecdb |
Executable
+39
@@ -0,0 +1,39 @@
|
||||
#!/bin/bash
|
||||
|
||||
#path=$(pwd)
|
||||
#folder=$($path | awk -F"/" '{$NF}')
|
||||
folder=$(basename "$(pwd)")
|
||||
|
||||
if [ "$folder" == "bioprocc2650" ]; then
|
||||
year=$(date +%-y)
|
||||
month=$(date +%-m)
|
||||
day=$(date +%-d)
|
||||
hour=$(date +%-H)
|
||||
minute=$(date +%-M)
|
||||
|
||||
hash=$(git rev-parse HEAD)
|
||||
branch=$(git rev-parse --abbrev-ref HEAD)
|
||||
|
||||
sed -i "5c #define VERSION_DATE_YEAR ${year}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "6c #define VERSION_DATE_MONTH ${month}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "7c #define VERSION_DATE_DAY ${day}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "8c #define VERSION_DATE_HOUR ${hour}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "9c #define VERSION_DATE_MINUTE ${minute}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "13c #define VERSION_HASH ${hash}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
sed -i "14c #define VERSION_GIT_BRANCH ${branch}"\
|
||||
./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
|
||||
#cat ./simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage/Elite_version.h
|
||||
fi
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/common/cc26xx/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/controller/cc26xx/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../tirtos_cc13xx_cc26xx_2_21_01_08/products/cc26xxware_2_24_03_17272/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/hal/src/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/cc26xx/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/heapmgr/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/examples/host_test/cc26xx/app/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/icall/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/icall/src/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/npi/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/osal/src/inc/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/profiles/roles/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/profiles/dev_info/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/profiles/simple_profile/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/rom/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/services/src/saddr/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/components/services/src/sdata/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/
|
||||
@@ -1 +0,0 @@
|
||||
../simplelink/ble_sdk_2_02_02_25/src/target/
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<configurations XML_version="1.2" id="configurations_0">
|
||||
<configuration XML_version="1.2" id="configuration_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS100v3 USB Debug Probe" href="connections/TIXDS100v3_Dot7_Connection.xml" id="Texas Instruments XDS100v3 USB Debug Probe" xml="TIXDS100v3_Dot7_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe">
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2icepick_c.xml" id="drivers" xml="tixds100v2icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cs_dap.xml" id="drivers" xml="tixds100v2cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cortexM.xml" id="drivers" xml="tixds100v2cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="2" id="The Converter Usage">
|
||||
<choice Name="Generate 1149.7 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="The Converter 1149.7 Frequency">
|
||||
<choice Name="Overclock with user specified value" value="unused">
|
||||
<property Type="choicelist" Value="5" id="-- Choose a value from 1.0MHz to 50.0MHz"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="5" id="The Target Scan Format"/>
|
||||
</choice>
|
||||
</property>
|
||||
<platform XML_version="1.2" id="platform_0">
|
||||
<instance XML_version="1.2" desc="CC2640F128" href="devices/cc2640f128.xml" id="CC2640F128" xml="cc2640f128.xml" xmlpath="devices"/>
|
||||
</platform>
|
||||
</connection>
|
||||
</configuration>
|
||||
</configurations>
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
The 'targetConfigs' folder contains target-configuration (.ccxml) files, automatically generated based
|
||||
on the device and connection settings specified in your project on the Properties > General page.
|
||||
|
||||
Please note that in automatic target-configuration management, changes to the project's device and/or
|
||||
connection settings will either modify an existing or generate a new target-configuration file. Thus,
|
||||
if you manually edit these auto-generated files, you may need to re-apply your changes. Alternatively,
|
||||
you may create your own target-configuration file for this project and manage it manually. You can
|
||||
always switch back to automatic target-configuration management by checking the "Manage the project's
|
||||
target-configuration automatically" checkbox on the project's Properties > General page.
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<configurations XML_version="1.2" id="configurations_0">
|
||||
<configuration XML_version="1.2" id="configuration_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS100v3 USB Debug Probe" href="connections/TIXDS100v3_Dot7_Connection.xml" id="Texas Instruments XDS100v3 USB Debug Probe" xml="TIXDS100v3_Dot7_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe">
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2icepick_c.xml" id="drivers" xml="tixds100v2icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cs_dap.xml" id="drivers" xml="tixds100v2cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cortexM.xml" id="drivers" xml="tixds100v2cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="2" id="The Converter Usage">
|
||||
<choice Name="Generate 1149.7 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="The Converter 1149.7 Frequency">
|
||||
<choice Name="Overclock with user specified value" value="unused">
|
||||
<property Type="choicelist" Value="5" id="-- Choose a value from 1.0MHz to 50.0MHz"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="5" id="The Target Scan Format"/>
|
||||
</choice>
|
||||
</property>
|
||||
<platform XML_version="1.2" id="platform_0">
|
||||
<instance XML_version="1.2" desc="CC2640F128" href="devices/cc2640f128.xml" id="CC2640F128" xml="cc2640f128.xml" xmlpath="devices"/>
|
||||
</platform>
|
||||
</connection>
|
||||
</configuration>
|
||||
</configurations>
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
The 'targetConfigs' folder contains target-configuration (.ccxml) files, automatically generated based
|
||||
on the device and connection settings specified in your project on the Properties > General page.
|
||||
|
||||
Please note that in automatic target-configuration management, changes to the project's device and/or
|
||||
connection settings will either modify an existing or generate a new target-configuration file. Thus,
|
||||
if you manually edit these auto-generated files, you may need to re-apply your changes. Alternatively,
|
||||
you may create your own target-configuration file for this project and manage it manually. You can
|
||||
always switch back to automatic target-configuration management by checking the "Manage the project's
|
||||
target-configuration automatically" checkbox on the project's Properties > General page.
|
||||
+1
-1
@@ -9,6 +9,6 @@
|
||||
<linkerCommandFile value="cc26x0f128.cmd"/>
|
||||
<rts value="libc.a"/>
|
||||
<createSlaveProjects value=""/>
|
||||
<connection value="common/targetdb/connections/TIXDS100v3_Dot7_Connection.xml"/>
|
||||
<connection value="common/targetdb/connections/TIXDS110_Connection.xml"/>
|
||||
<isTargetManual value="false"/>
|
||||
</projectOptions>
|
||||
|
||||
+57
-56
@@ -18,13 +18,13 @@
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="out" artifactName="${ProjName}" buildProperties="" cleanCommand="${CG_CLEAN_CMD}" description="" errorParsers="org.eclipse.rtsc.xdctools.parsers.ErrorParser;com.ti.rtsc.XDCtools.parsers.ErrorParser;com.ti.ccstudio.errorparser.CoffErrorParser;com.ti.ccstudio.errorparser.LinkErrorParser;com.ti.ccstudio.errorparser.AsmErrorParser;org.eclipse.cdt.core.GmakeErrorParser" id="com.ti.ccstudio.buildDefinitions.TMS470.Default.67178137" name="FlashROM" parent="com.ti.ccstudio.buildDefinitions.TMS470.Default" postbuildStep="${CG_TOOL_HEX} -order MS --memwidth=8 --romwidth=8 --intel -o ${ProjName}.hex ${ProjName}.out" prebuildStep="">
|
||||
<folderInfo id="com.ti.ccstudio.buildDefinitions.TMS470.Default.67178137." name="/" resourcePath="">
|
||||
<toolChain id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain.308833195" name="TI Build Tools" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain" targetTool="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.2125878104">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS.2138235341" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS" valueType="stringList">
|
||||
<toolChain id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain.410623502" name="TI Build Tools" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain" targetTool="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.1351821865">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS.1751124300" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="DEVICE_CONFIGURATION_ID=Cortex M.CC2650F128"/>
|
||||
<listOptionValue builtIn="false" value="DEVICE_ENDIANNESS=little"/>
|
||||
<listOptionValue builtIn="false" value="OUTPUT_FORMAT=ELF"/>
|
||||
<listOptionValue builtIn="false" value="RUNTIME_SUPPORT_LIBRARY=libc.a"/>
|
||||
<listOptionValue builtIn="false" value="XDC_VERSION=3.32.0.06_core"/>
|
||||
<listOptionValue builtIn="false" value="XDC_VERSION=3.32.2.25_core"/>
|
||||
<listOptionValue builtIn="false" value="INACTIVE_REPOS="/>
|
||||
<listOptionValue builtIn="false" value="EXPANDED_REPOS="/>
|
||||
<listOptionValue builtIn="false" value="RTSC_PRODUCTS=com.ti.rtsc.TIRTOSCC13XX_CC26XX:2.21.01.08;"/>
|
||||
@@ -34,17 +34,17 @@
|
||||
<listOptionValue builtIn="false" value="LINK_ORDER=TOOLS/ccs_linker_defines.cmd;TOOLS/cc26xx_app.cmd;"/>
|
||||
<listOptionValue builtIn="false" value="RTSC_MBS_VERSION=2.2.0"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION.243195404" name="Compiler version" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION" value="18.1.4.LTS" valueType="string"/>
|
||||
<targetPlatform id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug.955793533" name="Platform" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug"/>
|
||||
<builder buildPath="${BuildDirectory}" id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug.638576662" keepEnvironmentInBuildfile="false" name="GNU Make" parallelBuildOn="true" parallelizationNumber="optimal" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug.1016177761" name="ARM Compiler" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.2070806136" name="Target processor version (--silicon_version, -mv)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.7M3" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.1411365061" name="Designate code state, 16-bit (thumb) or 32-bit (--code_state)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.16" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.193495829" name="Application binary interface. (--abi)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.eabi" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN.1573436637" name="Little endian code [See 'General' page to edit] (--little_endian, -me)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.978889992" name="Optimization level (--opt_level, -O)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.4" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.1392883332" name="Speed vs. size trade-offs (--opt_for_speed, -mf)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.0" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH.511635494" name="Add dir to #include search path (--include_path, -I)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH" valueType="includePath">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION.277675815" name="Compiler version" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION" value="18.1.4.LTS" valueType="string"/>
|
||||
<targetPlatform id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug.1593934674" name="Platform" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug"/>
|
||||
<builder buildPath="${BuildDirectory}" id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug.632414212" keepEnvironmentInBuildfile="false" name="GNU Make" parallelBuildOn="true" parallelizationNumber="optimal" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug.154623462" name="ARM Compiler" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.974280107" name="Target processor version (--silicon_version, -mv)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.7M3" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.1783826131" name="Designate code state, 16-bit (thumb) or 32-bit (--code_state)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.16" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.1536570599" name="Application binary interface. (--abi)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.eabi" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN.1895413316" name="Little endian code [See 'General' page to edit] (--little_endian, -me)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.322983319" name="Optimization level (--opt_level, -O)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.4" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.1305400753" name="Speed vs. size trade-offs (--opt_for_speed, -mf)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.0" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH.1468985930" name="Add dir to #include search path (--include_path, -I)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/include"/>
|
||||
<listOptionValue builtIn="false" value="C:\ti\simplelink\ble_sdk_2_02_02_25\src\examples\simple_peripheral\cc26xx\app\headstage"/>
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/examples/simple_peripheral/cc26xx/app"/>
|
||||
@@ -70,10 +70,11 @@
|
||||
<listOptionValue builtIn="false" value="${SRC_BLE_CORE}/rom"/>
|
||||
<listOptionValue builtIn="false" value="${CC26XXWARE}"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE.521147483" name="Pre-define NAME (--define, -D)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE" valueType="definedSymbols">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE.1897088" name="Pre-define NAME (--define, -D)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="BOARD_DISPLAY_EXCLUDE_UART"/>
|
||||
<listOptionValue builtIn="false" value="POWER_SAVING"/>
|
||||
<listOptionValue builtIn="false" value="BOOSTXL_CC2650MA"/>
|
||||
<listOptionValue builtIn="false" value="HEADSTAGE_MA_USE_SPI2"/>
|
||||
<listOptionValue builtIn="false" value="CC26XX"/>
|
||||
<listOptionValue builtIn="false" value="GAPROLE_TASK_STACK_SIZE=540"/>
|
||||
<listOptionValue builtIn="false" value="HEAPMGR_SIZE=0"/>
|
||||
@@ -85,71 +86,71 @@
|
||||
<listOptionValue builtIn="false" value="xdc_runtime_Assert_DISABLE_ALL"/>
|
||||
<listOptionValue builtIn="false" value="xdc_runtime_Log_DISABLE_ALL"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL.1861999587" name="Debugging model" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL.SYMDEBUG__DWARF" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.1867564782" name="C Dialect" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.C99" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GCC.2052831394" name="Enable support for GCC extensions (DEPRECATED) (--gcc)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GCC" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS.1102242787" name="Suppress diagnostic <id> (--diag_suppress, -pds)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL.871011287" name="Debugging model" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEBUGGING_MODEL.SYMDEBUG__DWARF" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.863089168" name="C Dialect" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.C99" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GCC.1454248503" name="Enable support for GCC extensions (DEPRECATED) (--gcc)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GCC" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS.1965115059" name="Suppress diagnostic <id> (--diag_suppress, -pds)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="48"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING.727880917" name="Treat diagnostic <id> as warning (--diag_warning, -pdsw)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING.1638011093" name="Treat diagnostic <id> as warning (--diag_warning, -pdsw)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="225"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.996618365" name="Wrap diagnostic messages (--diag_wrap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER.858761211" name="Emit diagnostic identifier numbers (--display_error_number, -pden)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS.96303422" name="Place each function in a separate subsection (--gen_func_subsections, -ms)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE.1634706392" name="Read options from specified file (--cmd_file, -@)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.1920170652" name="Wrap diagnostic messages (--diag_wrap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER.2038786257" name="Emit diagnostic identifier numbers (--display_error_number, -pden)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS.811478344" name="Place each function in a separate subsection (--gen_func_subsections, -ms)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.GEN_FUNC_SUBSECTIONS.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE.1229809338" name="Read options from specified file (--cmd_file, -@)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/config/build_components.opt"/>
|
||||
<listOptionValue builtIn="false" value="${ORG_PROJ_DIR}/build_config.opt"/>
|
||||
<listOptionValue builtIn="false" value="${ORG_PROJ_DIR}/../../ccs/config/ccs_compiler_defines.bcfg"/>
|
||||
</option>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS.1149005836" name="C Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS.404213358" name="C++ Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS.1356338499" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS.1609020645" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS.1540775079" name="C Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS.319000695" name="C++ Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS.270651019" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS.463094612" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS"/>
|
||||
</tool>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.2125878104" name="ARM Linker" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE.1993482378" name="Set C system stack size (--stack_size, -stack)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE" value="256" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE.833137428" name="Heap size for C/C++ dynamic memory allocation (--heap_size, -heap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE" value="0" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE.1072440081" name="Link information (map) listed into <file> (--map_file, -m)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE" value=""${ProjName}.map"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE.95815077" name="Specify output file name (--output_file, -o)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE" value="${ProjName}.out" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY.1766117832" name="Include library file or command file as input (--library, -l)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY" valueType="libs">
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.1351821865" name="ARM Linker" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE.174129193" name="Set C system stack size (--stack_size, -stack)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE" value="256" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE.567300083" name="Heap size for C/C++ dynamic memory allocation (--heap_size, -heap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE" value="0" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE.1800982811" name="Link information (map) listed into <file> (--map_file, -m)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE" value=""${ProjName}.map"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE.1091211742" name="Specify output file name (--output_file, -o)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE" value="${ProjName}.out" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY.1479599481" name="Include library file or command file as input (--library, -l)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="libc.a"/>
|
||||
<listOptionValue builtIn="false" value="${CC26XXWARE}/driverlib/bin/ccs/driverlib.lib"/>
|
||||
<listOptionValue builtIn="false" value="${ROM}/common_rom_releases/03282014/common_rom.symbols"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH.1149343368" name="Add <dir> to library search path (--search_path, -i)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH" valueType="libPaths">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH.672837228" name="Add <dir> to library search path (--search_path, -i)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/lib"/>
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/include"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS.512740056" name="Suppress diagnostic <id> (--diag_suppress)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS.544523272" name="Suppress diagnostic <id> (--diag_suppress)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="10247-D"/>
|
||||
<listOptionValue builtIn="false" value="16002-D"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.755787473" name="Wrap diagnostic messages (--diag_wrap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER.1039632635" name="Emit diagnostic identifier numbers (--display_error_number)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO.160090718" name="Detailed link information data-base into <file> (--xml_link_info, -xml_link_info)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO" value=""${ProjName}_linkInfo.xml"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.1907564273" name="Aggressively reduce size of the DWARF information (--compress_dwarf)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.1278577864" name="Eliminate sections not needed in the executable (--unused_section_elimination)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.on" valueType="enumerated"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS.1166775149" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS.1192919935" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS.1491242603" name="Generated Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.1281207998" name="Wrap diagnostic messages (--diag_wrap)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER.468817864" name="Emit diagnostic identifier numbers (--display_error_number)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO.1679096029" name="Detailed link information data-base into <file> (--xml_link_info, -xml_link_info)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO" value=""${ProjName}_linkInfo.xml"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.254835397" name="Aggressively reduce size of the DWARF information (--compress_dwarf)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.1848192295" name="Eliminate sections not needed in the executable (--unused_section_elimination)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.on" valueType="enumerated"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS.1999849945" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS.25027104" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS.888093741" name="Generated Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS"/>
|
||||
</tool>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.1967400950" name="ARM Hex Utility" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH.1242139870" name="Specify rom width (--romwidth, -romwidth=width)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH.1863065780" name="Specify memory width (--memwidth, -memwidth=width)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.47746446" name="Output format" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.INTEL" valueType="enumerated"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.19288898" name="ARM Hex Utility" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH.11734737" name="Specify rom width (--romwidth, -romwidth=width)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH.466140455" name="Specify memory width (--memwidth, -memwidth=width)" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.824070691" name="Output format" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.INTEL" valueType="enumerated"/>
|
||||
</tool>
|
||||
<tool id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.1864525425" name="XDCtools" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool">
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.XDC_PATH.46430604" name="Package repositories (--xdcpath)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.XDC_PATH" valueType="stringList">
|
||||
<tool id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.1392704063" name="XDCtools" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool">
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.XDC_PATH.225737408" name="Package repositories (--xdcpath)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.XDC_PATH" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="${COM_TI_RTSC_TIRTOSCC13XX_CC26XX_REPOS}"/>
|
||||
<listOptionValue builtIn="false" value="${TARGET_CONTENT_BASE}"/>
|
||||
</option>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.TARGET.313008504" name="Target (-t)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.TARGET" value="ti.targets.arm.elf.M3" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM.807892561" name="Platform (-p)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM" value="ti.platforms.simplelink:CC2640F128" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM_RAW.1808973543" name="Platform (-p)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM_RAW" value="ti.platforms.simplelink:CC2640F128" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.BUILD_PROFILE.1028195441" name="Build-profile (-r)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.BUILD_PROFILE" value="release" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.CODEGEN_TOOL_DIR.295955151" name="Compiler tools directory (-c)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.CODEGEN_TOOL_DIR" value="${CG_TOOL_ROOT}" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.COMPILE_OPTIONS.128448790" name="Additional compiler options (--compileOptions)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.COMPILE_OPTIONS" value=""${COMPILER_FLAGS}"" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.TARGET.571281110" name="Target (-t)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.TARGET" value="ti.targets.arm.elf.M3" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM.205178830" name="Platform (-p)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM" value="ti.platforms.simplelink:CC2640F128" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM_RAW.1097777495" name="Platform (-p)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.PLATFORM_RAW" value="ti.platforms.simplelink:CC2640F128" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.BUILD_PROFILE.744121344" name="Build-profile (-r)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.BUILD_PROFILE" value="release" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.CODEGEN_TOOL_DIR.165807018" name="Compiler tools directory (-c)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.CODEGEN_TOOL_DIR" value="${CG_TOOL_ROOT}" valueType="string"/>
|
||||
<option id="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.COMPILE_OPTIONS.391961861" name="Additional compiler options (--compileOptions)" superClass="com.ti.rtsc.buildDefinitions.XDC_3.16.tool.COMPILE_OPTIONS" value=""${COMPILER_FLAGS}"" valueType="string"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
|
||||
+15
-14
@@ -1,19 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<configurations XML_version="1.2" id="configurations_0">
|
||||
<configuration XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS100v3 USB Debug Probe_0" href="connections/TIXDS100v3_Dot7_Connection.xml" id="Texas Instruments XDS100v3 USB Debug Probe_0" xml="TIXDS100v3_Dot7_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2icepick_c.xml" id="drivers" xml="tixds100v2icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cs_dap.xml" id="drivers" xml="tixds100v2cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cortexM.xml" id="drivers" xml="tixds100v2cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="2" id="The Converter Usage">
|
||||
<choice Name="Generate 1149.7 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="The Converter 1149.7 Frequency">
|
||||
<choice Name="Overclock with user specified value" value="unused">
|
||||
<property Type="choicelist" Value="5" id="-- Choose a value from 1.0MHz to 50.0MHz"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="5" id="The Target Scan Format"/>
|
||||
<configuration XML_version="1.2" id="Texas Instruments XDS110 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS110 USB Debug Probe_0" href="connections/TIXDS110_Connection.xml" id="Texas Instruments XDS110 USB Debug Probe_0" xml="TIXDS110_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS110 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" href="drivers/tixds510icepick_c.xml" id="drivers" xml="tixds510icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds510cs_dap.xml" id="drivers" xml="tixds510cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds510cortexM.xml" id="drivers" xml="tixds510cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="1" id="Power Selection">
|
||||
<choice Name="Probe supplied power" value="1">
|
||||
<property Type="stringfield" Value="3.3" id="Voltage Level"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="0" id="JTAG Signal Isolation"/>
|
||||
<property Type="choicelist" Value="4" id="SWD Mode Settings">
|
||||
<choice Name="cJTAG (1149.7) 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="XDS110 Aux Port"/>
|
||||
</choice>
|
||||
</property>
|
||||
<platform XML_version="1.2" id="platform_0">
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
+4
-4
@@ -16,11 +16,11 @@ BIOS_INC = -I"C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/pa
|
||||
|
||||
TARGET_INC = -I"C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/"
|
||||
|
||||
INCS = $(BIOS_INC) $(TARGET_INC) --include_path="C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/icall/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/dev_info" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/simple_profile/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/simple_profile" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/heapmgr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/controller/cc26xx/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/target" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/osal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/sdata" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/saddr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/icall/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/rom" --include_path="C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/cc26xxware_2_24_03_17272" -IC:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/
|
||||
INCS = $(BIOS_INC) $(TARGET_INC) --include_path="C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/include" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app/headstage" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/simple_peripheral/cc26xx/app" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/icall/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/dev_info" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/simple_profile/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/simple_profile" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/heapmgr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/controller/cc26xx/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/target" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/osal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/sdata" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/saddr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/icall/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/rom" --include_path="C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/cc26xxware_2_24_03_17272" -IC:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/
|
||||
|
||||
CC = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include
|
||||
ASM = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include
|
||||
AR = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armar rq
|
||||
CC = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/include
|
||||
ASM = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/include
|
||||
AR = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.3.LTS/bin/armar rq
|
||||
|
||||
DEL = C:/ti/xdctools_3_32_02_25_core/packages/../bin/rm -f
|
||||
CP = C:/ti/xdctools_3_32_02_25_core/packages/../bin/cp -f
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
+1
-1
@@ -9,6 +9,6 @@
|
||||
<linkerCommandFile value="cc26x0f128.cmd"/>
|
||||
<rts value="libc.a"/>
|
||||
<createSlaveProjects value=""/>
|
||||
<connection value="common/targetdb/connections/TIXDS100v3_Dot7_Connection.xml"/>
|
||||
<connection value="common/targetdb/connections/TIXDS110_Connection.xml"/>
|
||||
<isTargetManual value="false"/>
|
||||
</projectOptions>
|
||||
|
||||
+45
-45
@@ -15,8 +15,8 @@
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="out" artifactName="${ProjName}" buildProperties="" cleanCommand="${CG_CLEAN_CMD}" description="" id="com.ti.ccstudio.buildDefinitions.TMS470.Default.1209999684" name="FlashROM" parent="com.ti.ccstudio.buildDefinitions.TMS470.Default" postannouncebuildStep="" postbuildStep="${CG_TOOL_HEX} -order MS --memwidth=8 --romwidth=8 --intel -o ${ProjName}.hex ${ProjName}.out;${TOOLS_BLE}/frontier/frontier.exe ccs ${PROJECT_LOC}/${ConfigName}/${ProjName}_linkInfo.xml ${ORG_PROJ_DIR}/../../ccs/config/ccs_compiler_defines.bcfg ${ORG_PROJ_DIR}/../../ccs/config/ccs_linker_defines.cmd" preannouncebuildStep="" prebuildStep=""${TOOLS_BLE}/lib_search/lib_search.exe" ${ORG_PROJ_DIR}/build_config.opt "${TOOLS_BLE}/lib_search/params_split_cc2640.xml" ${SRC_BLE_CORE}/../blelib "${ORG_PROJ_DIR}/../../ccs/config/lib_linker.cmd"">
|
||||
<folderInfo id="com.ti.ccstudio.buildDefinitions.TMS470.Default.1209999684." name="/" resourcePath="">
|
||||
<toolChain id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain.929750171" name="TI Build Tools" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain" targetTool="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.1008890994">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS.1479696404" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS" valueType="stringList">
|
||||
<toolChain id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain.958553711" name="TI Build Tools" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.DebugToolchain" targetTool="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.2088015050">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS.2112506999" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_TAGS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="DEVICE_CONFIGURATION_ID=Cortex M.CC2650F128"/>
|
||||
<listOptionValue builtIn="false" value="DEVICE_ENDIANNESS=little"/>
|
||||
<listOptionValue builtIn="false" value="OUTPUT_FORMAT=ELF"/>
|
||||
@@ -26,17 +26,17 @@
|
||||
<listOptionValue builtIn="false" value="LINKER_COMMAND_FILE="/>
|
||||
<listOptionValue builtIn="false" value="OUTPUT_TYPE=executable"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION.201372544" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION" value="18.1.4.LTS" valueType="string"/>
|
||||
<targetPlatform id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug.1951196199" name="Platform" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug"/>
|
||||
<builder buildPath="${BuildDirectory}" id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug.20903631" name="GNU Make.FlashROM" parallelBuildOn="true" parallelizationNumber="optimal" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug.1176131016" name="ARM Compiler" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.647279085" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.7M3" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.1443871767" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.16" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.227818129" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.eabi" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN.784155377" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.494285153" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.4" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.581550859" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.0" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH.1288777730" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH" valueType="includePath">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION.101349069" superClass="com.ti.ccstudio.buildDefinitions.core.OPT_CODEGEN_VERSION" value="18.1.4.LTS" valueType="string"/>
|
||||
<targetPlatform id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug.572884961" name="Platform" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.targetPlatformDebug"/>
|
||||
<builder buildPath="${BuildDirectory}" id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug.50794417" name="GNU Make.FlashROM" parallelBuildOn="true" parallelizationNumber="optimal" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.builderDebug"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug.783335843" name="ARM Compiler" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.compilerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.341974501" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.SILICON_VERSION.7M3" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.274225680" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CODE_STATE.16" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.529764162" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.ABI.eabi" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN.1837039616" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.LITTLE_ENDIAN" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.1393115220" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_LEVEL.4" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.2112471580" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.OPT_FOR_SPEED.0" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH.152832201" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.INCLUDE_PATH" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/include"/>
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/examples/simple_peripheral/cc26xx/stack"/>
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/common/cc26xx"/>
|
||||
@@ -60,7 +60,7 @@
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/profiles/roles"/>
|
||||
<listOptionValue builtIn="false" value="${CC26XXWARE}"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE.986125825" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE" valueType="definedSymbols">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE.1361895403" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DEFINE" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CC26XX"/>
|
||||
<listOptionValue builtIn="false" value="POWER_SAVING"/>
|
||||
<listOptionValue builtIn="false" value="CC26XXWARE"/>
|
||||
@@ -81,60 +81,60 @@
|
||||
<listOptionValue builtIn="false" value="xTESTMODES"/>
|
||||
<listOptionValue builtIn="false" value="xTEST_BLEBOARD"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.372638078" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.C99" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS.201347726" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.1555958931" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.C_DIALECT.C99" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS.1144396572" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="48"/>
|
||||
<listOptionValue builtIn="false" value="16004"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING.73314177" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING.1546809951" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WARNING" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="225"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.1126279750" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER.1492280006" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE.538453952" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.12083718" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER.1432753391" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE.1345637669" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compilerID.CMD_FILE" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="${SRC_EX}/config/build_components.opt"/>
|
||||
<listOptionValue builtIn="false" value="${ORG_PROJ_DIR}/build_config.opt"/>
|
||||
</option>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS.313905687" name="C Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS.1129729173" name="C++ Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS.156783227" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS.538375181" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS.1884548091" name="C Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__C_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS.682104615" name="C++ Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__CPP_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS.662317863" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS.728508440" name="Assembly Sources" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.compiler.inputType__ASM2_SRCS"/>
|
||||
</tool>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.1008890994" name="ARM Linker" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE.1873600405" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE" value="256" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE.1359172875" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE" value="0" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE.1355177509" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE" value=""${ProjName}.map"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE.829303802" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE" value="${ProjName}.out" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY.1078356909" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY" valueType="libs">
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug.2088015050" name="ARM Linker" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exe.linkerDebug">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE.1079333148" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.STACK_SIZE" value="256" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE.1347544490" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.HEAP_SIZE" value="0" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE.136883143" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.MAP_FILE" value=""${ProjName}.map"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE.1510359183" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.OUTPUT_FILE" value="${ProjName}.out" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY.1331488920" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.LIBRARY" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="libc.a"/>
|
||||
<listOptionValue builtIn="false" value="${ORG_PROJ_DIR}/../../ccs/config/lib_linker.cmd"/>
|
||||
<listOptionValue builtIn="false" value="${ROM}/ble_rom_releases/04242014/ble_rom_patch.symbols"/>
|
||||
<listOptionValue builtIn="false" value="${CC26XXWARE}/driverlib/bin/ccs/driverlib.lib"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH.1707930214" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH" valueType="libPaths">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH.1835383942" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.SEARCH_PATH" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/lib"/>
|
||||
<listOptionValue builtIn="false" value="${CG_TOOL_ROOT}/include"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS.59164041" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS.821225577" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_SUPPRESS" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value="16002-D"/>
|
||||
<listOptionValue builtIn="false" value="10247-D"/>
|
||||
<listOptionValue builtIn="false" value="10325-D"/>
|
||||
<listOptionValue builtIn="false" value="10229-D"/>
|
||||
</option>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.11567165" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER.1727810233" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO.1385277262" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO" value=""${ProjName}_linkInfo.xml"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.ENTRY_POINT.1153340314" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.ENTRY_POINT" value="startup_entry" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.450995330" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.1827942626" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.on" valueType="enumerated"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS.1279238428" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS.526125450" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS.581803256" name="Generated Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.1390204935" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DIAG_WRAP.off" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER.1601082213" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.DISPLAY_ERROR_NUMBER" value="true" valueType="boolean"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO.351715800" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.XML_LINK_INFO" value=""${ProjName}_linkInfo.xml"" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.ENTRY_POINT.90863272" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.ENTRY_POINT" value="startup_entry" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.1779672459" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.COMPRESS_DWARF.on" valueType="enumerated"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.1701763005" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.linkerID.UNUSED_SECTION_ELIMINATION.on" valueType="enumerated"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS.687564793" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS.1056923280" name="Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__CMD2_SRCS"/>
|
||||
<inputType id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS.73723664" name="Generated Linker Command Files" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.exeLinker.inputType__GEN_CMDS"/>
|
||||
</tool>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.947560992" name="ARM Hex Utility" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH.1295209583" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH.110293046" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.1122561921" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.INTEL" valueType="enumerated"/>
|
||||
<tool id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.1766088709" name="ARM Hex Utility" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex">
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH.494132983" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.ROMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH.1603693219" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.MEMWIDTH" value="8" valueType="string"/>
|
||||
<option id="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.1153492005" superClass="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT" value="com.ti.ccstudio.buildDefinitions.TMS470_18.1.hex.OUTPUT_FORMAT.INTEL" valueType="enumerated"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
|
||||
+1
@@ -12,6 +12,7 @@
|
||||
<stringAttribute key="com.ti.ccstudio.debug.debugModel.ATTR_TARGET_CONFIG" value="${target_config_active_default:simple_peripheral_cc2650em_stack}"/>
|
||||
<stringAttribute key="com.ti.ccstudio.debug.debugModel.MRU_PROGRAM.C:\ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\targetConfigs\CC2650F128.ccxml.Texas Instruments XDS100v3 USB Debug Probe_0/Cortex_M3_0" value="C:/ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\FlashROM\simple_peripheral_cc2650em_stack.out"/>
|
||||
<stringAttribute key="com.ti.ccstudio.debug.debugModel.MRU_PROGRAM.C:\ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\targetConfigs\CC2650F128.ccxml.Texas Instruments XDS110 USB Debug Probe/Cortex_M3_0" value="C:/ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\FlashROM\simple_peripheral_cc2650em_stack.out"/>
|
||||
<stringAttribute key="com.ti.ccstudio.debug.debugModel.MRU_PROGRAM.C:\ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\targetConfigs\CC2650F128.ccxml.Texas Instruments XDS110 USB Debug Probe_0/Cortex_M3_0" value="C:/ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650em\simple_peripheral\ccs\stack\FlashROM\simple_peripheral_cc2650em_stack.out"/>
|
||||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
|
||||
<listEntry value="/simple_peripheral_cc2650em_stack"/>
|
||||
</listAttribute>
|
||||
|
||||
+15
-14
@@ -1,19 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<configurations XML_version="1.2" id="configurations_0">
|
||||
<configuration XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS100v3 USB Debug Probe_0" href="connections/TIXDS100v3_Dot7_Connection.xml" id="Texas Instruments XDS100v3 USB Debug Probe_0" xml="TIXDS100v3_Dot7_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS100v3 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2icepick_c.xml" id="drivers" xml="tixds100v2icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cs_dap.xml" id="drivers" xml="tixds100v2cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds100v2cortexM.xml" id="drivers" xml="tixds100v2cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="2" id="The Converter Usage">
|
||||
<choice Name="Generate 1149.7 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="The Converter 1149.7 Frequency">
|
||||
<choice Name="Overclock with user specified value" value="unused">
|
||||
<property Type="choicelist" Value="5" id="-- Choose a value from 1.0MHz to 50.0MHz"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="5" id="The Target Scan Format"/>
|
||||
<configuration XML_version="1.2" id="Texas Instruments XDS110 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" desc="Texas Instruments XDS110 USB Debug Probe_0" href="connections/TIXDS110_Connection.xml" id="Texas Instruments XDS110 USB Debug Probe_0" xml="TIXDS110_Connection.xml" xmlpath="connections"/>
|
||||
<connection XML_version="1.2" id="Texas Instruments XDS110 USB Debug Probe_0">
|
||||
<instance XML_version="1.2" href="drivers/tixds510icepick_c.xml" id="drivers" xml="tixds510icepick_c.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds510cs_dap.xml" id="drivers" xml="tixds510cs_dap.xml" xmlpath="drivers"/>
|
||||
<instance XML_version="1.2" href="drivers/tixds510cortexM.xml" id="drivers" xml="tixds510cortexM.xml" xmlpath="drivers"/>
|
||||
<property Type="choicelist" Value="1" id="Power Selection">
|
||||
<choice Name="Probe supplied power" value="1">
|
||||
<property Type="stringfield" Value="3.3" id="Voltage Level"/>
|
||||
</choice>
|
||||
</property>
|
||||
<property Type="choicelist" Value="0" id="JTAG Signal Isolation"/>
|
||||
<property Type="choicelist" Value="4" id="SWD Mode Settings">
|
||||
<choice Name="cJTAG (1149.7) 2-pin advanced modes" value="enable">
|
||||
<property Type="choicelist" Value="1" id="XDS110 Aux Port"/>
|
||||
</choice>
|
||||
</property>
|
||||
<platform XML_version="1.2" id="platform_0">
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@
|
||||
# sources were generated) is:
|
||||
# C:\ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650lp\host_test\ccs\config\src
|
||||
#
|
||||
GEN_SRC_DIR ?= ../../config/src
|
||||
GEN_SRC_DIR ?= ../../../../../ti/simplelink/ble_sdk_2_02_02_25/examples/cc2650lp/host_test/ccs/config/src
|
||||
|
||||
ifeq (,$(wildcard $(GEN_SRC_DIR)))
|
||||
$(error "ERROR: GEN_SRC_DIR must be set to the directory containing the generated sources")
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
+4
-4
@@ -16,11 +16,11 @@ BIOS_INC = -I"C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/pa
|
||||
|
||||
TARGET_INC = -I"C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/"
|
||||
|
||||
INCS = $(BIOS_INC) $(TARGET_INC) --include_path="C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/host_test/cc26xx/app/cc2650" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/host_test/cc26xx/app" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/icall/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/npi/src" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/heapmgr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/controller/cc26xx/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/target" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/osal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/sdata" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/saddr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/icall/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/rom" --include_path="C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/cc26xxware_2_24_03_17272" -IC:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/
|
||||
INCS = $(BIOS_INC) $(TARGET_INC) --include_path="C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/include" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/examples/host_test/cc26xx/app" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/icall/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/profiles/roles" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/npi/src" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/heapmgr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/controller/cc26xx/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/target" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/target/_common/cc26xx" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/hal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/osal/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/sdata" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/services/src/saddr" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/components/icall/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/inc" --include_path="C:/ti/simplelink/ble_sdk_2_02_02_25/src/rom" --include_path="C:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/cc26xxware_2_24_03_17272" -IC:/ti/tirtos_cc13xx_cc26xx_2_21_01_08/products/bios_6_46_01_38/packages/
|
||||
|
||||
CC = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include
|
||||
ASM = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include
|
||||
AR = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armar rq
|
||||
CC = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/include
|
||||
ASM = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/bin/armcl -c $(CCOPTS) -I C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/include
|
||||
AR = C:/ti/ccsv8/tools/compiler/ti-cgt-arm_16.9.4.LTS/bin/armar rq
|
||||
|
||||
DEL = C:/ti/xdctools_3_32_00_06_core/packages/../bin/rm -f
|
||||
CP = C:/ti/xdctools_3_32_00_06_core/packages/../bin/cp -f
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
+1
-1
@@ -16,7 +16,7 @@
|
||||
# sources were generated) is:
|
||||
# C:\ti\simplelink\ble_sdk_2_02_02_25\examples\cc2650lp\simple_peripheral\ccs\config\src
|
||||
#
|
||||
GEN_SRC_DIR ?= ../../config/src
|
||||
GEN_SRC_DIR ?= ../../../../../ti/simplelink/ble_sdk_2_02_02_25/examples/cc2650lp/simple_peripheral/ccs/config/src
|
||||
|
||||
ifeq (,$(wildcard $(GEN_SRC_DIR)))
|
||||
$(error "ERROR: GEN_SRC_DIR must be set to the directory containing the generated sources")
|
||||
|
||||
@@ -80,6 +80,7 @@ const PIN_Config BoardGpioInitTable[] = {
|
||||
Board_UART_TX | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL, /* UART TX */
|
||||
Board_SRDY | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL, /* SRDY */
|
||||
Board_MRDY | PIN_INPUT_EN | PIN_PULLDOWN, /* MRDY */
|
||||
|
||||
PIN_TERMINATE
|
||||
};
|
||||
|
||||
@@ -189,57 +190,6 @@ const UDMACC26XX_Config UDMACC26XX_config[] = {
|
||||
* ============================= UDMA end =====================================
|
||||
*/
|
||||
|
||||
/*
|
||||
* ========================== SPI DMA begin ===================================
|
||||
*/
|
||||
/* Place into subsections to allow the TI linker to remove items properly */
|
||||
#if defined(__TI_COMPILER_VERSION__)
|
||||
#pragma DATA_SECTION(SPI_config, ".const:SPI_config")
|
||||
#pragma DATA_SECTION(spiCC26XXDMAHWAttrs, ".const:spiCC26XXDMAHWAttrs")
|
||||
#endif
|
||||
|
||||
/* Include drivers */
|
||||
#include <ti/drivers/spi/SPICC26XXDMA.h>
|
||||
|
||||
/* SPI objects */
|
||||
SPICC26XXDMA_Object spiCC26XXDMAObjects[BOOSTXL_CC2650MA_SPICOUNT];
|
||||
|
||||
/* SPI configuration structure, describing which pins are to be used */
|
||||
const SPICC26XXDMA_HWAttrsV1 spiCC26XXDMAHWAttrs[BOOSTXL_CC2650MA_UDMACOUNT] = {
|
||||
{
|
||||
.baseAddr = SSI0_BASE,
|
||||
.intNum = INT_SSI0_COMB,
|
||||
.intPriority = ~0,
|
||||
.swiPriority = 0,
|
||||
.powerMngrId = PowerCC26XX_PERIPH_SSI0,
|
||||
.defaultTxBufValue = 0,
|
||||
.rxChannelBitMask = 1<<UDMA_CHAN_SSI0_RX,
|
||||
.txChannelBitMask = 1<<UDMA_CHAN_SSI0_TX,
|
||||
.mosiPin = Board_SPI0_MOSI,
|
||||
.misoPin = Board_SPI0_MISO,
|
||||
.clkPin = Board_SPI0_CLK,
|
||||
.csnPin = Board_SPI0_CS
|
||||
},
|
||||
};
|
||||
|
||||
/* SPI configuration structure */
|
||||
const SPI_Config SPI_config[] = {
|
||||
{
|
||||
.fxnTablePtr = &SPICC26XXDMA_fxnTable,
|
||||
.object = &spiCC26XXDMAObjects[0],
|
||||
.hwAttrs = &spiCC26XXDMAHWAttrs[0]
|
||||
},
|
||||
{
|
||||
.fxnTablePtr = &SPICC26XXDMA_fxnTable,
|
||||
.object = &spiCC26XXDMAObjects[1],
|
||||
.hwAttrs = &spiCC26XXDMAHWAttrs[1]
|
||||
},
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
/*
|
||||
* ========================== SPI DMA end =====================================
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* ========================== Crypto begin ====================================
|
||||
|
||||
@@ -89,24 +89,24 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
*/
|
||||
|
||||
/* Connector J1 */
|
||||
#define Board_BP_Pin_J1_2 DIO7
|
||||
#define Board_BP_Pin_J1_2 IOID_UNUSED
|
||||
#define Board_BP_Pin_J1_3 DIO0
|
||||
#define Board_BP_Pin_J1_4 DIO1
|
||||
#define Board_BP_Pin_J1_5 DIO2
|
||||
#define Board_BP_Pin_J1_6 DIO3
|
||||
#define Board_BP_Pin_J1_7 DIO10
|
||||
#define Board_BP_Pin_J1_7 DIO11 /* SCLK */
|
||||
#define Board_BP_Pin_J1_8 DIO4
|
||||
#define Board_BP_Pin_J1_9 DIO5
|
||||
#define Board_BP_Pin_J1_10 DIO6
|
||||
|
||||
/* Connector J2 */
|
||||
#define Board_BP_Pin_J2_19 DIO8
|
||||
#define Board_BP_Pin_J2_18 DIO9 /* CS */
|
||||
#define Board_BP_Pin_J2_19 IOID_UNUSED
|
||||
#define Board_BP_Pin_J2_18 IOID_UNUSED
|
||||
#define Board_BP_Pin_J2_17 IOID_UNUSED /* NC */
|
||||
#define Board_BP_Pin_J2_15 DIO11 /* MOSI */
|
||||
#define Board_BP_Pin_J2_14 DIO12 /* MISO */
|
||||
#define Board_BP_Pin_J2_13 DIO13
|
||||
#define Board_BP_Pin_J2_12 DIO14
|
||||
#define Board_BP_Pin_J2_15 DIO8 /* MOSI */
|
||||
#define Board_BP_Pin_J2_14 DIO7 /* MISO */
|
||||
#define Board_BP_Pin_J2_13 DIO9 /* DAC_CS */
|
||||
#define Board_BP_Pin_J2_12 DIO12 /* ADC_CS */
|
||||
#define Board_BP_Pin_J2_11 IOID_UNUSED /* NC */
|
||||
|
||||
/* Mapping of BoosterPack Connector Pins to BoosterPack Standard Functions (reflecting the BoosterPack Standard)
|
||||
@@ -125,12 +125,12 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
|
||||
/* Connector J2 */
|
||||
#define Board_BP_PWM_0 Board_BP_Pin_J2_19
|
||||
#define Board_BP_SPI_CS_Wireless Board_BP_Pin_J2_18
|
||||
#define Board_BP_SPI_CS_Wireless PIN_UNASSIGNED
|
||||
#define Board_BP_GPIO_3 Board_BP_Pin_J2_17
|
||||
#define Board_BP_SPI_MOSI Board_BP_Pin_J2_15
|
||||
#define Board_BP_SPI_MISO Board_BP_Pin_J2_14
|
||||
#define Board_BP_SPI_CS_Display Board_BP_Pin_J2_13
|
||||
#define Board_BP_SPI_CS_Other Board_BP_Pin_J2_12
|
||||
#define Board_BP_SPI_CS_Display PIN_UNASSIGNED
|
||||
#define Board_BP_SPI_CS_Other PIN_UNASSIGNED
|
||||
#define Board_BP_GPIO_2 Board_BP_Pin_J2_11
|
||||
|
||||
|
||||
@@ -145,11 +145,11 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
#define Board_UART_TX Board_BP_UART_Rx /* RXD */
|
||||
#define Board_UART_RX Board_BP_UART_Tx /* TXD */
|
||||
|
||||
/* SPI Board */
|
||||
#define Board_SPI0_MISO Board_BP_SPI_MISO
|
||||
#define Board_SPI0_MOSI Board_BP_SPI_MOSI
|
||||
#define Board_SPI0_CLK Board_BP_SPI_CLK
|
||||
#define Board_SPI0_CS Board_BP_SPI_CS_Wireless
|
||||
|
||||
|
||||
//#define Board_SPI0_MISO PIN_UNASSIGNED
|
||||
//#define Board_SPI0_MOSI PIN_UNASSIGNED
|
||||
|
||||
|
||||
/* Power Management Board */
|
||||
#define Board_SRDY Board_BP_Pin_J2_19
|
||||
@@ -170,6 +170,7 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
* ==========================================================================*/
|
||||
/* Generic SPI instance identifiers */
|
||||
#define Board_SPI0 BOOSTXL_CC2650MA_SPI0
|
||||
#define Board_SPI1 BOOSTXL_CC2650MA_SPI1
|
||||
/* Generic UART instance identifiers */
|
||||
#define Board_UART BOOSTXL_CC2650MA_UART0
|
||||
/* Generic TRNG instance identiifer */
|
||||
@@ -208,15 +209,7 @@ typedef enum BOOSTXL_CC2650MA_CryptoName {
|
||||
} BOOSTXL_CC2650MA_CryptoName;
|
||||
|
||||
|
||||
/*!
|
||||
* @def BOOSTXL_CC2650MA_SPIName
|
||||
* @brief Enum of SPI names on the CC2650 Booster Pack
|
||||
*/
|
||||
typedef enum BOOSTXL_CC2650MA_SPIName {
|
||||
BOOSTXL_CC2650MA_SPI0 = 0,
|
||||
|
||||
BOOSTXL_CC2650MA_SPICOUNT
|
||||
} BOOSTXL_CC2650MA_SPIName;
|
||||
|
||||
/*!
|
||||
* @def BOOSTXL_CC2650MA_TRNGName
|
||||
|
||||
@@ -39,6 +39,7 @@ extern "C" {
|
||||
|
||||
#include <ti/drivers/Power.h>
|
||||
|
||||
//#include "BOOSTXL_CC2650MA.h"
|
||||
#include "BOOSTXL_CC2650MA.h"
|
||||
|
||||
/* These #defines allow us to reuse TI-RTOS across other device families */
|
||||
|
||||
@@ -79,23 +79,22 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
|
||||
/* UART Board */
|
||||
#define Board_UART_RX IOID_2 /* RXD */
|
||||
#define Board_UART_TX IOID_3 /* TXD */
|
||||
#define Board_UART_TX PIN_UNASSIGNED /* TXD */
|
||||
#define Board_UART_CTS IOID_19 /* CTS */
|
||||
#define Board_UART_RTS IOID_18 /* RTS */
|
||||
|
||||
/* SPI Board */
|
||||
#define Board_SPI0_MISO IOID_8 /* RF1.20 */
|
||||
#define Board_SPI0_MOSI IOID_9 /* RF1.18 */
|
||||
#define Board_SPI0_CLK IOID_10 /* RF1.16 */
|
||||
#define Board_SPI0_MISO IOID_0 /* RF1.20 */
|
||||
#define Board_SPI0_MOSI IOID_1 /* RF1.18 */
|
||||
#define Board_SPI0_CLK IOID_3 /* RF1.16 */
|
||||
#define Board_SPI0_CSN PIN_UNASSIGNED
|
||||
#define Board_SPI1_MISO PIN_UNASSIGNED
|
||||
#define Board_SPI1_MOSI PIN_UNASSIGNED
|
||||
#define Board_SPI1_CLK PIN_UNASSIGNED
|
||||
#define Board_SPI1_MOSI IOID_8 /* LED_MOSI */
|
||||
#define Board_SPI1_CLK IOID_9 /* LED_CLK */
|
||||
|
||||
|
||||
#define Board_SPI1_CSN PIN_UNASSIGNED
|
||||
|
||||
/* I2C */
|
||||
#define Board_I2C0_SCL0 IOID_4
|
||||
#define Board_I2C0_SDA0 IOID_5
|
||||
|
||||
/* SPI */
|
||||
#define Board_SPI_FLASH_CS IOID_20
|
||||
@@ -103,8 +102,8 @@ extern const PIN_Config BoardGpioInitTable[];
|
||||
#define Board_FLASH_CS_OFF 1
|
||||
|
||||
/* Booster pack generic */
|
||||
#define Board_DIO0 IOID_0
|
||||
#define Board_DIO1_RFSW IOID_1
|
||||
#define Board_DIO0 PIN_UNASSIGNED
|
||||
#define Board_DIO1_RFSW PIN_UNASSIGNED
|
||||
#define Board_DIO12 IOID_12
|
||||
#define Board_DIO15 IOID_15
|
||||
#define Board_DIO16_TDO IOID_16
|
||||
|
||||
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
@@ -55,7 +55,7 @@ extern "C"
|
||||
// includes
|
||||
// ****************************************************************************
|
||||
#include "hal_types.h"
|
||||
#include "npi/src/inc/npi_config.h"
|
||||
#include "inc/npi_config.h"
|
||||
|
||||
// ****************************************************************************
|
||||
// defines
|
||||
|
||||
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
Executable → Regular
@@ -9,7 +9,7 @@
|
||||
Target Device: CC2650, CC2640
|
||||
|
||||
******************************************************************************
|
||||
|
||||
|
||||
Copyright (c) 2013-2018, Texas Instruments Incorporated
|
||||
All rights reserved.
|
||||
|
||||
@@ -45,121 +45,87 @@
|
||||
Release Date: 2018-04-02 18:03:35
|
||||
*****************************************************************************/
|
||||
|
||||
/*********************************************************************
|
||||
* INCLUDES
|
||||
*/
|
||||
|
||||
#include <ti/sysbios/knl/Task.h>
|
||||
|
||||
#include <ti/sysbios/hal/Hwi.h>
|
||||
|
||||
#include <ti/sysbios/knl/Clock.h>
|
||||
|
||||
#include <ti/sysbios/knl/Semaphore.h>
|
||||
|
||||
#include <ti/sysbios/knl/Queue.h>
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "hal_types.h"
|
||||
|
||||
#include "hci_tl.h"
|
||||
|
||||
#include "hci_ext.h"
|
||||
|
||||
#include "gatt.h"
|
||||
|
||||
#include "hci.h"
|
||||
|
||||
#include "gapgattserver.h"
|
||||
|
||||
#include "gattservapp.h"
|
||||
|
||||
#include "gapbondmgr.h"
|
||||
|
||||
#define OSAL_SNV 0
|
||||
|
||||
#include "osal_snv.h"
|
||||
|
||||
#include "icall_apimsg.h"
|
||||
|
||||
#include "util.h"
|
||||
#include <ti/mw/display/Display.h>
|
||||
|
||||
#include "inc/npi_ble.h"
|
||||
|
||||
#include "inc/npi_task.h"
|
||||
|
||||
#include <inc/hw_types.h>
|
||||
|
||||
#include "hal_defs.h"
|
||||
|
||||
#if defined ( USE_RCOSC )
|
||||
#include "rcosc_calibration.h"
|
||||
#endif // USE_RCOSC
|
||||
|
||||
#if defined ( GATT_TEST ) || defined ( GATT_QUAL )
|
||||
#include "gatttest.h"
|
||||
#if defined(GATT_TEST) || defined(GATT_QUAL)
|
||||
#include "gatttest.h"
|
||||
#endif
|
||||
|
||||
#include "host_test_app.h"
|
||||
|
||||
#if defined( USE_FPGA ) || defined( DEBUG_SW_TRACE )
|
||||
#include <driverlib/ioc.h>
|
||||
#endif // USE_FPGA | DEBUG_SW_TRACE
|
||||
//#define PERIODIC_USE_GPTIMER
|
||||
|
||||
/*********************************************************************
|
||||
* CONSTANTS
|
||||
*/
|
||||
#include "cc2650/cc2650_util.h"
|
||||
|
||||
//#include "cc2650/cc2650_slave.h"
|
||||
|
||||
#include "cc2650/cc2650_master.h"
|
||||
|
||||
// LE Event Lengths
|
||||
#define HCI_CMD_COMPLETE_EVENT_LEN 3
|
||||
#define HCI_CMD_VS_COMPLETE_EVENT_LEN 2
|
||||
#define HCI_CMD_STATUS_EVENT_LEN 4
|
||||
#define HCI_PHY_UPDATE_COMPLETE_EVENT_LEN 6
|
||||
#define HCI_CMD_COMPLETE_EVENT_LEN 3
|
||||
#define HCI_CMD_VS_COMPLETE_EVENT_LEN 2
|
||||
#define HCI_CMD_STATUS_EVENT_LEN 4
|
||||
#define HCI_PHY_UPDATE_COMPLETE_EVENT_LEN 6
|
||||
|
||||
static void HTA_init(void);
|
||||
static void HTA_main(UArg a0, UArg a1);
|
||||
static void HTA_handle_gap_event(ICall_HciExtEvt *message);
|
||||
static void HTA_handle_att_event(gattMsgEvent_t *message);
|
||||
static void HTA_handle_ble_event(ICall_HciExtEvt *message);
|
||||
static void send_command_complete_event(uint8 eventCode, uint16 opcode, uint8 numParam, uint8 *param);
|
||||
static void send_command_status_event(uint8_t eventCode, uint16_t status, uint16_t opcode);
|
||||
static void send_ble_complete_event(uint8 eventLen, uint8 *pEvent);
|
||||
|
||||
extern void AssertHandler(uint8 assertCause, uint8 assertSubCause);
|
||||
|
||||
// Task configuration
|
||||
#define HTA_TASK_PRIORITY 1
|
||||
#define HTA_TASK_STACK_SIZE 644
|
||||
#define HTA_TASK_STACK_SIZE 512
|
||||
Task_Struct hta_task;
|
||||
Char hta_task_stack[HTA_TASK_STACK_SIZE];
|
||||
|
||||
/*********************************************************************
|
||||
* GLOBAL VARIABLES
|
||||
*/
|
||||
|
||||
// Display Interface
|
||||
Display_Handle dispHandle = NULL;
|
||||
|
||||
/*********************************************************************
|
||||
* LOCAL VARIABLES
|
||||
*/
|
||||
// Entity ID globally used to check for source and/or destination of messages
|
||||
static ICall_EntityID selfEntity;
|
||||
|
||||
// Semaphore globally used to post events to the application thread
|
||||
static ICall_Semaphore sem;
|
||||
|
||||
// Task configuration
|
||||
Task_Struct htaTask;
|
||||
Char htaTaskStack[HTA_TASK_STACK_SIZE];
|
||||
|
||||
#if !defined ( GATT_DB_OFF_CHIP )
|
||||
static uint8 deviceName[GAP_DEVICE_NAME_LEN] = { 0 };
|
||||
static uint16 appearance = 17;
|
||||
#endif
|
||||
|
||||
// Stack build revision
|
||||
ICall_BuildRevision buildRev;
|
||||
|
||||
/*********************************************************************
|
||||
* LOCAL FUNCTIONS
|
||||
*/
|
||||
|
||||
static void HostTestApp_init(void);
|
||||
static void HostTestApp_taskFxn(UArg a0, UArg a1);
|
||||
|
||||
static void HostTestApp_processGapEvent(ICall_HciExtEvt *pMsg);
|
||||
static void HostTestApp_processBLEEvent(ICall_HciExtEvt *pMsg);
|
||||
|
||||
static void sendCommandCompleteEvent(uint8 eventCode, uint16 opcode,
|
||||
uint8 numParam, uint8 *param);
|
||||
static void sendCommandStatusEvent(uint8_t eventCode, uint16_t status,
|
||||
uint16_t opcode);
|
||||
static void sendBLECompleteEvent(uint8 eventLen, uint8 *pEvent);
|
||||
|
||||
/*********************************************************************
|
||||
* EXTERN FUNCTIONS
|
||||
*/
|
||||
extern void AssertHandler(uint8 assertCause, uint8 assertSubcause);
|
||||
|
||||
/*********************************************************************
|
||||
* PUBLIC FUNCTIONS
|
||||
*/
|
||||
|
||||
/*********************************************************************
|
||||
/*
|
||||
* @fn HostTestApp_createTask
|
||||
*
|
||||
* @brief Task creation function for the Host Test App.
|
||||
@@ -168,21 +134,30 @@ extern void AssertHandler(uint8 assertCause, uint8 assertSubcause);
|
||||
*
|
||||
* @return none
|
||||
*/
|
||||
void HostTestApp_createTask(void)
|
||||
{
|
||||
Task_Params taskParams;
|
||||
void HostTestApp_createTask(void) {
|
||||
/* main task */
|
||||
Task_Params task_main_parameter;
|
||||
Task_Params_init(&task_main_parameter);
|
||||
task_main_parameter.stack = hta_task_stack;
|
||||
task_main_parameter.stackSize = HTA_TASK_STACK_SIZE;
|
||||
task_main_parameter.priority = 1;
|
||||
|
||||
// Configure task
|
||||
Task_Params_init(&taskParams);
|
||||
taskParams.stack = htaTaskStack;
|
||||
taskParams.stackSize = HTA_TASK_STACK_SIZE;
|
||||
taskParams.priority = HTA_TASK_PRIORITY;
|
||||
|
||||
Task_construct(&htaTask, HostTestApp_taskFxn, &taskParams, NULL);
|
||||
Task_construct(&hta_task, HTA_main, &task_main_parameter, NULL);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* @fn HostTestApp_init
|
||||
// Entity ID globally used to check for source and/or destination of messages
|
||||
static ICall_EntityID self;
|
||||
|
||||
// Semaphore globally used to post events to the application thread
|
||||
extern ICall_Semaphore semaphore;
|
||||
|
||||
extern uint16_t event_flags;
|
||||
|
||||
// Stack build revision
|
||||
ICall_BuildRevision build_reversion;
|
||||
|
||||
/*
|
||||
* @fn HTA_init
|
||||
*
|
||||
* @brief Called during initialization and contains application
|
||||
* specific initialization (ie. hardware initialization/setup,
|
||||
@@ -193,118 +168,30 @@ void HostTestApp_createTask(void)
|
||||
*
|
||||
* @return none
|
||||
*/
|
||||
static void HostTestApp_init(void)
|
||||
{
|
||||
// Register the current thread as an ICall dispatcher application
|
||||
// so that the application can send and receive messages.
|
||||
ICall_registerApp(&selfEntity, &sem);
|
||||
static void HTA_init(void) {
|
||||
// Register the current thread as an ICall dispatcher application
|
||||
// so that the application can send and receive messages.
|
||||
ICall_registerApp(&self, &semaphore);
|
||||
|
||||
#if defined( USE_FPGA )
|
||||
// configure RF Core SMI Data Link
|
||||
IOCPortConfigureSet(IOID_12, IOC_PORT_RFC_GPO0, IOC_STD_OUTPUT);
|
||||
IOCPortConfigureSet(IOID_11, IOC_PORT_RFC_GPI0, IOC_STD_INPUT);
|
||||
// Initialize GATT Client
|
||||
VOID GATT_InitClient();
|
||||
|
||||
// configure RF Core SMI Command Link
|
||||
IOCPortConfigureSet(IOID_10, IOC_IOCFG0_PORT_ID_RFC_SMI_CL_OUT, IOC_STD_OUTPUT);
|
||||
IOCPortConfigureSet(IOID_9, IOC_IOCFG0_PORT_ID_RFC_SMI_CL_IN, IOC_STD_INPUT);
|
||||
// Register to receive incoming ATT Indications or Notifications of attribute values.
|
||||
GATT_RegisterForInd(self);
|
||||
|
||||
// configure RF Core tracer IO
|
||||
IOCPortConfigureSet(IOID_8, IOC_PORT_RFC_TRC, IOC_STD_OUTPUT);
|
||||
#else // !USE_FPGA
|
||||
#if defined( DEBUG_SW_TRACE )
|
||||
// configure RF Core tracer IO
|
||||
IOCPortConfigureSet(IOID_8, IOC_PORT_RFC_TRC, IOC_STD_OUTPUT | IOC_CURRENT_4MA | IOC_SLEW_ENABLE);
|
||||
#endif // DEBUG_SW_TRACE
|
||||
#endif // USE_FPGA
|
||||
// Register for GATT local events and ATT Responses pending for transmission.
|
||||
GATT_RegisterForMsgs(self);
|
||||
|
||||
// Set device's Sleep Clock Accuracy
|
||||
//HCI_EXT_SetSCACmd(40);
|
||||
|
||||
#if defined( USE_RCOSC )
|
||||
RCOSC_enableCalibration();
|
||||
#endif // USE_RCOSC
|
||||
|
||||
dispHandle = Display_open(Display_Type_LCD, NULL);
|
||||
|
||||
// Register for unprocessed HCI/Host event messages
|
||||
GAP_RegisterForMsgs(selfEntity);
|
||||
|
||||
// Initialize GATT Client
|
||||
VOID GATT_InitClient();
|
||||
|
||||
// Get build revision
|
||||
VOID Util_buildRevision(&buildRev);
|
||||
|
||||
#if !defined ( GATT_DB_OFF_CHIP )
|
||||
|
||||
#if defined ( GATT_QUAL )
|
||||
VOID GATTQual_AddService( GATT_ALL_SERVICES ); // Includes GAP and GATT Services
|
||||
#else
|
||||
// Add our services to GATT Server
|
||||
VOID GGS_AddService( GATT_ALL_SERVICES );
|
||||
VOID GATTServApp_AddService( GATT_ALL_SERVICES );
|
||||
#if defined ( GATT_TEST )
|
||||
VOID GATTTest_AddService( GATT_ALL_SERVICES );
|
||||
#endif
|
||||
#endif
|
||||
GGS_AddService(GATT_ALL_SERVICES);
|
||||
GATTServApp_AddService(GATT_ALL_SERVICES);
|
||||
|
||||
// Set device name
|
||||
if ((buildRev.hostInfo & CENTRAL_CFG) && (buildRev.hostInfo & PERIPHERAL_CFG))
|
||||
{
|
||||
memcpy(deviceName, "TI BLE All", 10);
|
||||
}
|
||||
else if (buildRev.hostInfo & CENTRAL_CFG)
|
||||
{
|
||||
memcpy(deviceName, "TI BLE Central", 14);
|
||||
}
|
||||
else if (buildRev.hostInfo & PERIPHERAL_CFG)
|
||||
{
|
||||
memcpy(deviceName, "TI BLE Peripheral", 17);
|
||||
}
|
||||
else
|
||||
{
|
||||
memcpy(deviceName, "TI BLE Unknown", 14);
|
||||
}
|
||||
|
||||
VOID GGS_SetParameter(GGS_DEVICE_NAME_ATT, strlen((char *)deviceName), deviceName);
|
||||
VOID GGS_SetParameter(GGS_APPEARANCE_ATT, sizeof(uint16), (void*)&appearance);
|
||||
|
||||
#endif // GATT_DB_OFF_CHIP
|
||||
|
||||
Display_print0(dispHandle, 0, 0, "TI BLEv2.0");
|
||||
Display_print0(dispHandle, 1, 0, "HostTestApp");
|
||||
|
||||
// Display Host build configuration
|
||||
if ((buildRev.hostInfo & CENTRAL_CFG) && (buildRev.hostInfo & PERIPHERAL_CFG))
|
||||
{
|
||||
Display_print0(dispHandle, 2, 0, "All");
|
||||
}
|
||||
else if ((buildRev.hostInfo & CENTRAL_CFG) &&
|
||||
(buildRev.hostInfo & BROADCASTER_CFG))
|
||||
{
|
||||
Display_print0(dispHandle, 2, 0, "Cent+Bcast");
|
||||
}
|
||||
else if ((buildRev.hostInfo & PERIPHERAL_CFG) &&
|
||||
(buildRev.hostInfo & OBSERVER_CFG))
|
||||
{
|
||||
Display_print0(dispHandle, 2, 0, "Peri+Observ");
|
||||
}
|
||||
else if (buildRev.hostInfo & CENTRAL_CFG)
|
||||
{
|
||||
Display_print0(dispHandle, 2, 0, "Central");
|
||||
}
|
||||
else if (buildRev.hostInfo & PERIPHERAL_CFG)
|
||||
{
|
||||
Display_print0(dispHandle, 2, 0, "Peripheral");
|
||||
}
|
||||
else
|
||||
{
|
||||
Display_print1(dispHandle, 2, 0, "Unknown build cfg %d", buildRev.hostInfo);
|
||||
}
|
||||
// Register for unprocessed HCI/Host event messages
|
||||
GAP_RegisterForMsgs(self);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* @fn HostTestApp_taskFxn
|
||||
/*
|
||||
* @fn HTA_main
|
||||
*
|
||||
* @brief Application task entry point for the Host Test App.
|
||||
*
|
||||
@@ -312,365 +199,340 @@ static void HostTestApp_init(void)
|
||||
*
|
||||
* @return none
|
||||
*/
|
||||
static void HostTestApp_taskFxn(UArg a0, UArg a1)
|
||||
{
|
||||
// Initialize application
|
||||
HostTestApp_init();
|
||||
static void HTA_main(UArg a0, UArg a1) {
|
||||
// Initialize application
|
||||
HTA_init();
|
||||
HTA_util_init();
|
||||
HTA_main_init();
|
||||
|
||||
// Application main loop
|
||||
for (;;)
|
||||
{
|
||||
// Waits for a signal to the semaphore associated with the calling thread.
|
||||
// Note that the semaphore associated with a thread is signaled when a
|
||||
// message is queued to the message receive queue of the thread or when
|
||||
// ICall_signal() function is called onto the semaphore.
|
||||
ICall_Errno errno = ICall_wait(ICALL_TIMEOUT_FOREVER);
|
||||
// Application main loop
|
||||
for (;;) {
|
||||
// Waits for a signal to the semaphore associated with the calling thread.
|
||||
// Note that the semaphore associated with a thread is signaled when a
|
||||
// message is queued to the message receive queue of the thread or when
|
||||
// ICall_signal() function is called onto the semaphore.
|
||||
ICall_Errno errno = ICall_wait(ICALL_TIMEOUT_FOREVER);
|
||||
|
||||
if (errno == ICALL_ERRNO_SUCCESS)
|
||||
{
|
||||
ICall_EntityID dest;
|
||||
ICall_ServiceEnum src;
|
||||
ICall_HciExtEvt *pMsg = NULL;
|
||||
if (errno == ICALL_ERRNO_SUCCESS) {
|
||||
ICall_EntityID dest;
|
||||
ICall_ServiceEnum src;
|
||||
ICall_HciExtEvt * message = NULL;
|
||||
|
||||
if (ICall_fetchServiceMsg(&src, &dest,
|
||||
(void **)&pMsg) == ICALL_ERRNO_SUCCESS)
|
||||
{
|
||||
bool dealloc = true;
|
||||
if (ICall_fetchServiceMsg(&src, &dest, (void **)&message) == ICALL_ERRNO_SUCCESS) {
|
||||
bool dealloc = true;
|
||||
|
||||
if ((src == ICALL_SERVICE_CLASS_BLE) && (dest == selfEntity))
|
||||
{
|
||||
// Process incoming messages
|
||||
switch (pMsg->hdr.event)
|
||||
{
|
||||
case HCI_GAP_EVENT_EVENT:
|
||||
HostTestApp_processGapEvent(pMsg);
|
||||
break;
|
||||
if ((src == ICALL_SERVICE_CLASS_BLE) && (dest == self)) {
|
||||
// Process incoming messages
|
||||
switch (message->hdr.event) {
|
||||
case HCI_GAP_EVENT_EVENT:
|
||||
HTA_handle_gap_event(message);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
case GATT_MSG_EVENT:
|
||||
HTA_handle_att_event((gattMsgEvent_t *)message);
|
||||
break;
|
||||
|
||||
case GAP_MSG_EVENT:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (dealloc && message) {
|
||||
ICall_freeMsg(message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (dealloc == true)
|
||||
{
|
||||
ICall_freeMsg(pMsg);
|
||||
if (event_flags > 0) {
|
||||
HTA_event_call();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* @fn HostTestApp_processGapEvent
|
||||
/*
|
||||
* @fn HTA_handle_gap_event
|
||||
*
|
||||
* @brief Process an incoming GAP Event.
|
||||
*
|
||||
* @param pMsg - message to process
|
||||
* @param message - message to process
|
||||
*
|
||||
* @return none
|
||||
*/
|
||||
static void HostTestApp_processGapEvent(ICall_HciExtEvt *pMsg)
|
||||
{
|
||||
switch(pMsg->hdr.status)
|
||||
{
|
||||
case HCI_COMMAND_COMPLETE_EVENT_CODE:
|
||||
{
|
||||
hciEvt_CmdComplete_t *pkt = (hciEvt_CmdComplete_t *)pMsg;
|
||||
static void HTA_handle_gap_event(ICall_HciExtEvt *message) {
|
||||
switch (message->hdr.status) {
|
||||
case HCI_COMMAND_COMPLETE_EVENT_CODE: {
|
||||
hciEvt_CmdComplete_t *pkt = (hciEvt_CmdComplete_t *)message;
|
||||
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode)
|
||||
{
|
||||
// app processes this as it was embedded msg to stack
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode) {
|
||||
// application processes this as it was embedded message to stack
|
||||
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
} else {
|
||||
osal_msg_hdr_t *msgHdr;
|
||||
uint8 len;
|
||||
|
||||
msgHdr = (osal_msg_hdr_t *)message;
|
||||
msgHdr--; // Backup to the message header
|
||||
|
||||
len = (uint8)(msgHdr->len - sizeof(hciEvt_CmdComplete_t));
|
||||
|
||||
send_command_complete_event(HCI_COMMAND_COMPLETE_EVENT_CODE, pkt->cmdOpcode, len, pkt->pReturnParam);
|
||||
}
|
||||
else
|
||||
{
|
||||
osal_msg_hdr_t *msgHdr;
|
||||
uint8 len;
|
||||
|
||||
msgHdr = (osal_msg_hdr_t *)pMsg;
|
||||
msgHdr--; // Backup to the msg header
|
||||
|
||||
len = (uint8)(msgHdr->len - sizeof ( hciEvt_CmdComplete_t ));
|
||||
|
||||
sendCommandCompleteEvent(HCI_COMMAND_COMPLETE_EVENT_CODE,
|
||||
pkt->cmdOpcode, len, pkt->pReturnParam);
|
||||
}
|
||||
}
|
||||
break;
|
||||
break;
|
||||
}
|
||||
|
||||
case HCI_DISCONNECTION_COMPLETE_EVENT_CODE:
|
||||
break;
|
||||
break;
|
||||
|
||||
case HCI_COMMAND_STATUS_EVENT_CODE:
|
||||
{
|
||||
hciEvt_CommandStatus_t *pkt = (hciEvt_CommandStatus_t *)pMsg;
|
||||
case HCI_COMMAND_STATUS_EVENT_CODE: {
|
||||
hciEvt_CommandStatus_t *pkt = (hciEvt_CommandStatus_t *)message;
|
||||
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode)
|
||||
{
|
||||
// app processes this as it was embedded msg to stack
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode) {
|
||||
// app processes this as it was embedded msg to stack
|
||||
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
} else if (pkt->cmdOpcode == HCI_LE_SET_PHY) {
|
||||
send_command_status_event(HCI_COMMAND_STATUS_EVENT_CODE, pkt->cmdStatus, pkt->cmdOpcode);
|
||||
}
|
||||
else if (pkt->cmdOpcode == HCI_LE_SET_PHY)
|
||||
{
|
||||
sendCommandStatusEvent(HCI_COMMAND_STATUS_EVENT_CODE, pkt->cmdStatus,
|
||||
pkt->cmdOpcode);
|
||||
break;
|
||||
}
|
||||
|
||||
case HCI_LE_EVENT_CODE: {
|
||||
HTA_handle_ble_event(message);
|
||||
break;
|
||||
}
|
||||
|
||||
case HCI_BLE_HARDWARE_ERROR_EVENT_CODE: {
|
||||
AssertHandler(HAL_ASSERT_CAUSE_HARDWARE_ERROR, 0);
|
||||
break;
|
||||
}
|
||||
|
||||
case HCI_VE_EVENT_CODE: {
|
||||
hciEvt_VSCmdComplete_t *pkt = (hciEvt_VSCmdComplete_t *)message;
|
||||
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode) {
|
||||
// app processes this as it was embedded msg to stack
|
||||
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
} else {
|
||||
send_command_complete_event(HCI_VE_EVENT_CODE, pkt->cmdOpcode, pkt->length, pkt->pEventParam);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case HCI_LE_EVENT_CODE:
|
||||
{
|
||||
HostTestApp_processBLEEvent(pMsg);
|
||||
}
|
||||
break;
|
||||
|
||||
case HCI_BLE_HARDWARE_ERROR_EVENT_CODE:
|
||||
{
|
||||
AssertHandler(HAL_ASSERT_CAUSE_HARDWARE_ERROR,0);
|
||||
}
|
||||
break;
|
||||
|
||||
case HCI_VE_EVENT_CODE:
|
||||
{
|
||||
hciEvt_VSCmdComplete_t *pkt = (hciEvt_VSCmdComplete_t *)pMsg;
|
||||
|
||||
if (lastAppOpcodeSent == pkt->cmdOpcode)
|
||||
{
|
||||
// app processes this as it was embedded msg to stack
|
||||
|
||||
// Reset last opcode sent
|
||||
lastAppOpcodeSent = 0xFFFF;
|
||||
}
|
||||
else
|
||||
{
|
||||
sendCommandCompleteEvent(HCI_VE_EVENT_CODE, pkt->cmdOpcode,
|
||||
pkt->length, pkt->pEventParam);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* @fn HostTestApp_processBLEEvent
|
||||
static void HTA_handle_att_event(gattMsgEvent_t *message) {
|
||||
uint8_t method = message->method;
|
||||
|
||||
if (message->hdr.status == blePending) {
|
||||
// pass
|
||||
} else if ((method == ATT_READ_RSP) || (method == ATT_ERROR_RSP && message->msg.errorRsp.reqOpcode == ATT_READ_REQ)) {
|
||||
// pass
|
||||
} else if ((method == ATT_WRITE_RSP) || (method == ATT_ERROR_RSP && message->msg.errorRsp.reqOpcode == ATT_WRITE_REQ)) {
|
||||
// pass
|
||||
} else if (method == ATT_HANDLE_VALUE_NOTI) {
|
||||
#ifdef HTA_PIN_RS
|
||||
if (!PIN_getInputValue(HTA_PIN_RS)) {
|
||||
#endif
|
||||
attHandleValueNoti_t *att_notify = (attHandleValueNoti_t *)(&message->msg);
|
||||
HTA_main_handle_notify(att_notify->len, att_notify->pValue);
|
||||
#ifdef HTA_PIN_RS
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
// Free message. Needed only for ATT Protocol messages
|
||||
GATT_bm_free(&message->msg, message->method);
|
||||
}
|
||||
|
||||
/*
|
||||
* @fn HTA_handle_ble_event
|
||||
*
|
||||
* @brief Process an incoming BLE Event.
|
||||
|
||||
* @param pMsg - message to process
|
||||
* @param message - message to process
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
static void HostTestApp_processBLEEvent(ICall_HciExtEvt *pMsg)
|
||||
{
|
||||
hciEvt_BLEPhyUpdateComplete_t *pEvt = (hciEvt_BLEPhyUpdateComplete_t *)pMsg;
|
||||
uint8 event[HCI_PHY_UPDATE_COMPLETE_EVENT_LEN];
|
||||
uint8 eventLen;
|
||||
static void HTA_handle_ble_event(ICall_HciExtEvt *message) {
|
||||
hciEvt_BLEPhyUpdateComplete_t *pEvt = (hciEvt_BLEPhyUpdateComplete_t *)message;
|
||||
|
||||
switch (pEvt->BLEEventCode)
|
||||
{
|
||||
case HCI_BLE_PHY_UPDATE_COMPLETE_EVENT:
|
||||
{
|
||||
event[0] = HCI_BLE_PHY_UPDATE_COMPLETE_EVENT; // event code
|
||||
event[1] = pEvt->status; // status
|
||||
event[2] = LO_UINT16(pEvt->connHandle); // connection handle (LSB)
|
||||
event[3] = HI_UINT16(pEvt->connHandle); // connection handle (MSB)
|
||||
event[4] = pEvt->txPhy; // TX PHY
|
||||
event[5] = pEvt->rxPhy; // RX PHY
|
||||
uint8 event[HCI_PHY_UPDATE_COMPLETE_EVENT_LEN];
|
||||
uint8 eventLen = 0;
|
||||
|
||||
switch (pEvt->BLEEventCode) {
|
||||
case HCI_BLE_PHY_UPDATE_COMPLETE_EVENT: {
|
||||
event[0] = HCI_BLE_PHY_UPDATE_COMPLETE_EVENT; // event code
|
||||
event[1] = pEvt->status; // status
|
||||
event[2] = LO_UINT16(pEvt->connHandle); // connection handle (LSB)
|
||||
event[3] = HI_UINT16(pEvt->connHandle); // connection handle (MSB)
|
||||
event[4] = pEvt->txPhy; // TX PHY
|
||||
event[5] = pEvt->rxPhy; // RX PHY
|
||||
|
||||
eventLen = HCI_PHY_UPDATE_COMPLETE_EVENT_LEN;
|
||||
}
|
||||
break;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
default:
|
||||
eventLen = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
if (eventLen > 0)
|
||||
{
|
||||
// Send BLE Complete Event
|
||||
sendBLECompleteEvent(eventLen, event);
|
||||
}
|
||||
if (eventLen) {
|
||||
// Send BLE Complete Event
|
||||
send_ble_complete_event(eventLen, event);
|
||||
}
|
||||
}
|
||||
|
||||
//*****************************************************************************
|
||||
// the function prototypes
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* This generic function sends a Command Complete or a Vendor Specific Command
|
||||
* Complete Event to the Host.
|
||||
*
|
||||
*/
|
||||
static void sendCommandCompleteEvent(uint8_t eventCode, uint16_t opcode,
|
||||
uint8_t numParam, uint8_t *param)
|
||||
{
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
uint8_t txLen = 0; // Length to transmit
|
||||
static void send_command_complete_event(uint8_t eventCode, uint16_t opcode, uint8_t numParam, uint8_t *param) {
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
uint8_t txLen = 0; // Length to transmit
|
||||
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Return Parameters (0..N)
|
||||
totalLength = sizeof(npiPkt_t) + HCI_EVENT_MIN_LENGTH + numParam;
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Return Parameters (0..N)
|
||||
totalLength = sizeof(npiPkt_t) + HCI_EVENT_MIN_LENGTH + numParam;
|
||||
|
||||
// adjust the size of the event packet based on event code
|
||||
// Note: If not a vendor specific event, then the event includes:
|
||||
// Command Complete Data: Number of HCI Commands Allowed(1) + Command Opcode(2)
|
||||
// Note: If a vendor specific event, then the event includes:
|
||||
// Vendor Specific Command Complete Data: Vendor Specific Event Opcode(2)
|
||||
totalLength += ( (eventCode != HCI_VE_EVENT_CODE) ?
|
||||
HCI_CMD_COMPLETE_EVENT_LEN :
|
||||
HCI_CMD_VS_COMPLETE_EVENT_LEN );
|
||||
// adjust the size of the event packet based on event code
|
||||
// Note: If not a vendor specific event, then the event includes:
|
||||
// Command Complete Data: Number of HCI Commands Allowed(1) + Command Opcode(2)
|
||||
// Note: If a vendor specific event, then the event includes:
|
||||
// Vendor Specific Command Complete Data: Vendor Specific Event Opcode(2)
|
||||
totalLength += ((eventCode != HCI_VE_EVENT_CODE) ? HCI_CMD_COMPLETE_EVENT_LEN : HCI_CMD_VS_COMPLETE_EVENT_LEN);
|
||||
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
if (msg)
|
||||
{
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
msg->pData = (uint8*)(msg+1);
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
|
||||
// fill in Command Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = eventCode;
|
||||
if (msg) {
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
msg->pData = (uint8 *)(msg + 1);
|
||||
|
||||
txLen += 2;
|
||||
// fill in Command Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = eventCode;
|
||||
|
||||
// check if this isn't a vendor specific event
|
||||
if ( eventCode != HCI_VE_EVENT_CODE )
|
||||
{
|
||||
msg->pData[2] = numParam + HCI_CMD_COMPLETE_EVENT_LEN;
|
||||
msg->pData[3] = 1;// hciCtrlCmdToken; // event parameter 1
|
||||
msg->pData[4] = LO_UINT16( opcode ); // event parameter 2
|
||||
msg->pData[5] = HI_UINT16( opcode ); // event parameter 2
|
||||
txLen += 2;
|
||||
|
||||
txLen += 4;
|
||||
// check if this isn't a vendor specific event
|
||||
if (eventCode != HCI_VE_EVENT_CODE) {
|
||||
msg->pData[2] = numParam + HCI_CMD_COMPLETE_EVENT_LEN;
|
||||
msg->pData[3] = 1; // hciCtrlCmdToken; // event parameter 1
|
||||
msg->pData[4] = LO_UINT16(opcode); // event parameter 2
|
||||
msg->pData[5] = HI_UINT16(opcode); // event parameter 2
|
||||
|
||||
// remaining event parameters
|
||||
(void)memcpy(&msg->pData[6], param, numParam);
|
||||
txLen += 4;
|
||||
|
||||
txLen += numParam;
|
||||
// remaining event parameters
|
||||
(void)memcpy(&msg->pData[6], param, numParam);
|
||||
|
||||
txLen += numParam;
|
||||
|
||||
} else { // it is a vendor specific event
|
||||
// less one byte as number of complete packets not used in vendor specific event
|
||||
msg->pData[2] = numParam + HCI_CMD_VS_COMPLETE_EVENT_LEN;
|
||||
msg->pData[3] = param[0]; // event parameter 0: event opcode LSB
|
||||
msg->pData[4] = param[1]; // event parameter 1: event opcode MSB
|
||||
msg->pData[5] = param[2]; // event parameter 2: status
|
||||
msg->pData[6] = LO_UINT16(opcode); // event parameter 3: command opcode LSB
|
||||
msg->pData[7] = HI_UINT16(opcode); // event parameter 3: command opcode MSB
|
||||
|
||||
txLen += 6;
|
||||
|
||||
// remaining event parameters
|
||||
// Note: The event opcode and status were already placed in the msg packet.
|
||||
(void)memcpy(&msg->pData[8], ¶m[3], numParam - HCI_EVENT_MIN_LENGTH);
|
||||
|
||||
txLen += (numParam - HCI_EVENT_MIN_LENGTH);
|
||||
}
|
||||
|
||||
msg->pktLen = txLen;
|
||||
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
else // it is a vendor specific event
|
||||
{
|
||||
// less one byte as number of complete packets not used in vendor specific event
|
||||
msg->pData[2] = numParam + HCI_CMD_VS_COMPLETE_EVENT_LEN;
|
||||
msg->pData[3] = param[0]; // event parameter 0: event opcode LSB
|
||||
msg->pData[4] = param[1]; // event parameter 1: event opcode MSB
|
||||
msg->pData[5] = param[2]; // event parameter 2: status
|
||||
msg->pData[6] = LO_UINT16( opcode ); // event parameter 3: command opcode LSB
|
||||
msg->pData[7] = HI_UINT16( opcode ); // event parameter 3: command opcode MSB
|
||||
|
||||
txLen += 6;
|
||||
|
||||
// remaining event parameters
|
||||
// Note: The event opcode and status were already placed in the msg packet.
|
||||
(void)memcpy(&msg->pData[8], ¶m[3], numParam-HCI_EVENT_MIN_LENGTH);
|
||||
|
||||
txLen += (numParam-HCI_EVENT_MIN_LENGTH);
|
||||
}
|
||||
|
||||
msg->pktLen = txLen;
|
||||
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* This generic function sends a Command Complete or a Vendor Specific Command
|
||||
* Complete Event to the Host.
|
||||
*
|
||||
*/
|
||||
static void sendCommandStatusEvent(uint8_t eventCode, uint16_t status,
|
||||
uint16_t opcode)
|
||||
{
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
static void send_command_status_event(uint8_t eventCode, uint16_t status, uint16_t opcode) {
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Command Status Event Data: Status (1) + Num HCI Cmd Pkt (1) + Cmd Opcode (2)
|
||||
totalLength = sizeof(npiPkt_t) +
|
||||
HCI_EVENT_MIN_LENGTH +
|
||||
HCI_CMD_STATUS_EVENT_LEN;
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Command Status Event Data: Status (1) + Num HCI Cmd Pkt (1) + Cmd Opcode (2)
|
||||
totalLength = sizeof(npiPkt_t) + HCI_EVENT_MIN_LENGTH + HCI_CMD_STATUS_EVENT_LEN;
|
||||
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
if (msg)
|
||||
{
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
if (msg) {
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
|
||||
// fill in length and data pointer
|
||||
msg->pktLen = HCI_EVENT_MIN_LENGTH + HCI_CMD_STATUS_EVENT_LEN;
|
||||
msg->pData = (uint8*)(msg+1);
|
||||
// fill in length and data pointer
|
||||
msg->pktLen = HCI_EVENT_MIN_LENGTH + HCI_CMD_STATUS_EVENT_LEN;
|
||||
msg->pData = (uint8 *)(msg + 1);
|
||||
|
||||
// fill in Command Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = eventCode;
|
||||
msg->pData[2] = HCI_CMD_STATUS_EVENT_LEN;
|
||||
msg->pData[3] = status;
|
||||
msg->pData[4] = 1; // number of HCI command packets
|
||||
msg->pData[5] = LO_UINT16(opcode); // opcode (LSB)
|
||||
msg->pData[6] = HI_UINT16(opcode); // opcode (MSB)
|
||||
// fill in Command Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = eventCode;
|
||||
msg->pData[2] = HCI_CMD_STATUS_EVENT_LEN;
|
||||
msg->pData[3] = status;
|
||||
msg->pData[4] = 1; // number of HCI command packets
|
||||
msg->pData[5] = LO_UINT16(opcode); // opcode (LSB)
|
||||
msg->pData[6] = HI_UINT16(opcode); // opcode (MSB)
|
||||
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* This is a generic function used to send BLE Complete Event to the
|
||||
* Host processor.
|
||||
*
|
||||
*/
|
||||
static void sendBLECompleteEvent(uint8 eventLen, uint8 *pEvent)
|
||||
{
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Event Data: eventLen
|
||||
totalLength = sizeof(npiPkt_t) + HCI_EVENT_MIN_LENGTH + eventLen;
|
||||
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
if (msg)
|
||||
{
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
|
||||
// fill in length and data pointer
|
||||
msg->pktLen = HCI_EVENT_MIN_LENGTH + eventLen;
|
||||
msg->pData = (uint8*)(msg+1);
|
||||
|
||||
// fill in BLE Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = HCI_LE_EVENT_CODE;
|
||||
msg->pData[2] = eventLen;
|
||||
|
||||
// populate event data
|
||||
if (eventLen > 0)
|
||||
{
|
||||
memcpy(&msg->pData[3], pEvent, eventLen);
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
*********************************************************************/
|
||||
/*
|
||||
* This is a generic function used to send BLE Complete Event to the Host processor.
|
||||
*/
|
||||
static void send_ble_complete_event(uint8 eventLen, uint8 *pEvent) {
|
||||
npiPkt_t *msg;
|
||||
uint8_t totalLength;
|
||||
|
||||
// The initial length will be:
|
||||
// OSAL message header(4) - not part of packet sent to HCI Host!
|
||||
// Minimum Event Data: Packet Type(1) + Event Code(1) + Length(1)
|
||||
// Event Data: eventLen
|
||||
totalLength = sizeof(npiPkt_t) + HCI_EVENT_MIN_LENGTH + eventLen;
|
||||
|
||||
// allocate memory for OSAL hdr + packet
|
||||
msg = (npiPkt_t *)ICall_allocMsg(totalLength);
|
||||
if (msg) {
|
||||
// OSAL message event, status, and pointer to packet
|
||||
msg->hdr.event = HCI_EVENT_PACKET;
|
||||
msg->hdr.status = 0xFF;
|
||||
|
||||
// fill in length and data pointer
|
||||
msg->pktLen = HCI_EVENT_MIN_LENGTH + eventLen;
|
||||
msg->pData = (uint8 *)(msg + 1);
|
||||
|
||||
// fill in BLE Complete Event data
|
||||
msg->pData[0] = HCI_EVENT_PACKET;
|
||||
msg->pData[1] = HCI_LE_EVENT_CODE;
|
||||
msg->pData[2] = eventLen;
|
||||
|
||||
// populate event data
|
||||
if (eventLen > 0) {
|
||||
memcpy(&msg->pData[3], pEvent, eventLen);
|
||||
}
|
||||
|
||||
NPITask_sendToHost((uint8_t *)msg);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
Target Device: CC2650, CC2640
|
||||
|
||||
******************************************************************************
|
||||
|
||||
|
||||
Copyright (c) 2013-2018, Texas Instruments Incorporated
|
||||
All rights reserved.
|
||||
|
||||
@@ -49,37 +49,16 @@
|
||||
#define HOSTESTAPP_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*********************************************************************
|
||||
* INCLUDES
|
||||
*/
|
||||
|
||||
/*********************************************************************
|
||||
* CONSTANTS
|
||||
*/
|
||||
|
||||
/*********************************************************************
|
||||
* MACROS
|
||||
*/
|
||||
|
||||
/*********************************************************************
|
||||
* FUNCTIONS
|
||||
*/
|
||||
|
||||
/*
|
||||
* Task creation function for the Host Test App.
|
||||
*/
|
||||
extern void HostTestApp_createTask(void);
|
||||
|
||||
|
||||
/*********************************************************************
|
||||
*********************************************************************/
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* HOSTESTAPP_H */
|
||||
#endif
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
Target Device: CC2650, CC2640
|
||||
|
||||
******************************************************************************
|
||||
|
||||
|
||||
Copyright (c) 2013-2018, Texas Instruments Incorporated
|
||||
All rights reserved.
|
||||
|
||||
@@ -44,26 +44,29 @@
|
||||
Release Date: 2018-04-02 18:03:35
|
||||
*****************************************************************************/
|
||||
|
||||
/*******************************************************************************
|
||||
* INCLUDES
|
||||
*/
|
||||
|
||||
#include <xdc/runtime/Error.h>
|
||||
|
||||
#include <ti/drivers/Power.h>
|
||||
|
||||
#include <ti/drivers/power/PowerCC26XX.h>
|
||||
|
||||
#include <ti/sysbios/BIOS.h>
|
||||
|
||||
#include "icall.h"
|
||||
#include "hal_assert.h"
|
||||
#include "board.h"
|
||||
|
||||
#include "hal_assert.h"
|
||||
|
||||
#include "icall.h"
|
||||
|
||||
#include "inc/npi_task.h"
|
||||
|
||||
#include "host_test_app.h"
|
||||
|
||||
/* Header files required to enable instruction fetch cache */
|
||||
#include <inc/hw_memmap.h>
|
||||
#include <driverlib/vims.h>
|
||||
|
||||
#include <inc/hw_memmap.h>
|
||||
|
||||
#ifndef USE_DEFAULT_USER_CFG
|
||||
|
||||
#include "ble_user_config.h"
|
||||
@@ -71,70 +74,12 @@
|
||||
// BLE user defined configuration
|
||||
bleUserCfg_t user0Cfg = BLE_USER_CFG;
|
||||
|
||||
#endif // USE_DEFAULT_USER_CFG
|
||||
#endif // USE_DEFAULT_USER_CFG
|
||||
|
||||
#include <ti/mw/display/Display.h>
|
||||
|
||||
#ifdef USE_FPGA
|
||||
#include <inc/hw_prcm.h>
|
||||
#endif // USE_FPGA
|
||||
|
||||
/*******************************************************************************
|
||||
* MACROS
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* CONSTANTS
|
||||
*/
|
||||
|
||||
#if defined( USE_FPGA )
|
||||
#define RFC_MODE_BLE PRCM_RFCMODESEL_CURR_MODE1
|
||||
#define RFC_MODE_ANT PRCM_RFCMODESEL_CURR_MODE4
|
||||
#define RFC_MODE_EVERYTHING_BUT_ANT PRCM_RFCMODESEL_CURR_MODE5
|
||||
#define RFC_MODE_EVERYTHING PRCM_RFCMODESEL_CURR_MODE6
|
||||
//
|
||||
#define SET_RFC_BLE_MODE(mode) HWREG( PRCM_BASE + PRCM_O_RFCMODESEL ) = (mode)
|
||||
#endif // USE_FPGA
|
||||
|
||||
/*******************************************************************************
|
||||
* TYPEDEFS
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* LOCAL VARIABLES
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* GLOBAL VARIABLES
|
||||
*/
|
||||
|
||||
#ifdef CC1350_LAUNCHXL
|
||||
#ifdef POWER_SAVING
|
||||
// Power Notify Object for wake-up callbacks
|
||||
Power_NotifyObj rFSwitchPowerNotifyObj;
|
||||
static uint8_t rFSwitchNotifyCb(uint8_t eventType, uint32_t *eventArg,
|
||||
uint32_t *clientArg);
|
||||
#endif //POWER_SAVING
|
||||
|
||||
PIN_State radCtrlState;
|
||||
PIN_Config radCtrlCfg[] =
|
||||
{
|
||||
Board_DIO1_RFSW | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* RF SW Switch defaults to 2.4GHz path*/
|
||||
Board_DIO30_SWPWR | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* Power to the RF Switch */
|
||||
PIN_TERMINATE
|
||||
};
|
||||
PIN_Handle radCtrlHandle;
|
||||
#endif //CC1350_LAUNCHXL
|
||||
|
||||
/*******************************************************************************
|
||||
* EXTERNS
|
||||
*/
|
||||
|
||||
extern void AssertHandler(uint8 assertCause, uint8 assertSubcause);
|
||||
|
||||
extern Display_Handle dispHandle;
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* @fn Main
|
||||
*
|
||||
* @brief Application Main
|
||||
@@ -149,68 +94,38 @@ extern Display_Handle dispHandle;
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
int main()
|
||||
{
|
||||
#if defined( USE_FPGA )
|
||||
HWREG(PRCM_BASE + PRCM_O_PDCTL0) &= ~PRCM_PDCTL0_RFC_ON;
|
||||
HWREG(PRCM_BASE + PRCM_O_PDCTL1) &= ~PRCM_PDCTL1_RFC_ON;
|
||||
#endif // USE_FPGA
|
||||
int main() {
|
||||
|
||||
/* Register Application callback to trap asserts raised in the Stack */
|
||||
RegisterAssertCback(AssertHandler);
|
||||
/* Register Application callback to trap asserts raised in the Stack */
|
||||
RegisterAssertCback(AssertHandler);
|
||||
|
||||
PIN_init(BoardGpioInitTable);
|
||||
PIN_init(BoardGpioInitTable);
|
||||
|
||||
#ifdef CC1350_LAUNCHXL
|
||||
// Enable 2.4GHz Radio
|
||||
radCtrlHandle = PIN_open(&radCtrlState, radCtrlCfg);
|
||||
// Enable iCache prefetching
|
||||
VIMSConfigure(VIMS_BASE, TRUE, TRUE);
|
||||
|
||||
#ifdef POWER_SAVING
|
||||
Power_registerNotify(&rFSwitchPowerNotifyObj,
|
||||
PowerCC26XX_ENTERING_STANDBY | PowerCC26XX_AWAKE_STANDBY,
|
||||
(Power_NotifyFxn) rFSwitchNotifyCb, NULL);
|
||||
#endif //POWER_SAVING
|
||||
#endif //CC1350_LAUNCHXL
|
||||
// Enable cache
|
||||
VIMSModeSet(VIMS_BASE, VIMS_MODE_ENABLED);
|
||||
|
||||
#if defined( USE_FPGA )
|
||||
// set RFC mode to support BLE
|
||||
// Note: This must be done before the RF Core is released from reset!
|
||||
SET_RFC_BLE_MODE(RFC_MODE_BLE);
|
||||
#endif // USE_FPGA
|
||||
/* Initialize ICall module */
|
||||
ICall_init();
|
||||
|
||||
// Enable iCache prefetching
|
||||
VIMSConfigure(VIMS_BASE, TRUE, TRUE);
|
||||
/* Start tasks of external images */
|
||||
ICall_createRemoteTasks();
|
||||
|
||||
// Enable cache
|
||||
VIMSModeSet(VIMS_BASE, VIMS_MODE_ENABLED);
|
||||
/* Kick off application */
|
||||
HostTestApp_createTask();
|
||||
|
||||
#if !defined( POWER_SAVING ) || defined( USE_FPGA )
|
||||
/* Set constraints for Standby, powerdown and idle mode */
|
||||
// PowerCC26XX_SB_DISALLOW may be redundant
|
||||
Power_setConstraint(PowerCC26XX_SB_DISALLOW);
|
||||
Power_setConstraint(PowerCC26XX_IDLE_PD_DISALLOW);
|
||||
#endif // POWER_SAVING | USE_FPGA
|
||||
/* Kick off NPI */
|
||||
NPITask_createTask(ICALL_SERVICE_CLASS_BLE);
|
||||
|
||||
/* Initialize ICall module */
|
||||
ICall_init();
|
||||
/* enable interrupts and start SYS/BIOS */
|
||||
BIOS_start();
|
||||
|
||||
/* Start tasks of external images */
|
||||
ICall_createRemoteTasks();
|
||||
|
||||
/* Kick off application */
|
||||
HostTestApp_createTask();
|
||||
|
||||
/* Kick off NPI */
|
||||
NPITask_createTask(ICALL_SERVICE_CLASS_BLE);
|
||||
|
||||
/* enable interrupts and start SYS/BIOS */
|
||||
BIOS_start();
|
||||
|
||||
return 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* @fn AssertHandler
|
||||
*
|
||||
* @brief This is the Application's callback handler for asserts raised
|
||||
@@ -246,57 +161,9 @@ int main()
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
void AssertHandler(uint8 assertCause, uint8 assertSubcause)
|
||||
{
|
||||
// Open the display if the app has not already done so
|
||||
if ( !dispHandle )
|
||||
{
|
||||
dispHandle = Display_open(Display_Type_LCD, NULL);
|
||||
}
|
||||
void AssertHandler(uint8 assertCause, uint8 assertSubcause) {}
|
||||
|
||||
Display_print0(dispHandle, 0, 0, ">>>STACK ASSERT");
|
||||
|
||||
// check the assert cause
|
||||
switch (assertCause)
|
||||
{
|
||||
// This assert is raised from the BLE Stack when a malloc failure occurs.
|
||||
case HAL_ASSERT_CAUSE_OUT_OF_MEMORY:
|
||||
Display_print0(dispHandle, 0, 0, "***ERROR***");
|
||||
Display_print0(dispHandle, 2, 0, ">> OUT OF MEMORY!");
|
||||
break;
|
||||
|
||||
case HAL_ASSERT_CAUSE_INTERNAL_ERROR:
|
||||
// check the subcause
|
||||
if (assertSubcause == HAL_ASSERT_SUBCAUSE_FW_INERNAL_ERROR)
|
||||
{
|
||||
Display_print0(dispHandle, 0, 0, "***ERROR***");
|
||||
Display_print0(dispHandle, 2, 0, ">> INTERNAL FW ERROR!");
|
||||
}
|
||||
else
|
||||
{
|
||||
Display_print0(dispHandle, 0, 0, "***ERROR***");
|
||||
Display_print0(dispHandle, 2, 0, ">> INTERNAL ERROR!");
|
||||
}
|
||||
break;
|
||||
|
||||
// An assert originating from an ICall failure.
|
||||
case HAL_ASSERT_CAUSE_ICALL_ABORT:
|
||||
Display_print0(dispHandle, 0, 0, "***ERROR***");
|
||||
Display_print0(dispHandle, 2, 0, ">> ICALL ABORT!");
|
||||
HAL_ASSERT_SPINLOCK;
|
||||
break;
|
||||
|
||||
default:
|
||||
Display_print0(dispHandle, 0, 0, "***ERROR***");
|
||||
Display_print0(dispHandle, 2, 0, ">> DEFAULT SPINLOCK!");
|
||||
HAL_ASSERT_SPINLOCK;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* @fn exceptionHandler
|
||||
*
|
||||
* @brief Generic spinlock to trap RTOS raised errors.
|
||||
@@ -311,13 +178,11 @@ void AssertHandler(uint8 assertCause, uint8 assertSubcause)
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
void exceptionHandler( void )
|
||||
{
|
||||
volatile uint8 i = 1;
|
||||
while(i);
|
||||
void exceptionHandler(void) {
|
||||
for (;;);
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
/*
|
||||
* @fn smallErrorHook
|
||||
*
|
||||
* @brief Error handler to be hooked into TI-RTOS.
|
||||
@@ -332,45 +197,6 @@ void exceptionHandler( void )
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
void smallErrorHook(Error_Block *eb)
|
||||
{
|
||||
for (;;);
|
||||
void smallErrorHook(Error_Block *eb) {
|
||||
for (;;);
|
||||
}
|
||||
|
||||
#if defined (CC1350_LAUNCHXL) && defined (POWER_SAVING)
|
||||
/*******************************************************************************
|
||||
* @fn rFSwitchNotifyCb
|
||||
*
|
||||
* @brief Power driver callback to toggle RF switch on Power state
|
||||
* transitions.
|
||||
*
|
||||
* input parameters
|
||||
*
|
||||
* @param eventType - The state change.
|
||||
* @param eventArg - Not used.
|
||||
* @param clientArg - Not used.
|
||||
*
|
||||
* @return Power_NOTIFYDONE to indicate success.
|
||||
*/
|
||||
static uint8_t rFSwitchNotifyCb(uint8_t eventType, uint32_t *eventArg,
|
||||
uint32_t *clientArg)
|
||||
{
|
||||
if (eventType == PowerCC26XX_ENTERING_STANDBY)
|
||||
{
|
||||
// Power down RF Switch
|
||||
PIN_setOutputValue(radCtrlHandle, Board_DIO30_SWPWR, 0);
|
||||
}
|
||||
else if (eventType == PowerCC26XX_AWAKE_STANDBY)
|
||||
{
|
||||
// Power up RF Switch
|
||||
PIN_setOutputValue(radCtrlHandle, Board_DIO30_SWPWR, 1);
|
||||
}
|
||||
|
||||
// Notification handled successfully
|
||||
return Power_NOTIFYDONE;
|
||||
}
|
||||
#endif //CC1350_LAUNCHXL || POWER_SAVING
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
*/
|
||||
|
||||
+179
@@ -0,0 +1,179 @@
|
||||
{
|
||||
"name": "Elite-ZM",
|
||||
"version": "1.2.30",
|
||||
"match_rule": {
|
||||
"local_name_pattern": "Elite-ZM.+",
|
||||
"major_product_number": 0,
|
||||
"minor_product_number": 2,
|
||||
"major_version_number": 1,
|
||||
"minor_version_number": 2
|
||||
},
|
||||
"constant": {
|
||||
"ADC_CHANNEL_NUMBER": [
|
||||
12,
|
||||
13,
|
||||
14,
|
||||
15
|
||||
],
|
||||
"VOLT_MAX": 4095
|
||||
},
|
||||
"parameters": {
|
||||
"CHANNEL": {
|
||||
"description": "record channels",
|
||||
"record_meta": true,
|
||||
"domain": "property",
|
||||
"value": [
|
||||
0,
|
||||
1,
|
||||
2
|
||||
]
|
||||
},
|
||||
"SAMPLE_RATE": {
|
||||
"description": "data sampling rate",
|
||||
"record_meta": true,
|
||||
"domain": "constant",
|
||||
"value": 1
|
||||
},
|
||||
"AMP_GAIN": {
|
||||
"description": "amp gain",
|
||||
"record_meta": true,
|
||||
"domain": "constant",
|
||||
"value": 1
|
||||
},
|
||||
"MODE": {
|
||||
"description": "working mode",
|
||||
"value": [
|
||||
"I-V Curve",
|
||||
"Cyclic Voltammetry",
|
||||
"Function Generator",
|
||||
"Z-T Curve",
|
||||
"V-T Curve",
|
||||
"I-T Curve",
|
||||
"ADC test"
|
||||
]
|
||||
},
|
||||
"VOLT_ORIGIN": {
|
||||
"description": "Origin Voltage of Scan",
|
||||
"domain": [
|
||||
"VOLT_MAX"
|
||||
]
|
||||
},
|
||||
"VOLT_FINAL": {
|
||||
"description": "The last Voltage of Scan",
|
||||
"domain": [
|
||||
"VOLT_MAX"
|
||||
],
|
||||
"value": "1365 * VALUE"
|
||||
},
|
||||
"VOLT_STEP": {
|
||||
"description": "Voltage Step",
|
||||
"domain": [
|
||||
5
|
||||
]
|
||||
},
|
||||
"STEP_TIME": {
|
||||
"description": "How much time between two step",
|
||||
"domain": [
|
||||
4
|
||||
]
|
||||
},
|
||||
"DAC_VOLT": {
|
||||
"description": "DAC output Voltage",
|
||||
"domain": [
|
||||
"VOLT_MAX"
|
||||
]
|
||||
},
|
||||
"ADC_CHANNEL": {
|
||||
"description": "read ADC data",
|
||||
"value": [
|
||||
"ANA0",
|
||||
"ANA1",
|
||||
"ANA2",
|
||||
"ANA3"
|
||||
]
|
||||
}
|
||||
},
|
||||
"instruction": {
|
||||
"start": [
|
||||
{
|
||||
"expression": "MODE",
|
||||
"when": {
|
||||
"0": "curve_iv",
|
||||
"1": "curve_cv",
|
||||
"2": "func_gen",
|
||||
"6": "adc_test"
|
||||
}
|
||||
}
|
||||
],
|
||||
"data_format": [
|
||||
"_data_format('TDC4VAF2')"
|
||||
],
|
||||
"curve_iv": [
|
||||
"data_format",
|
||||
"_notify(True)",
|
||||
"curve_iv0",
|
||||
"_sync(True)",
|
||||
"VIS_STI"
|
||||
],
|
||||
"curve_iv0": {
|
||||
"type": "RIS",
|
||||
"parameter": {
|
||||
"va": "(VOLT_ORIGIN + 1) * 0x0010",
|
||||
"vb": "(VOLT_FINAL + 1) * 0x0010",
|
||||
"dv": "VOLT_STEP * 0x40",
|
||||
"dt": "STEP_TIME * 0x12"
|
||||
},
|
||||
"data": [
|
||||
"1X10;2B>va;2B>vb;B>dv;B>dt"
|
||||
]
|
||||
},
|
||||
"curve_cv": [
|
||||
"data_format",
|
||||
"_notify(True)",
|
||||
"curve_cv0",
|
||||
"_sync(True)",
|
||||
"VIS_STI"
|
||||
],
|
||||
"curve_cv0": {
|
||||
"type": "RIS",
|
||||
"parameter": {
|
||||
"va": "(VOLT_ORIGIN + 1) * 0x0010",
|
||||
"vb": "(VOLT_FINAL + 1) * 0x0010",
|
||||
"dv": "VOLT_STEP * 0x40",
|
||||
"dt": "STEP_TIME * 0x12"
|
||||
},
|
||||
"data": [
|
||||
"1X20;2B>va;2B>vb;B>dv;B>dt"
|
||||
]
|
||||
},
|
||||
"func_gen": [
|
||||
"data_format",
|
||||
"func_gen0",
|
||||
"VIS_STI"
|
||||
],
|
||||
"func_gen0": {
|
||||
"type": "RIS",
|
||||
"parameter": {
|
||||
"v": "(DAC_VOLT + 1) * 0x0010"
|
||||
},
|
||||
"data": [
|
||||
"X30;X30;2B>v"
|
||||
]
|
||||
},
|
||||
"adc_test": [
|
||||
"data_format",
|
||||
"_notify(True)",
|
||||
"adc_test0",
|
||||
"_sync(True)",
|
||||
"VIS_STI"
|
||||
],
|
||||
"adc_test0": {
|
||||
"type": "RIS",
|
||||
"data": [
|
||||
"X90;B>ADC_CHANNEL"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+283
@@ -0,0 +1,283 @@
|
||||
|
||||
#ifndef Elite15_PIN
|
||||
#define Elite_15PIN
|
||||
|
||||
#include "Elite_PIN.h"
|
||||
|
||||
static void update_latch_status (uint32_t latch_num, uint32_t elite_pin, bool highlow) {
|
||||
switch (latch_num) {
|
||||
case LOAD0: {
|
||||
switch (elite_pin) {
|
||||
case D0: {
|
||||
LH.LATCH0[0] = highlow;
|
||||
break;
|
||||
}
|
||||
case D1: {
|
||||
LH.LATCH0[1] = highlow;
|
||||
break;
|
||||
}
|
||||
case D2: {
|
||||
LH.LATCH0[2] = highlow;
|
||||
break;
|
||||
}
|
||||
case D3: {
|
||||
LH.LATCH0[3] = highlow;
|
||||
break;
|
||||
}
|
||||
case D4: {
|
||||
LH.LATCH0[4] = highlow;
|
||||
break;
|
||||
}
|
||||
case D5: {
|
||||
LH.LATCH0[5] = highlow;
|
||||
break;
|
||||
}
|
||||
case D6: {
|
||||
LH.LATCH0[6] = highlow;
|
||||
break;
|
||||
}
|
||||
case D7: {
|
||||
LH.LATCH0[7] = highlow;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case LOAD1: {
|
||||
switch (elite_pin) {
|
||||
case D0: {
|
||||
LH.LATCH1[0] = highlow;
|
||||
break;
|
||||
}
|
||||
case D1: {
|
||||
LH.LATCH1[1] = highlow;
|
||||
break;
|
||||
}
|
||||
case D2: {
|
||||
LH.LATCH1[2] = highlow;
|
||||
break;
|
||||
}
|
||||
case D3: {
|
||||
LH.LATCH1[3] = highlow;
|
||||
break;
|
||||
}
|
||||
case D4: {
|
||||
LH.LATCH1[4] = highlow;
|
||||
break;
|
||||
}
|
||||
case D5: {
|
||||
LH.LATCH1[5] = highlow;
|
||||
break;
|
||||
}
|
||||
case D6: {
|
||||
LH.LATCH1[6] = highlow;
|
||||
break;
|
||||
}
|
||||
case D7: {
|
||||
LH.LATCH1[7] = highlow;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case LOAD2: {
|
||||
switch (elite_pin) {
|
||||
case D0: {
|
||||
LH.LATCH2[0] = highlow;
|
||||
break;
|
||||
}
|
||||
case D1: {
|
||||
LH.LATCH2[1] = highlow;
|
||||
break;
|
||||
}
|
||||
case D2: {
|
||||
LH.LATCH2[2] = highlow;
|
||||
break;
|
||||
}
|
||||
case D3: {
|
||||
LH.LATCH2[3] = highlow;
|
||||
break;
|
||||
}
|
||||
case D4: {
|
||||
LH.LATCH2[4] = highlow;
|
||||
break;
|
||||
}
|
||||
case D5: {
|
||||
LH.LATCH2[5] = highlow;
|
||||
break;
|
||||
}
|
||||
case D6: {
|
||||
LH.LATCH2[6] = highlow;
|
||||
break;
|
||||
}
|
||||
case D7: {
|
||||
LH.LATCH2[7] = highlow;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void PIN15_setOutputValue (uint32_t latch_num, uint32_t pin_num, bool highlow) {
|
||||
ELITE15_SPI_CLOSE();
|
||||
add_elite_pin();
|
||||
update_latch_status (latch_num, pin_num, highlow);
|
||||
// PIN_setOutputValue(&ZM_rst, latch_num, 1); // Turn on latch
|
||||
|
||||
switch (latch_num) {
|
||||
case LOAD0: {
|
||||
// PIN_setOutputValue(&ZM_rst, D0, LH.LATCH0[0]);
|
||||
// PIN_setOutputValue(&ZM_rst, D1, LH.LATCH0[1]);
|
||||
// PIN_setOutputValue(&ZM_rst, D2, LH.LATCH0[2]);
|
||||
// PIN_setOutputValue(&ZM_rst, D3, LH.LATCH0[3]);
|
||||
// PIN_setOutputValue(pin_handle, D4, LH.LATCH0[4]);
|
||||
// PIN_setOutputValue(pin_handle, D5, LH.LATCH0[5]);
|
||||
// PIN_setOutputValue(pin_handle, D6, LH.LATCH0[6]);
|
||||
// PIN_setOutputValue(pin_handle, D7, LH.LATCH0[7]);
|
||||
break;
|
||||
}
|
||||
case LOAD1: {
|
||||
PIN_setOutputValue(pin_handle, D0, LH.LATCH1[0]);
|
||||
PIN_setOutputValue(pin_handle, D1, LH.LATCH1[1]);
|
||||
PIN_setOutputValue(pin_handle, D2, LH.LATCH1[2]);
|
||||
PIN_setOutputValue(pin_handle, D3, LH.LATCH1[3]);
|
||||
PIN_setOutputValue(pin_handle, D4, LH.LATCH1[4]);
|
||||
PIN_setOutputValue(pin_handle, D5, LH.LATCH1[5]);
|
||||
PIN_setOutputValue(pin_handle, D6, LH.LATCH1[6]);
|
||||
PIN_setOutputValue(pin_handle, D7, LH.LATCH1[7]);
|
||||
break;
|
||||
}
|
||||
case LOAD2: {
|
||||
PIN_setOutputValue(pin_handle, D0, LH.LATCH2[0]);
|
||||
PIN_setOutputValue(pin_handle, D1, LH.LATCH2[1]);
|
||||
PIN_setOutputValue(pin_handle, D2, LH.LATCH2[2]);
|
||||
PIN_setOutputValue(pin_handle, D3, LH.LATCH2[3]);
|
||||
PIN_setOutputValue(pin_handle, D4, LH.LATCH2[4]);
|
||||
PIN_setOutputValue(pin_handle, D5, LH.LATCH2[5]);
|
||||
PIN_setOutputValue(pin_handle, D6, LH.LATCH2[6]);
|
||||
PIN_setOutputValue(pin_handle, D7, LH.LATCH2[7]);
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
latch_setOutputValue(latch_num, 1); // Turn on latch
|
||||
// CPUdelay(10);
|
||||
// latch_setOutputValue(latch_num, 0); // Turn off latch
|
||||
latch_setOutputValue(LOAD0, 1); // set latch at LOAD0 for SPI transfer
|
||||
remove_elite_pin();
|
||||
ELITE15_SPI_HOLD();
|
||||
}
|
||||
|
||||
static void Init_Elite15_PIN () {
|
||||
InitLH();
|
||||
add_elite_pin();
|
||||
|
||||
PIN_setOutputValue(pin_handle, D0, 0);
|
||||
PIN_setOutputValue(pin_handle, D1, 0);
|
||||
PIN_setOutputValue(pin_handle, D2, 0);
|
||||
PIN_setOutputValue(pin_handle, D3, 0);
|
||||
PIN_setOutputValue(pin_handle, D4, 0);
|
||||
PIN_setOutputValue(pin_handle, D5, 0);
|
||||
PIN_setOutputValue(pin_handle, D6, 0);
|
||||
PIN_setOutputValue(pin_handle, D7, 0);
|
||||
latch_setOutputValue(LOAD0, 1);
|
||||
latch_setOutputValue(LOAD1, 1);
|
||||
latch_setOutputValue(LOAD2, 1);
|
||||
CPUdelay(10);
|
||||
latch_setOutputValue(LOAD2, 0);
|
||||
|
||||
remove_elite_pin();
|
||||
}
|
||||
|
||||
static void latch_setOutputValue (uint32_t latch_num, bool highlow) {
|
||||
// decode latch value for Elite trigger board
|
||||
if (highlow) {
|
||||
switch (latch_num) {
|
||||
case LOAD0: {
|
||||
PIN_setOutputValue(pin_handle, LOADB, 0);
|
||||
PIN_setOutputValue(pin_handle, LOADA, 0);
|
||||
break;
|
||||
}
|
||||
case LOAD1: {
|
||||
PIN_setOutputValue(pin_handle, LOADB, 0);
|
||||
PIN_setOutputValue(pin_handle, LOADA, 1);
|
||||
break;
|
||||
}
|
||||
case LOAD2: {
|
||||
PIN_setOutputValue(pin_handle, LOADB, 1);
|
||||
PIN_setOutputValue(pin_handle, LOADA, 0);
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else { // All latch turn off
|
||||
PIN_setOutputValue(pin_handle, LOADB, 1);
|
||||
PIN_setOutputValue(pin_handle, LOADA, 1);
|
||||
// PIN_setPortOutputValue(pin_handle, ((1<<LOADA)|(1<<LOADB)));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
static void PIN15_setOutputValue_refresh() {
|
||||
ELITE15_SPI_CLOSE();
|
||||
add_elite_pin();
|
||||
|
||||
PIN_setOutputValue(pin_handle, D0, LH.LATCH1[0]);
|
||||
PIN_setOutputValue(pin_handle, D1, LH.LATCH1[1]);
|
||||
PIN_setOutputValue(pin_handle, D2, LH.LATCH1[2]);
|
||||
PIN_setOutputValue(pin_handle, D3, LH.LATCH1[3]);
|
||||
PIN_setOutputValue(pin_handle, D4, LH.LATCH1[4]);
|
||||
PIN_setOutputValue(pin_handle, D5, LH.LATCH1[5]);
|
||||
PIN_setOutputValue(pin_handle, D6, LH.LATCH1[6]);
|
||||
PIN_setOutputValue(pin_handle, D7, LH.LATCH1[7]);
|
||||
latch_setOutputValue(LOAD1, 1); // Turn on latch
|
||||
latch_setOutputValue(LOAD0, 1); // set latch at LOAD0 for SPI transfer
|
||||
|
||||
PIN_setOutputValue(pin_handle, D0, LH.LATCH2[0]);
|
||||
PIN_setOutputValue(pin_handle, D1, LH.LATCH2[1]);
|
||||
PIN_setOutputValue(pin_handle, D2, LH.LATCH2[2]);
|
||||
PIN_setOutputValue(pin_handle, D3, LH.LATCH2[3]);
|
||||
PIN_setOutputValue(pin_handle, D4, LH.LATCH2[4]);
|
||||
PIN_setOutputValue(pin_handle, D5, LH.LATCH2[5]);
|
||||
PIN_setOutputValue(pin_handle, D6, LH.LATCH2[6]);
|
||||
PIN_setOutputValue(pin_handle, D7, LH.LATCH2[7]);
|
||||
latch_setOutputValue(LOAD2, 1); // Turn on latch
|
||||
latch_setOutputValue(LOAD0, 1); // set latch at LOAD0 for SPI transfer
|
||||
|
||||
remove_elite_pin();
|
||||
ELITE15_SPI_HOLD();
|
||||
}
|
||||
static void disable_trig_output() {
|
||||
update_latch_status(DO_PR_0 , 0);
|
||||
update_latch_status(DO_MOS_0 , 0);
|
||||
update_latch_status(AO_MOS_0 , 0);
|
||||
update_latch_status(AO_MOS_2 , 0);
|
||||
update_latch_status(AO_MOS_3 , 0);
|
||||
update_latch_status(AO_MOS_1 , 0);
|
||||
update_latch_status(DO_MOS_1 , 0);
|
||||
update_latch_status(DO_PR_1 , 0);
|
||||
update_latch_status(OUT_5V_EN_0, 1);
|
||||
update_latch_status(OUT_5V_EN_1, 1);
|
||||
|
||||
PIN15_setOutputValue_refresh();
|
||||
}
|
||||
|
||||
#endif
|
||||
+711
@@ -0,0 +1,711 @@
|
||||
|
||||
#ifndef EliteADC
|
||||
#define EliteADC
|
||||
|
||||
#include "Elite_PIN.h"
|
||||
#include "EliteSPI.h"
|
||||
#include "EliteNotify.h"
|
||||
|
||||
// Elite ADC macro
|
||||
// ADC command, Elite will use these cmd to control ADC
|
||||
#define CMD_CURRENT_MEASURE 0xC5
|
||||
#define CMD_VOLT_MEASURE 0xD5
|
||||
#define CMD_DAC_MEASURE 0xE5
|
||||
#define CMD_BATTERY_MEASURE 0xF1
|
||||
|
||||
// Elite TRIG01 ADC command
|
||||
#define CMD_DOUT_5V_IMON_0 0xC5
|
||||
#define CMD_DOUT_5V_IMON_1 0xD5
|
||||
//#define CMD_DAC_MEASURE 0xE5 // ADC AIN2 left floating
|
||||
#define CMD_BATTERY_MEASURE 0xF1
|
||||
|
||||
// controller command, these are command from control box
|
||||
#define ADC_CH_CURRENT 0x00
|
||||
#define ADC_CH_VOLT 0x01
|
||||
#define ADC_CH_DAC 0x02
|
||||
#define ADC_CH_BAT 0x03
|
||||
|
||||
#define Aout_CH_0 0x00
|
||||
#define Aout_CH_1 0x01
|
||||
#define Aout_CH_2 0x02
|
||||
#define Aout_CH_3 0x03
|
||||
|
||||
|
||||
static void ADC_write(uint8_t ADCin) {
|
||||
/*
|
||||
* This function can only define [15]~[8] through ADCin
|
||||
* [7]~[0] should always be 0b11101011
|
||||
*
|
||||
* [15] : SS, 0 = no effect, 1 = start work, default 0b0
|
||||
* [14]~[12] : MUX[2:0], default 0b000
|
||||
* [11]~[9] : PGA[2:0], default 0b010 = FSR is ±2.048
|
||||
* [8] : mode, 0 = continuous, 1 = one shot, default 0b1 (Power-down and single-shot mode )
|
||||
*
|
||||
* [7]~[5] : data rate, default 0b100 = 128 SPS
|
||||
* [4] : Temperature? default 0b0 = ADC mode
|
||||
* [3] : Pullup enable, default 0b1 = Pullup resistor enabled
|
||||
* [2]~[1] : NOP, default 0b01
|
||||
* [0] : reserved, default 0b1
|
||||
*
|
||||
*/
|
||||
|
||||
// spi_ADC_txbuf[0] = 0b00000101;
|
||||
for(int i=0 ; i<SPI_ADC_SIZE ; i++){
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
spi_ADC_txbuf[0] = ADCin;
|
||||
spi_ADC_txbuf[1] = 0b11101011;
|
||||
|
||||
ADC_SPI(2, spi_ADC_txbuf, spi_ADC_rxbuf);
|
||||
}
|
||||
|
||||
static void ADC_read(uint8_t *ADCdata){
|
||||
for(int i=0 ; i<SPI_ADC_SIZE ; i++){
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
ADC_SPI(2, spi_ADC_txbuf, spi_ADC_rxbuf);
|
||||
}
|
||||
|
||||
/* Elite1.5 Calibration Usage */
|
||||
static void CAL_ADC_read(uint8_t *ADCdata){
|
||||
for(int i=0 ; i<SPI_ADC_SIZE ; i++){
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
CAL_ADC_SPI(SPI_ADC_SIZE, spi_ADC_txbuf, ADCdata);
|
||||
}
|
||||
|
||||
static void CAL_ADC_write(uint8_t ADCin) {
|
||||
for(int i=0 ; i<SPI_ADC_SIZE ; i++){
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
spi_ADC_txbuf[0] = ADCin;
|
||||
spi_ADC_txbuf[1] = 0b11101011;
|
||||
|
||||
CAL_ADC_SPI(2, spi_ADC_txbuf, spi_ADC_rxbuf);
|
||||
}
|
||||
|
||||
/* Gain Control for Vin & Iin */
|
||||
static void IinADCGainControl(uint8_t IinADCLevel){
|
||||
// if(IinADCLevel == 0){
|
||||
// // ADC gain level = 0, using 3M resister
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 0);
|
||||
// }
|
||||
// else if(IinADCLevel == 1){
|
||||
// // ADC gain level = 1, using 100K resister
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 1);
|
||||
// }
|
||||
// else if(IinADCLevel == 2){
|
||||
// // ADC gain level = 2, using 3K resister
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 1);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 0);
|
||||
// }
|
||||
// else if(IinADCLevel == 3){
|
||||
// // ADC gain level = 3, using 100R resistor
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 1);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 0);
|
||||
// }
|
||||
// else if(IinADCLevel == 4){
|
||||
// // ADC gain level = 3, auto gain (using 100R resister)
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 1);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 0);
|
||||
// }
|
||||
// else{
|
||||
// // default using 100R resister
|
||||
// PIN15_setOutputValue(Turnon_I_LARGE, 1);
|
||||
// PIN15_setOutputValue(Turnon_I_MID, 0);
|
||||
// PIN15_setOutputValue(Turnon_I_SMALL, 0);
|
||||
// }
|
||||
//
|
||||
// if(IinADCLevel == 0 || IinADCLevel == 1 || IinADCLevel == 2 || IinADCLevel == 3){
|
||||
// lastIinADCGainLevel = IinADCLevel;
|
||||
// }else{
|
||||
// lastIinADCGainLevel = 3;
|
||||
// }
|
||||
}
|
||||
|
||||
static void VinADCGainControl(uint8_t VinADCLevel){
|
||||
// if(VinADCLevel == 0){
|
||||
// // Vin ADC gain level = 0, using 1M resister
|
||||
// PIN15_setOutputValue(Turnon_V_SMALL, 0);
|
||||
// PIN15_setOutputValue(Turnon_V_MID, 0);
|
||||
// }
|
||||
// else if(VinADCLevel == 1){
|
||||
// // Vin ADC gain level = 1, using 30K resister
|
||||
// PIN15_setOutputValue(Turnon_V_SMALL, 0);
|
||||
// PIN15_setOutputValue(Turnon_V_MID, 1);
|
||||
// }
|
||||
// else if(VinADCLevel == 2){
|
||||
// // Vin ADC gain level = 2, using 1K resister
|
||||
// PIN15_setOutputValue(Turnon_V_SMALL, 1);
|
||||
// PIN15_setOutputValue(Turnon_V_MID, 0);
|
||||
// }
|
||||
// else if(VinADCLevel == 3){
|
||||
// // Vin ADC gain level = 3, auto gain (using 1K resister)
|
||||
// PIN15_setOutputValue(Turnon_V_SMALL, 1);
|
||||
// PIN15_setOutputValue(Turnon_V_MID, 0);
|
||||
// }
|
||||
// else{
|
||||
// // default using 1K resister
|
||||
// PIN15_setOutputValue(Turnon_V_SMALL, 1);
|
||||
// PIN15_setOutputValue(Turnon_V_MID, 0);
|
||||
// }
|
||||
//
|
||||
// if(VinADCLevel == 0 || VinADCLevel == 1 || VinADCLevel == 2){
|
||||
// lastVinADCGainLevel = VinADCLevel;
|
||||
// }else{
|
||||
// lastVinADCGainLevel = 2;
|
||||
// }
|
||||
}
|
||||
|
||||
static void ADCChannelSelect(uint8_t ADCChannel){
|
||||
// set ADC parameter
|
||||
// 0xC1~F1 = reading AIN0~AIN3. Using FSR+-6V, resolution = 187.5uV
|
||||
// 0xC5~F5 = reading AIN0~AIN3. Using FSR+-2V, resolution = 62.5 uV
|
||||
switch(ADCChannel){
|
||||
// AINp is AIN0; AINn is GND
|
||||
// measure AIN0, which is a current measure
|
||||
case ADC_CH_CURRENT :{
|
||||
ADC_write(CMD_CURRENT_MEASURE);
|
||||
break;
|
||||
}
|
||||
|
||||
// AINp is AIN1; AINn is GND
|
||||
// AIN1, which is a volt measure
|
||||
case ADC_CH_VOLT :{
|
||||
ADC_write(CMD_VOLT_MEASURE);
|
||||
break;
|
||||
}
|
||||
|
||||
// AINp is AIN2; AINn is GND
|
||||
// AIN2, measure DAC voltage (Note that this is NOT DAC real output value!!)
|
||||
case ADC_CH_DAC :{
|
||||
ADC_write(CMD_DAC_MEASURE);
|
||||
break;
|
||||
}
|
||||
|
||||
// measure battery volt
|
||||
case ADC_CH_BAT :{
|
||||
ADC_write(CMD_BATTERY_MEASURE);
|
||||
break;
|
||||
}
|
||||
default :{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void ReadADCIin(uint8_t *buf){
|
||||
// Read data twice since the first data we get is previous data
|
||||
// IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
ADCChannelSelect(ADC_CH_CURRENT);
|
||||
ADC_read(buf);
|
||||
|
||||
ADCChannelSelect(ADC_CH_CURRENT);
|
||||
ADC_read(buf);
|
||||
}
|
||||
|
||||
static void ReadADCVin(uint8_t *buf){
|
||||
// Read data twice since the first data we get is previous data
|
||||
|
||||
// VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
ADCChannelSelect(ADC_CH_VOLT);
|
||||
ADC_read(buf);
|
||||
|
||||
ADCChannelSelect(ADC_CH_VOLT);
|
||||
ADC_read(buf);
|
||||
}
|
||||
|
||||
static void ReadADCVout(uint8_t *buf){
|
||||
// Read data twice since the first data we get is previous data
|
||||
ADCChannelSelect(ADC_CH_DAC);
|
||||
ADC_read(buf);
|
||||
|
||||
ADCChannelSelect(ADC_CH_DAC);
|
||||
ADC_read(buf);
|
||||
}
|
||||
|
||||
static void ReadADCBat(uint8_t *buf){
|
||||
// Read data twice since the first data we get is previous data
|
||||
ADCChannelSelect(ADC_CH_BAT);
|
||||
ADC_read(buf);
|
||||
|
||||
ADCChannelSelect(ADC_CH_BAT);
|
||||
ADC_read(buf);
|
||||
}
|
||||
|
||||
/* for Elite1.5-re */
|
||||
// Iin theoretical boundary <2.67, 1.89~80, 63~2600, >1900 (uA)
|
||||
/* Old boundary
|
||||
#define I_GAIN_SMALL_BOUNDARY 4000 // 4 uA = 4,000,000 pA
|
||||
#define I_GAIN_MID1_BOUNDARY1 2000 // 2 uA = 2,000,000 pA
|
||||
#define I_GAIN_MID1_BOUNDARY2 90000 // 90 uA = 90,000,000 pA
|
||||
#define I_GAIN_MID2_BOUNDARY1 70000 // 70 uA = 70,000,000 pA
|
||||
#define I_GAIN_MID2_BOUNDARY2 1800000 // 1800 uA = 1,800,000 nA
|
||||
#define I_GAIN_LARGE_BOUNDARY 950000 // 950 uA = 950,000 nA
|
||||
*/
|
||||
#define I_GAIN_SMALL_BOUNDARY 4000 // 4 uA = 4,000,000 pA
|
||||
#define I_GAIN_MID1_BOUNDARY1 2500 // 2.5 uA = 2,500,000 pA
|
||||
#define I_GAIN_MID1_BOUNDARY2 100000 // 100 uA = 100,000,000 pA
|
||||
#define I_GAIN_MID2_BOUNDARY1 85000 // 85 uA = 85,000,000 pA
|
||||
#define I_GAIN_MID2_BOUNDARY2 2050000 // 2050 uA = 2,050,000 nA
|
||||
#define I_GAIN_LARGE_BOUNDARY 1800000 // 1800 uA = 1,800,000 nA
|
||||
|
||||
// Vin theoretical boundary <7, 5~200, >100 (mV)
|
||||
#define VIN_GAIN_SMALL_BOUNDARY 7000 // 7 mV = 7,000,000 nV
|
||||
#define VIN_GAIN_MID1_BOUNDARY1 5000 // 5 mV = 5,000,000 nV
|
||||
#define VIN_GAIN_MID1_BOUNDARY2 300000 // 300 mV = 300,000,000 nV
|
||||
#define VIN_GAIN_LARGE_BOUNDARY 250000 // 250 mV = 250,000,000 nV
|
||||
|
||||
static int32_t AutoGainReadIin(uint8_t *buf){
|
||||
int32_t RealCurrent = 0;
|
||||
|
||||
ReadADCIin(spi_ADC_rxbuf);
|
||||
RealCurrent = DecodeADCValue(INSTRUCTION.ADCGainLevel, ADC_CH_CURRENT, spi_ADC_rxbuf);
|
||||
|
||||
return RealCurrent;
|
||||
}
|
||||
|
||||
static int32_t AutoGainReadVin(uint8_t *buf){
|
||||
int32_t RealVolt = 0;
|
||||
|
||||
ReadADCVin(spi_ADC_rxbuf);
|
||||
RealVolt = DecodeADCValue(INSTRUCTION.VinADCGainLevel, ADC_CH_VOLT, spi_ADC_rxbuf);
|
||||
|
||||
return RealVolt;
|
||||
}
|
||||
|
||||
static void AutoGainChangeIin(int32_t RealCurrent){
|
||||
// switch to 1 level current(small) 3M
|
||||
// switch to 2 level current 100K
|
||||
// switch to 3 level current 3K
|
||||
// switch to 4 level current(large) 100R
|
||||
if(INSTRUCTION.ADCGainLevel == I_GAIN_100R){
|
||||
if(RealCurrent < I_GAIN_LARGE_BOUNDARY && RealCurrent > -1*I_GAIN_LARGE_BOUNDARY){
|
||||
// switch to 1 level current(small)
|
||||
if (RealCurrent < I_GAIN_MID1_BOUNDARY1 && RealCurrent > -1*I_GAIN_MID1_BOUNDARY1){
|
||||
I_GAIN_3M_counter++;
|
||||
if(I_GAIN_3M_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3M;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3M_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 2 level current
|
||||
else if (RealCurrent < I_GAIN_MID2_BOUNDARY1 && RealCurrent > -1*I_GAIN_MID2_BOUNDARY1){
|
||||
I_GAIN_100K_counter++;
|
||||
if(I_GAIN_100K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 3 level current
|
||||
else{
|
||||
I_GAIN_3K_counter++;
|
||||
if(I_GAIN_3K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(I_GAIN_3K_counter > 0){
|
||||
I_GAIN_3K_counter--;
|
||||
}
|
||||
if(I_GAIN_100K_counter > 0){
|
||||
I_GAIN_100K_counter--;
|
||||
}
|
||||
if(I_GAIN_3M_counter > 0){
|
||||
I_GAIN_3M_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.ADCGainLevel == I_GAIN_3K){
|
||||
// switch to 4 level current(large)
|
||||
if(RealCurrent > I_GAIN_MID2_BOUNDARY2 || RealCurrent < -1*I_GAIN_MID2_BOUNDARY2){
|
||||
I_GAIN_100R_counter++;
|
||||
if(I_GAIN_100R_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100R;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100R_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
else if (RealCurrent < I_GAIN_MID2_BOUNDARY1 && RealCurrent > -1*I_GAIN_MID2_BOUNDARY1){
|
||||
// switch to 1 level current(small)
|
||||
if(RealCurrent < I_GAIN_MID1_BOUNDARY1 && RealCurrent > -1*I_GAIN_MID1_BOUNDARY1){
|
||||
I_GAIN_3M_counter++;
|
||||
if(I_GAIN_3M_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3M;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3M_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 2 level current
|
||||
else{
|
||||
I_GAIN_100K_counter++;
|
||||
if(I_GAIN_100K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(I_GAIN_100R_counter > 0){
|
||||
I_GAIN_100R_counter--;
|
||||
}
|
||||
if(I_GAIN_100K_counter > 0){
|
||||
I_GAIN_100K_counter--;
|
||||
}
|
||||
if(I_GAIN_3M_counter > 0){
|
||||
I_GAIN_3M_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.ADCGainLevel == I_GAIN_100K){
|
||||
// switch to 1 level current(small)
|
||||
if(RealCurrent < I_GAIN_MID1_BOUNDARY1 && RealCurrent > -1*I_GAIN_MID1_BOUNDARY1){
|
||||
I_GAIN_3M_counter++;
|
||||
if(I_GAIN_3M_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3M;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3M_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
else if (RealCurrent > I_GAIN_MID1_BOUNDARY2 || RealCurrent < -1*I_GAIN_MID1_BOUNDARY2){
|
||||
// switch to 4 level current(large)
|
||||
if(RealCurrent > I_GAIN_MID2_BOUNDARY2 || RealCurrent < -1*I_GAIN_MID2_BOUNDARY2){
|
||||
I_GAIN_100R_counter++;
|
||||
if(I_GAIN_100R_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100R;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100R_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 3 level current
|
||||
else{
|
||||
I_GAIN_3K_counter++;
|
||||
if(I_GAIN_3K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(I_GAIN_100R_counter > 0){
|
||||
I_GAIN_100R_counter--;
|
||||
}
|
||||
if(I_GAIN_3K_counter > 0){
|
||||
I_GAIN_3K_counter--;
|
||||
}
|
||||
if(I_GAIN_3M_counter > 0){
|
||||
I_GAIN_3M_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.ADCGainLevel == I_GAIN_3M){
|
||||
if(RealCurrent > I_GAIN_SMALL_BOUNDARY || RealCurrent < -1*I_GAIN_SMALL_BOUNDARY){
|
||||
// switch to 4 level current(large)
|
||||
if(RealCurrent > I_GAIN_MID2_BOUNDARY2 || RealCurrent < -1*I_GAIN_MID2_BOUNDARY2){
|
||||
I_GAIN_100R_counter++;
|
||||
if(I_GAIN_100R_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100R;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100R_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 3 level current
|
||||
else if(RealCurrent > I_GAIN_MID1_BOUNDARY2 || RealCurrent < -1*I_GAIN_MID1_BOUNDARY2){
|
||||
I_GAIN_3K_counter++;
|
||||
if(I_GAIN_3K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_3K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_3K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 2 level current
|
||||
else{
|
||||
I_GAIN_100K_counter++;
|
||||
if(I_GAIN_100K_counter > 2){
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_100K;
|
||||
IinADCGainControl(INSTRUCTION.ADCGainLevel);
|
||||
I_GAIN_100K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
|
||||
}
|
||||
}else{
|
||||
if(I_GAIN_100R_counter > 0){
|
||||
I_GAIN_100R_counter--;
|
||||
}
|
||||
if(I_GAIN_3K_counter > 0){
|
||||
I_GAIN_3K_counter--;
|
||||
}
|
||||
if(I_GAIN_100K_counter > 0){
|
||||
I_GAIN_100K_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void AutoGainChangeVin(int32_t RealVin){
|
||||
// switch to 1 level volt(small) 1M
|
||||
// switch to 2 level volt 30K
|
||||
// switch to 3 level volt(large) 1K
|
||||
if(INSTRUCTION.VinADCGainLevel == VIN_GAIN_1M){
|
||||
if(RealVin > VIN_GAIN_SMALL_BOUNDARY || RealVin < -1*VIN_GAIN_SMALL_BOUNDARY){
|
||||
// switch to 3 level volt(large)
|
||||
if (RealVin > VIN_GAIN_MID1_BOUNDARY2 || RealVin < -1*VIN_GAIN_MID1_BOUNDARY2){
|
||||
VIN_GAIN_1K_counter++;
|
||||
if(VIN_GAIN_1K_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_1K;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_1K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 2 level volt
|
||||
else{
|
||||
VIN_GAIN_30K_counter++;
|
||||
if(VIN_GAIN_30K_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_30K;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_30K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(VIN_GAIN_1K_counter > 0){
|
||||
VIN_GAIN_1K_counter--;
|
||||
}
|
||||
if(VIN_GAIN_30K_counter > 0){
|
||||
VIN_GAIN_30K_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.VinADCGainLevel == VIN_GAIN_30K){
|
||||
// switch to 1 level volt(small)
|
||||
if(RealVin < VIN_GAIN_MID1_BOUNDARY1 && RealVin > -1*VIN_GAIN_MID1_BOUNDARY1){
|
||||
VIN_GAIN_1M_counter++;
|
||||
if(VIN_GAIN_1M_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_1M;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_1M_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
else if (RealVin > VIN_GAIN_MID1_BOUNDARY2 || RealVin < -1*VIN_GAIN_MID1_BOUNDARY2){
|
||||
// switch to 3 level volt
|
||||
VIN_GAIN_1K_counter++;
|
||||
if(VIN_GAIN_1K_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_1K;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_1K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}else{
|
||||
if(VIN_GAIN_1K_counter > 0){
|
||||
VIN_GAIN_1K_counter--;
|
||||
}
|
||||
if(VIN_GAIN_1M_counter > 0){
|
||||
VIN_GAIN_1M_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.VinADCGainLevel == VIN_GAIN_1K){
|
||||
if(RealVin < VIN_GAIN_LARGE_BOUNDARY && RealVin > -1*VIN_GAIN_LARGE_BOUNDARY){
|
||||
// switch to 1 level volt(small)
|
||||
if (RealVin < VIN_GAIN_MID1_BOUNDARY1 && RealVin > -1*VIN_GAIN_MID1_BOUNDARY1){
|
||||
VIN_GAIN_1M_counter++;
|
||||
if(VIN_GAIN_1M_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_1M;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_1M_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
// switch to 2 level volt
|
||||
else{
|
||||
VIN_GAIN_30K_counter++;
|
||||
if(VIN_GAIN_30K_counter > 2){
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_30K;
|
||||
VinADCGainControl(INSTRUCTION.VinADCGainLevel);
|
||||
VIN_GAIN_30K_counter = 0;
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(VIN_GAIN_1M_counter > 0){
|
||||
VIN_GAIN_1M_counter--;
|
||||
}
|
||||
if(VIN_GAIN_30K_counter > 0){
|
||||
VIN_GAIN_30K_counter--;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static uint16_t ADC_CURRENT_AVG_calibration (uint8_t ADC_channel) {
|
||||
uint32_t ADCValueTemp = 0;
|
||||
uint32_t ADCValueSUM = 0;
|
||||
uint32_t ADCValueAVG = 0;
|
||||
uint16_t ADCValueAVG_RAW = 0;
|
||||
#define avgcount 10000
|
||||
|
||||
// Red light for start acquiring data
|
||||
Elite_led_color(COLOR_RED);
|
||||
// CPUdelay(10);
|
||||
for(int i=0; i<avgcount; i++){
|
||||
CAL_ADC_write(ADC_channel);
|
||||
CAL_ADC_read(spi_ADC_rxbuf);
|
||||
CPUdelay(10);
|
||||
CAL_ADC_write(ADC_channel);
|
||||
CAL_ADC_read(spi_ADC_rxbuf);
|
||||
CPUdelay(500);
|
||||
|
||||
ADCValueTemp = 0x0000FFFF & (((uint32_t) (spi_ADC_rxbuf[0]) << 8) | ((uint32_t) (spi_ADC_rxbuf[1])));
|
||||
ADCValueSUM = ADCValueSUM + ADCValueTemp;
|
||||
}
|
||||
|
||||
ADCValueAVG = ADCValueSUM / avgcount;
|
||||
ADCValueAVG_RAW = (uint16_t) (ADCValueAVG & 0x0000FFFF);
|
||||
|
||||
// Blue light for data acquire done
|
||||
Elite_led_color(COLOR_BLUE);
|
||||
|
||||
if (ADCValueAVG_RAW > 0x7FFF) {
|
||||
ADCValueAVG_RAW = 0x0000;
|
||||
}
|
||||
|
||||
// clean data
|
||||
ADCValueAVG = 0;
|
||||
ADCValueSUM = 0;
|
||||
ADCValueTemp = 0;
|
||||
|
||||
// // Blue light for data acquire done
|
||||
// Elite_led_color(COLOR_BLUE);
|
||||
|
||||
|
||||
|
||||
return ADCValueAVG_RAW;
|
||||
}
|
||||
|
||||
/* use GPIO to control TW1508 */
|
||||
|
||||
|
||||
|
||||
static void GPIO_SPI_write(uint8_t GPIO_channel, uint16_t GPIOin) {
|
||||
/*
|
||||
Iout = 1.25/680 * ([9:7] +1)/8 * [6:0]
|
||||
*/
|
||||
static uint32_t TW_CH_0 [2] = {TW_SCKI_0};
|
||||
static uint32_t TW_CH_1 [2] = {TW_SCKI_1};
|
||||
static uint32_t TW_CH_2 [2] = {TW_SCKI_2};
|
||||
static uint32_t TW_CH_3 [2] = {TW_SCKI_3};
|
||||
|
||||
uint32_t CLK_CH[2] = {0};
|
||||
spi_GPIO_txbuf = 0;
|
||||
static bool trans_valid = false;
|
||||
|
||||
switch (GPIO_channel) {
|
||||
case Aout_CH_0: {
|
||||
CLK_CH[0] = TW_CH_0[0];
|
||||
CLK_CH[1] = TW_CH_0[1];
|
||||
trans_valid = true;
|
||||
break;
|
||||
}
|
||||
case Aout_CH_1: {
|
||||
CLK_CH[0] = TW_CH_1[0];
|
||||
CLK_CH[1] = TW_CH_1[1];
|
||||
trans_valid = true;
|
||||
break;
|
||||
}
|
||||
case Aout_CH_2: {
|
||||
CLK_CH[0] = TW_CH_2[0];
|
||||
CLK_CH[1] = TW_CH_2[1];
|
||||
trans_valid = true;
|
||||
break;
|
||||
}
|
||||
case Aout_CH_3: {
|
||||
CLK_CH[0] = TW_CH_3[0];
|
||||
CLK_CH[1] = TW_CH_3[1];
|
||||
trans_valid = true;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
trans_valid = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* GPIOin = 0x0000 ~ 0x03FF */
|
||||
spi_GPIO_txbuf = GPIOin;
|
||||
if (trans_valid) {
|
||||
GPIO_SPI_transfer(CLK_CH, spi_GPIO_txbuf);
|
||||
trans_valid = false;
|
||||
}
|
||||
}
|
||||
|
||||
static void AoutChannelSelect(uint8_t Aout_channel, bool on_off) {
|
||||
switch (Aout_channel) {
|
||||
case Aout_CH_0: {
|
||||
PIN15_setOutputValue(AO_MOS_0, on_off);
|
||||
break;
|
||||
}
|
||||
case Aout_CH_1: {
|
||||
PIN15_setOutputValue(AO_MOS_1, on_off);
|
||||
break;
|
||||
}
|
||||
case Aout_CH_2: {
|
||||
PIN15_setOutputValue(AO_MOS_2, on_off);
|
||||
break;
|
||||
}
|
||||
case Aout_CH_3: {
|
||||
PIN15_setOutputValue(AO_MOS_3, on_off);
|
||||
break;
|
||||
}
|
||||
case 0xFF :{ // output all off or on
|
||||
PIN15_setOutputValue(AO_MOS_0, on_off);
|
||||
PIN15_setOutputValue(AO_MOS_1, on_off);
|
||||
PIN15_setOutputValue(AO_MOS_2, on_off);
|
||||
PIN15_setOutputValue(AO_MOS_3, on_off);
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void TW1508reset() {
|
||||
GPIO_SPI_write(Aout_CH_0, 0x0000);
|
||||
GPIO_SPI_write(Aout_CH_1, 0x0000);
|
||||
GPIO_SPI_write(Aout_CH_2, 0x0000);
|
||||
GPIO_SPI_write(Aout_CH_3, 0x0000);
|
||||
}
|
||||
|
||||
#endif
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
|
||||
#ifndef ELITECCC
|
||||
#define ELITECCC
|
||||
|
||||
#include "EliteCCMode.h"
|
||||
|
||||
|
||||
// XXX : should we reset DAC output after STOP?
|
||||
static void CCModeReverseCurrent(CCCMode *CCC){
|
||||
if(CCC->StandBy){
|
||||
if(CT.StandByCounter == CCC->StandByTime){
|
||||
CCC->StandBy = false;
|
||||
CT.StandByCounter = 0;
|
||||
}
|
||||
else{
|
||||
CT.StandByCounter ++;
|
||||
}
|
||||
}
|
||||
else{
|
||||
// reverse charge/discharge
|
||||
if(CCC->BatteryV == CCC->VMax){
|
||||
CCC->StandBy = true;
|
||||
CCC->value = CCC->DischargeCurrent;
|
||||
}
|
||||
else if(CCC->BatteryV == CCC->VMin){
|
||||
CCC->StandBy = true;
|
||||
CCC->value = CCC->ChargeCurrent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
+83
@@ -0,0 +1,83 @@
|
||||
|
||||
#ifndef ELITECCMODE
|
||||
#define ELITECCMODE
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
#define DELTAVOLTMAX 100000
|
||||
|
||||
/* Transform setting CC into IUC
|
||||
*
|
||||
* User code in CC mode : 0 ~ 3000000
|
||||
* Real current value : -15.00000 ~ 15.00000 mA
|
||||
* => user code = 1500000 mapping to 0.00000 mA
|
||||
*/
|
||||
static void CC_Vscan(CCMode *CC){
|
||||
static int32_t Iin = 0;
|
||||
static int32_t deltaI = 0;
|
||||
static int32_t deltaV = 0;
|
||||
uint16_t divisionRate;
|
||||
|
||||
if(vscanReset){
|
||||
Vset = 0;
|
||||
|
||||
if(CC->_charge == 0){
|
||||
CC->_Iset *= -1;
|
||||
}
|
||||
|
||||
Iin = CC->_measureCurrent * 20; //[50pA] nA => 50pA
|
||||
deltaI = Iin - CC->_Iset;
|
||||
|
||||
if(deltaI > 20000000 || deltaI < -20000000){ //1mA
|
||||
divisionRate = 1000;
|
||||
}else{
|
||||
divisionRate = 10;
|
||||
}
|
||||
|
||||
deltaV = -1 * (deltaI / divisionRate); //-5 * deltaI / 5000 //pV=> 5nV
|
||||
|
||||
if(deltaV > DELTAVOLTMAX){ //100000 = 500uV
|
||||
deltaV = DELTAVOLTMAX;
|
||||
}else if(deltaV < (-DELTAVOLTMAX)){
|
||||
deltaV = (-DELTAVOLTMAX);
|
||||
}
|
||||
|
||||
Vset = Vset + deltaV; //[5nV]
|
||||
|
||||
if(Vset <= CC->_Vmin){
|
||||
Vset = CC->_Vmin;
|
||||
}else if(Vset >= CC->_Vmax){
|
||||
Vset = CC->_Vmax;
|
||||
}
|
||||
}
|
||||
|
||||
if(!vscanReset){
|
||||
Iin = CC->_measureCurrent * 20; //[50pA] nA => 50pA
|
||||
deltaI = Iin - CC->_Iset;
|
||||
|
||||
if(deltaI > 20000000 || deltaI < -20000000){ //1mA
|
||||
divisionRate = 1000;
|
||||
}else{
|
||||
divisionRate = 10;
|
||||
}
|
||||
|
||||
deltaV = -1 * (deltaI / divisionRate); //-5 * deltaI / 5000 //pV=> 5nV
|
||||
|
||||
if(deltaV > DELTAVOLTMAX){ //100000 = 500uV
|
||||
deltaV = DELTAVOLTMAX;
|
||||
}else if(deltaV < (-DELTAVOLTMAX)){
|
||||
deltaV = (-DELTAVOLTMAX);
|
||||
}
|
||||
|
||||
Vset = Vset + deltaV; //[5nV]
|
||||
|
||||
if(Vset <= CC->_Vmin){
|
||||
Vset = CC->_Vmin;
|
||||
}else if(Vset >= CC->_Vmax){
|
||||
Vset = CC->_Vmax;
|
||||
}
|
||||
}
|
||||
// int32_t RealV;
|
||||
// RealV = (int32_t)(deltaV);
|
||||
// InputNotify(NOTIFY_IMPEDANCE, RealV);
|
||||
}
|
||||
#endif
|
||||
+152
@@ -0,0 +1,152 @@
|
||||
#ifndef ELITECV3
|
||||
#define ELITECV3
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
|
||||
static uint16_t CV3Curve(CV3Mode *CV3){
|
||||
static uint16_t DACOutCode;
|
||||
static int32_t Vin;
|
||||
static int32_t Vout;
|
||||
static int32_t DeltaVout;
|
||||
|
||||
Vin = CV3->_measureVin * 200;//[5nV]
|
||||
if(DACReset){
|
||||
Vout = Vset + Vin;
|
||||
DACReset = false;
|
||||
}else{
|
||||
DeltaVout = Vset - (Vout - Vin);
|
||||
Vout = Vout + DeltaVout;
|
||||
}
|
||||
|
||||
INSTRUCTION.VoltConstant = Vout / 40000 + 25000;//5nV=>usercode
|
||||
DACOutCode = Usercode_Correction_to_DAC(INSTRUCTION.VoutGainLevel, INSTRUCTION.VoltConstant);
|
||||
|
||||
int32_t RealV2;
|
||||
RealV2 = (int32_t)((Vout - Vin) / 200);//[1uV]
|
||||
InputNotify(NOTIFY_VOLT, RealV2);
|
||||
|
||||
int32_t RealV;
|
||||
RealV = (int32_t)(Vout / 200);//[1uV]
|
||||
InputNotify(NOTIFY_IMPEDANCE, RealV);
|
||||
|
||||
DAC_outputV(DACOutCode);
|
||||
|
||||
return DACOutCode;
|
||||
}
|
||||
|
||||
|
||||
static void CV3_Vscan(CV3Mode *CV3) {
|
||||
static bool VminCounter;
|
||||
static bool VmaxCounter;
|
||||
|
||||
NotifyCycleNumber = (INSTRUCTION.cycleNumber - CV3->_cycleNumber + 1);
|
||||
|
||||
if (vscanReset) {
|
||||
VmaxCounter = false;
|
||||
VminCounter = false;
|
||||
|
||||
if (INSTRUCTION.directionInit == 1) {
|
||||
CV3->_direction_up = true;
|
||||
CV3->_current_direction_up = true;
|
||||
} else {
|
||||
CV3->_direction_up = false;
|
||||
CV3->_current_direction_up = false;
|
||||
}
|
||||
|
||||
//Vsetp = x * 20 * N, x=xmV ; N=VscanRate
|
||||
if (INSTRUCTION.step <= 10) {
|
||||
CV3->_Vstep = INSTRUCTION.step * INSTRUCTION.VsetRate / 5;
|
||||
} else {
|
||||
CV3->_Vstep = INSTRUCTION.step / 5 * INSTRUCTION.VsetRate;
|
||||
}
|
||||
|
||||
if (CV3->_Vmin == CV3->_Vinit) {
|
||||
VminCounter = true;
|
||||
}
|
||||
if (CV3->_Vmax == CV3->_Vinit) {
|
||||
VmaxCounter = true;
|
||||
}
|
||||
|
||||
Vset = CV3->_Vinit;
|
||||
}
|
||||
|
||||
if (!vscanReset) {
|
||||
if ((INSTRUCTION.Vinit < INSTRUCTION.Ve1 && INSTRUCTION.Vinit < INSTRUCTION.Ve2) ||
|
||||
(INSTRUCTION.Vinit > INSTRUCTION.Ve1 && INSTRUCTION.Vinit > INSTRUCTION.Ve2)
|
||||
) {
|
||||
if (CV3->_current_direction_up) {
|
||||
Vset = Vset + CV3->_Vstep * GPT.GptimerMultiple;
|
||||
} else {
|
||||
Vset = Vset - CV3->_Vstep * GPT.GptimerMultiple;
|
||||
}
|
||||
|
||||
if (INSTRUCTION.Vinit < INSTRUCTION.Ve1 && INSTRUCTION.Vinit < INSTRUCTION.Ve2) {
|
||||
if (Vset == CV3->_Vmin) {
|
||||
VminCounter = true;
|
||||
INSTRUCTION.Vinit = INSTRUCTION.Vmin;
|
||||
CV3->_Vinit = CV3->_Vmin;
|
||||
}
|
||||
} else if (INSTRUCTION.Vinit > INSTRUCTION.Ve1 && INSTRUCTION.Vinit > INSTRUCTION.Ve2) {
|
||||
if (Vset == CV3->_Vmax) {
|
||||
VmaxCounter = true;
|
||||
INSTRUCTION.Vinit = INSTRUCTION.Vmax;
|
||||
CV3->_Vinit = CV3->_Vmax;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (Vset >= CV3->_Vmax) {
|
||||
VmaxCounter = true;
|
||||
} else if (Vset <= CV3->_Vmin) {
|
||||
VminCounter = true;
|
||||
}
|
||||
|
||||
if (CV3->_current_direction_up) {
|
||||
Vset = Vset + CV3->_Vstep * GPT.GptimerMultiple;
|
||||
} else {
|
||||
Vset = Vset - CV3->_Vstep * GPT.GptimerMultiple;
|
||||
}
|
||||
|
||||
if (VmaxCounter && VminCounter) {
|
||||
if (CV3->_direction_up && CV3->_current_direction_up) {
|
||||
if (Vset >= CV3->_Vinit) {
|
||||
CV3->_cycleNumber--;
|
||||
VminCounter = false;
|
||||
VmaxCounter = false;
|
||||
}
|
||||
}
|
||||
if (!CV3->_direction_up && !CV3->_current_direction_up) {
|
||||
if (Vset <= CV3->_Vinit) {
|
||||
CV3->_cycleNumber--;
|
||||
VminCounter = false;
|
||||
VmaxCounter = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (Vset >= CV3->_Vmax) {
|
||||
CV3->_current_direction_up = false;
|
||||
} else if (Vset <= CV3->_Vmin) {
|
||||
CV3->_current_direction_up = true;
|
||||
}
|
||||
|
||||
/*stop condition*/
|
||||
if (CV3->_cycleNumber == 0) {
|
||||
// PeriodicEvent = false;
|
||||
ModeLED(POST_WORK);
|
||||
InitEliteFlag();
|
||||
INSTRUCTION.eliteFxn = CONSTANT_CURRENT;
|
||||
INSTRUCTION.sampleRate = 15;
|
||||
INSTRUCTION.charge = 0x01;
|
||||
INSTRUCTION.constantCurrent = 0x00;
|
||||
INSTRUCTION.Vmax = 0xC350;
|
||||
INSTRUCTION.Vmin = 0x0000;
|
||||
INSTRUCTION.notifyRate = 500;
|
||||
INSTRUCTION.VoViSwitch = 0x02;//read Vscan = Vout - Vin
|
||||
}
|
||||
}
|
||||
}
|
||||
// int32_t RealV;
|
||||
// RealV = (int32_t)(Vset / 500);//[1uV]
|
||||
// InputNotify(NOTIFY_VOLT, RealV);
|
||||
}
|
||||
#endif
|
||||
+213
@@ -0,0 +1,213 @@
|
||||
|
||||
#ifndef ELITECV
|
||||
#define ELITECV
|
||||
|
||||
static uint16_t SWVCurve(WorkMode *WorkModeData) {
|
||||
static uint8_t counter;
|
||||
static uint16_t outputV;
|
||||
static uint16_t Volt;
|
||||
static bool direction_up;
|
||||
|
||||
// reset origin volt at the begin
|
||||
if (DACReset) {
|
||||
Volt = INSTRUCTION.Ve1;
|
||||
outputV = INSTRUCTION.Ve1;
|
||||
if (INSTRUCTION.Ve1 < INSTRUCTION.Ve2)
|
||||
direction_up = true;
|
||||
else
|
||||
direction_up = false;
|
||||
counter = 1;
|
||||
DACReset = false;
|
||||
}
|
||||
|
||||
if (counter == 2 * PulseWidth)
|
||||
counter = 1;
|
||||
else
|
||||
counter++;
|
||||
|
||||
// output a certain volt
|
||||
outputV = Volt;
|
||||
DAC_outputV(outputV);
|
||||
|
||||
// VoltValue = (ramp1*16 + ramp0/16) * 3.05;
|
||||
|
||||
// check if we reach the final volt
|
||||
if ((outputV >= INSTRUCTION.Ve2 && direction_up) || (outputV <= INSTRUCTION.Ve2 && !direction_up)) {
|
||||
PeriodicEvent = false;
|
||||
DACReset = true;
|
||||
}
|
||||
|
||||
// prepare the next output volt
|
||||
if (direction_up) {
|
||||
if (counter == PulseWidth)
|
||||
Volt = Volt + Amplitude;
|
||||
else if (counter == 2 * PulseWidth)
|
||||
Volt = Volt - (Amplitude - INSTRUCTION.step);
|
||||
else
|
||||
Volt = Volt;
|
||||
} else {
|
||||
if (counter == PulseWidth)
|
||||
Volt = Volt - Amplitude;
|
||||
else if (counter == 2 * PulseWidth)
|
||||
Volt = Volt + (Amplitude - INSTRUCTION.step);
|
||||
else
|
||||
Volt = Volt;
|
||||
}
|
||||
|
||||
return outputV;
|
||||
}
|
||||
|
||||
static uint16_t DPVCurve(WorkMode *WorkModeData) {
|
||||
static uint8_t counter;
|
||||
static uint16_t Volt1;
|
||||
static uint16_t Volt2;
|
||||
static uint16_t outputV;
|
||||
static bool direction_up;
|
||||
|
||||
// reset origin volt at the begin
|
||||
if (DACReset) {
|
||||
if (INSTRUCTION.Ve1 < INSTRUCTION.Ve2)
|
||||
direction_up = true;
|
||||
else
|
||||
direction_up = false;
|
||||
|
||||
Volt1 = INSTRUCTION.Ve1;
|
||||
if (direction_up)
|
||||
Volt2 = INSTRUCTION.Ve1 + Amplitude;
|
||||
else
|
||||
Volt2 = INSTRUCTION.Ve1 - Amplitude;
|
||||
|
||||
counter = 1;
|
||||
DACReset = false;
|
||||
}
|
||||
|
||||
if (counter == PulsePeriod)
|
||||
counter = 1;
|
||||
else
|
||||
counter++;
|
||||
|
||||
// output a certain volt
|
||||
if (counter <= (PulsePeriod - PulseWidth)) {
|
||||
outputV = Volt1;
|
||||
DAC_outputV(Volt1);
|
||||
} else {
|
||||
outputV = Volt2;
|
||||
DAC_outputV(Volt2);
|
||||
}
|
||||
|
||||
|
||||
// VoltValue = (ramp1*16 + ramp0/16) * 3.05;
|
||||
|
||||
// check if we reach the final volt
|
||||
if (((outputV >= INSTRUCTION.Ve2) && direction_up) || ((outputV <= INSTRUCTION.Ve2) && !direction_up)) {
|
||||
PeriodicEvent = false;
|
||||
DACReset = true;
|
||||
}
|
||||
|
||||
// check overflow/underflow and prepare for next output
|
||||
if (direction_up) {
|
||||
if (Volt1 + INSTRUCTION.step < Volt1)
|
||||
Volt1 = 0xffff;
|
||||
else
|
||||
Volt1 = Volt1 + INSTRUCTION.step;
|
||||
if (Volt2 + INSTRUCTION.step < Volt2)
|
||||
Volt2 = 0xffff;
|
||||
else
|
||||
Volt2 = Volt2 + INSTRUCTION.step;
|
||||
} else {
|
||||
if (Volt1 - INSTRUCTION.step > Volt1)
|
||||
Volt1 = 0x0000;
|
||||
else
|
||||
Volt1 = Volt1 - INSTRUCTION.step;
|
||||
if (Volt2 - INSTRUCTION.step > Volt2)
|
||||
Volt2 = 0x0000;
|
||||
else
|
||||
Volt2 = Volt2 - INSTRUCTION.step;
|
||||
}
|
||||
|
||||
if (counter + 1 <= (PulsePeriod - PulseWidth)) {
|
||||
return Volt1;
|
||||
} else {
|
||||
return Volt2;
|
||||
}
|
||||
}
|
||||
|
||||
static void CV_Vscan(CVMode *CV){
|
||||
static bool VminCounter;
|
||||
static bool VmaxCounter;
|
||||
|
||||
NotifyCycleNumber = (INSTRUCTION.cycleNumber - CV->_cycleNumber + 1);
|
||||
|
||||
if(vscanReset){
|
||||
VmaxCounter = false;
|
||||
VminCounter = false;
|
||||
|
||||
if(INSTRUCTION.directionInit == 1){
|
||||
CV->_direction_up = true;
|
||||
CV->_current_direction_up = true;
|
||||
}else if(INSTRUCTION.directionInit == 0){
|
||||
CV->_direction_up = false;
|
||||
CV->_current_direction_up = false;
|
||||
}
|
||||
|
||||
//Vsetp = x * 20 * N, x=xmV ; N=VscanRate
|
||||
if(INSTRUCTION.step <= 10){
|
||||
CV->_Vstep = INSTRUCTION.step * INSTRUCTION.VsetRate / 5;
|
||||
}else{
|
||||
CV->_Vstep = INSTRUCTION.step / 5 * INSTRUCTION.VsetRate;
|
||||
}
|
||||
|
||||
if(CV->_Vmin == CV->_Vinit){
|
||||
VminCounter = true;
|
||||
}
|
||||
if(CV->_Vmax == CV->_Vinit){
|
||||
VmaxCounter = true;
|
||||
}
|
||||
|
||||
Vset = CV->_Vinit;
|
||||
}
|
||||
|
||||
if(!vscanReset){
|
||||
if (Vset >= CV->_Vmax){
|
||||
VmaxCounter = true;
|
||||
}else if (Vset <= CV->_Vmin){
|
||||
VminCounter = true;
|
||||
}
|
||||
|
||||
if (CV->_current_direction_up){
|
||||
Vset = Vset + CV->_Vstep * GPT.GptimerMultiple;
|
||||
}else{
|
||||
Vset = Vset - CV->_Vstep * GPT.GptimerMultiple;
|
||||
}
|
||||
|
||||
if(VmaxCounter && VminCounter){
|
||||
if(CV->_direction_up && CV->_current_direction_up){
|
||||
if(Vset >= CV->_Vinit){
|
||||
CV->_cycleNumber--;
|
||||
VminCounter = false;
|
||||
VmaxCounter = false;
|
||||
}
|
||||
}
|
||||
if(!CV->_direction_up && !CV->_current_direction_up){
|
||||
if(Vset <= CV->_Vinit){
|
||||
CV->_cycleNumber--;
|
||||
VminCounter = false;
|
||||
VmaxCounter = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (Vset >= CV->_Vmax){
|
||||
CV->_current_direction_up = false;
|
||||
}else if (Vset <= CV->_Vmin){
|
||||
CV->_current_direction_up = true;
|
||||
}
|
||||
|
||||
/*stop condition*/
|
||||
if(CV->_cycleNumber == 0){
|
||||
PeriodicEvent = false;
|
||||
ModeLED(NO_EVENT);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+47
@@ -0,0 +1,47 @@
|
||||
#ifndef ELITECVSCAN
|
||||
#define ELITECVSCAN
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
|
||||
static uint16_t CVSCANCurve(CVSCANMode *CVSCAN){
|
||||
static uint16_t DACOutCode;
|
||||
static int32_t Vin;
|
||||
static int32_t Vout;
|
||||
static int32_t DeltaVout;
|
||||
|
||||
Vin = CVSCAN->_measureVin * 200;//[5nV]
|
||||
if(DACReset){
|
||||
Vout = Vset + Vin;
|
||||
DACReset = false;
|
||||
}else{
|
||||
DeltaVout = Vset - (Vout - Vin);
|
||||
Vout = Vout + DeltaVout;
|
||||
}
|
||||
|
||||
INSTRUCTION.VoltConstant = Vout / 40000 + 25000;//5nV=>usercode
|
||||
DACOutCode = Usercode_Correction_to_DAC(INSTRUCTION.VoutGainLevel, INSTRUCTION.VoltConstant);
|
||||
|
||||
int32_t RealV2;
|
||||
RealV2 = (int32_t)((Vout - Vin) / 200);//[1uV]
|
||||
InputNotify(NOTIFY_VOLT, RealV2);
|
||||
|
||||
int32_t RealV;
|
||||
RealV = (int32_t)(Vout / 200);//[1uV]
|
||||
InputNotify(NOTIFY_IMPEDANCE, RealV);
|
||||
|
||||
DAC_outputV(DACOutCode);
|
||||
|
||||
return DACOutCode;
|
||||
}
|
||||
|
||||
static void CVSCAN_Vscan(CVSCANMode *CVSCAN){
|
||||
|
||||
if(vscanReset){
|
||||
Vset = CVSCAN->_Vinit;
|
||||
}
|
||||
|
||||
if(!vscanReset){
|
||||
Vset = CVSCAN->_Vinit;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+121
@@ -0,0 +1,121 @@
|
||||
|
||||
#ifndef EliteDAC
|
||||
#define EliteDAC
|
||||
|
||||
static bool DACReset;
|
||||
|
||||
|
||||
//#ifdef ELITE_VERSION_1_3
|
||||
//#define DACOUT 0x30
|
||||
//
|
||||
//static void DAC_outputV(uint16_t voltLV) {
|
||||
// // C = command, X = don't care, D = data
|
||||
// // CCCC XXXX = command
|
||||
// // DDDD DDDD = v1
|
||||
// // DDDD XXXX = v2
|
||||
//
|
||||
// uint8_t v1, v2 = 0;
|
||||
// v1 = (uint8_t) (voltLV >> 4) & 0xFF;
|
||||
// v2 = (uint8_t) ((voltLV & 0x000F) << 4) & 0xF0;
|
||||
//
|
||||
// spi_DACtxbuf[0] = command;
|
||||
// spi_DACtxbuf[1] = v1;
|
||||
// spi_DACtxbuf[2] = v2;
|
||||
// for (int i = 3; i < SPI_DAC_SIZE; i++) {
|
||||
// spi_DACtxbuf[i] = 0;
|
||||
// }
|
||||
//
|
||||
// DAC_SPI(SPI_DAC_SIZE, spi_DACtxbuf, spi_rxbuf);
|
||||
//}
|
||||
//#endif
|
||||
|
||||
#ifdef ELITE_VERSION_1_4
|
||||
#define DACCLS 0x02
|
||||
#define DACOUT 0x31
|
||||
|
||||
static uint16_t DAC_outputV(uint16_t voltLV) {
|
||||
// C = command, X = don't care, D = data
|
||||
// CCCC CCCC = command
|
||||
// DDDD DDDD = v1
|
||||
// DDDD DDDD = v2
|
||||
|
||||
// command
|
||||
// 0x02 = clear
|
||||
// 0x31 = output voltage
|
||||
|
||||
uint8_t v1, v2 = 0;
|
||||
v1 = (uint8_t) ((voltLV & 0xFF00) >> 8);
|
||||
v2 = (uint8_t) (voltLV & 0x00FF);
|
||||
|
||||
spi_DACtxbuf[0] = DACOUT;
|
||||
spi_DACtxbuf[1] = v1;
|
||||
spi_DACtxbuf[2] = v2;
|
||||
|
||||
// DAC_SPI(SPI_DAC_SIZE, spi_DACtxbuf, spi_rxbuf);
|
||||
|
||||
return voltLV;
|
||||
}
|
||||
|
||||
static void VoutGainControl(uint8_t VOUTLevel){
|
||||
if(VOUTLevel == 0){
|
||||
// VOUT gain level = 0, using 240K resister
|
||||
// PIN15_setOutputValue(Turon_VOUT_SMALL, 0);
|
||||
}
|
||||
else if(VOUTLevel == 1){
|
||||
// VOUT gain level = 1, using 15K resister
|
||||
// PIN15_setOutputValue(Turon_VOUT_SMALL, 1);
|
||||
}
|
||||
else if(VOUTLevel == 2){
|
||||
// VOUT gain level = 2, using 15K resister
|
||||
// PIN15_setOutputValue(Turon_VOUT_SMALL, 1);
|
||||
}
|
||||
else{
|
||||
// default using 15K resister
|
||||
// PIN15_setOutputValue(Turon_VOUT_SMALL, 1);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
static int32_t User2Real(uint16_t UserCode){
|
||||
/* transfer usercode to real voltage value (mV) */
|
||||
return (int32_t)((UserCode - 25000) / 5);
|
||||
}
|
||||
|
||||
|
||||
// DAC Vout theoretical boundary <300, 100~ (mV)
|
||||
#define DAC_VOUT_GAIN_SMALL_BOUNDARY 100000 // 25500(usercode) = 100 mV
|
||||
#define DAC_VOUT_GAIN_LARGE_BOUNDARY 300000 // 26500(usercode) = 300 mV
|
||||
#define DAC_VOUT_GAIN_LARGE_BOUNDARY_USERCODE 26500 // 26500(usercode) = 300 mV
|
||||
#define DAC_VOUT_GAIN_LARGE_BOUNDARY1_USERCODE 23500 // 23500(usercode) = -300 mV
|
||||
|
||||
static void AutoGainChangeVout(int32_t userCode){
|
||||
int32_t RealVolt = (userCode - 25000) * 200; // (userCode - 25000) / 5 * 1000 [1uV]
|
||||
// switch to 1 level volt(small) 15K
|
||||
// switch to 2 level volt(large) 240K
|
||||
|
||||
if(INSTRUCTION.VoutGainLevel == VOUT_GAIN_AUTO){
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_15K;
|
||||
VoutGainControl(INSTRUCTION.VoutGainLevel);
|
||||
record_flag = false;
|
||||
}
|
||||
|
||||
if(INSTRUCTION.VoutGainLevel == VOUT_GAIN_15K){
|
||||
if(RealVolt > DAC_VOUT_GAIN_LARGE_BOUNDARY || RealVolt < -1 * DAC_VOUT_GAIN_LARGE_BOUNDARY){
|
||||
// switch to 2 level volt(large)
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_240K;
|
||||
VoutGainControl(INSTRUCTION.VoutGainLevel);
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
else if(INSTRUCTION.VoutGainLevel == VOUT_GAIN_240K){
|
||||
if(RealVolt < DAC_VOUT_GAIN_SMALL_BOUNDARY && RealVolt > -1 * DAC_VOUT_GAIN_SMALL_BOUNDARY ){
|
||||
// switch to 1 level volt(small)
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_15K;
|
||||
VoutGainControl(INSTRUCTION.VoutGainLevel);
|
||||
record_flag = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
+633
@@ -0,0 +1,633 @@
|
||||
#ifndef EliteCorrection
|
||||
#define EliteCorrection
|
||||
|
||||
#include "EliteDAC.h"
|
||||
#include "EliteADC.h"
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Correction Array include all the correction coeff and offset
|
||||
*
|
||||
* Correction formula format is " RealValue = coeff * code + offset "
|
||||
* RealValue can be RealCurrent, RealVolt, or RealResister ...
|
||||
* code is the code we read from ADC buffer
|
||||
*
|
||||
* ADC measure Voltage
|
||||
* RealVolt = Correction.ADC_volt.coeff * code + Correction.ADC_volt.offset
|
||||
*
|
||||
* ADC measure Current
|
||||
* ADCGain: 0 => 200k, 1 => 10k, 2 => 200R
|
||||
* RealCurrent = Correction.ADC_current[ADCGain].coeff * code + Correction.ADC_current[ADCGain].offset
|
||||
*
|
||||
* DAC output Voltage
|
||||
* RealVolt = Correction.DAC2RealV.coeff * DACcode + Correction.DAC2RealV.offset
|
||||
*
|
||||
* Usercode to DACcode
|
||||
* DACcode = Correction.Usercode2DAC.coeff * code + Correction.Usercode2DAC.offset
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#define BOARD_C903
|
||||
|
||||
typedef struct _formula{
|
||||
|
||||
long long coeff;
|
||||
long long offset;
|
||||
|
||||
}Formula;
|
||||
|
||||
struct _correction{
|
||||
|
||||
Formula ADC_volt[3];
|
||||
Formula ADC_current[4];
|
||||
Formula Usercode2DAC[2];
|
||||
uint16_t Gain0Boundary[2];
|
||||
uint16_t Gain1Boundary[4];
|
||||
uint16_t Gain2Boundary[2];
|
||||
|
||||
} Correction =
|
||||
|
||||
#ifdef BOARD_C7A1 //megafly
|
||||
{
|
||||
.ADC_volt[0].coeff = (6256),
|
||||
.ADC_volt[0].offset = -101532028,
|
||||
|
||||
.ADC_volt[1].coeff = (215138),
|
||||
.ADC_volt[1].offset = -3501890770,
|
||||
|
||||
.ADC_volt[2].coeff = (6245014),
|
||||
.ADC_volt[2].offset = -101751226981,
|
||||
|
||||
.ADC_current[0].coeff = 3125920,
|
||||
.ADC_current[0].offset = (-50880328288),
|
||||
|
||||
.ADC_current[1].coeff = 71636129,
|
||||
.ADC_current[1].offset = (-1166093783868),
|
||||
|
||||
.ADC_current[2].coeff = 1459555637,
|
||||
.ADC_current[2].offset = (-23757721396024),
|
||||
|
||||
.ADC_current[3].coeff = 30723232882,
|
||||
.ADC_current[3].offset = (-500144809348170),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10543817),
|
||||
.Usercode2DAC[0].offset = 583163641972,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178077711),
|
||||
.Usercode2DAC[1].offset = 4777894559527,
|
||||
|
||||
//.Usercode2DAC15v = 41485,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C724 //megafly
|
||||
{
|
||||
.ADC_volt[0].coeff = (6251),
|
||||
.ADC_volt[0].offset = -99750397,
|
||||
|
||||
.ADC_volt[1].coeff = (214419),
|
||||
.ADC_volt[1].offset = -3491659841,
|
||||
|
||||
.ADC_volt[2].coeff = (6227737),
|
||||
.ADC_volt[2].offset = -101557618268,
|
||||
|
||||
.ADC_current[0].coeff = 3138613,
|
||||
.ADC_current[0].offset = (-51149570420),
|
||||
|
||||
.ADC_current[1].coeff = 71715555,
|
||||
.ADC_current[1].offset = (-1168777305352),
|
||||
|
||||
.ADC_current[2].coeff = 1455501991,
|
||||
.ADC_current[2].offset = (-23719715469357),
|
||||
|
||||
.ADC_current[3].coeff = 30688298312,
|
||||
.ADC_current[3].offset = (-500150163983795),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10540182),
|
||||
.Usercode2DAC[0].offset = 584459109821,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-179175265),
|
||||
.Usercode2DAC[1].offset = 4801179734836,
|
||||
|
||||
//.Usercode2DAC15v = MEGA_15V,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C874 //megafly
|
||||
{
|
||||
.ADC_volt[0].coeff = (6260),
|
||||
.ADC_volt[0].offset = -99787811,
|
||||
|
||||
.ADC_volt[1].coeff = (214494),
|
||||
.ADC_volt[1].offset = -3492178752,
|
||||
|
||||
.ADC_volt[2].coeff = (6231057),
|
||||
.ADC_volt[2].offset = -101591914655,
|
||||
|
||||
.ADC_current[0].coeff = 3148251,
|
||||
.ADC_current[0].offset = (-51277675282),
|
||||
|
||||
.ADC_current[1].coeff = 71859885,
|
||||
.ADC_current[1].offset = (-1170556644217),
|
||||
|
||||
.ADC_current[2].coeff = 1462458824,
|
||||
.ADC_current[2].offset = (-23822062635236),
|
||||
|
||||
.ADC_current[3].coeff = 30748473913,
|
||||
.ADC_current[3].offset = (-500860829105930),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10570366),
|
||||
.Usercode2DAC[0].offset = 585189864243,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178920333),
|
||||
.Usercode2DAC[1].offset = 4794801719146,
|
||||
|
||||
//.Usercode2DAC15v = 41355,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C604
|
||||
{
|
||||
.ADC_volt[0].coeff = (6194),
|
||||
.ADC_volt[0].offset = -100974071,
|
||||
|
||||
.ADC_volt[1].coeff = (215506),
|
||||
.ADC_volt[1].offset = -3517864544,
|
||||
|
||||
.ADC_volt[2].coeff = (6243728),
|
||||
.ADC_volt[2].offset = -102012564806,
|
||||
|
||||
.ADC_current[0].coeff = 3139436,
|
||||
.ADC_current[0].offset = (-51217085818),
|
||||
|
||||
.ADC_current[1].coeff = 71622830,
|
||||
.ADC_current[1].offset = (-1168462302473),
|
||||
|
||||
.ADC_current[2].coeff = 1462344785,
|
||||
.ADC_current[2].offset = (-23855062972762),
|
||||
|
||||
.ADC_current[3].coeff = 30689232716,
|
||||
.ADC_current[3].offset = (-500670762245868),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10507403),
|
||||
.Usercode2DAC[0].offset = 582940058695,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178479878),
|
||||
.Usercode2DAC[1].offset = 4782895510276,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C69F
|
||||
{
|
||||
.ADC_volt[0].coeff = (6118),
|
||||
.ADC_volt[0].offset = -99518615,
|
||||
|
||||
.ADC_volt[1].coeff = (209748),
|
||||
.ADC_volt[1].offset = -3417768725,
|
||||
|
||||
.ADC_volt[2].coeff = (6131501),
|
||||
.ADC_volt[2].offset = -99999128933,
|
||||
|
||||
.ADC_current[0].coeff = 3148514,
|
||||
.ADC_current[0].offset = (-50485662786),
|
||||
|
||||
.ADC_current[1].coeff = 71804564,
|
||||
.ADC_current[1].offset = (-1151299062516),
|
||||
|
||||
.ADC_current[2].coeff = 1463584080,
|
||||
.ADC_current[2].offset = (-23465643586165),
|
||||
|
||||
.ADC_current[3].coeff = 30747070723,
|
||||
.ADC_current[3].offset = (-492979538892707),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10534427),
|
||||
.Usercode2DAC[0].offset = 577647889649,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178317702),
|
||||
.Usercode2DAC[1].offset = 4773350420707,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C903
|
||||
{
|
||||
.ADC_volt[0].coeff = (6268),
|
||||
.ADC_volt[0].offset = -103687047,
|
||||
|
||||
.ADC_volt[1].coeff = (216289),
|
||||
.ADC_volt[1].offset = -3581110600,
|
||||
|
||||
.ADC_volt[2].coeff = (6255165),
|
||||
.ADC_volt[2].offset = -103653080405,
|
||||
|
||||
.ADC_current[0].coeff = 3136844,
|
||||
.ADC_current[0].offset = (-51057548335),
|
||||
|
||||
.ADC_current[1].coeff = 71729828,
|
||||
.ADC_current[1].offset = (-1167474302377),
|
||||
|
||||
.ADC_current[2].coeff = 1457587112,
|
||||
.ADC_current[2].offset = (-23722230272507),
|
||||
|
||||
.ADC_current[3].coeff = 30688020320,
|
||||
.ADC_current[3].offset = (-499567626613052),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10538549),
|
||||
.Usercode2DAC[0].offset = 582561125327,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-179443367),
|
||||
.Usercode2DAC[1].offset = 4806000714268,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C60C
|
||||
{
|
||||
.ADC_volt[0].coeff = (6232),
|
||||
.ADC_volt[0].offset = -100384012,
|
||||
|
||||
.ADC_volt[1].coeff = (216642),
|
||||
.ADC_volt[1].offset = -3529452462,
|
||||
|
||||
.ADC_volt[2].coeff = (6233108),
|
||||
.ADC_volt[2].offset = -100604531870,
|
||||
|
||||
.ADC_current[0].coeff = 3145651,
|
||||
.ADC_current[0].offset = (-51102123184),
|
||||
|
||||
.ADC_current[1].coeff = 71727284,
|
||||
.ADC_current[1].offset = (-1165169041311),
|
||||
|
||||
.ADC_current[2].coeff = 1463455403,
|
||||
.ADC_current[2].offset = (-23772125686630),
|
||||
|
||||
.ADC_current[3].coeff = 30773610135,
|
||||
.ADC_current[3].offset = (-499913505030514),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10570464),
|
||||
.Usercode2DAC[0].offset = 583479916773,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178725281),
|
||||
.Usercode2DAC[1].offset = 4787957689974,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C78B
|
||||
{
|
||||
.ADC_volt[0].coeff = (6242),
|
||||
.ADC_volt[0].offset = -101356025,
|
||||
|
||||
.ADC_volt[1].coeff = (215624),
|
||||
.ADC_volt[1].offset = -3503045312,
|
||||
|
||||
.ADC_volt[2].coeff = (6243816),
|
||||
.ADC_volt[2].offset = -101524034738,
|
||||
|
||||
.ADC_current[0].coeff = 3131950,
|
||||
.ADC_current[0].offset = (-50953509336),
|
||||
|
||||
.ADC_current[1].coeff = 71591803,
|
||||
.ADC_current[1].offset = (-1164676104750),
|
||||
|
||||
.ADC_current[2].coeff = 1457994881,
|
||||
.ADC_current[2].offset = (-23717445756897),
|
||||
|
||||
.ADC_current[3].coeff = 30731877501,
|
||||
.ADC_current[3].offset = (-499947688305697),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10509141),
|
||||
.Usercode2DAC[0].offset = 581313489845,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-177847688),
|
||||
.Usercode2DAC[1].offset = 4765751343445,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C615
|
||||
{
|
||||
.ADC_volt[0].coeff = (6213),
|
||||
.ADC_volt[0].offset = -100904734,
|
||||
|
||||
.ADC_volt[1].coeff = (213486),
|
||||
.ADC_volt[1].offset = -3475774161,
|
||||
|
||||
.ADC_volt[2].coeff = (6220838),
|
||||
.ADC_volt[2].offset = -101367452805,
|
||||
|
||||
.ADC_current[0].coeff = 3133669,
|
||||
.ADC_current[0].offset = (-50985338691),
|
||||
|
||||
.ADC_current[1].coeff = 71848701,
|
||||
.ADC_current[1].offset = (-1168930549263),
|
||||
|
||||
.ADC_current[2].coeff = 1465220422,
|
||||
.ADC_current[2].offset = (-23836711044239),
|
||||
|
||||
.ADC_current[3].coeff = 30753809644,
|
||||
.ADC_current[3].offset = (-500364315274466),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10519306),
|
||||
.Usercode2DAC[0].offset = 583547544303,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-179481859),
|
||||
.Usercode2DAC[1].offset = 4808633144378,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C797
|
||||
{
|
||||
.ADC_volt[0].coeff = (6285),
|
||||
.ADC_volt[0].offset = -102399765,
|
||||
|
||||
.ADC_volt[1].coeff = (217179),
|
||||
.ADC_volt[1].offset = -3541219740,
|
||||
|
||||
.ADC_volt[2].coeff = (6293290),
|
||||
.ADC_volt[2].offset = -102701705789,
|
||||
|
||||
.ADC_current[0].coeff = 3124793,
|
||||
.ADC_current[0].offset = (-50785593516),
|
||||
|
||||
.ADC_current[1].coeff = 71661923,
|
||||
.ADC_current[1].offset = (-1164632411724),
|
||||
|
||||
.ADC_current[2].coeff = 1459117290,
|
||||
.ADC_current[2].offset = (-23712400276764),
|
||||
|
||||
.ADC_current[3].coeff = 30624856407,
|
||||
.ADC_current[3].offset = (-497729976849926),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10517402),
|
||||
.Usercode2DAC[0].offset = 581255473226,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178353177),
|
||||
.Usercode2DAC[1].offset = 4777407394955,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C639
|
||||
{
|
||||
.ADC_volt[0].coeff = (6208),
|
||||
.ADC_volt[0].offset = -100729867,
|
||||
|
||||
.ADC_volt[1].coeff = (214500),
|
||||
.ADC_volt[1].offset = -3488858165,
|
||||
|
||||
.ADC_volt[2].coeff = (6228268),
|
||||
.ADC_volt[2].offset = -101395718164,
|
||||
|
||||
.ADC_current[0].coeff = 3139511,
|
||||
.ADC_current[0].offset = (-51174954874),
|
||||
|
||||
.ADC_current[1].coeff = 71851912,
|
||||
.ADC_current[1].offset = (-1171152880960),
|
||||
|
||||
.ADC_current[2].coeff = 1461965017,
|
||||
.ADC_current[2].offset = (-23828340962540),
|
||||
|
||||
.ADC_current[3].coeff = 30773724865,
|
||||
.ADC_current[3].offset = (-501611882239925),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10520659),
|
||||
.Usercode2DAC[0].offset = 581192312483,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-177973792),
|
||||
.Usercode2DAC[1].offset = 4768259045109,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C771 //die
|
||||
{
|
||||
.ADC_volt[0].coeff = (6301),
|
||||
.ADC_volt[0].offset = -102184705,
|
||||
|
||||
.ADC_volt[1].coeff = (216877),
|
||||
.ADC_volt[1].offset = -3519583281,
|
||||
|
||||
.ADC_volt[2].coeff = (6298448),
|
||||
.ADC_volt[2].offset = -102304286091,
|
||||
|
||||
.ADC_current[0].coeff = 3115431,
|
||||
.ADC_current[0].offset = (-50586460394),
|
||||
|
||||
.ADC_current[1].coeff = 71203612,
|
||||
.ADC_current[1].offset = (-1156022105141),
|
||||
|
||||
.ADC_current[2].coeff = 1451318434,
|
||||
.ADC_current[2].offset = (-23560731221983),
|
||||
|
||||
.ADC_current[3].coeff = 30518004246,
|
||||
.ADC_current[3].offset = (-495456618814855),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10568719),
|
||||
.Usercode2DAC[0].offset = 585036272447,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-179441058),
|
||||
.Usercode2DAC[1].offset = 4807380622351,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C6E1 // not well
|
||||
{
|
||||
.ADC_volt[0].coeff = (-6251051),
|
||||
.ADC_volt[0].offset = 102081366120,
|
||||
|
||||
.ADC_volt[1].coeff = (-6251051),
|
||||
.ADC_volt[1].offset = 102081366120,
|
||||
|
||||
.ADC_volt[2].coeff = (-6251051),
|
||||
.ADC_volt[2].offset = 102081366120,
|
||||
|
||||
.ADC_current[0].coeff = 2079230,
|
||||
.ADC_current[0].offset = (-34256067906),
|
||||
|
||||
.ADC_current[1].coeff = 64550018,
|
||||
.ADC_current[1].offset = (-1063052554820),
|
||||
|
||||
.ADC_current[2].coeff = 2096336928,
|
||||
.ADC_current[2].offset = (-34514344284104),
|
||||
|
||||
.ADC_current[3].coeff = 60200953965,
|
||||
.ADC_current[3].offset = (-991270580672004),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10511469),
|
||||
.Usercode2DAC[0].offset = 563770560100,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-10511469),
|
||||
.Usercode2DAC[1].offset = 563770560100,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef BOARD_C6D4 // not well
|
||||
{
|
||||
.ADC_volt[0].coeff = (6226),
|
||||
.ADC_volt[0].offset = -100075170,
|
||||
|
||||
.ADC_volt[1].coeff = (215972),
|
||||
.ADC_volt[1].offset = -3484380085,
|
||||
|
||||
.ADC_volt[2].coeff = (6223818),
|
||||
.ADC_volt[2].offset = -100571214617,
|
||||
|
||||
.ADC_current[0].coeff = 3136256,
|
||||
.ADC_current[0].offset = (-50747854551),
|
||||
|
||||
.ADC_current[1].coeff = 72219340,
|
||||
.ADC_current[1].offset = (-1168719058378),
|
||||
|
||||
.ADC_current[2].coeff = 1450319129,
|
||||
.ADC_current[2].offset = (-23465744053517),
|
||||
|
||||
.ADC_current[3].coeff = 30710734735,
|
||||
.ADC_current[3].offset = (-496978137538345),
|
||||
|
||||
.Usercode2DAC[0].coeff = (-10543212),
|
||||
.Usercode2DAC[0].offset = 582976692942,
|
||||
|
||||
.Usercode2DAC[1].coeff = (-178746005),
|
||||
.Usercode2DAC[1].offset = 4789272862069,
|
||||
};
|
||||
#endif
|
||||
// this function turn ADC measure value (0xXXXX) into real voltage
|
||||
// unit should be uV
|
||||
static int32_t DecodeADCVolt(uint8_t ADCGain, uint16_t ADC_measure){
|
||||
long long ADCRealVolt = 0;
|
||||
|
||||
ADCRealVolt = (Correction.ADC_volt[ADCGain].coeff * ADC_measure + Correction.ADC_volt[ADCGain].offset)/1e4;
|
||||
|
||||
return (int32_t) (ADCRealVolt);
|
||||
}
|
||||
|
||||
// this function turn ADC measure value (0xXXXX) into Vout voltage
|
||||
// unit should be mV
|
||||
static int32_t DecodeADCVoutVolt(uint16_t ADC_measure){
|
||||
long long ADCVoutVolt = 0;
|
||||
|
||||
ADCVoutVolt = ((-62658782380) * ADC_measure + 1020118014900000);
|
||||
ADCVoutVolt = ADCVoutVolt / 1e11;
|
||||
return (int32_t) (ADCVoutVolt);
|
||||
}
|
||||
|
||||
// this function turn ADC measure value (0xXXXX) into Battery voltage
|
||||
// unit should be mV
|
||||
static int32_t DecodeADCBatVolt(uint16_t ADC_measure){
|
||||
long long ADCBatVolt = 0;
|
||||
|
||||
ADCBatVolt = (47362594 * ADC_measure + 290422184577);
|
||||
ADCBatVolt = ADCBatVolt / 1e8;
|
||||
return (int32_t) (ADCBatVolt);
|
||||
}
|
||||
|
||||
// this function turn ADC measure value (0xXXXX) into real current
|
||||
// unit should be nA
|
||||
static int32_t DecodeADCCurrent(uint8_t ADCGain, uint16_t ADC_measure){
|
||||
long long ADCRealCurrent = 0;
|
||||
|
||||
ADCRealCurrent = (Correction.ADC_current[ADCGain].coeff * ADC_measure + Correction.ADC_current[ADCGain].offset)/1e7;
|
||||
|
||||
// Current unit is pA;
|
||||
// If ADCGain is I_GAIN_100R unit is nA
|
||||
return (int32_t) (ADCRealCurrent);
|
||||
}
|
||||
|
||||
// Decode ADC measure value (could be a volt or current) and put it into notify buffer
|
||||
static int32_t DecodeADCValue(uint8_t ADCGain, uint8_t ADCChannel, uint8_t *ADC_raw){
|
||||
|
||||
uint16_t ADC_measure = (uint16_t) (ADC_raw[0] << 8) | (uint16_t) (ADC_raw[1]);
|
||||
int32_t ADCRealVolt = 0, ret = 0, ADCRealCurrent = 0, ADCVoutVolt = 0, ADCBatVolt = 0;
|
||||
|
||||
// InputNotify(NOTIFY_VOLT, (uint32_t)(ADC_measure));//
|
||||
// return real volt to controller
|
||||
if(ADCChannel == ADC_CH_VOLT){
|
||||
ADCRealVolt = DecodeADCVolt(ADCGain, ADC_measure);
|
||||
ret = ADCRealVolt;
|
||||
}
|
||||
|
||||
// return real current to controller
|
||||
else if(ADCChannel == ADC_CH_CURRENT){
|
||||
ADCRealCurrent = DecodeADCCurrent(ADCGain, ADC_measure);
|
||||
ret = ADCRealCurrent;
|
||||
}
|
||||
|
||||
// return real VoutVolt to controller
|
||||
else if(ADCChannel == ADC_CH_DAC){
|
||||
ADCVoutVolt = DecodeADCVoutVolt(ADC_measure);
|
||||
ret = ADCVoutVolt;
|
||||
}
|
||||
|
||||
// return real Battery Volt to controller
|
||||
else if(ADCChannel == ADC_CH_BAT){
|
||||
ADCBatVolt = DecodeADCBatVolt(ADC_measure);
|
||||
ret = ADCBatVolt;
|
||||
}
|
||||
|
||||
else{
|
||||
// not support AIN2 / AIN3 yet
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
// #0 board, (0x5f75 <= rawdata) && (rawdata <= 0x5fb2)
|
||||
// ((0x5f97 < rawdata) && (rawdata < 0x6589)) || ((0x5999 < rawdata) && (rawdata < 0x5f93))
|
||||
|
||||
static void ADC_overflow(uint8_t gain, uint8_t *rawdata){
|
||||
|
||||
// Gain boundary defines different ADC gain level working area
|
||||
// Gain0Boundary = {lowerbound, upperbound}, is the lower and upper bound of gain level 0 working area.
|
||||
|
||||
uint16_t U16Rawdata = 0;
|
||||
U16Rawdata = (((uint16_t) (rawdata[0]))<<8) | ((uint16_t) (rawdata[1]));
|
||||
|
||||
if(gain == I_GAIN_3M){
|
||||
if( U16Rawdata <= Correction.Gain0Boundary[0]){
|
||||
rawdata[0] = Correction.Gain0Boundary[0] >> 4;
|
||||
rawdata[1] = (uint8_t) (Correction.Gain0Boundary[0] & 0x00FF);
|
||||
}
|
||||
else if(U16Rawdata >= Correction.Gain0Boundary[1]){
|
||||
rawdata[0] = (uint8_t) (Correction.Gain0Boundary[1] >> 4);
|
||||
rawdata[1] = (uint8_t) (Correction.Gain0Boundary[1] & 0x00FF);
|
||||
}
|
||||
}
|
||||
else if(gain == I_GAIN_100K){
|
||||
if( U16Rawdata <= Correction.Gain1Boundary[0]){
|
||||
rawdata[0] = Correction.Gain1Boundary[0] >> 4;
|
||||
rawdata[1] = (uint8_t) (Correction.Gain1Boundary[0] & 0x00FF);
|
||||
}
|
||||
else if(U16Rawdata >= Correction.Gain1Boundary[1]){
|
||||
rawdata[0] = (uint8_t) (Correction.Gain1Boundary[1] >> 4);
|
||||
rawdata[1] = (uint8_t) (Correction.Gain1Boundary[1] & 0x00FF);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// User will enter -5V~+5V in UI.
|
||||
// websever and controler use 0~50000 represent -5~+5V
|
||||
// this function should turn 0~50000 into DACcode which output the exactly voltage user want
|
||||
static uint16_t Usercode_Correction_to_DAC(uint8_t DACGain, uint16_t usercode)
|
||||
{
|
||||
long long usercode_32;
|
||||
uint16_t DACcode = 0;
|
||||
|
||||
usercode_32 = (long long)(usercode);
|
||||
|
||||
DACcode = (uint16_t) ((Correction.Usercode2DAC[DACGain].coeff * usercode_32 + Correction.Usercode2DAC[DACGain].offset)/1e7);
|
||||
|
||||
return DACcode;
|
||||
}
|
||||
|
||||
|
||||
static int32_t DAC_to_realV(uint8_t DACGain, uint16_t DACcode)
|
||||
{
|
||||
int32_t RealV = 0;
|
||||
long long usercode_32;
|
||||
|
||||
usercode_32 = ((DACcode * 1e7) - Correction.Usercode2DAC[DACGain].offset) / Correction.Usercode2DAC[DACGain].coeff;
|
||||
|
||||
RealV = (int32_t) ((usercode_32 / 5) - 5000) * 1000;
|
||||
// RealV = (int32_t) usercode_32;
|
||||
// return nV
|
||||
return RealV;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
+47
@@ -0,0 +1,47 @@
|
||||
|
||||
#ifndef ELITE_FLAG_CT_INIT
|
||||
#define ELITE_FLAG_CT_INIT
|
||||
|
||||
// CT counter
|
||||
struct _CT{
|
||||
uint32_t SampleRate_counter;
|
||||
uint16_t StepTimeCounter;
|
||||
uint16_t NotifyCounter;
|
||||
uint32_t StandByCounter;
|
||||
}CT = {0};
|
||||
|
||||
// GPT counter
|
||||
struct _GPT{
|
||||
uint32_t GptimerCounter;
|
||||
uint32_t GptimerCounter0;
|
||||
uint8_t DeltaGptimerCounter;
|
||||
uint32_t SampleRateCounter;
|
||||
uint32_t NotifyCounter;
|
||||
uint32_t VscanRateCounter;
|
||||
uint32_t LeadTimeCounter;
|
||||
uint32_t BatteryADCCounter;
|
||||
uint32_t BatteryCheckCounter;
|
||||
uint32_t GptimerMultiple;
|
||||
uint32_t StiCounter;
|
||||
}GPT = {0};
|
||||
|
||||
static void InitCT(){
|
||||
CT.SampleRate_counter = 1;
|
||||
CT.StepTimeCounter = 1;
|
||||
CT.NotifyCounter = 1;
|
||||
CT.StandByCounter = 0;
|
||||
}
|
||||
|
||||
static void InitGPT(){
|
||||
GPT.GptimerCounter = 0;
|
||||
GPT.GptimerCounter0 = 0;
|
||||
GPT.DeltaGptimerCounter = 0;
|
||||
GPT.SampleRateCounter = 0;
|
||||
GPT.NotifyCounter = 0;
|
||||
GPT.VscanRateCounter = 0;
|
||||
GPT.LeadTimeCounter = 0;
|
||||
GPT.BatteryADCCounter = 0;
|
||||
GPT.BatteryCheckCounter = 0;
|
||||
GPT.StiCounter = 0;
|
||||
}
|
||||
#endif
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
/* Copyright (c) 2019. BioPro. Scientific.
|
||||
*/
|
||||
#ifndef HEADSTAGE_GPTIMER_H
|
||||
#define HEADSTAGE_GPTIMER_H
|
||||
|
||||
#include <Board.h>
|
||||
#include <ti/drivers/timer/GPTimerCC26XX.h>
|
||||
#include <ti/sysbios/BIOS.h>
|
||||
#include <xdc/runtime/Types.h>
|
||||
|
||||
#define EVT_PERIODIC_GPTIMER EVT_PERIODIC_0
|
||||
|
||||
static GPTimerCC26XX_Handle gptimer_handle;
|
||||
|
||||
static void elite_gptimer_callback(GPTimerCC26XX_Handle handle, GPTimerCC26XX_IntMask interruptMask);
|
||||
|
||||
#define elite_gptimer_start() GPTimerCC26XX_start(gptimer_handle)
|
||||
#define elite_gptimer_stop() GPTimerCC26XX_stop(gptimer_handle)
|
||||
#define elite_gptimer_close() GPTimerCC26XX_close(gptimer_handle)
|
||||
#define CLOCK_FREQ 4800 // clock freq = 0.1 ms
|
||||
|
||||
#define elite_gptimer_open() \
|
||||
do { \
|
||||
GPTimerCC26XX_Params params; \
|
||||
GPTimerCC26XX_Params_init(¶ms); \
|
||||
params.width = GPT_CONFIG_16BIT; \
|
||||
params.mode = GPT_MODE_PERIODIC_DOWN; \
|
||||
params.debugStallMode = GPTimerCC26XX_DEBUG_STALL_OFF; \
|
||||
gptimer_handle = GPTimerCC26XX_open(Board_GPTIMER0A, ¶ms); \
|
||||
Types_FreqHz freq; \
|
||||
BIOS_getCpuFreq(&freq); \
|
||||
GPTimerCC26XX_Value loadVal = freq.lo / 1000 - 1; /*47999*/ \
|
||||
GPTimerCC26XX_setLoadValue(gptimer_handle, loadVal); \
|
||||
GPTimerCC26XX_setLoadValue(gptimer_handle, CLOCK_FREQ); /* 0.1 ms*/ \
|
||||
GPTimerCC26XX_registerInterrupt(gptimer_handle, elite_gptimer_callback, GPT_INT_TIMEOUT); \
|
||||
} while (0)
|
||||
|
||||
#endif // HEADSTAGE_GPTIMER_H
|
||||
+95
@@ -0,0 +1,95 @@
|
||||
|
||||
#ifndef ELITE_I2C
|
||||
#define ELITE_I2C
|
||||
|
||||
/*
|
||||
* Read I2C example in
|
||||
* http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/tirtos/2_14_02_22/
|
||||
* exports/tirtos_full_2_14_02_22/docs/doxygen/html/_i2_c_c_c26_x_x_8h.html
|
||||
*
|
||||
*/
|
||||
|
||||
#include <ti/drivers/I2C.h>
|
||||
#include <ti/drivers/Power.h>
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#include <stddef.h>
|
||||
|
||||
// I2C
|
||||
static I2C_Handle I2Chandle;
|
||||
static I2C_Params I2Cparams;
|
||||
static I2C_Transaction i2cTrans;
|
||||
|
||||
#define I2CBufSize 4
|
||||
static uint8_t I2CtxBuf[I2CBufSize]; // Transmit buffer
|
||||
static uint8_t I2CrxBuf[I2CBufSize]; // Receive buffer
|
||||
bool transferDone = false;
|
||||
|
||||
static void I2CCallbackFunction(I2C_Handle handle, I2C_Transaction *msg, bool transfer) {
|
||||
if(transfer){
|
||||
transferDone = true;
|
||||
}
|
||||
}
|
||||
|
||||
static void I2Cinit(){
|
||||
I2C_init();
|
||||
|
||||
// Configure I2C parameters.
|
||||
I2C_Params_init(&I2Cparams);
|
||||
|
||||
I2Cparams.transferMode = I2C_MODE_CALLBACK;
|
||||
I2Cparams.transferCallbackFxn = I2CCallbackFunction;
|
||||
I2Cparams.bitRate = I2C_100kHz;
|
||||
|
||||
// Initialize master I2C transaction structure
|
||||
i2cTrans.writeCount = I2CBufSize;
|
||||
i2cTrans.writeBuf = I2CtxBuf;
|
||||
i2cTrans.readCount = I2CBufSize;
|
||||
i2cTrans.readBuf = I2CrxBuf;
|
||||
i2cTrans.slaveAddress = 0xA0;
|
||||
|
||||
for(int i=0 ; i<10 ; i++){
|
||||
I2CtxBuf[i] = 0;
|
||||
I2CrxBuf[i] = 0;
|
||||
}
|
||||
|
||||
// Open I2C
|
||||
I2Chandle = I2C_open(Board_I2C, &I2Cparams);
|
||||
|
||||
}
|
||||
#define WriteMem 0b10100001
|
||||
#define ReadMem 0b10100000
|
||||
|
||||
static void I2CWrite(uint8_t addr, uint8_t data){
|
||||
for(int i=0 ; i<I2CBufSize ; i++){
|
||||
I2CtxBuf[i] = 0;
|
||||
I2CrxBuf[i] = 0;
|
||||
}
|
||||
|
||||
I2CtxBuf[0] = WriteMem;
|
||||
I2CtxBuf[1] = addr;
|
||||
I2CtxBuf[2] = data;
|
||||
|
||||
// I2Chandle = I2C_open(Board_I2C, &I2Cparams);
|
||||
I2C_transfer(I2Chandle, &i2cTrans);
|
||||
// I2C_close(I2Chandle);
|
||||
}
|
||||
|
||||
|
||||
static void I2CRead(uint8_t addr){
|
||||
for(int i=0 ; i<I2CBufSize ; i++){
|
||||
I2CtxBuf[i] = 0;
|
||||
I2CrxBuf[i] = 0;
|
||||
}
|
||||
|
||||
I2CtxBuf[0] = ReadMem;
|
||||
I2CtxBuf[1] = addr;
|
||||
|
||||
// I2Chandle = I2C_open(Board_I2C, &I2Cparams);
|
||||
I2C_transfer(I2Chandle, &i2cTrans);
|
||||
// I2C_close(I2Chandle);
|
||||
}
|
||||
|
||||
|
||||
#endif // ELITE_I2C
|
||||
|
||||
+48
@@ -0,0 +1,48 @@
|
||||
|
||||
#ifndef ELITEIV
|
||||
#define ELITEIV
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
|
||||
static void IV_Vscan(IVMode *IV){
|
||||
if(vscanReset){
|
||||
if(INSTRUCTION.directionInit == 1){
|
||||
IV->_direction_up = true;
|
||||
IV->_current_direction_up = true;
|
||||
}else if(INSTRUCTION.directionInit == 0){
|
||||
IV->_direction_up = false;
|
||||
IV->_current_direction_up = false;
|
||||
}
|
||||
|
||||
//Vsetp = x * 20 * N, x=xmV ; N=VscanRate
|
||||
if(INSTRUCTION.step <= 10){
|
||||
IV->_Vstep = INSTRUCTION.step * INSTRUCTION.VsetRate / 5;
|
||||
}else{
|
||||
IV->_Vstep = INSTRUCTION.step / 5 * INSTRUCTION.VsetRate;
|
||||
}
|
||||
|
||||
Vset = IV->_Vinit;
|
||||
}
|
||||
|
||||
if(!vscanReset){
|
||||
if(IV->_current_direction_up){
|
||||
if(Vset >= IV->_Vmax){
|
||||
PeriodicEvent = false;
|
||||
ModeLED(NO_EVENT);
|
||||
}
|
||||
}else{
|
||||
if(Vset <= IV->_Vmin){
|
||||
PeriodicEvent = false;
|
||||
ModeLED(NO_EVENT);
|
||||
}
|
||||
}
|
||||
|
||||
if (IV->_current_direction_up){
|
||||
Vset = Vset + IV->_Vstep * GPT.GptimerMultiple;
|
||||
}else{
|
||||
Vset = Vset - IV->_Vstep * GPT.GptimerMultiple;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
+193
@@ -0,0 +1,193 @@
|
||||
|
||||
#ifndef ELITEINSTRUCTION
|
||||
#define ELITEINSTRUCTION
|
||||
|
||||
/** Iin, Vin, Vout **/
|
||||
#define IIN_ADC 0x00
|
||||
#define VIN_ADC 0x01
|
||||
#define VOUT_DAC 0x02
|
||||
#define HIGH_Z 0x03
|
||||
|
||||
/** TRIG01 AOUT, DOUT, PROUT **/
|
||||
#define AOUT_ADC 0x00
|
||||
#define DOUT_ADC 0x01
|
||||
#define PR_DAC 0x02
|
||||
#define LEDtest 0x03
|
||||
#define OUT_5V_EN 0x04
|
||||
|
||||
/** ADC Iin gain level **/
|
||||
#define I_GAIN_3M 0x00 // largest gain
|
||||
#define I_GAIN_100K 0x01
|
||||
#define I_GAIN_3K 0x02
|
||||
#define I_GAIN_100R 0x03 // the least gain
|
||||
#define I_GAIN_AUTO 0x04
|
||||
|
||||
/** ADC Vin gain level **/
|
||||
#define VIN_GAIN_1M 0x00
|
||||
#define VIN_GAIN_30K 0x01
|
||||
#define VIN_GAIN_1K 0x02
|
||||
#define VIN_GAIN_AUTO 0x03
|
||||
|
||||
/** Vout gain level **/
|
||||
#define VOUT_GAIN_240K 0x00
|
||||
#define VOUT_GAIN_15K 0x01
|
||||
#define VOUT_GAIN_AUTO 0x02
|
||||
|
||||
/* DAC reset parameter */
|
||||
#define DAC_ZERO 25000
|
||||
|
||||
// Step time macro
|
||||
#define STEPTIME_HALF_SEC 5000
|
||||
#define STEPTIME_ONE_SEC 10000
|
||||
#define STEPTIME_TWO_SEC 20000
|
||||
|
||||
/*==============================
|
||||
==== headstage instruction ====
|
||||
=============================*/
|
||||
struct HEADSTAGE_INSTRUCTION {
|
||||
|
||||
uint8_t chip_id;
|
||||
uint8_t eliteFxn;
|
||||
|
||||
/** DAC parameter **/
|
||||
uint8_t VsetRateIndex;
|
||||
uint32_t VsetRate;
|
||||
int32_t Vset;
|
||||
uint16_t VoltConstant;
|
||||
uint8_t directionInit;
|
||||
uint32_t step;
|
||||
uint16_t Ve1;
|
||||
uint16_t Ve2;
|
||||
int32_t Vinit;
|
||||
int32_t Vmax;
|
||||
int32_t Vmin;
|
||||
|
||||
/** ADC parameter **/
|
||||
uint8_t sampleRateIndex;
|
||||
uint32_t sampleRate;
|
||||
uint8_t VoViSwitch;
|
||||
uint8_t AutoGainEnable;
|
||||
uint8_t VinAutoGainEnable;
|
||||
uint8_t VoutAutoGainEnable;
|
||||
uint8_t ADCGainLevel;
|
||||
// voltage output gain
|
||||
uint16_t VoutGainLevel;
|
||||
uint8_t VinADCGainLevel;
|
||||
|
||||
/** Notify parameter **/
|
||||
uint32_t notifyRate;
|
||||
|
||||
/** mode parameter **/
|
||||
uint16_t cycleNumber;
|
||||
uint8_t charge;
|
||||
int32_t constantCurrent;
|
||||
int32_t Currentmax;
|
||||
int32_t sti_v1;
|
||||
int32_t sti_v2;
|
||||
int32_t sti_v3;
|
||||
int32_t sti_v4;
|
||||
int32_t sti_v5;
|
||||
int32_t sti_v6;
|
||||
int32_t sti_v7;
|
||||
int32_t sti_t1;
|
||||
int32_t sti_t2;
|
||||
int32_t sti_t3;
|
||||
int32_t sti_t4;
|
||||
int32_t sti_t5;
|
||||
int32_t sti_t6;
|
||||
int32_t sti_t7;
|
||||
uint16_t sti_cy;
|
||||
uint16_t sti_loop;
|
||||
|
||||
uint16_t StepTime;
|
||||
|
||||
uint8_t AdcChannel;
|
||||
|
||||
/** TRIG chan **/
|
||||
bool tri_pr0;
|
||||
bool tri_d0;
|
||||
bool tri_a0;
|
||||
bool tri_a2;
|
||||
bool tri_a3;
|
||||
bool tri_a1;
|
||||
bool tri_d1;
|
||||
bool tri_pr1;
|
||||
bool output_5v_en0;
|
||||
bool output_5v_en1;
|
||||
|
||||
/** trigger mode enable **/
|
||||
bool trig0_en;
|
||||
bool trig1_en;
|
||||
|
||||
} INSTRUCTION = {0};
|
||||
|
||||
/*********************************************************************
|
||||
* @fn InitEliteInstruction
|
||||
*
|
||||
* @brief Init all INSTRUCTION variable.
|
||||
*
|
||||
* @param None.
|
||||
*
|
||||
* @return None.
|
||||
*/
|
||||
static void InitEliteInstruction(){
|
||||
INSTRUCTION.chip_id = 0;
|
||||
INSTRUCTION.eliteFxn = 0; //default is a null event
|
||||
INSTRUCTION.VsetRateIndex = 0;
|
||||
INSTRUCTION.VsetRate = 2;
|
||||
INSTRUCTION.Vset = 0;
|
||||
INSTRUCTION.VoltConstant = DAC_ZERO; //DAC_ZERO is about 0V
|
||||
INSTRUCTION.directionInit = 1; //0:reverse 1:forward
|
||||
INSTRUCTION.step = 0;
|
||||
INSTRUCTION.Ve1 = DAC_ZERO;
|
||||
INSTRUCTION.Ve2 = DAC_ZERO;
|
||||
INSTRUCTION.Vinit = 0;
|
||||
INSTRUCTION.Vmax = 0;
|
||||
INSTRUCTION.Vmin = 0;
|
||||
INSTRUCTION.sampleRateIndex = 1;
|
||||
INSTRUCTION.sampleRate = 100;
|
||||
INSTRUCTION.VoViSwitch = 0x01; //0:user see Vo 1: user see Vi
|
||||
INSTRUCTION.AutoGainEnable = 1;
|
||||
INSTRUCTION.VinAutoGainEnable = 1;
|
||||
INSTRUCTION.VoutAutoGainEnable = 1;
|
||||
INSTRUCTION.ADCGainLevel = I_GAIN_AUTO;
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_AUTO;
|
||||
INSTRUCTION.VinADCGainLevel = VIN_GAIN_AUTO;
|
||||
INSTRUCTION.notifyRate = STEPTIME_ONE_SEC;
|
||||
INSTRUCTION.cycleNumber = 1;
|
||||
INSTRUCTION.charge = 1; //0:discharge 1:charge
|
||||
INSTRUCTION.constantCurrent = 0;
|
||||
INSTRUCTION.Currentmax = 0;
|
||||
INSTRUCTION.StepTime = STEPTIME_ONE_SEC;
|
||||
INSTRUCTION.AdcChannel = 0;
|
||||
|
||||
//pulse mode
|
||||
INSTRUCTION.sti_t1 = 0;
|
||||
INSTRUCTION.sti_t2 = 0;
|
||||
INSTRUCTION.sti_t3 = 0;
|
||||
INSTRUCTION.sti_t4 = 0;
|
||||
INSTRUCTION.sti_t5 = 0;
|
||||
INSTRUCTION.sti_t6 = 0;
|
||||
INSTRUCTION.sti_t7 = 0;
|
||||
INSTRUCTION.sti_v1 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v2 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v3 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v4 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v5 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v6 = DAC_ZERO;
|
||||
INSTRUCTION.sti_v7 = DAC_ZERO;
|
||||
INSTRUCTION.sti_loop = 1;
|
||||
INSTRUCTION.sti_cy = 0;
|
||||
|
||||
INSTRUCTION.tri_pr0 = 0;
|
||||
INSTRUCTION.tri_pr1 = 0;
|
||||
INSTRUCTION.tri_a0 = 0;
|
||||
INSTRUCTION.tri_a1 = 0;
|
||||
INSTRUCTION.tri_a2 = 0;
|
||||
INSTRUCTION.tri_a3 = 0;
|
||||
INSTRUCTION.tri_d0 = 0;
|
||||
INSTRUCTION.tri_d1 = 0;
|
||||
INSTRUCTION.output_5v_en0 = 1; // 1 => disable
|
||||
INSTRUCTION.output_5v_en1 = 1; // 1 => disable
|
||||
}
|
||||
#endif
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
|
||||
#ifndef ELITEKEYDETECT
|
||||
#define ELITEKEYDETECT
|
||||
|
||||
static bool TurnOnElite(uint8_t key) {
|
||||
static uint16_t TurnOnCounter = 0;
|
||||
|
||||
if (key == 0) {
|
||||
// press 1 sec, power on LED, read bat power
|
||||
if (TurnOnCounter >= CLOCK_ONE_SECOND) {
|
||||
headstage_battery_volt();
|
||||
uint16_t bat = ((uint16_t)(NotifyVoltBat[2]) << 8 & 0xFF00 ) |
|
||||
((uint16_t)(NotifyVoltBat[3]) & 0x00FF);
|
||||
if( bat < 768 && bat > 20){
|
||||
PIN15_setOutputValue(enable_5v, 0);
|
||||
return false;
|
||||
}else{
|
||||
PIN15_setOutputValue(enable_5v, 1); // enable 5V
|
||||
TurnOn10V();
|
||||
ModeLED(BT_WAIT);
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
TurnOnCounter++;
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
TurnOnCounter = 0;
|
||||
PIN15_setOutputValue(enable_5v, 0); // disable 5V
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
static void EliteKeyPress(uint8_t key) {
|
||||
static uint16_t ShutDownCounter = 0;
|
||||
static uint8_t OriginEliteFxn = 0;
|
||||
|
||||
if (key == 0) {
|
||||
// key = 0 if press
|
||||
// press key => bight LED
|
||||
|
||||
if (ShutDownCounter == CLOCK_ONE_SECOND) {
|
||||
KEYLED();
|
||||
}
|
||||
|
||||
// press 3~4 sec, shutdown 2650
|
||||
else if (ShutDownCounter > (CLOCK_ONE_SECOND*3) ) {
|
||||
LED_color(DARKLED, 0xFF, 0xFF, 0x00);
|
||||
PIN15_setOutputValue(enable_5v, 0); // disable 5V
|
||||
}
|
||||
ShutDownCounter ++;
|
||||
} else {
|
||||
if (OriginEliteFxn == INSTRUCTION.eliteFxn) { // old function == currunt instruction
|
||||
if (ShutDownCounter != 0) {
|
||||
// dark LED
|
||||
checkFlafLED();
|
||||
ShutDownCounter = 0;
|
||||
}
|
||||
} else { // old function != currunt instruction
|
||||
OriginEliteFxn = INSTRUCTION.eliteFxn;
|
||||
if (ShutDownCounter != 0) {
|
||||
ShutDownCounter = 0;
|
||||
}
|
||||
checkFlafLED();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void TurnOn10V() {
|
||||
If10Von = true;
|
||||
// PIN15_setOutputValue(enable_10v, 1);
|
||||
CPUdelay(8000);
|
||||
}
|
||||
|
||||
#endif
|
||||
+427
@@ -0,0 +1,427 @@
|
||||
|
||||
#ifndef ELITELED
|
||||
#define ELITELED
|
||||
|
||||
#define DARKLED 0xE1
|
||||
#define LIGHTLED 0xE8
|
||||
|
||||
/* Channels for TRIG01 LED notation */
|
||||
#define LED_PR0 0x00
|
||||
#define LED_D0 0x01
|
||||
#define LED_A0 0x02
|
||||
#define LED_A2 0x03
|
||||
#define LED_A3 0x04
|
||||
#define LED_A1 0x05
|
||||
#define LED_D1 0x06
|
||||
#define LED_PR1 0x07
|
||||
|
||||
static void WorkModeLED();
|
||||
static void update_LED_status (uint8_t chan, uint8_t bright, uint8_t red, uint8_t green, uint8_t blue);
|
||||
static void SET_LED_CHAN(bool *chan_en, uint16_t modeStatus);
|
||||
static void refresh_LED();
|
||||
|
||||
static void LED_color(uint8_t bright, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
spi_LEDtxbuf[0] = 0x0000;
|
||||
spi_LEDtxbuf[1] = 0x0000;
|
||||
for (int i = 2; i < SPI_LED_SIZE - 2; i += 2) {
|
||||
spi_LEDtxbuf[i] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
spi_LEDtxbuf[i + 1] = ((uint16_t)green << 8) | red;
|
||||
}
|
||||
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 2] = 0xffff;
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 1] = 0xffff;
|
||||
|
||||
LED_SPI(SPI_LED_SIZE, spi_LEDtxbuf, spi_LEDrxbuf);
|
||||
}
|
||||
|
||||
static void Elite_led_color(uint16_t color){
|
||||
switch (color) {
|
||||
case COLOR_RED: {
|
||||
LED_color(DARKLED, 0xFF, 0x00, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_ORANGE: {
|
||||
LED_color(DARKLED, 0xFF, 0x58, 0x09);
|
||||
break;
|
||||
}
|
||||
case COLOR_YELLOW: {
|
||||
LED_color(LIGHTLED, 0xFF, 0x80, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_GREEN: {
|
||||
LED_color(DARKLED, 0x00, 0xFA, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_YELLOWGREEN: {
|
||||
LED_color(DARKLED, 0x64, 0xA6, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLUE: {
|
||||
LED_color(DARKLED, 0x00, 0x00, 0xAA);
|
||||
break;
|
||||
}
|
||||
case COLOR_CYAN: {
|
||||
LED_color(DARKLED, 0x00, 0x40, 0x40);
|
||||
break;
|
||||
}
|
||||
case COLOR_MAGENTA: {
|
||||
LED_color(DARKLED, 0xFF, 0x00, 0x80);
|
||||
break;
|
||||
}
|
||||
case COLOR_PURPLE: {
|
||||
LED_color(DARKLED, 0xFF, 0x00, 0xFF);
|
||||
break;
|
||||
}
|
||||
case COLOR_WHITE: {
|
||||
LED_color(DARKLED, 0xCA, 0xFF, 0xFF);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLACK: {
|
||||
LED_color(0x00, 0x00, 0x00, 0x00);
|
||||
break;
|
||||
}
|
||||
//dark LED
|
||||
case COLOR_YELLOW_DARK: {
|
||||
LED_color(DARKLED, 0xFF, 0x80, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_GREEN_DARK: {
|
||||
LED_color(DARKLED, 0x00, 0x33, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLUE_DARK: {
|
||||
LED_color(DARKLED, 0x00, 0x00, 0x33);
|
||||
break;
|
||||
}
|
||||
case COLOR_CYAN_DARK: {
|
||||
LED_color(DARKLED, 0x00, 0x10, 0x10);
|
||||
break;
|
||||
}
|
||||
case COLOR_PURPLE_DARK: {
|
||||
LED_color(DARKLED, 0x55, 0x00, 0x55);
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void Elite_chan_led_color(uint16_t color, uint8_t chan) {
|
||||
switch (color) {
|
||||
case COLOR_RED: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x00, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_ORANGE: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x58, 0x09);
|
||||
break;
|
||||
}
|
||||
case COLOR_YELLOW: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x80, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_GREEN: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0xFA, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_YELLOWGREEN: {
|
||||
update_LED_status(chan, DARKLED, 0x64, 0xA6, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLUE: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0x00, 0xAA);
|
||||
break;
|
||||
}
|
||||
case COLOR_CYAN: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0x40, 0x40);
|
||||
break;
|
||||
}
|
||||
case COLOR_MAGENTA: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x00, 0x80);
|
||||
break;
|
||||
}
|
||||
case COLOR_PURPLE: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x00, 0xFF);
|
||||
break;
|
||||
}
|
||||
case COLOR_WHITE: {
|
||||
update_LED_status(chan, DARKLED, 0xCA, 0xFF, 0xFF);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLACK: {
|
||||
update_LED_status(chan, 0x00, 0x00, 0x00, 0x00);
|
||||
break;
|
||||
}
|
||||
//dark LED
|
||||
case COLOR_YELLOW_DARK: {
|
||||
update_LED_status(chan, DARKLED, 0xFF, 0x80, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_GREEN_DARK: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0x33, 0x00);
|
||||
break;
|
||||
}
|
||||
case COLOR_BLUE_DARK: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0x00, 0x33);
|
||||
break;
|
||||
}
|
||||
case COLOR_CYAN_DARK: {
|
||||
update_LED_status(chan, DARKLED, 0x00, 0x10, 0x10);
|
||||
break;
|
||||
}
|
||||
case COLOR_PURPLE_DARK: {
|
||||
update_LED_status(chan, DARKLED, 0x55, 0x00, 0x55);
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
// refresh_LED();
|
||||
}
|
||||
}
|
||||
|
||||
static void ModeLED(uint16_t modeStatus) {
|
||||
btWaitLedFlag = 0;
|
||||
noEventLedFlag = 0;
|
||||
preWorkLedFlag = 0;
|
||||
workingLedFlag = 0;
|
||||
postWorkLedFlag = 0;
|
||||
TRIG01workFlag = 0;
|
||||
|
||||
switch (modeStatus) {
|
||||
case BT_WAIT: {
|
||||
btWaitLedFlag = 1;
|
||||
BT_WAIT_LED();
|
||||
break;
|
||||
}
|
||||
case NO_EVENT: {
|
||||
noEventLedFlag = 1;
|
||||
LEDPowerON();
|
||||
break;
|
||||
}
|
||||
case PRE_WORK: {
|
||||
preWorkLedFlag = 1;
|
||||
Elite_led_color(COLOR_BLUE);
|
||||
break;
|
||||
}
|
||||
case WORKING: {
|
||||
workingLedFlag = 1;
|
||||
WorkModeLED();
|
||||
break;
|
||||
}
|
||||
case POST_WORK: {
|
||||
postWorkLedFlag = 1;
|
||||
Elite_led_color(COLOR_BLUE);
|
||||
break;
|
||||
}
|
||||
case TRIG01_WORK: {
|
||||
TRIG01workFlag = 1;
|
||||
WorkModeLED();
|
||||
refresh_LED();
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
LEDPowerON();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void checkFlafLED() {
|
||||
if(btWaitLedFlag == 1){
|
||||
ModeLED(BT_WAIT);
|
||||
}
|
||||
else if(noEventLedFlag == 1){
|
||||
ModeLED(NO_EVENT);
|
||||
}
|
||||
else if(preWorkLedFlag == 1){
|
||||
ModeLED(PRE_WORK);
|
||||
}
|
||||
else if(workingLedFlag == 1){
|
||||
ModeLED(WORKING);
|
||||
}
|
||||
else if(postWorkLedFlag == 1){
|
||||
ModeLED(POST_WORK);
|
||||
}
|
||||
else if(TRIG01workFlag == 1){
|
||||
ModeLED(TRIG01_WORK);
|
||||
}
|
||||
}
|
||||
|
||||
static void WorkModeLED() {
|
||||
switch (INSTRUCTION.eliteFxn) {
|
||||
case IV_CURVE:
|
||||
case CV_CURVE:
|
||||
case DIFFERENTIAL_PULSE_VOLTAMMETRY:
|
||||
case SQUARE_WAVE_VOLTAMMETRY:
|
||||
case VOLT_OUTPUT:
|
||||
case ZT_CURVE:
|
||||
case VT_CURVE:
|
||||
case IT_CURVE:
|
||||
case ADC_TEST:{
|
||||
SET_LED_CHAN(TRC.chan_en, WORKING);
|
||||
break;
|
||||
}
|
||||
case CYCLIC_VOLTAMMETRY:
|
||||
case LINEAR_SWEEP_VOLTAMMETRY:
|
||||
case CONSTANT_VSCAN:{
|
||||
WORKLED();
|
||||
break;
|
||||
}
|
||||
case PULSE_MODE:{
|
||||
// Elite_led_color(COLOR_YELLOW);
|
||||
WORKLED();
|
||||
break;
|
||||
}
|
||||
case CONSTANT_CURRENT:{
|
||||
WORKLED();
|
||||
break;
|
||||
}
|
||||
case CALI_ADC_MODE:{
|
||||
if(INSTRUCTION.AdcChannel == IIN_ADC){
|
||||
Elite_led_color(COLOR_RED);
|
||||
}else if(INSTRUCTION.AdcChannel == VIN_ADC){
|
||||
Elite_led_color(COLOR_ORANGE);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
// case VIS_RST: {
|
||||
// LEDPowerON();
|
||||
// break;
|
||||
// }
|
||||
default: {
|
||||
WORKLED();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void LED_channel_write(uint8_t chan, uint8_t bright, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
update_LED_status(chan, bright, red, green, blue);
|
||||
refresh_LED();
|
||||
}
|
||||
|
||||
static void update_LED_status (uint8_t chan, uint8_t bright, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
switch(chan) {
|
||||
case LED_PR0: {
|
||||
LED.LED_buf[2] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[3] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_D0: {
|
||||
LED.LED_buf[4] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[5] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_A0: {
|
||||
LED.LED_buf[6] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[7] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_A2: {
|
||||
LED.LED_buf[8] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[9] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_A3: {
|
||||
LED.LED_buf[10] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[11] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_A1: {
|
||||
LED.LED_buf[12] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[13] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_D1: {
|
||||
LED.LED_buf[14] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[15] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
case LED_PR1: {
|
||||
LED.LED_buf[16] = 0xE000 | ((uint16_t)bright << 8) | blue;
|
||||
LED.LED_buf[17] = ((uint16_t)green << 8) | red;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
static void refresh_LED() {
|
||||
spi_LEDtxbuf[0] = 0x0000;
|
||||
spi_LEDtxbuf[1] = 0x0000;
|
||||
|
||||
for (int i = 2; i < SPI_LED_SIZE - 2; i += 2) {
|
||||
spi_LEDtxbuf[i] = LED.LED_buf[i];
|
||||
spi_LEDtxbuf[i+1] = LED.LED_buf[i+1];
|
||||
}
|
||||
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 2] = 0xffff;
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 1] = 0xffff;
|
||||
|
||||
LED_SPI(SPI_LED_SIZE, spi_LEDtxbuf, spi_LEDrxbuf);
|
||||
}
|
||||
static void TRIG_LED_Init() {
|
||||
spi_LEDtxbuf[0] = 0x0000;
|
||||
spi_LEDtxbuf[1] = 0x0000;
|
||||
|
||||
for (int i = 2; i < SPI_LED_SIZE - 2; i += 2) {
|
||||
spi_LEDtxbuf[i] = 0xE000;
|
||||
spi_LEDtxbuf[i+1] = 0x0000;
|
||||
}
|
||||
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 2] = 0xffff;
|
||||
spi_LEDtxbuf[SPI_LED_SIZE - 1] = 0xffff;
|
||||
|
||||
LED_SPI(SPI_LED_SIZE, spi_LEDtxbuf, spi_LEDrxbuf);
|
||||
}
|
||||
|
||||
static void SET_LED_CHAN(bool *chan_en, uint16_t modeStatus){
|
||||
uint8_t ledcolor = 0;
|
||||
switch(modeStatus) {
|
||||
case NO_EVENT:{
|
||||
ledcolor = COLOR_GREEN;
|
||||
break;
|
||||
}
|
||||
case WORKING:{
|
||||
ledcolor = COLOR_CYAN;
|
||||
break;
|
||||
}
|
||||
default:{
|
||||
ledcolor = COLOR_GREEN;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
uint8_t trig_chan = 0;
|
||||
for (int i=0; i<TRIG_CHAN_COUNT-2; i++) {
|
||||
trig_chan = (uint8_t) (i);
|
||||
if(TRC.chan_en[i]) {
|
||||
Elite_chan_led_color(ledcolor, trig_chan);
|
||||
} else {
|
||||
Elite_chan_led_color(COLOR_BLACK, trig_chan);
|
||||
}
|
||||
}
|
||||
if(!TRC.chan_en[8]) {
|
||||
Elite_chan_led_color(COLOR_PURPLE_DARK, LED_D0);
|
||||
} else if(TRC.chan_en[1]) {
|
||||
Elite_chan_led_color(ledcolor, LED_D0);
|
||||
} else {
|
||||
Elite_chan_led_color(COLOR_BLACK, LED_D0); // determine DOUT on or off
|
||||
}
|
||||
if(!TRC.chan_en[9]) {
|
||||
Elite_chan_led_color(COLOR_PURPLE_DARK, LED_D1);
|
||||
} else if(TRC.chan_en[6]) {
|
||||
Elite_chan_led_color(ledcolor, LED_D1);
|
||||
} else {
|
||||
Elite_chan_led_color(COLOR_BLACK, LED_D1);
|
||||
}
|
||||
refresh_LED();
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
|
||||
#ifndef ELITE_LED_INIT
|
||||
#define ELITE_LED_INIT
|
||||
|
||||
static void InitLED() {
|
||||
for (int i = 2; i < SPI_LED_SIZE - 2; i += 2) {
|
||||
LED.LED_buf[i] = 0xE000;
|
||||
LED.LED_buf[i+1] = 0x0000;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
+98
@@ -0,0 +1,98 @@
|
||||
#ifndef ELITELSV
|
||||
#define ELITELSV
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
|
||||
static uint16_t LSVCurve(LSVMode *LSV){
|
||||
static uint16_t DACOutCode;
|
||||
static int32_t Vin;
|
||||
static int32_t Vout;
|
||||
static int32_t DeltaVout;
|
||||
|
||||
Vin = LSV->_measureVin * 200;//[5nV]
|
||||
if(DACReset){
|
||||
Vout = Vset + Vin;
|
||||
DACReset = false;
|
||||
}else{
|
||||
DeltaVout = Vset - (Vout - Vin);
|
||||
Vout = Vout + DeltaVout;
|
||||
}
|
||||
|
||||
INSTRUCTION.VoltConstant = Vout / 40000 + 25000;//5nV=>usercode
|
||||
DACOutCode = Usercode_Correction_to_DAC(INSTRUCTION.VoutGainLevel, INSTRUCTION.VoltConstant);
|
||||
|
||||
int32_t RealV2;
|
||||
RealV2 = (int32_t)((Vout - Vin) / 200);//[1uV]
|
||||
InputNotify(NOTIFY_VOLT, RealV2);
|
||||
|
||||
int32_t RealV;
|
||||
RealV = (int32_t)(Vout / 200);//[1uV]
|
||||
InputNotify(NOTIFY_IMPEDANCE, RealV);
|
||||
|
||||
DAC_outputV(DACOutCode);
|
||||
//
|
||||
return DACOutCode;
|
||||
}
|
||||
|
||||
static void LSV_Vscan(LSVMode *LSV){
|
||||
|
||||
NotifyCycleNumber = (INSTRUCTION.cycleNumber - LSV->_cycleNumber + 1);
|
||||
|
||||
if(vscanReset){
|
||||
if(INSTRUCTION.directionInit == 1){
|
||||
LSV->_direction_up = true;
|
||||
LSV->_current_direction_up = true;
|
||||
}else{
|
||||
LSV->_direction_up = false;
|
||||
LSV->_current_direction_up = false;
|
||||
}
|
||||
|
||||
//Vsetp = x * 20 * N, x=xmV ; N=VscanRate
|
||||
if(INSTRUCTION.step <= 10){
|
||||
LSV->_Vstep = INSTRUCTION.step * INSTRUCTION.VsetRate / 5;
|
||||
}else{
|
||||
LSV->_Vstep = INSTRUCTION.step / 5 * INSTRUCTION.VsetRate;
|
||||
}
|
||||
|
||||
Vset = LSV->_Vinit;
|
||||
}
|
||||
|
||||
if(!vscanReset){
|
||||
|
||||
if (LSV->_current_direction_up){
|
||||
Vset = Vset + LSV->_Vstep * GPT.GptimerMultiple;
|
||||
}else{
|
||||
Vset = Vset - LSV->_Vstep * GPT.GptimerMultiple;
|
||||
}
|
||||
|
||||
/*stop condition*/
|
||||
if (Vset >= LSV->_Vmax){
|
||||
ModeLED(POST_WORK);
|
||||
// PeriodicEvent = false;
|
||||
Vset = LSV->_Vmin;
|
||||
InitEliteFlag();
|
||||
INSTRUCTION.eliteFxn = CONSTANT_CURRENT;
|
||||
INSTRUCTION.sampleRate = 15;
|
||||
INSTRUCTION.charge = 0x01;
|
||||
INSTRUCTION.constantCurrent = 0x00;
|
||||
INSTRUCTION.Vmax = 0xC350;
|
||||
INSTRUCTION.Vmin = 0x0000;
|
||||
INSTRUCTION.notifyRate = 500;
|
||||
INSTRUCTION.VoViSwitch = 0x02;//read Vscan = Vout - Vin
|
||||
}else if (Vset <= LSV->_Vmin){
|
||||
ModeLED(POST_WORK);
|
||||
// PeriodicEvent = false;
|
||||
Vset = LSV->_Vmax;
|
||||
InitEliteFlag();
|
||||
INSTRUCTION.eliteFxn = CONSTANT_CURRENT;
|
||||
INSTRUCTION.sampleRate = 15;
|
||||
INSTRUCTION.charge = 0x01;
|
||||
INSTRUCTION.constantCurrent = 0x00;
|
||||
INSTRUCTION.Vmax = 0xC350;
|
||||
INSTRUCTION.Vmin = 0x0000;
|
||||
INSTRUCTION.notifyRate = 500;
|
||||
INSTRUCTION.VoViSwitch = 0x02;//read Vscan = Vout - Vin
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
|
||||
#ifndef ELITE_LATCH_INIT
|
||||
#define ELITE_LATCH_INIT
|
||||
|
||||
static void InitLH() {
|
||||
for (int i=0; i<LATCH_BUFF_SIZE; i++) {
|
||||
LH.LATCH0[i] = 0;
|
||||
LH.LATCH1[i] = 0;
|
||||
LH.LATCH2[i] = 0;
|
||||
}
|
||||
LH.LoadState = 0;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
+188
@@ -0,0 +1,188 @@
|
||||
/**
|
||||
* notify data buffer.
|
||||
* the length equals to the characteristic 4 which value is 20 bytes.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef ELITENOTIFY
|
||||
#define ELITENOTIFY
|
||||
|
||||
#include "headstage.h"
|
||||
|
||||
/*notify's input type*/
|
||||
#define NOTIFY_CURRENT 0
|
||||
#define NOTIFY_VOLT 1
|
||||
#define NOTIFY_IMPEDANCE 2
|
||||
#define NOTIFY_VOLT_BAT 3
|
||||
|
||||
#define NOT_BUF_OFFSET_INIT 8
|
||||
|
||||
/**
|
||||
* the index where to start insert data into buffer.
|
||||
* start from 6.
|
||||
*/
|
||||
static size_t not_buf_offset = NOT_BUF_OFFSET_INIT;
|
||||
static uint32_t not_time_stamp;
|
||||
|
||||
static uint8_t NotifyCurrent[4] = {0};
|
||||
static uint8_t NotifyVolt[4] = {0};
|
||||
static uint8_t NotifyImpedance[4] = {0};
|
||||
static uint8_t NotifyVoltBat[4] = {0};
|
||||
static uint16_t NotifyCycleNumber = 0;
|
||||
|
||||
// ****************** New Notify Format ******************************** //
|
||||
/*
|
||||
* Notify format
|
||||
*
|
||||
*
|
||||
| | 1 | 2 | 3 |
|
||||
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
|
||||
-----------------------------------------------------------------
|
||||
| header |
|
||||
| current |
|
||||
| voltage or impedance |
|
||||
| mode & gain |
|
||||
| time stamp |
|
||||
| cycle number |
|
||||
|
||||
|
||||
mode & gain
|
||||
this byte include Elite working mode and ADC gain level
|
||||
we use "(mode & 0xF0) | (gain & 0x0F)" to encode these two information
|
||||
|
||||
cycle number
|
||||
for cyclic voltammetry use, we save it as channel number.
|
||||
0xFF
|
||||
|
||||
* header = device ID
|
||||
* I = current (0.001nA), V = voltage (mV),
|
||||
* Z = impedance (k ohm), T = time (ms)
|
||||
*
|
||||
*
|
||||
*/
|
||||
// ********* End New Format Notify ***************************************** //
|
||||
|
||||
/*
|
||||
* Notify format
|
||||
*
|
||||
*
|
||||
| | 1 | 2 | 3 |
|
||||
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
|
||||
-----------------------------------------------------------------
|
||||
| header |
|
||||
| current |
|
||||
| voltage |
|
||||
| impedance |
|
||||
| time stamp |
|
||||
| cycle number |
|
||||
|
||||
cycle number
|
||||
for cyclic voltammetry use, we save it as channel number.
|
||||
0xFF
|
||||
|
||||
* header = device ID
|
||||
* I = current (nA), V = voltage (uV),
|
||||
* Z = impedance (ohm), T = time (ms)
|
||||
*
|
||||
*
|
||||
*/
|
||||
static void SendNotify() {
|
||||
initDATBuf();
|
||||
|
||||
not_buf[0] = INSTRUCTION.chip_id;
|
||||
|
||||
for (int i = 0; i < 4; i++) {
|
||||
not_buf[i + 1] = NotifyCurrent[i];
|
||||
not_buf[i + 5] = NotifyVolt[i];
|
||||
not_buf[i + 9] = NotifyImpedance[i];
|
||||
}
|
||||
|
||||
// 1 Timestamp = 32 usec; 31 Timestamp ~= 1 msec
|
||||
not_time_stamp = (Timestamp_get32()) / 31; // msec
|
||||
|
||||
not_buf[13] = not_time_stamp & 0xff;
|
||||
not_buf[14] = (not_time_stamp >> 8) & 0xff;
|
||||
not_buf[15] = (not_time_stamp >> 16) & 0xff;
|
||||
not_buf[16] = (not_time_stamp >> 24) & 0xff;
|
||||
|
||||
not_buf[17] = (NotifyCycleNumber >> 8) & 0xff;
|
||||
not_buf[18] = NotifyCycleNumber & 0xff;
|
||||
|
||||
for (int i = 19; i < BLE_DAT_BUFF_SIZE; i++){
|
||||
not_buf[i] = 0;
|
||||
}
|
||||
|
||||
SimpleProfile_SetParameter(BLE_DAT_BUFF_CHAR, BLE_DAT_BUFF_SIZE, not_buf);
|
||||
}
|
||||
|
||||
static void initDATBuf(){
|
||||
for (int i = 0; i < BLE_DAT_BUFF_SIZE; i++){
|
||||
not_buf[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
static void initINSBuf(){
|
||||
for (int i = 0; i < BLE_INS_BUFF_SIZE; i++){
|
||||
ins_buf[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
static void initCISBuf(){
|
||||
for (int i = 0; i < BLE_CIS_BUFF_SIZE; i++){
|
||||
cis_buf[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
static void initRawDataBuf(){
|
||||
not_time_stamp = 0;
|
||||
NotifyCycleNumber = 0;
|
||||
|
||||
for (int i = 0; i < 4; i++){
|
||||
NotifyCurrent[i] = 0;
|
||||
NotifyVolt[i] = 0;
|
||||
NotifyImpedance[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
static void FlushNotify(){
|
||||
initRawDataBuf();
|
||||
initDATBuf();
|
||||
|
||||
not_buf[0] = INSTRUCTION.chip_id;
|
||||
|
||||
SimpleProfile_SetParameter(BLE_DAT_BUFF_CHAR, BLE_DAT_BUFF_SIZE, not_buf);
|
||||
}
|
||||
|
||||
static void InputNotify(int NotifyType, int32_t Data){
|
||||
|
||||
switch (NotifyType) {
|
||||
case NOTIFY_CURRENT:
|
||||
NotifyCurrent[0] = (uint8_t)((Data & 0xFF000000) >> 24);
|
||||
NotifyCurrent[1] = (uint8_t)((Data & 0x00FF0000) >> 16);
|
||||
NotifyCurrent[2] = (uint8_t)((Data & 0x0000FF00) >> 8);
|
||||
NotifyCurrent[3] = (uint8_t)(Data & 0x000000FF);
|
||||
break;
|
||||
|
||||
case NOTIFY_IMPEDANCE:
|
||||
NotifyImpedance[0] = (uint8_t)((Data & 0xFF000000) >> 24);
|
||||
NotifyImpedance[1] = (uint8_t)((Data & 0x00FF0000) >> 16);
|
||||
NotifyImpedance[2] = (uint8_t)((Data & 0x0000FF00) >> 8);
|
||||
NotifyImpedance[3] = (uint8_t)(Data & 0x000000FF);
|
||||
break;
|
||||
|
||||
case NOTIFY_VOLT :
|
||||
NotifyVolt[0] = (uint8_t)((Data & 0xFF000000) >> 24);
|
||||
NotifyVolt[1] = (uint8_t)((Data & 0x00FF0000) >> 16);
|
||||
NotifyVolt[2] = (uint8_t)((Data & 0x0000FF00) >> 8);
|
||||
NotifyVolt[3] = (uint8_t)(Data & 0x000000FF);
|
||||
break;
|
||||
|
||||
case NOTIFY_VOLT_BAT :
|
||||
NotifyVoltBat[0] = (uint8_t)((Data & 0xFF000000) >> 24);
|
||||
NotifyVoltBat[1] = (uint8_t)((Data & 0x00FF0000) >> 16);
|
||||
NotifyVoltBat[2] = (uint8_t)((Data & 0x0000FF00) >> 8);
|
||||
NotifyVoltBat[3] = (uint8_t)(Data & 0x000000FF);
|
||||
break;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+112
@@ -0,0 +1,112 @@
|
||||
#ifndef ELITEPULSE
|
||||
#define ELITEPULSE
|
||||
|
||||
#define Vset INSTRUCTION.Vset
|
||||
|
||||
static void PULSE_Vscan(PULSEMode *PULSE)
|
||||
{
|
||||
static uint16_t lastVolt;
|
||||
if (stiFirstTime) {
|
||||
stiFirstTime = false;
|
||||
lastVolt = 25000;
|
||||
PULSE->_sti_t_flag = 1;
|
||||
PULSE->_sti_v = PULSE->_sti_v1;
|
||||
PULSE->_sti_t = PULSE->_sti_t1;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else if(!stiFirstTime) {
|
||||
if (GPT.StiCounter >= PULSE->_sti_t) {
|
||||
GPT.StiCounter -= PULSE->_sti_t; //to get right time
|
||||
|
||||
if (PULSE->_sti_lp > 0) {
|
||||
if (PULSE->_sti_cy > 0) {
|
||||
if (PULSE->_sti_t_flag == 1) {
|
||||
PULSE->_sti_t_flag = 2;
|
||||
PULSE->_sti_v = PULSE->_sti_v2;
|
||||
PULSE->_sti_t = PULSE->_sti_t2;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else if (PULSE->_sti_t_flag == 2) {
|
||||
PULSE->_sti_t_flag = 3;
|
||||
PULSE->_sti_v = PULSE->_sti_v3;
|
||||
PULSE->_sti_t = PULSE->_sti_t3;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else if (PULSE->_sti_t_flag == 3) {
|
||||
PULSE->_sti_cy -- ;
|
||||
if (PULSE->_sti_cy == 0) {
|
||||
PULSE->_sti_t_flag = 4;
|
||||
PULSE->_sti_v = PULSE->_sti_v4;
|
||||
PULSE->_sti_t = PULSE->_sti_t4;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else {
|
||||
PULSE->_sti_t_flag = 2;
|
||||
PULSE->_sti_v = PULSE->_sti_v2;
|
||||
PULSE->_sti_t = PULSE->_sti_t2;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (PULSE->_sti_cy <= 0){
|
||||
if (PULSE->_sti_t_flag == 4) {
|
||||
PULSE->_sti_lp -- ;
|
||||
if (PULSE->_sti_lp > 0) {
|
||||
PULSE->_sti_cy = INSTRUCTION.sti_cy;
|
||||
PULSE->_sti_t_flag = 2;
|
||||
PULSE->_sti_v = PULSE->_sti_v2;
|
||||
PULSE->_sti_t = PULSE->_sti_t2;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else {
|
||||
PULSE->_sti_t_flag = 5;
|
||||
PULSE->_sti_v = PULSE->_sti_v5;
|
||||
PULSE->_sti_t = PULSE->_sti_t5;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (PULSE->_sti_lp <= 0) {
|
||||
if (PULSE->_sti_t_flag == 5) {
|
||||
PULSE->_sti_t_flag = 6;
|
||||
PULSE->_sti_v = PULSE->_sti_v6;
|
||||
PULSE->_sti_t = PULSE->_sti_t6;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else if (PULSE->_sti_t_flag == 6) {
|
||||
PULSE->_sti_t_flag = 7;
|
||||
PULSE->_sti_v = PULSE->_sti_v7;
|
||||
PULSE->_sti_t = PULSE->_sti_t7;
|
||||
if (PULSE->_sti_t == 1) {
|
||||
PULSE->_sti_v = lastVolt;
|
||||
}
|
||||
} else if (PULSE->_sti_t_flag == 7) {
|
||||
PULSE->_sti_v = 25000;
|
||||
PeriodicEvent = false;
|
||||
ModeLED(NO_EVENT);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (lastVolt != PULSE->_sti_v) {
|
||||
lastVolt = PULSE->_sti_v;
|
||||
//if (PULSE->_sti_v == 25000) {
|
||||
// PIN15_setOutputValue(HIGH_Z_MODE, 0); // 1 => close high_z mode
|
||||
//} else {
|
||||
// PIN15_setOutputValue(HIGH_Z_MODE, 1); // 1 => close high_z mode
|
||||
//}
|
||||
DAC_outputV(Usercode_Correction_to_DAC(VOUT_GAIN_240K, PULSE->_sti_v));
|
||||
DAC_outputV(Usercode_Correction_to_DAC(VOUT_GAIN_240K, PULSE->_sti_v));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
|
||||
#ifndef ELITERESET
|
||||
#define ELITERESET
|
||||
|
||||
static void reset() {
|
||||
megaStiEnable = false;
|
||||
ModeLED(NO_EVENT);
|
||||
InitEliteFlag();
|
||||
InitFlag();
|
||||
InitCT();
|
||||
InitGPT();
|
||||
|
||||
InitLED();
|
||||
InitTrigChan();
|
||||
|
||||
VinADCGainControl(VIN_GAIN_AUTO);
|
||||
IinADCGainControl(I_GAIN_AUTO);
|
||||
disable_trig_output();
|
||||
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_15K;
|
||||
VoutGainControl(INSTRUCTION.VoutGainLevel);
|
||||
DAC_outputV(Usercode_Correction_to_DAC(INSTRUCTION.VoutGainLevel, 25000));
|
||||
|
||||
initINSBuf();
|
||||
initDATBuf();
|
||||
|
||||
|
||||
for (int i = 0; i < SPI_LED_SIZE; i++) {
|
||||
spi_LEDtxbuf[i] = 0;
|
||||
spi_LEDrxbuf[i] = 0;
|
||||
}
|
||||
|
||||
for (int i = 0; i < SPI_DAC_SIZE; i++) {
|
||||
spi_DACtxbuf[i] = 0;
|
||||
spi_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
for (int i = 0; i < SPI_ADC_SIZE; i++) {
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
CPUdelay(1600);
|
||||
}
|
||||
|
||||
static void Eliteinterrupt() {
|
||||
megaStiEnable = false;
|
||||
ModeLED(NO_EVENT);
|
||||
InitFlag();
|
||||
InitEliteFlag();
|
||||
InitCT();
|
||||
InitGPT();
|
||||
|
||||
// PIN15_setOutputValue(HIGH_Z_MODE, 1); // 0 => open high_z mode
|
||||
|
||||
INSTRUCTION.VoutGainLevel = VOUT_GAIN_15K;
|
||||
VoutGainControl(INSTRUCTION.VoutGainLevel);
|
||||
DAC_outputV(Usercode_Correction_to_DAC(INSTRUCTION.VoutGainLevel, 25000));
|
||||
|
||||
initINSBuf();
|
||||
initDATBuf();
|
||||
|
||||
for (int i = 0; i < SPI_LED_SIZE; i++) {
|
||||
spi_LEDtxbuf[i] = 0;
|
||||
spi_LEDrxbuf[i] = 0;
|
||||
}
|
||||
|
||||
for (int i = 0; i < SPI_DAC_SIZE; i++) {
|
||||
spi_DACtxbuf[i] = 0;
|
||||
spi_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
for (int i = 0; i < SPI_ADC_SIZE; i++) {
|
||||
spi_ADC_txbuf[i] = 0;
|
||||
spi_ADC_rxbuf[i] = 0;
|
||||
}
|
||||
|
||||
CPUdelay(8000);
|
||||
}
|
||||
#endif
|
||||
+174
@@ -0,0 +1,174 @@
|
||||
|
||||
#ifndef ELITE_SPI
|
||||
#define ELITE_SPI
|
||||
|
||||
/*
|
||||
* Read SPI example in
|
||||
* http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/tirtos/2_14_02_22/
|
||||
* exports/tirtos_full_2_14_02_22/docs/doxygen/html/_s_p_i_c_c26_x_x_d_m_a_8h.html
|
||||
*/
|
||||
|
||||
#include <Board.h>
|
||||
#include <ti/drivers/SPI.h>
|
||||
#include <ti/drivers/dma/UDMACC26XX.h>
|
||||
#include <ti/drivers/spi/SPICC26XXDMA.h>
|
||||
#include "Elite_PIN.h"
|
||||
|
||||
/* application use SPI parameters and buffers */
|
||||
#define SPI_LED_SIZE LED_BUFF_SIZE
|
||||
#define SPI_DAC_SIZE 3
|
||||
#define SPI_ADC_SIZE 4
|
||||
#define SPI_GPIO_BUFF_SIZE 10
|
||||
|
||||
static uint16_t spi_LEDtxbuf[SPI_LED_SIZE] = {0};
|
||||
static uint16_t spi_LEDrxbuf[SPI_LED_SIZE] = {0};
|
||||
|
||||
static uint8_t spi_DACtxbuf[SPI_DAC_SIZE] = {0};
|
||||
static uint8_t spi_rxbuf[SPI_DAC_SIZE] = {0};
|
||||
|
||||
static uint8_t spi_ADC_txbuf[SPI_ADC_SIZE] = {0};
|
||||
static uint8_t spi_ADC_rxbuf[SPI_ADC_SIZE] = {0};
|
||||
|
||||
static uint16_t spi_GPIO_txbuf = 0;
|
||||
static uint16_t SPI_GPIO[SPI_GPIO_BUFF_SIZE] = {0};
|
||||
|
||||
/* system use SPI parameters */
|
||||
static SPI_Handle spiHandle0 = NULL; // SPI0 = LED
|
||||
static SPI_Handle spiHandle1 = NULL; // SPI1 = ADC +DAC
|
||||
static SPI_Params spiParams0;
|
||||
static SPI_Params spiParams1;
|
||||
static SPI_Transaction LED_transaction;
|
||||
static SPI_Transaction ADC_DAC_transaction;
|
||||
|
||||
static void ELITE15_SPI_HOLD();
|
||||
static void ELITE15_SPI_CLOSE();
|
||||
|
||||
static void Elite_SPI_init(){
|
||||
SPI_init();
|
||||
SPI_Params_init(&spiParams0);
|
||||
spiParams0.bitRate = 2000; // 12k
|
||||
spiParams0.mode = SPI_MASTER;
|
||||
spiParams0.dataSize = 16;
|
||||
spiParams0.frameFormat = SPI_POL0_PHA1;
|
||||
spiHandle0 = SPI_open(Board_SPI0, &spiParams0); // LED SPI
|
||||
|
||||
SPI_Params_init(&spiParams1);
|
||||
spiParams1.bitRate = 1000000; // 1M
|
||||
spiParams1.mode = SPI_MASTER;
|
||||
spiParams1.dataSize = 8;
|
||||
spiParams1.frameFormat = SPI_POL0_PHA1;
|
||||
spiHandle1 = SPI_open(Board_SPI1, &spiParams1); // ADC DAC SPI
|
||||
}
|
||||
|
||||
static void LED_SPI(uint8_t length, uint16_t *spi_txbuf, uint16_t *spi_rxbuf) {
|
||||
LED_transaction.count = length;
|
||||
LED_transaction.txBuf = spi_txbuf;
|
||||
LED_transaction.rxBuf = spi_rxbuf;
|
||||
|
||||
SPI_transfer(spiHandle0, &LED_transaction);
|
||||
}
|
||||
|
||||
static void ADC_SPI(uint8_t length, uint8_t *spi_txbuf, uint8_t *spi_rxbuf) {
|
||||
// PIN15_setOutputValue(ADC_CS, 0); // ADC_CS LOW
|
||||
latch_setOutputValue(LOAD0, 1);
|
||||
// PIN_setOutputValue(pin_handle, D6, 0); // ADC_CS LOW
|
||||
|
||||
ADC_DAC_transaction.count = length;
|
||||
ADC_DAC_transaction.txBuf = spi_txbuf;
|
||||
ADC_DAC_transaction.rxBuf = spi_rxbuf;
|
||||
|
||||
SPI_transfer(spiHandle1, &ADC_DAC_transaction);
|
||||
|
||||
// PIN_setOutputValue(pin_handle, D6, 1); // ADC_CS HOGH
|
||||
// update_latch_status (ADC_CS, 1);
|
||||
// PIN15_setOutputValue(ADC_CS, 1); // ADC_CS HIGH
|
||||
}
|
||||
|
||||
static void DAC_SPI(uint8_t length, uint8_t *spi_txbuf, uint8_t *spi_rxbuf) {
|
||||
// PIN15_setOutputValue(DAC_CS, 0); // DAC_CS LOW
|
||||
// PIN_setOutputValue(pin_handle, LOAD0, 1);
|
||||
// PIN_setOutputValue(pin_handle, D7, 0); // DAC_CS LOW
|
||||
//
|
||||
// ADC_DAC_transaction.count = length;
|
||||
// ADC_DAC_transaction.txBuf = spi_txbuf;
|
||||
// ADC_DAC_transaction.rxBuf = spi_rxbuf;
|
||||
//
|
||||
// SPI_transfer(spiHandle1, &ADC_DAC_transaction);
|
||||
//
|
||||
// PIN_setOutputValue(pin_handle, D7, 1); // DAC_CS HOGH
|
||||
// update_latch_status (DAC_CS, 1);
|
||||
// PIN15_setOutputValue(DAC_CS, 1); // DAC_CS HIGH
|
||||
}
|
||||
|
||||
static void ELITE15_SPI_HOLD() {
|
||||
Elite_SPI_init();
|
||||
|
||||
// PIN_setOutputValue(pin_handle, LOADA, 0); // Turn on LATCH0
|
||||
// PIN_setOutputValue(pin_handle, LOADB, 0);
|
||||
PIN_setPortOutputValue(pin_handle, 0); // stay at LOAD0
|
||||
}
|
||||
static void ELITE15_SPI_CLOSE() {
|
||||
// PIN_setOutputValue(pin_handle, LOADB, 1); // Turn off all LATCH
|
||||
// PIN_setOutputValue(pin_handle, LOADA, 1);
|
||||
PIN_setPortOutputValue(pin_handle, 0); // stay at LOAD0
|
||||
|
||||
SPI_close(spiHandle0);
|
||||
SPI_close(spiHandle1);
|
||||
}
|
||||
|
||||
/* Elite1.5 Calibration SPI */
|
||||
static void CAL_ADC_SPI(uint8_t length, uint8_t *spi_txbuf, uint8_t *spi_rxbuf) {
|
||||
// PIN15_setOutputValue(ADC_CS, 0); // ADC_CS LOW
|
||||
latch_setOutputValue(LOAD0, 1);
|
||||
// PIN_setOutputValue(pin_handle, D6, 0); // ADC_CS LOW
|
||||
|
||||
ADC_DAC_transaction.count = length;
|
||||
ADC_DAC_transaction.txBuf = spi_txbuf;
|
||||
ADC_DAC_transaction.rxBuf = spi_rxbuf;
|
||||
|
||||
SPI_transfer(spiHandle1, &ADC_DAC_transaction);
|
||||
|
||||
// PIN_setOutputValue(pin_handle, D6, 1); // ADC_CS HIGH
|
||||
// update_latch_status (ADC_CS, 1);
|
||||
// PIN15_setOutputValue(ADC_CS, 1); // ADC_CS HIGH
|
||||
}
|
||||
|
||||
static void GPIO_SPI_transfer(uint32_t *GPIO_CLK_CH, uint16_t spi_GPIO_txbuf) {
|
||||
|
||||
for (int i=0; i<SPI_GPIO_BUFF_SIZE; i++) {
|
||||
SPI_GPIO[i] = 0;
|
||||
}
|
||||
|
||||
SPI_GPIO[0] = (spi_GPIO_txbuf & 0b0000000000000001); // MOSI
|
||||
SPI_GPIO[1] = (spi_GPIO_txbuf & 0b0000000000000010);
|
||||
SPI_GPIO[2] = (spi_GPIO_txbuf & 0b0000000000000100);
|
||||
SPI_GPIO[3] = (spi_GPIO_txbuf & 0b0000000000001000);
|
||||
SPI_GPIO[4] = (spi_GPIO_txbuf & 0b0000000000010000);
|
||||
SPI_GPIO[5] = (spi_GPIO_txbuf & 0b0000000000100000);
|
||||
SPI_GPIO[6] = (spi_GPIO_txbuf & 0b0000000001000000);
|
||||
SPI_GPIO[7] = (spi_GPIO_txbuf & 0b0000000010000000);
|
||||
SPI_GPIO[8] = (spi_GPIO_txbuf & 0b0000000100000000);
|
||||
SPI_GPIO[9] = (spi_GPIO_txbuf & 0b0000001000000000);
|
||||
|
||||
ELITE15_SPI_CLOSE();
|
||||
PIN_setPortOutputValue(pin_handle, 0); // Turn on LATCH0
|
||||
add_elite_pin();
|
||||
|
||||
for (int i=9; i>=0; i--) {
|
||||
PIN_setOutputValue(pin_handle, GPIO_CLK_CH[1], 0); // generate clk signal
|
||||
PIN_setOutputValue(pin_handle, D3, SPI_GPIO[i]); // data transfer at rising edge, MOSI = D3
|
||||
PIN_setOutputValue(pin_handle, GPIO_CLK_CH[1], 1); // generate clk signal
|
||||
}
|
||||
|
||||
PIN_setOutputValue(pin_handle, GPIO_CLK_CH[1], 0);
|
||||
update_latch_status (GPIO_CLK_CH[0], GPIO_CLK_CH[1], 0);
|
||||
|
||||
PIN_setOutputValue(pin_handle, D3, 0);
|
||||
update_latch_status (ADC_SPI_MOSI, 0);
|
||||
|
||||
// PIN_setPortOutputValue(pin_handle, 0); // set all LATCH0 pin to LOW
|
||||
remove_elite_pin();
|
||||
ELITE15_SPI_HOLD();
|
||||
}
|
||||
|
||||
#endif // ELITE_SPI
|
||||
+621
@@ -0,0 +1,621 @@
|
||||
#ifndef ELITE_WORK_DATA
|
||||
#define ELITE_WORK_DATA
|
||||
|
||||
#define CLOCK_ONE_SECOND 10000
|
||||
|
||||
#include "EliteInstruction.h"
|
||||
|
||||
static bool Free_Work_Mode = false;
|
||||
typedef void (*InitWorkData) ();
|
||||
|
||||
/***** Template of Measure and VoltOut parameter *****/
|
||||
#define MEASURE \
|
||||
int32_t _measureCurrent; \
|
||||
int32_t _measureVin; \
|
||||
int32_t _measureVout; \
|
||||
int32_t _measureBat; \
|
||||
uint8_t _VoViSwitch
|
||||
|
||||
#define VOUT_PARA \
|
||||
int32_t _Vinit; \
|
||||
int32_t _Vmax; \
|
||||
int32_t _Vmin; \
|
||||
int32_t _Vset; \
|
||||
uint32_t _Vstep; \
|
||||
bool _direction_up; \
|
||||
bool _current_direction_up; \
|
||||
uint16_t _cycleNumber
|
||||
|
||||
// direction_up = true, if directionInit=1
|
||||
// current_direction_up = true, Vstep => positive. vice versa
|
||||
|
||||
/* CC Mode parameter
|
||||
* @ Measure : measure current value (nA)
|
||||
* @ Charge : Charge or Discharge
|
||||
* @ BatteryV : Vin measure battery voltage (mV)
|
||||
* @ value : constant current setting.
|
||||
* Current value divide current level into 3,000,001 pieces
|
||||
* 1,500,000 is zero point; 3,000,000 is 15mA
|
||||
* Current = (value - 1,500,000)/100,000 mA
|
||||
* @ Done : Done = false => Ignore Vmin condition;
|
||||
* Done will be true, if BatteryV <= Vmin last for about 12sec in discharge mode
|
||||
* @ VMax : voltage upper bound in charge mode
|
||||
* CC->value will set to zero if BatteryV >= VMax in charge mode
|
||||
* @ VMin : voltage lower bound in charge mode
|
||||
* CC->value will set to zero if BatteryV <=> VMin in charge mode
|
||||
* Note that VMax and VMin are always larger or equal to zero
|
||||
* @_Transform2RealnA : transform a current user code (IUC) to real current in nA
|
||||
*/
|
||||
#define CC_PARA \
|
||||
int32_t _measureCurrent; \
|
||||
uint8_t _VoViSwitch; \
|
||||
uint8_t Charge; \
|
||||
int32_t BatteryV; \
|
||||
int32_t value; \
|
||||
uint16_t Done; \
|
||||
uint32_t VMax; \
|
||||
uint16_t VMin; \
|
||||
int32_t _measureVin; \
|
||||
int32_t Vset; \
|
||||
int32_t Iset; \
|
||||
int32_t (*_Transform2RealnA)(struct CCModePara *)
|
||||
|
||||
#define LIMIT \
|
||||
uint32_t _LimitValue; \
|
||||
void (*SetLimitValue) (struct Limit *, uint32_t); \
|
||||
uint32_t (*GetLimitValue) (struct Limit*)
|
||||
|
||||
struct Measure{
|
||||
MEASURE;
|
||||
};
|
||||
|
||||
struct VoltOutPara{
|
||||
VOUT_PARA;
|
||||
};
|
||||
|
||||
struct Limit{
|
||||
LIMIT;
|
||||
};
|
||||
|
||||
struct CCModePara{
|
||||
CC_PARA;
|
||||
};
|
||||
/***** End of Measure and VoltOut parameter *****/
|
||||
|
||||
/**** Limit Mode ****/
|
||||
//LimitValue
|
||||
void _SetLimitValue(struct Limit *self, uint32_t LimitValue){
|
||||
self->_LimitValue = LimitValue;
|
||||
}
|
||||
uint32_t _GetLimitValue(struct Limit *self){
|
||||
return self->_LimitValue;
|
||||
}
|
||||
|
||||
|
||||
/* VoltOut Mode Data */
|
||||
typedef struct _VoltOutMode{
|
||||
uint16_t _Vset;
|
||||
}VoltOutMode;
|
||||
|
||||
VoltOutMode *InitVoltOutMode(){
|
||||
VoltOutMode *ret = malloc(sizeof(VoltOutMode));
|
||||
ret->_Vset = INSTRUCTION.VoltConstant;
|
||||
return ret;
|
||||
}
|
||||
/* End of VoltOut Mode Data */
|
||||
|
||||
/* IT Mode Data */
|
||||
typedef struct _ITMode{
|
||||
MEASURE;
|
||||
}ITMode;
|
||||
|
||||
ITMode * InitITMode(){
|
||||
ITMode *ret = malloc(sizeof(ITMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
return ret;
|
||||
}
|
||||
/* End of IT Mode Data */
|
||||
|
||||
/* VT Mode Data */
|
||||
typedef struct _VTMode{
|
||||
MEASURE;
|
||||
}VTMode;
|
||||
|
||||
VTMode * InitVTMode(){
|
||||
VTMode *ret = malloc(sizeof(VTMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
return ret;
|
||||
}
|
||||
/* End of VT Mode Data */
|
||||
|
||||
/* RT Mode Data */
|
||||
typedef struct _RTMode{
|
||||
MEASURE;
|
||||
int32_t _Vset;
|
||||
}RTMode;
|
||||
|
||||
RTMode * InitRTMode(){
|
||||
RTMode *ret = malloc(sizeof(RTMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vset = INSTRUCTION.VoltConstant;
|
||||
return ret;
|
||||
}
|
||||
/* End of RT Mode Data */
|
||||
|
||||
/* IV Mode Data */
|
||||
typedef struct _IVMode{
|
||||
MEASURE;
|
||||
VOUT_PARA;
|
||||
}IVMode;
|
||||
|
||||
IVMode *InitIVMode(){
|
||||
IVMode *ret = malloc(sizeof(IVMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vinit = (INSTRUCTION.Vinit - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmax = (INSTRUCTION.Vmax - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmin = (INSTRUCTION.Vmin - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
ret->_Vstep = 0;
|
||||
ret->_direction_up = true;
|
||||
ret->_current_direction_up = true;
|
||||
ret->_cycleNumber = INSTRUCTION.cycleNumber;
|
||||
return ret;
|
||||
}
|
||||
/* End of IV Mode Data */
|
||||
|
||||
/* CV Mode(CYCLE_IV)*/
|
||||
typedef struct _CVMode{
|
||||
MEASURE;
|
||||
VOUT_PARA;
|
||||
}CVMode;
|
||||
|
||||
CVMode * InitCVMode(){
|
||||
CVMode *ret = malloc(sizeof(CVMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vinit = (INSTRUCTION.Vinit - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmax = (INSTRUCTION.Vmax - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmin = (INSTRUCTION.Vmin - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
ret->_Vstep = 0;
|
||||
ret->_direction_up = true;
|
||||
ret->_current_direction_up = true;
|
||||
ret->_cycleNumber = INSTRUCTION.cycleNumber;
|
||||
return ret;
|
||||
}
|
||||
/*End of CV Mode*/
|
||||
|
||||
/* CC Mode(CONSTANT_CURRENT)*/
|
||||
#define CC_ZERO_POINT 0
|
||||
#define MAX_DAC_UC 50000
|
||||
#define MIN_DAC_UC 0
|
||||
/*********************************************************************
|
||||
* @fn Transform2RealnA
|
||||
*
|
||||
* @brief transform an IUC into real current value in nA.
|
||||
*
|
||||
* @param self, which is an IUC
|
||||
*
|
||||
* @return an int32_t current value in nA
|
||||
*/
|
||||
int32_t _Transform2RealnA(struct CCModePara *self){
|
||||
int32_t IUCReal;
|
||||
|
||||
// self->value : 0 ~ 1500000 (which is 0 ~ 1500000 (10nA) )
|
||||
if(self->Charge){
|
||||
IUCReal = (self->value - CC_ZERO_POINT) * 10;
|
||||
}
|
||||
else{
|
||||
IUCReal = -1 * (self->value - CC_ZERO_POINT) * 10;
|
||||
}
|
||||
return IUCReal;
|
||||
}
|
||||
|
||||
typedef struct _CCMode{
|
||||
MEASURE;
|
||||
int32_t _Vmax;
|
||||
int32_t _Vmin;
|
||||
int32_t _Vset;
|
||||
int32_t _Iset;
|
||||
uint8_t _charge;
|
||||
int32_t (*_Transform2RealnA)(struct CCModePara *);
|
||||
}CCMode;
|
||||
|
||||
CCMode * InitCCMode(){
|
||||
CCMode *ret = malloc(sizeof(CCMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vmax = (INSTRUCTION.Vmax - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmin = (INSTRUCTION.Vmin - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
ret->_Iset = INSTRUCTION.constantCurrent * 200 ; //[50pA] //controller UI 15000uA => Elite 1500000 => 1500000 * 10 * 1000 / 50 [50pA]
|
||||
ret->_charge = INSTRUCTION.charge;
|
||||
ret->_Transform2RealnA = &_Transform2RealnA;
|
||||
return ret;
|
||||
}
|
||||
/*End of CC Mode*/
|
||||
|
||||
/* CV3 Mode(CYCLIC_VOLTAMMETRY)*/
|
||||
typedef struct _CV3Mode{
|
||||
MEASURE;
|
||||
VOUT_PARA;
|
||||
}CV3Mode;
|
||||
|
||||
CV3Mode * InitCV3Mode(){
|
||||
CV3Mode *ret = malloc(sizeof(CV3Mode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vinit = (INSTRUCTION.Vinit - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmax = (INSTRUCTION.Vmax - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmin = (INSTRUCTION.Vmin - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
ret->_Vstep = 0;
|
||||
ret->_direction_up = true;
|
||||
ret->_current_direction_up = true;
|
||||
ret->_cycleNumber = INSTRUCTION.cycleNumber;
|
||||
return ret;
|
||||
}
|
||||
/*End of CV3 Mode*/
|
||||
|
||||
/* LSV Mode(LINEAR_SWEEP_VOLTAMMETRY)*/
|
||||
typedef struct _LSVMode{
|
||||
MEASURE;
|
||||
VOUT_PARA;
|
||||
}LSVMode;
|
||||
|
||||
LSVMode * InitLSVMode(){
|
||||
LSVMode *ret = malloc(sizeof(LSVMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vinit = (INSTRUCTION.Vinit - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmax = (INSTRUCTION.Vmax - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vmin = (INSTRUCTION.Vmin - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
ret->_Vstep = 0;
|
||||
ret->_direction_up = true;
|
||||
ret->_current_direction_up = true;
|
||||
ret->_cycleNumber = INSTRUCTION.cycleNumber;
|
||||
return ret;
|
||||
}
|
||||
/*End of LSV Mode*/
|
||||
|
||||
/* CONSTANT_VSCAN Mode(CONSTANT_VSCAN)*/
|
||||
typedef struct _CVSCANMode{
|
||||
MEASURE;
|
||||
int32_t _Vinit;
|
||||
int32_t _Vset;
|
||||
}CVSCANMode;
|
||||
|
||||
CVSCANMode * InitCVSCANMode(){
|
||||
CVSCANMode *ret = malloc(sizeof(CVSCANMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vinit = (INSTRUCTION.Vinit - 25000) * 4 * 10000; //[5nV]
|
||||
ret->_Vset = 0;
|
||||
return ret;
|
||||
}
|
||||
/*End of CONSTANT_VSCAN Mode*/
|
||||
|
||||
/* PULSE_MODE Mode(PULSE_MODE)*/
|
||||
typedef struct _PULSEMode {
|
||||
MEASURE;
|
||||
int32_t _Vset;
|
||||
int32_t _sti_v1;
|
||||
int32_t _sti_v2;
|
||||
int32_t _sti_v3;
|
||||
int32_t _sti_v4;
|
||||
int32_t _sti_v5;
|
||||
int32_t _sti_v6;
|
||||
int32_t _sti_v7;
|
||||
int32_t _sti_t1;
|
||||
int32_t _sti_t2;
|
||||
int32_t _sti_t3;
|
||||
int32_t _sti_t4;
|
||||
int32_t _sti_t5;
|
||||
int32_t _sti_t6;
|
||||
int32_t _sti_t7;
|
||||
int32_t _sti_t;
|
||||
int32_t _sti_v; //output voltage now
|
||||
int32_t _sti_t_flag; //Where's the time stage turn
|
||||
uint16_t _sti_cy;
|
||||
uint16_t _sti_lp;
|
||||
} PULSEMode;
|
||||
|
||||
PULSEMode * InitPULSEMode() {
|
||||
PULSEMode *ret = malloc(sizeof(PULSEMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->_measureVin = 0;
|
||||
ret->_measureVout = 0;
|
||||
ret->_measureBat = 0;
|
||||
ret->_VoViSwitch = INSTRUCTION.VoViSwitch;
|
||||
ret->_Vset = 0;
|
||||
ret->_sti_v1 = INSTRUCTION.sti_v1;
|
||||
ret->_sti_v2 = INSTRUCTION.sti_v2;
|
||||
ret->_sti_v3 = INSTRUCTION.sti_v3;
|
||||
ret->_sti_v4 = INSTRUCTION.sti_v4;
|
||||
ret->_sti_v5 = INSTRUCTION.sti_v5;
|
||||
ret->_sti_v6 = INSTRUCTION.sti_v6;
|
||||
ret->_sti_v7 = INSTRUCTION.sti_v7;
|
||||
ret->_sti_t1 = INSTRUCTION.sti_t1;
|
||||
ret->_sti_t2 = INSTRUCTION.sti_t2;
|
||||
ret->_sti_t3 = INSTRUCTION.sti_t3;
|
||||
ret->_sti_t4 = INSTRUCTION.sti_t4;
|
||||
ret->_sti_t5 = INSTRUCTION.sti_t5;
|
||||
ret->_sti_t6 = INSTRUCTION.sti_t6;
|
||||
ret->_sti_t7 = INSTRUCTION.sti_t7;
|
||||
ret->_sti_t = INSTRUCTION.sti_t1;
|
||||
ret->_sti_v = INSTRUCTION.sti_v1;
|
||||
ret->_sti_t_flag = 1;
|
||||
ret->_sti_cy = INSTRUCTION.sti_cy;
|
||||
ret->_sti_lp = INSTRUCTION.sti_loop;
|
||||
return ret;
|
||||
}
|
||||
/*End of PULSE_MODE Mode*/
|
||||
|
||||
/* Cycle CC Mode */
|
||||
typedef struct _CCCMode{
|
||||
int32_t _measureCurrent;
|
||||
uint8_t _VoViSwitch;
|
||||
uint8_t Charge;
|
||||
int32_t BatteryV;
|
||||
int32_t value;
|
||||
uint16_t Done;
|
||||
uint32_t VMax;
|
||||
uint32_t VMin;
|
||||
int32_t _measureVin;
|
||||
int32_t Vset;
|
||||
int32_t Iset;
|
||||
int32_t (*_Transform2RealnA)(struct CCModePara *);
|
||||
|
||||
/* Vmax and Vmin */
|
||||
// Vmax protect battery charge
|
||||
// Vmin protect battery discharge, uint = mV
|
||||
|
||||
/* Charge/Discharge Current */
|
||||
int32_t ChargeCurrent;
|
||||
int32_t DischargeCurrent;
|
||||
uint8_t CycleNumber;
|
||||
|
||||
bool StandBy;
|
||||
uint32_t StandByTime;
|
||||
}CCCMode;
|
||||
|
||||
CCCMode * InitCCCMode(){
|
||||
CCCMode *ret = malloc(sizeof(CCCMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->Charge = 1;
|
||||
ret->BatteryV = 0;
|
||||
|
||||
ret->value = CC_ZERO_POINT;
|
||||
ret->VMax = MAX_DAC_UC; // max DAC UserCode
|
||||
ret->VMin = MIN_DAC_UC; // min DAC UserCode
|
||||
ret->ChargeCurrent = 0;
|
||||
ret->DischargeCurrent = 0;
|
||||
ret->CycleNumber = 0;
|
||||
ret->StandBy = false;
|
||||
ret->StandByTime = 0;
|
||||
ret->_Transform2RealnA = &_Transform2RealnA;
|
||||
return ret;
|
||||
}
|
||||
/* End of Cycle CC Mode */
|
||||
|
||||
/** Potential State Mode **/
|
||||
typedef struct _PS{
|
||||
// measure
|
||||
int32_t _measureCurrent;
|
||||
uint8_t _VoViSwitch;
|
||||
int32_t ReferenceVolt;
|
||||
int32_t _MeasureVolt;
|
||||
uint16_t _VoltOut;
|
||||
uint16_t _originVolt;
|
||||
uint16_t _stopVolt;
|
||||
uint16_t _step;
|
||||
uint16_t _StepTime;
|
||||
uint16_t _cycleNumber;
|
||||
}PSMode;
|
||||
|
||||
PSMode *InitPSMode(){
|
||||
PSMode *ret = malloc(sizeof(PSMode));
|
||||
ret->_measureCurrent = 0;
|
||||
ret->ReferenceVolt = 0;
|
||||
ret->_MeasureVolt = INSTRUCTION.Ve1;
|
||||
|
||||
ret->_VoltOut = DAC_ZERO; // 25000 is DAC_ZERO
|
||||
ret->_originVolt = INSTRUCTION.Ve1;
|
||||
ret->_stopVolt = INSTRUCTION.Ve2;
|
||||
ret->_step = INSTRUCTION.step;
|
||||
ret->_StepTime = INSTRUCTION.StepTime; // STEPTIME_ONE_SEC
|
||||
ret->_cycleNumber = INSTRUCTION.cycleNumber;
|
||||
return ret;
|
||||
}
|
||||
/** End of Potential State Mode **/
|
||||
|
||||
typedef union _WorkMode{
|
||||
|
||||
// Output Only
|
||||
VoltOutMode *VO;
|
||||
|
||||
// Measure only
|
||||
ITMode *IT;
|
||||
VTMode *VT;
|
||||
|
||||
// Measure + Output
|
||||
RTMode *RT;
|
||||
IVMode *IV;
|
||||
CVMode *CV;
|
||||
CCMode *CC;
|
||||
CV3Mode *CV3;
|
||||
LSVMode *LSV;
|
||||
CVSCANMode *CVSCAN;
|
||||
PSMode *PS;
|
||||
PULSEMode *PULSE;
|
||||
// CCCMode *CCC;
|
||||
}WorkMode;
|
||||
|
||||
WorkMode *CreateWorkMode(){
|
||||
WorkMode *ret = malloc(sizeof(WorkMode));
|
||||
return ret;
|
||||
}
|
||||
|
||||
void InitWorkMode(WorkMode *WM){
|
||||
switch(INSTRUCTION.eliteFxn){
|
||||
case VOLT_OUTPUT:
|
||||
case CALI_DAC_MODE:
|
||||
WM->VO = InitVoltOutMode();
|
||||
break;
|
||||
case IT_CURVE:
|
||||
WM->IT = InitITMode();
|
||||
break;
|
||||
case VT_CURVE:
|
||||
WM->VT = InitVTMode();
|
||||
break;
|
||||
case ZT_CURVE:
|
||||
WM->RT = InitRTMode();
|
||||
break;
|
||||
case IV_CURVE:
|
||||
WM->IV = InitIVMode();
|
||||
break;
|
||||
case CV_CURVE:
|
||||
WM->CV = InitCVMode();
|
||||
break;
|
||||
case CONSTANT_CURRENT:
|
||||
WM->CC = InitCCMode();
|
||||
break;
|
||||
case CYCLIC_VOLTAMMETRY:
|
||||
WM->CV3 = InitCV3Mode();
|
||||
break;
|
||||
case LINEAR_SWEEP_VOLTAMMETRY:
|
||||
WM->LSV = InitLSVMode();
|
||||
break;
|
||||
case CONSTANT_VSCAN:
|
||||
WM->CVSCAN = InitCVSCANMode();
|
||||
break;
|
||||
case PULSE_MODE:
|
||||
WM->PULSE = InitPULSEMode();
|
||||
break;
|
||||
// case CYCLE_CONSTANT_CURRENT:
|
||||
// WM->CCC = InitCCCMode();
|
||||
// break;
|
||||
default:
|
||||
WM->VT = InitVTMode();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void FreeWorkMode(WorkMode *WM){
|
||||
switch(INSTRUCTION.eliteFxn){
|
||||
case VOLT_OUTPUT:
|
||||
case CALI_DAC_MODE:
|
||||
if(WM->VO != NULL){
|
||||
free(WM->VO);
|
||||
WM->VO = NULL;
|
||||
}
|
||||
break;
|
||||
case IT_CURVE:
|
||||
if(WM->IT != NULL){
|
||||
free(WM->IT);
|
||||
WM->IT = NULL;
|
||||
}
|
||||
break;
|
||||
case VT_CURVE:
|
||||
if(WM->VT != NULL){
|
||||
free(WM->VT);
|
||||
WM->VT = NULL;
|
||||
}
|
||||
break;
|
||||
case ZT_CURVE:
|
||||
if(WM->RT != NULL){
|
||||
free(WM->RT);
|
||||
WM->RT = NULL;
|
||||
}
|
||||
break;
|
||||
case IV_CURVE:
|
||||
if(WM->IV != NULL){
|
||||
free(WM->IV);
|
||||
WM->IV = NULL;
|
||||
}
|
||||
break;
|
||||
case CV_CURVE:
|
||||
if(WM->CV != NULL){
|
||||
free(WM->CV);
|
||||
WM->CV = NULL;
|
||||
}
|
||||
break;
|
||||
case CONSTANT_CURRENT:
|
||||
if(WM->CC != NULL){
|
||||
free(WM->CC);
|
||||
WM->CC = NULL;
|
||||
}
|
||||
break;
|
||||
case CYCLIC_VOLTAMMETRY:
|
||||
if(WM->CV3 != NULL){
|
||||
free(WM->CV3);
|
||||
WM->CV3 = NULL;
|
||||
}
|
||||
break;
|
||||
case LINEAR_SWEEP_VOLTAMMETRY:
|
||||
if(WM->LSV != NULL){
|
||||
free(WM->LSV);
|
||||
WM->LSV = NULL;
|
||||
}
|
||||
break;
|
||||
case CONSTANT_VSCAN:
|
||||
if(WM->CVSCAN != NULL){
|
||||
free(WM->CVSCAN);
|
||||
WM->CVSCAN = NULL;
|
||||
}
|
||||
break;
|
||||
case PULSE_MODE:
|
||||
if(WM->PULSE != NULL){
|
||||
free(WM->PULSE);
|
||||
WM->PULSE = NULL;
|
||||
}
|
||||
break;
|
||||
// case CYCLE_CONSTANT_CURRENT:
|
||||
// if(WM->CCC != NULL){
|
||||
// free(WM->CCC);
|
||||
// WM->CCC = NULL;
|
||||
// }
|
||||
// break;
|
||||
default:
|
||||
if(WM->VT != NULL){
|
||||
free(WM->VT);
|
||||
WM->VT = NULL;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user