Jump to content
Issues with Images is known, we are working on it. ×

Cosmik42

Eurobricks Citizen
  • Posts

    267
  • Joined

  • Last visited

Everything posted by Cosmik42

  1. It's an open source project that was only meant for me. Feel free to contribute state of the art programming! 😘
  2. Glad you fixed it! Was about to come reply to try just that :)
  3. Thank you kindly sir! Your energy and passion in this forum was a great source of inspiration to continue working on this project.
  4. Hi everyone, I have finally release the source code of this project. My life choices simply prevent me to engage further in this project, and it would be stupid not have the community take over and make it even better! You can download the full source code here: https://github.com/Cosmik42/BAP Feel free to upload some pull-request and help improve this software!
  5. I am affraid this is a tricky one. Not sure I can fix it. This module is certainly far from perfect. Rethinking train detection to actually know when a train leaves a section would be a huge improvement. For now it is assumed the train leaves the section within a certain timeframe. That should be doable! So very hard to say! :(
  6. Wow !!! <3 Very hard for me to find any time for this project anymore. But I will try! Do you still experience the issue? Thanks for all the kind words. Happy this is useful for more people :) I do not own the Wedo 1 hardware, which is why it was never implemented. But beyond that, the whole mindset was a BLE centric thinking.
  7. @collectormania - If you manage to recode the LEGO protocol, then yes, you could attach any custom hardware and BAP will integrate it. However, I am not aware of any projects who have tried to reimplement this protocol. It is, however, well documented and could be a worty endeavour? If you do throw yourself on this, keep us posted! Otherwise no, BAP cannot communicate with any other custom protocols and do not support natively 4DBrix switches unfortunately. The lack of BT support from 4DBrix made it harder to integrate in the current BAP stack. You can set it like this : Hub[0].SpeedCoefficient = 1.0f;
  8. Hi Nivst - You have 2 arrays - the Hub[0]. This error could trigger if you did not connect your device. The second one State[] - I just verified and 99 should work, but to avoid any issue, start from State[0], State[1]. etc.
  9. Unfortunately what you get is what the API gives me! You can set it in the option of each hub inside BAP.
  10. Very good thinking forward! I would then not make a 'wait 5 second' but wait for the other wagon to reach another trigger.
  11. Hi Walt, you are going for an overcomplicated solution here, and unfortunately you cannot use Threads because they cannot access the Hubs which are not a static member. Watching your video, I think all of this can be accomplished with simple events like If train 1 arrive at sensor 1 => Execute Sequence. (Sequence could like this: "stop for 4 seconds. Then resume at speed s".
  12. Did you try to reboot your computer? This has solved this kind of issue for me in the past.
  13. Closer is what I meant. I am not 100% sure what you are trying to achieve, but you can check the option to allow getting into a section only if the very next is free to.
  14. Are you using PUP Sensors or PF Sensors? PF Sensors via SBrick are horribly difficult to use because their sensitivity depends on the battery level of the SBrick host! I would recommend to stick with PUP sensors. If you are using PUP sensors, then make sure the distance you use is high enough to trigger when the train passes in front of it.
  15. I confirm that I myself run 12 to 14 devices with BAP at once without issues.
  16. Option 1 is made this way because sections can be be freed even if a train has not fully left it. As soon as a train is allowed to move to the next section, a cool down is trigger. Once this cool down is over, the current section is freed and the next train can enter it. This is made in a way to fluidify traffic and also allow to run 2 trains with as little as 3 sections. Without it you would need more sections and traffic would be stopped all the time. Option 2 detects if the next section is free or not. If not, we can prevently slowdown the train before it stops completely when hitting the end of the current section. Option 3 is to deal with different battery level. If a battery is getting low, you can punch this coffecient up to achieve the same speed accross by just virtually increasing speed. Hope it helps.
  17. Then it is another form of hardware limitation from your built-in bluetooth hub I am affraid. Try with a dongle! As for your message, the way this works is simplified. Basically as soon as you enter a new section, there is a cool-down set at the configuratuion level of the train to define such value.
  18. Hi TuxTown! Thanks for trying BAP. What you are experiencing is due to your bluetooth dongle and you are simply seeing the limit of BLE device yours can connect to. I found a dongle that can connect up to 14 simultaneous devices. The original link below shows that it is not available anymore, but maybe you can find it somewhere else? https://www.amazon.de/dp/B007MKMJGO/ref=pe_3044161_185740101_TE_item?fbclid=IwAR1abc9ElM11bo_vzv6oeAsiEFAxxDdodY9MwihJGgYQrP2meCM_RD5zwbs The best option is always built-in bluetooth because the only limitation to the number of device you can connect with is linked to RAM consuption of the dongle. Don't worry guys. I am still here. Just hardly available, but even though I don't comment often here, I do answer most of my PM. My company has grown from 6 people to almost 20, and that keeps me busy way beyond the usual 9-5pm. I guess it's a good problem to have, but it's not super compatible with hobby time :) However I recently kinda find a new pocket of time and I am looking at spending some time again on the software. So I will be more active here as well as on the FB group. Cheers!
  19. Are you simply looking at the display on screen? If so, it does not necesseraly refresh in real time. However, try to create an event trigger and see if the event is captured there. Maybe my software is too strict in detection to avoid false positive. I will give it a look tonight.
  20. Sorry Speedy, I looked at this SDK 7-8 months ago, have not opened it since and will not have the time to do this for you. I encourage you to downlowd the SDK, start it up and start playing with it. It is fairly well documented.
  21. Actually lego has one! That's how I started this project! https://education.lego.com/en-us/support/wedo-2/developer-kits It is specifically for WeDo 2.0 and is in C#!
  22. Oh did not know about the feature. No idea yet then. Will let you know.
×
×
  • Create New...