**** BEGIN LOGGING AT Tue Jul 16 03:02:17 2019 Jul 16 04:50:09 abhishek_: I will have to go to college today for registration of courses, will resume work as soon as I return. Jul 16 05:31:22 Ok Jul 16 13:17:33 julieng: probably I shouldn't set up interrupts for nodes with "status=disabled" property ? Jul 16 13:28:37 embden[m]: Hmmm, the property indicates the device is not operational yet but might become later on. So technically, we should set up the interrupts for those nodes. Jul 16 13:28:44 I guess you are asking the question because of Dom0? Jul 16 13:40:02 julieng: I think I've done a small mistake somewhere, because I can see only around 100 node with interrupts property. So, they should fit Jul 16 13:43:40 embden[m]: interrupts property may contain one or more interrupts. Jul 16 13:45:46 embden[m]: So it is quite possible to have exhaust the number of GIC interrupts. Jul 16 13:46:09 julieng: what is the format of the additional interrupts? and how to deal with it? Jul 16 13:47:08 embden[m]: For the device linked to the GIC interrupts property will look like Jul 16 13:47:15 So 3 cells per interrupt Jul 16 13:47:50 We discussed about the meaning of each cells yesterday. Jul 16 13:48:01 The code in Xen is already able to cater with that. Jul 16 13:48:15 Now the problem is whether we want to route all the interrupts while building Xen. Jul 16 13:48:32 As the number of GIC interrupts is limited, it might be wiser to dynamically configure the routing. Jul 16 13:49:31 embden[m]: But before looking at this problem, I would try to make sure the UART is up and running so you can validate your crossbar driver is doing the right thing. Jul 16 14:30:22 julieng: I've just count - there are 175 different interrupts in the dt Jul 16 14:30:54 hm, wait Jul 16 14:32:50 yes, 175 Jul 16 14:53:52 embden[m]: But the crossbar can only route 160 interrupts (see ti,max-irqs property). Jul 16 14:54:36 julieng: so, I just mapped all the interrupts after 160 to 159th line Jul 16 14:55:15 though, it is a terrible idea probably because in the last 15 interrupts there are irqs from mmu Jul 16 15:49:26 embden[m]: I don't think we can all statically route interrupts in the crossbar. We will have to do some of them (any interrupts routed to Dom0) dynamically so the domain can decide what it wants to use. Jul 16 15:58:49 julieng: So, I tried to map only enabled devices. But it doesn't respond to triple Ctrl+A Jul 16 15:59:07 and doesn't boot dom0 Jul 16 16:02:05 https://github.com/embeddedden/xen/commit/e16a32cfa7abb895c39e8bcffb05d30d4b9533b0 Jul 16 16:12:08 embden[m]: Your function crossbar_translate doesn't look correct to me. Jul 16 16:13:06 Particularly these 2 lines: Jul 16 16:13:09 + writel(max_busy_irq_number+1, Jul 16 16:13:11 + base_ctrl+max_busy_irq_number*4); Jul 16 16:13:23 I would have expected you have the crossbar interrupt ID in hand. Jul 16 16:14:37 But here you seem to increment an index and then write this into the crossbar. Jul 16 16:18:08 embden[m]: Can you explain why you are doing this? Jul 16 16:21:37 julieng: yes, I also got to this conclusion Jul 16 16:21:47 So, working on it right now Jul 16 16:23:13 (to the conclusion that something really wrong with the function) Jul 16 17:05:59 .julieng am I right that I can write on byte-aligned addresses? or should the addresses be aligned to 4-byte boundary? Jul 16 17:07:56 The alignment should match the size you write. IOW, if you write a 32-bit value then it should be 32-bit aligned. Jul 16 17:08:32 Xen on Arm32 has been configured to check the alignment. So it will throw you an error if you don't align properly Jul 16 17:10:43 ok, thank you Jul 16 17:26:06 zeekhuge abhishek_ I am unable to correctly send interrupt to PRU1 after PRU0 completes sending pulses to the motor-driver. Jul 16 17:26:10 PRU0 firmware: https://github.com/pratimugale/PRUSS-Bindings/blob/sandbox/examples/firmware_examples/example7-stepper-control/PRU0/main_pru0.c Jul 16 17:26:46 PRU1: https://github.com/pratimugale/PRUSS-Bindings/blob/sandbox/examples/firmware_examples/example7-stepper-control/PRU1/main.c Jul 16 17:28:06 julieng: https://github.com/embeddedden/xen/commit/7644806dd38a71a8770b80bfd8d0717af72a9eae Jul 16 17:28:07 now it switches on triple Ctrl+A ! Jul 16 17:28:32 embden[m]: Congrats! Jul 16 17:29:51 julieng: I will continue to work on it tomorrow and also will push that old patch about switching to hyp mode Jul 16 17:34:32 zeekhuge: The interrupt works correctly if is is triggered (and configured) before the start() statement https://github.com/pratimugale/PRUSS-Bindings/blob/6170bc64c43f722b11f4d2f67083107e986fa3e1/examples/firmware_examples/example7-stepper-control/PRU0/main_pru0.c#L40 Jul 16 17:36:05 i.e. if configIntc() and PRU0_PRU1_TRIGGER are executed before start() Jul 16 17:36:42 * zeekhuge[m] trying to go through pratimugale 's code Jul 16 17:37:16 Okay, so I think its that classical confusion. Jul 16 17:37:41 pratimugale: So, do you know that PRU interrupts don't really interrupt ? Jul 16 17:38:24 Yes Jul 16 17:39:10 I have read about it Jul 16 17:40:32 So, what the problem exactly then ? Can you please elaborate ? Jul 16 17:41:16 about how PRU doesn't support asynchronous interrupts and uses specialized instructions for polling of events Jul 16 17:42:01 zeekhuge: I want to interrupt PRU1 once PRU0 is done sending its pulses Jul 16 17:42:42 After which PRU1 will notify the ARM through rpmsg channel Jul 16 17:42:58 So that multiple commands aren't sent to the stepper motor at once Jul 16 17:47:38 The linux side will wait until it gets the message from pru Jul 16 17:47:55 zeekhuge: i am able to run the program correctly and also some little suggestion on the pins that i should use for now to remove the high frequency signal which i encounter during my test on the logic analyzer . i get on my problem solved thanks from @zmatt in the #beagle irc grp . I had implemented that liittle bit can see the updated code : Jul 16 17:47:55 https://github.com/pranav083/pocket_beagle-work/blob/wip/pru_wip/74hc299_10_v1.p in here . Now changing all the pins which lies in p8_07-19 as it does not conflicts with the eMMC as suggested by @zmatt Jul 16 18:03:59 pratimugale: You are using HOST1 for both the rpmsg and pru0-to-pru1 ? Jul 16 18:07:06 pratimugale: yes ? Jul 16 18:07:48 rpmsg uses same host1 for the interrupt events Jul 16 18:07:54 and your configuration maps the pru0-to-pru1 interrupt to host1 as well. Jul 16 18:08:08 yes Jul 16 18:08:09 that's what it seems like Jul 16 18:08:59 pratimugale: You will have to use different hosts : https://github.com/ZeekHuge/BeagleScope/blob/master/examples/firmware_exmples/pru1_to_pru0_to_arm/main_pru0.c#L50 Jul 16 18:09:21 zeekhuge: im having dinner, will look into it in 5 mins Jul 16 18:09:28 sure. Jul 16 18:11:51 @zeekhuge can you suggest any thing why i am getting voltage drop when logic is high on the I/O pins of the shift register which is only 2.6v for the high logic . All the circuit is powered by beaglebone only Jul 16 18:13:49 pranav_kumar: why do you need the shift register ? Jul 16 18:16:44 just to do bidirctional async communication between multiple devices without getting much effected by thier operating frequency. Jul 16 18:17:26 pranav_kumar: what are *.p file ? They are the assembly files, right ? when why not use .asm as the extension ? (allows for auto code highlighting, and easily readable). Also, why are their so many *.bin files ? Use ".gitignore" to prevent them from getting commited. Jul 16 18:18:44 ok i will remove all those *.bin file .Thanks for the suggestion Jul 16 18:23:24 pranav_kumar: I can't be sure about lower voltage, but I'd suggest to use an adpater to power BBB instead of using laptop/system Jul 16 18:23:56 s/adpater/adapter Jul 16 18:25:53 zeekhuge: I get it now, will update after trying to use different hosts Jul 16 18:26:41 pratimugale: great. Jul 16 18:27:20 ok , i will get 5v dc adapter for the market tommorow. Jul 16 18:29:32 btw, make sure you are careful with BBB gpios. They can source something like 8mA only. Jul 16 18:30:15 pranav_kumar: ^ Jul 16 18:31:26 i have studied somewhere that it can give only 4mA of power through the GPIO pins. Probably in the derek molloy lectures i guess Jul 16 18:32:16 okay. Then believe on 4mA thing Jul 16 18:32:44 though i pass all my logic through the logic level converter . so , i dont think i would be a big problem for me. Jul 16 18:35:27 as the shift register runs on 5v logic . And it is a bidirectional logic level converter. that is this TXB0108 ic **** ENDING LOGGING AT Wed Jul 17 02:59:57 2019